diff --git a/resources/language/resource.language.en_au/strings.po b/resources/language/resource.language.en_au/strings.po index 15061487b..323f8658a 100644 --- a/resources/language/resource.language.en_au/strings.po +++ b/resources/language/resource.language.en_au/strings.po @@ -1392,3 +1392,7 @@ msgstr "" msgctxt "#30772" msgid "Disable all framerate hinting" msgstr "" + +msgctxt "#30773" +msgid "Show video details in video lists" +msgstr "" diff --git a/resources/language/resource.language.en_gb/strings.po b/resources/language/resource.language.en_gb/strings.po index 7aa8b57cf..76985ca47 100644 --- a/resources/language/resource.language.en_gb/strings.po +++ b/resources/language/resource.language.en_gb/strings.po @@ -1392,3 +1392,7 @@ msgstr "" msgctxt "#30772" msgid "Disable all framerate hinting" msgstr "" + +msgctxt "#30773" +msgid "Show video details in video lists" +msgstr "" diff --git a/resources/language/resource.language.en_nz/strings.po b/resources/language/resource.language.en_nz/strings.po index 68aa61c74..763f2b9c8 100644 --- a/resources/language/resource.language.en_nz/strings.po +++ b/resources/language/resource.language.en_nz/strings.po @@ -1388,3 +1388,7 @@ msgstr "" msgctxt "#30772" msgid "Disable all framerate hinting" msgstr "" + +msgctxt "#30773" +msgid "Show video details in video lists" +msgstr "" diff --git a/resources/language/resource.language.en_us/strings.po b/resources/language/resource.language.en_us/strings.po index 8a96ff20e..c1a918ea7 100644 --- a/resources/language/resource.language.en_us/strings.po +++ b/resources/language/resource.language.en_us/strings.po @@ -1393,3 +1393,7 @@ msgstr "" msgctxt "#30772" msgid "Disable all framerate hinting" msgstr "" + +msgctxt "#30773" +msgid "Show video details in video lists" +msgstr "" diff --git a/resources/lib/youtube_plugin/kodion/constants/const_settings.py b/resources/lib/youtube_plugin/kodion/constants/const_settings.py index f2fabe702..d88340cef 100644 --- a/resources/lib/youtube_plugin/kodion/constants/const_settings.py +++ b/resources/lib/youtube_plugin/kodion/constants/const_settings.py @@ -30,6 +30,7 @@ USE_REMOTE_HISTORY = 'kodion.history.remote' # (bool) HIDE_SHORT_VIDEOS = 'youtube.hide_shorts' # (bool) DETAILED_DESCRIPTION = 'youtube.view.description.details' # (bool) +DETAILED_LABELS = 'youtube.view.label.details' # (bool) SUPPORT_ALTERNATIVE_PLAYER = 'kodion.support.alternative_player' # (bool) ALTERNATIVE_PLAYER_WEB_URLS = 'kodion.alternative_player.web.urls' # (bool) diff --git a/resources/lib/youtube_plugin/kodion/context/xbmc/xbmc_context.py b/resources/lib/youtube_plugin/kodion/context/xbmc/xbmc_context.py index 0e51d6a02..1c69e9cb2 100644 --- a/resources/lib/youtube_plugin/kodion/context/xbmc/xbmc_context.py +++ b/resources/lib/youtube_plugin/kodion/context/xbmc/xbmc_context.py @@ -417,17 +417,26 @@ def set_content(self, content_type, sub_type=None, category_label=None): category_label = self.get_param('category_label') if category_label: xbmcplugin.setPluginCategory(self._plugin_handle, category_label) + detailed_labels = self.get_settings().show_detailed_labels() if sub_type == 'history': self.add_sort_method( (sort.LASTPLAYED, '%T \u2022 %P', '%D | %J'), (sort.PLAYCOUNT, '%T \u2022 %P', '%D | %J'), (sort.UNSORTED, '%T \u2022 %P', '%D | %J'), (sort.LABEL_IGNORE_THE, '%T \u2022 %P', '%D | %J'), + ) if detailed_labels else self.add_sort_method( + (sort.LASTPLAYED,), + (sort.PLAYCOUNT,), + (sort.UNSORTED,), + (sort.LABEL_IGNORE_THE,), ) else: self.add_sort_method( (sort.UNSORTED, '%T \u2022 %P', '%D | %J'), (sort.LABEL_IGNORE_THE, '%T \u2022 %P', '%D | %J'), + ) if detailed_labels else self.add_sort_method( + (sort.UNSORTED,), + (sort.LABEL_IGNORE_THE,), ) if content_type == content.VIDEO_CONTENT: self.add_sort_method( @@ -437,6 +446,13 @@ def set_content(self, content_type, sub_type=None, category_label=None): (sort.DATEADDED, '%T \u2022 %P | %D', '%a'), (sort.VIDEO_RUNTIME, '%T \u2022 %P | %J', '%D'), (sort.TRACKNUM, '[%N. ]%T \u2022 %P', '%D | %J'), + ) if detailed_labels else self.add_sort_method( + (sort.PROGRAM_COUNT,), + (sort.VIDEO_RATING,), + (sort.DATE,), + (sort.DATEADDED,), + (sort.VIDEO_RUNTIME,), + (sort.TRACKNUM,), ) def add_sort_method(self, *sort_methods): diff --git a/resources/lib/youtube_plugin/kodion/settings/abstract_settings.py b/resources/lib/youtube_plugin/kodion/settings/abstract_settings.py index baea0cb9d..9ff3e5b6d 100644 --- a/resources/lib/youtube_plugin/kodion/settings/abstract_settings.py +++ b/resources/lib/youtube_plugin/kodion/settings/abstract_settings.py @@ -313,6 +313,9 @@ def client_selection(self): def show_detailed_description(self): return self.get_bool(settings.DETAILED_DESCRIPTION, True) + def show_detailed_labels(self): + return self.get_bool(settings.DETAILED_LABELS, True) + def get_language(self): return self.get_string(settings.LANGUAGE, 'en_US').replace('_', '-') diff --git a/resources/settings.xml b/resources/settings.xml index 34025973d..c07d24083 100644 --- a/resources/settings.xml +++ b/resources/settings.xml @@ -689,6 +689,11 @@ true + + 0 + true + +