diff options
author | tmzullinger <tmzullinger@f01d2545-417e-4e96-918e-98f8d0dbbcb6> | 2007-04-16 04:36:33 +0000 |
---|---|---|
committer | tmzullinger <tmzullinger@f01d2545-417e-4e96-918e-98f8d0dbbcb6> | 2007-04-16 04:36:33 +0000 |
commit | 1697dc8977f5236d4223456137c09e2fb7227c85 (patch) | |
tree | 0945ac33e28e5abd5928f2f8bd730f3eb3aa818f /bindings | |
parent | d94eed2291a0bb14ad9d8514aeaa28a4121b1f84 (diff) | |
download | libgpod-1697dc8977f5236d4223456137c09e2fb7227c85.tar.gz libgpod-1697dc8977f5236d4223456137c09e2fb7227c85.tar.xz libgpod-1697dc8977f5236d4223456137c09e2fb7227c85.zip |
put down the pipe and commit something that should actually work...
git-svn-id: https://gtkpod.svn.sf.net/svnroot/gtkpod/libgpod/trunk@1416 f01d2545-417e-4e96-918e-98f8d0dbbcb6
Diffstat (limited to 'bindings')
-rw-r--r-- | bindings/python/ipod.py | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/bindings/python/ipod.py b/bindings/python/ipod.py index 03bf4c9..2ff0b89 100644 --- a/bindings/python/ipod.py +++ b/bindings/python/ipod.py @@ -385,7 +385,8 @@ class Track: def copy_to_ipod(self): """Copy the track to the iPod.""" self['userdata']['sha1_hash'] = gtkpod.sha1_hash(self._userdata_into_default_locale('filename')) - if not gpod.itdb_get_mountpoint(self._track.itdb): + mp = gpod.itdb_get_mountpoint(self._track.itdb) + if not mp: return False if gpod.itdb_cp_track_to_ipod(self._track, self._userdata_into_default_locale('filename'), @@ -393,8 +394,9 @@ class Track: raise TrackException('Unable to copy %s to iPod as %s' % ( self._userdata_into_default_locale('filename'), self)) + fname = self.ipod_filename().replace(mp, '').replace(os.path.sep, ':') + self['userdata']['filename_ipod'] = fname self['userdata']['transferred'] = 1 - self['userdata']['filename_ipod'] = self._track['ipod_path'] return True def ipod_filename(self): |