X-Git-Url: https://git.cweiske.de/enigma2.git/blobdiff_plain/09565fe7720e8e042712b42a9dc7aac2949130cb..8e5c4dddb513786c7a558a88da25c3e9cddc8964:/lib/python/Plugins/Extensions/DVDPlayer/plugin.py
diff --git a/lib/python/Plugins/Extensions/DVDPlayer/plugin.py b/lib/python/Plugins/Extensions/DVDPlayer/plugin.py
index 593d4d2e..29e69ee1 100644
--- a/lib/python/Plugins/Extensions/DVDPlayer/plugin.py
+++ b/lib/python/Plugins/Extensions/DVDPlayer/plugin.py
@@ -1,5 +1,5 @@
from os import path as os_path, remove as os_remove, listdir as os_listdir, system
-from enigma import eTimer, iPlayableService, iServiceInformation, eServiceReference, iServiceKeys
+from enigma import eTimer, iPlayableService, iServiceInformation, eServiceReference, iServiceKeys, getDesktop
from Screens.Screen import Screen
from Screens.MessageBox import MessageBox
from Screens.ChoiceBox import ChoiceBox
@@ -109,10 +109,11 @@ class DVDSummary(Screen):
self["Title"].setText(title)
class DVDOverlay(Screen):
- skin = """"""
def __init__(self, session, args = None):
+ desktop_size = getDesktop(0).size()
+ DVDOverlay.skin = """""" %(desktop_size.width(), desktop_size.height())
Screen.__init__(self, session)
-
+
class ChapterZap(Screen):
skin = """
@@ -352,7 +353,7 @@ class DVDPlayer(Screen, InfoBarBase, InfoBarNotifications, InfoBarSeek, InfoBarP
if file.mimetype == "video/x-dvd":
self.dvd_device = devicepath
print "physical dvd found:", self.dvd_device
- self.physicalDVD = True
+ self.physicalDVD = True
self.dvd_filelist = dvd_filelist
self.onFirstExecBegin.append(self.showFileBrowser)
@@ -387,9 +388,6 @@ class DVDPlayer(Screen, InfoBarBase, InfoBarNotifications, InfoBarSeek, InfoBarP
def serviceStarted(self): #override InfoBarShowHide function
self.dvdScreen.show()
- subs = self.getServiceInterface("subtitle")
- if subs:
- subs.enableSubtitles(self.dvdScreen.instance, None)
def doEofInternal(self, playing):
if self.in_menu:
@@ -489,7 +487,7 @@ class DVDPlayer(Screen, InfoBarBase, InfoBarNotifications, InfoBarSeek, InfoBarP
self.doShow()
def askLeavePlayer(self):
- choices = [(_("Continue playing"), "play"), (_("Exit"), "exit")]
+ choices = [(_("Exit"), "exit"), (_("Continue playing"), "play")]
if not self.physicalDVD:
choices.insert(1,(_("Return to file browser"), "browser"))
self.session.openWithCallback(self.exitCB, ChoiceBox, title=_("Leave DVD Player?"), list = choices)
@@ -588,18 +586,24 @@ class DVDPlayer(Screen, InfoBarBase, InfoBarNotifications, InfoBarSeek, InfoBarP
self.service = self.session.nav.getCurrentService()
print "self.service", self.service
print "cur_dlg", self.session.current_dialog
+ subs = self.getServiceInterface("subtitle")
+ if subs:
+ subs.enableSubtitles(self.dvdScreen.instance, None)
def exitCB(self, answer):
- if not answer or answer and answer[1] == "exit":
- if self.service:
- self.service = None
- self.close()
- if answer and answer[1] == "browser":
+ if answer is not None:
+ if answer[1] == "exit":
+ if self.service:
+ self.service = None
+ self.close()
+ if answer[1] == "browser":
#TODO check here if a paused dvd playback is already running... then re-start it...
#else
- if self.service:
- self.service = None
- self.showFileBrowser()
+ if self.service:
+ self.service = None
+ self.showFileBrowser()
+ else:
+ pass
def __onClose(self):
for i in (("/proc/stb/video/aspect", self.old_aspect), ("/proc/stb/video/policy", self.old_policy), ("/proc/stb/denc/0/wss", self.old_wss)):