list.append((_("Swap services"), self.PIPSWAP))
s = self.getCurrentServiceSubtitle()
+ l = s and s.getSubtitleList() or [ ]
- for x in s.getSubtitleList():
+ for x in l:
list.append(("DEBUG: Enable Subtitles: " + x[0], self.ENABLE_SUBTITLE, x))
self.session.openWithCallback(self.extensionCallback, ChoiceBox, title=_("Please choose an extension..."), list = list)
subtitle = self.getCurrentServiceSubtitle()
if enable and self.__selected_subtitle:
if subtitle and not self.__subtitles_enabled:
- subtitle.enableSubtitles(self.subtitle_window.instance, self.selected_subtitle)
+ subtitle.enableSubtitles(self.subtitle_window.instance, self.selected_subtitle[1])
self.subtitle_window.show()
self.__subtitles_enabled = True
else:
if (m_subtitle_widget)
disableSubtitles(parent);
+ if (!m_teletext_parser)
+ return -1;
+
+ if (!PyInt_Check(entry))
+ return -1;
+
m_subtitle_widget = new eSubtitleWidget(parent);
m_subtitle_widget->resize(parent->size()); /* full size */
+
+ int page = PyInt_AsLong(entry);
+
+ m_teletext_parser->setPage(page);
return 0;
}