Exemplo n.º 1
0
	def __init__(self, session):
		EcasaPictureWall.__init__(self, session)
		self.skinName = ["EcasaOverview", "EcasaPictureWall"]
		thread = SimpleThread(self.api.getFeatured)
		thread.deferred.addCallbacks(self.gotPictures, self.errorPictures)
		thread.start()

		self.onClose.append(self.__onClose)
Exemplo n.º 2
0
    def __init__(self, session):
        EcasaPictureWall.__init__(self, session)
        self.skinName = ["EcasaOverview", "EcasaPictureWall"]
        thread = SimpleThread(self.api.getFeatured)
        thread.deferred.addCallbacks(self.gotPictures, self.errorPictures)
        thread.start()

        self.onClose.append(self.__onClose)
Exemplo n.º 3
0
    def setupClosed(self):
        api = self.api
        EcasaPictureWall.setupClosed(self)
        if api != self.api:
            self.pictures = ()
            self["highlight"].hide()
            for i in range(self.PICS_PER_PAGE):
                self['image%d' % i].instance.setPixmap(None)
            self["waitingtext"].show()

            thread = SimpleThread(self.api.getFeatured)
            thread.deferred.addCallbacks(self.gotPictures, self.errorPictures)
            thread.start()
Exemplo n.º 4
0
	def setupClosed(self):
		api = self.api
		EcasaPictureWall.setupClosed(self)
		if api != self.api:
			self.pictures = ()
			self["highlight"].hide()
			for i in xrange(self.PICS_PER_PAGE):
				self['image%d' % i].instance.setPixmap(None)
			self["waitingtext"].show()

			thread = SimpleThread(self.api.getFeatured)
			thread.deferred.addCallbacks(self.gotPictures, self.errorPictures)
			thread.start()
Exemplo n.º 5
0
 def acquireAlbumsForUser(self, user):
     thread = SimpleThread(lambda: self.api.getAlbums(user=user))
     thread.deferred.addCallbacks(self.gotAlbums, self.errorAlbums)
     thread.start()
Exemplo n.º 6
0
 def __onClose(self):
     thread = SimpleThread(lambda: self.api.cleanupCache(
         config.plugins.ecasa.cachesize.value))
     thread.start()
Exemplo n.º 7
0
	def parseEPGAsync(self, simulateOnly = False):
		t = SimpleThread(lambda: self.parseEPG(simulateOnly=simulateOnly))
		t.start()
		return t.deferred
Exemplo n.º 8
0
 def parseEPGAsync(self, simulateOnly=False):
     t = SimpleThread(lambda: self.parseEPG(simulateOnly=simulateOnly))
     t.start()
     return t.deferred
Exemplo n.º 9
0
	def acquireAlbumsForUser(self, user):
		thread = SimpleThread(lambda:self.api.getAlbums(user=user))
		thread.deferred.addCallbacks(self.gotAlbums, self.errorAlbums)
		thread.start()
Exemplo n.º 10
0
	def __onClose(self):
		thread = SimpleThread(lambda: self.api.cleanupCache(config.plugins.ecasa.cachesize.value))
		thread.start()