<key id="KEY_RED" mapto="instantRecord" flags="m" />
</map>
+ <map context="InfobarExtensions">
+ <key id="KEY_BLUE" mapto="extensions" flags="m" />
+ </map>
+
<map context="InfobarChannelSelection">
<key id="KEY_LEFT" mapto="zapUp" flags="mr" />
<key id="KEY_RIGHT" mapto="zapDown" flags="mr" />
<widget name="ButtonYellow" pixmap="button_yellow.png" position="430,132" size="27,12" />
<widget name="ButtonYellowText" position="460,130" size="85,22" font="Regular;14" backgroundColor="blue" transparent="1" />
<widget name="ButtonBlue" pixmap="button_blue.png" position="540,132" size="27,12" />
- <widget name="ButtonBlueText" position="570,130" size="85,22" font="Regular;14" backgroundColor="blue" transparent="1" />
+ <widget name="ButtonBlueText" position="570,130" size="95,22" font="Regular;14" backgroundColor="blue" transparent="1" />
</screen>
<screen name="MoviePlayer" flags="wfNoBorder" position="0,370" size="720,148" title="InfoBar">
<widget name="duration" position="140,345" size="100,30" font="Regular;22" />
<widget name="channel" position="240,345" size="270,30" font="Regular;22" />
</screen>
+ <screen name="PictureInPicture" position="500,100" size="180,140" zPosition="-1" flags="wfNoBorder" >
+ <widget name="video" position="0,0" size="160,120" />
+ </screen>
<screen name="MovieSelection" position="90,98" size="560,415" title="Select a movie">
<widget name="waitingtext" position="0,0" size="500,335" zPosition="2" font="Regular;22" />
<widget name="list" position="0,0" size="560,375" zPosition="1" scrollbarMode="showOnDemand" />
InfoBarAudioSelection, InfoBarAdditionalInfo, InfoBarNotifications, InfoBarDish, \
InfoBarSubserviceSelection, InfoBarTuner, InfoBarShowMovies, InfoBarTimeshift, \
InfoBarServiceNotifications, InfoBarPVRState, InfoBarCueSheetSupport, InfoBarSimpleEventView, \
- InfoBarSummarySupport, InfoBarTimeshiftState, InfoBarTeletextPlugin
+ InfoBarSummarySupport, InfoBarTimeshiftState, InfoBarTeletextPlugin, InfoBarExtensions
from Screens.HelpMenu import HelpableScreen, HelpMenu
InfoBarEvent, InfoBarServiceName, InfoBarInstantRecord, InfoBarAudioSelection,
HelpableScreen, InfoBarAdditionalInfo, InfoBarNotifications, InfoBarDish,
InfoBarSubserviceSelection, InfoBarTuner, InfoBarTimeshift, InfoBarSeek,
- InfoBarSummarySupport, InfoBarTimeshiftState, InfoBarTeletextPlugin, Screen):
+ InfoBarSummarySupport, InfoBarTimeshiftState, InfoBarTeletextPlugin, InfoBarExtensions, Screen):
def __init__(self, session):
Screen.__init__(self, session)
InfoBarEvent, InfoBarServiceName, InfoBarInstantRecord, InfoBarAudioSelection, \
InfoBarAdditionalInfo, InfoBarNotifications, InfoBarDish, InfoBarSubserviceSelection, \
InfoBarTuner, InfoBarTimeshift, InfoBarSeek, InfoBarSummarySupport, InfoBarTimeshiftState, \
- InfoBarTeletextPlugin:
+ InfoBarTeletextPlugin, InfoBarExtensions:
x.__init__(self)
self.helpList.append((self["actions"], "InfobarActions", [("showMovies", "Watch a Movie...")]))
from Screens.MessageBox import MessageBox
from Screens.MinuteInput import MinuteInput
from Screens.TimerSelection import TimerSelection
+from Screens.PictureInPicture import PictureInPicture
from ServiceReference import ServiceReference
from Tools import Notifications
self.timeshift_enabled = False
self.__seekableStatusChanged()
+class InfoBarExtensions:
+ def __init__(self):
+ self.pipshown = False
+
+ self["InstantExtensionsActions"] = HelpableActionMap(self, "InfobarExtensions",
+ {
+ "extensions": (self.extensions, "Extensions..."),
+ })
+
+ def extensions(self):
+ list = []
+ if self.pipshown == False:
+ list.append((_("Activate Picture in Picture"), "pipon"))
+ elif self.pipshown == True:
+ list.append((_("Disable Picture in Picture"), "pipoff"))
+ self.session.openWithCallback(self.extensionCallback, ChoiceBox, title=_("Please choose an extension..."), list = list)
+
+ def extensionCallback(self, answer):
+ if answer[1] == "pipon":
+ self.pip = self.session.instantiateDialog(PictureInPicture)
+ self.pip.show()
+ self.pipshown = True
+ print "would show PiP now"
+ elif answer[1] == "pipoff":
+ self.pip.hide()
+ del self.pip
+ self.pipshown = False
+
from RecordTimer import parseEvent
class InfoBarInstantRecord:
self.onLayoutFinish.append(self["ButtonYellowText"].update)
self["ButtonBlue"] = PixmapConditional(withTimer = False)
- self["ButtonBlue"].setConnect(lambda: False)
+ self["ButtonBlue"].setConnect(lambda: True)
self["ButtonBlueText"] = LabelConditional(text = _("Extensions"), withTimer = False)
- self["ButtonBlueText"].setConnect(lambda: False)
+ self["ButtonBlueText"].setConnect(lambda: True)
self.onLayoutFinish.append(self["ButtonBlue"].update)
self.onLayoutFinish.append(self["ButtonBlueText"].update)
Dish.py SubserviceSelection.py LanguageSelection.py StartWizard.py \
TutorialWizard.py PluginBrowser.py MinuteInput.py Scart.py PVRState.py \
Console.py InputBox.py ChoiceBox.py SimpleSummary.py ImageWizard.py \
- MediaPlayer.py TimerSelection.py
+ MediaPlayer.py TimerSelection.py PictureInPicture.py
--- /dev/null
+from Screens.Screen import Screen
+
+from Components.VideoWindow import VideoWindow
+
+class PictureInPicture(Screen):
+ def __init__(self, session):
+ Screen.__init__(self, session)
+
+ self["video"] = VideoWindow()
\ No newline at end of file