From f29cef262a7d6e4c8655c3c38b5d42a4caaffb68 Mon Sep 17 00:00:00 2001 From: MrS0m30n3 Date: Fri, 14 Oct 2016 23:41:41 +0300 Subject: [PATCH] Subtitles: replace wx.CheckListBox with wx.ListBox --- youtube_dl_gui/optionsframe.py | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/youtube_dl_gui/optionsframe.py b/youtube_dl_gui/optionsframe.py index a57ea0e..e088dfa 100644 --- a/youtube_dl_gui/optionsframe.py +++ b/youtube_dl_gui/optionsframe.py @@ -225,6 +225,14 @@ class TabPanel(wx.Panel): return checklistbox + def crt_listbox(self, choices, style=None): + if style is None: + listbox = wx.ListBox(self, choices=choices) + else: + listbox = wx.ListBox(self, choices=choices, style=style) + + return listbox + class GeneralTab(TabPanel): @@ -400,7 +408,7 @@ class DownloadsTab(TabPanel): self.subtitles_label = self.crt_statictext("Subtitles") self.subtitles_combobox = self.crt_combobox(self.SUBS_CHOICES) - self.subtitles_lang_listbox = self.crt_checklistbox(self.SUBS_LANG.values()) + self.subtitles_lang_listbox = self.crt_listbox(self.SUBS_LANG.values()) self.subtitles_opts_label = self.crt_statictext("Subtitles options") self.embed_subs_checkbox = self.crt_checkbox("Embed subtitles into video file (mp4 ONLY)")