def open_youtube_list(self, prev_window=None, search_str="", filters=[], sort="relevance", filter_label="", media_type="video"): """ open video list, deal with window stack and color """ from dialogs import DialogYoutubeList if prev_window: try: # TODO rework color = prev_window.data["general"]['ImageColor'] except: color = "FFFFFFFF" else: color = "FFFFFFFF" youtube_class = DialogYoutubeList.get_window(BaseClasses.WindowXML) dialog = youtube_class(u'script-%s-YoutubeList.xml' % ADDON_NAME, ADDON_PATH, search_str=search_str, color=color, filters=filters, filter_label=filter_label, type=media_type) if prev_window: self.add_to_stack(prev_window) prev_window.close() dialog.doModal()
def open_youtube_list(self, prev_window=None, search_str="", filters=None, sort="relevance", filter_label="", media_type="video"): """ open video list, deal with window stack and color """ filters = [] if not filters else filters from dialogs import DialogYoutubeList if prev_window: try: # TODO rework color = prev_window.data["general"]['ImageColor'] except: color = "FFFFFFFF" else: color = "FFFFFFFF" youtube_class = DialogYoutubeList.get_window(BaseClasses.WindowXML) dialog = youtube_class(u'script-%s-YoutubeList.xml' % ADDON_NAME, ADDON_PATH, search_str=search_str, color=color, filters=filters, filter_label=filter_label, type=media_type) if prev_window: self.add_to_stack(prev_window) prev_window.close() dialog.doModal()
def open_youtube_list(self, search_str="", filters=None, filter_label="", media_type="video"): """ open video list, deal with window stack """ from dialogs import DialogYoutubeList YouTube = DialogYoutubeList.get_window(windows.DialogXML) dialog = YouTube(u'script-%s-YoutubeList.xml' % addon.ID, addon.PATH, search_str=search_str, filters=[] if not filters else filters, type=media_type) self.open_dialog(dialog)
def open_youtube_list(self, search_str="", filters=None, filter_label="", media_type="video"): """ open video list, deal with window stack """ from dialogs import DialogYoutubeList YouTube = DialogYoutubeList.get_window(windows.DialogXML) dialog = YouTube(u'script-%s-YoutubeList.xml' % addon.NAME, addon.PATH, search_str=search_str, filters=[] if not filters else filters, type=media_type) self.open_dialog(dialog)
def open_youtube_list(self, prev_window=None, search_str="", filters=None, sort="relevance", filter_label="", media_type="video"): """ open video list, deal with window stack """ filters = [] if not filters else filters from dialogs import DialogYoutubeList youtube_class = DialogYoutubeList.get_window(windows.WindowXML) dialog = youtube_class(u'script-%s-YoutubeList.xml' % addon.NAME, addon.PATH, search_str=search_str, filters=filters, filter_label=filter_label, type=media_type) if prev_window: self.add_to_stack(prev_window) prev_window.close() dialog.doModal()