Web   ·   Wiki   ·   Activities   ·   Blog   ·   Lists   ·   Chat   ·   Meeting   ·   Bugs   ·   Git   ·   Translate   ·   Archive   ·   People   ·   Donate
summaryrefslogtreecommitdiffstats
path: root/record.py
diff options
context:
space:
mode:
authorerikb <erikb@574bc980-5f2d-0410-acbc-c8f9f0eb14e0>2007-11-01 20:37:35 (GMT)
committer erikb <erikb@574bc980-5f2d-0410-acbc-c8f9f0eb14e0>2007-11-01 20:37:35 (GMT)
commit3ff19131016a59ae85e539e128569d6d721087e2 (patch)
tree20a789554334e5a383eeecd7c56fb5516bd67324 /record.py
parentb1ddac3d076def677944c67aedef52122e5dd2e4 (diff)
audio?
git-svn-id: http://mediamods.com/public-svn/camera-activity/Record.activity@835 574bc980-5f2d-0410-acbc-c8f9f0eb14e0
Diffstat (limited to 'record.py')
-rwxr-xr-xrecord.py27
1 files changed, 17 insertions, 10 deletions
diff --git a/record.py b/record.py
index 6ba6139..1aa419e 100755
--- a/record.py
+++ b/record.py
@@ -73,7 +73,6 @@ class Record(activity.Activity):
self.m = Model( self )
self.glive = Glive( self )
self.gplay = Gplay( self )
- self.greplay = Greplay( self )
self.ui = UI( self )
#CSCL
@@ -449,20 +448,28 @@ class Record(activity.Activity):
recd.meshDownlodingPercent = 1.0
recd.downloadedFromBuddy = True
if (recd.type == Constants.TYPE_AUDIO):
- self.connect(greplay.getAlbumArt, recd, _getAlbumArtCb)
+ record.Record.debug("_recdBitsArrivedCb:TYPE_AUDIO")
+ greplay = Greplay()
+ greplay.connect("coverart-found", _getAlbumArtCb, recd )
+ filepath = recd.getMediaFilelocation(False)
+ greplay.findAlbumArt(filepath)
else:
self.ui.showMeshRecd( recd )
elif part > numparts:
- self.__class__.log.debug('More parts than required have arrived')
+ self.__class__.log.error('More parts than required have arrived')
- def _getAlbumArtCb( self, recd, pixbuf ):
- if (pixbuf == None):
- return False
- imagePath = os.path.join(Instance.tmpPath, "audioPicture.png")
- imagePath = utils.getUniqueFilepath( imagePath, 0 )
- pixbuf.save( imagePath, "png", {} )
- recd.audioImageFilename = os.path.basename(imagePath)
+ def _getAlbumArtCb( self, pixbuf, recd ):
+ self.__class__.log.debug("_getAlbumArtCb:" + str(pixbuf) + "," + str(recd))
+
+ if (pixbuf != None):
+ imagePath = os.path.join(Instance.tmpPath, "audioPicture.png")
+ imagePath = utils.getUniqueFilepath( imagePath, 0 )
+ pixbuf.save( imagePath, "png", {} )
+ recd.audioImageFilename = os.path.basename(imagePath)
+
+ self.ui.showMeshRecd( recd )
+ return False
def _recdUnavailableCb( self, objectThatSentTheSignal, md5sumOfIt, whoDoesntHaveIt ):