Skip to content

Commit

Permalink
Merge pull request #110 from yaser01/develop
Browse files Browse the repository at this point in the history
Update 2.4.1
  • Loading branch information
yaser01 authored Jan 6, 2024
2 parents 633d482 + 5d94a78 commit 6dc52d7
Show file tree
Hide file tree
Showing 4 changed files with 16 additions and 5 deletions.
1 change: 1 addition & 0 deletions packages/Tabs/AudioTab/AudioSelection.py
Original file line number Diff line number Diff line change
Expand Up @@ -423,6 +423,7 @@ def set_default_directory(self):
def set_preset_options(self):
self.create_properties()
self.create_global_properties()
self.audio_language_comboBox.initialize()
self.audio_language_comboBox.set_current_index()
self.audio_extensions_comboBox.set_current_extensions()
self.set_default_directory()
Expand Down
8 changes: 6 additions & 2 deletions packages/Tabs/AudioTab/Widgets/AudioLanguageComboBox.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,14 +12,18 @@ def __init__(self, tab_index):
self.tab_index = tab_index
self.hint_when_enabled = ""
self.setMinimumWidth(screen_size.width() // 13)
self.addItems(Options.CurrentPreset.Default_Favorite_Audio_Languages)
self.initialize()
self.set_current_index()
self.setToolTip("Audio Language: " + Options.CurrentPreset.Default_Audio_Language + "\nYou can add/remove "
"languages in options")
"languages in options")
self.setMaxVisibleItems(8)
self.setStyleSheet("QComboBox { combobox-popup: 0; }")
self.currentTextChanged.connect(self.change_global_audio_language)

def initialize(self):
self.clear()
self.addItems(Options.CurrentPreset.Default_Favorite_Audio_Languages)

def set_current_index(self):
self.setCurrentIndex(
Options.CurrentPreset.Default_Favorite_Audio_Languages.index(Options.CurrentPreset.Default_Audio_Language))
Expand Down
1 change: 1 addition & 0 deletions packages/Tabs/SubtitleTab/SubtitleSelection.py
Original file line number Diff line number Diff line change
Expand Up @@ -423,6 +423,7 @@ def set_default_directory(self):
def set_preset_options(self):
self.create_properties()
self.create_global_properties()
self.subtitle_language_comboBox.initialize()
self.subtitle_language_comboBox.set_current_index()
self.subtitle_extensions_comboBox.set_current_extensions()
self.set_default_directory()
Expand Down
11 changes: 8 additions & 3 deletions packages/Tabs/SubtitleTab/Widgets/SubtitleLanguageComboBox.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,14 +12,19 @@ def __init__(self, tab_index):
self.tab_index = tab_index
self.hint_when_enabled = ""
self.setMinimumWidth(screen_size.width() // 13)
self.addItems(Options.CurrentPreset.Default_Favorite_Subtitle_Languages)
self.initialize()
self.set_current_index()
self.setToolTip("Subtitle Language: " + Options.CurrentPreset.Default_Subtitle_Language + "\nYou can add/remove "
"languages in options")
self.setToolTip(
"Subtitle Language: " + Options.CurrentPreset.Default_Subtitle_Language + "\nYou can add/remove "
"languages in options")
self.setMaxVisibleItems(8)
self.setStyleSheet("QComboBox { combobox-popup: 0; }")
self.currentTextChanged.connect(self.change_global_subtitle_language)

def initialize(self):
self.clear()
self.addItems(Options.CurrentPreset.Default_Favorite_Subtitle_Languages)

def set_current_index(self):
self.setCurrentIndex(
Options.CurrentPreset.Default_Favorite_Subtitle_Languages.index(
Expand Down

0 comments on commit 6dc52d7

Please sign in to comment.