def __init__(self, plugin, selected_playlist=None): self.plugin = plugin guiutil.initialize_from_xml(self) self.info_bar = dialogs.MessageBar(self.info_bar, type=gtk.MESSAGE_ERROR, buttons=gtk.BUTTONS_CLOSE) self.__build_template_list() self.__build_playlist_list(selected_playlist) self.__initialize_presets() self.__tag_widgets = [] self.window.show_all() def tag_data_key(td): if td: return td.translated_name # convenience td = tag_data.values() # Add grouptagger to the list gt = get_default_tagdata('__grouptagger') gt.translated_name = _('GroupTagger') td.append(gt) self.__sorted_tags = sorted(td, key=tag_data_key) # setup the selected template guiutil.persist_selection(self.template_list, 0, 'plugin/playlistanalyzer/last_tmpl')
def __init__(self, plugin, selected_playlist=None): self.plugin = plugin guiutil.initialize_from_xml(self) self.info_bar = dialogs.MessageBar(self.info_bar, type=Gtk.MessageType.ERROR, buttons=Gtk.ButtonsType.CLOSE) self.__build_template_list() self.__build_playlist_list(selected_playlist) self.__initialize_presets() self.__tag_widgets = [] self.window.show_all() def tag_data_key(td): if td: return td.translated_name # convenience td = tag_data.values() # Add grouptagger to the list gt = get_default_tagdata('__grouptagger') gt.translated_name = _('GroupTagger') td.append(gt) self.__sorted_tags = sorted(td, key=tag_data_key) # setup the selected template guiutil.persist_selection(self.template_list, 0, 'plugin/playlistanalyzer/last_tmpl')