from Components.ConfigList import ConfigList
from Components.config import *
-from Tools.Directories import resolveFilename, pathExists, createDir, SCOPE_MEDIA
+from Tools.Directories import resolveFilename, fileExists, pathExists, createDir, SCOPE_MEDIA
from Components.FileList import FileList
from Components.AVSwitch import AVSwitch
self["label0"].setText(_("no Picture found"))
self.ThumbTimer = eTimer()
- self.ThumbTimer.timeout.get().append(self.showThumb)
+ self.ThumbTimer.callback.append(self.showThumb)
self.fillPage()
self["pause"] = Pixmap()
self.decodeTimer = eTimer()
- self.decodeTimer.timeout.get().append(self.decodePic)
+ self.decodeTimer.callback.append(self.decodePic)
self.decodeTimer.start(300, True)
self.slideTimer = eTimer()
- self.slideTimer.timeout.get().append(self.slidePic)
+ self.slideTimer.callback.append(self.slidePic)
def Pause(self):
self["thumbnail"] = Pixmap()
self.ThumbTimer = eTimer()
- self.ThumbTimer.timeout.get().append(self.showThumb)
+ self.ThumbTimer.callback.append(self.showThumb)
self.ThumbTimer.start(500, True)
def up(self):
def filescan(**kwargs):
from Components.Scanner import Scanner, ScanPath
+
+ # Overwrite checkFile to only detect local
+ class LocalScanner(Scanner):
+ def checkFile(self, file):
+ return fileExists(file.path)
+
return \
- Scanner(mimetypes = ["image/jpeg", "image/png", "image/gif", "image/bmp"],
+ LocalScanner(mimetypes = ["image/jpeg", "image/png", "image/gif", "image/bmp"],
paths_to_scan =
[
ScanPath(path = "DCIM", with_subdirs = True),