From 5777e4085aab0cb2afe61f04f5250fa2ec83b9b4 Mon Sep 17 00:00:00 2001 From: jurialmunkey Date: Wed, 24 Nov 2021 11:51:55 +1100 Subject: [PATCH] Simplify changing fallback widget to image - #107 --- 16x9/Includes_Defs.xml | 1 + 16x9/Includes_Image.xml | 3 ++- 16x9/Includes_Label.xml | 1 + 16x9/SkinSettings.xml | 13 +++++++++++++ addon.xml | 2 +- language/resource.language.en_gb/strings.po | 10 ++++++++++ 6 files changed, 28 insertions(+), 2 deletions(-) diff --git a/16x9/Includes_Defs.xml b/16x9/Includes_Defs.xml index 185088f..1557883 100644 --- a/16x9/Includes_Defs.xml +++ b/16x9/Includes_Defs.xml @@ -474,6 +474,7 @@ - $INFO[Window(Weather).Property(Current.FanartCode),resource://resource.images.weatherfanart.multi/,]/ + - $INFO[Window(Weather).Property(Current.FanartCode),resource://resource.images.weatherfanart.multi/,]/ $INFO[Skin.String(home.fallbackwidget)] special://skin/extras/playlists/RandomMovies.xsp diff --git a/16x9/Includes_Image.xml b/16x9/Includes_Image.xml index 6c04ba0..6824451 100644 --- a/16x9/Includes_Image.xml +++ b/16x9/Includes_Image.xml @@ -131,8 +131,9 @@ $INFO[Container(9988).ListItem.Art(fanart)] $INFO[Container(9000).ListItem.Property(Background)] $INFO[Container(9001).ListItem.PicturePath] - special://skin/extras/backgrounds/home.jpg + $INFO[Skin.String(widget.background.fallback)] $INFO[Skin.String(background.fallback)] + special://skin/extras/backgrounds/home.jpg common/black.png $INFO[Skin.String(background.fallback)] diff --git a/16x9/Includes_Label.xml b/16x9/Includes_Label.xml index b4598ce..16e6278 100644 --- a/16x9/Includes_Label.xml +++ b/16x9/Includes_Label.xml @@ -341,6 +341,7 @@ + $LOCALIZE[31283] $INFO[Skin.String(home.fallbackwidget.name)] $LOCALIZE[31180] diff --git a/16x9/SkinSettings.xml b/16x9/SkinSettings.xml index 1ddbedd..becdc7d 100644 --- a/16x9/SkinSettings.xml +++ b/16x9/SkinSettings.xml @@ -179,12 +179,25 @@ 100% $VAR[Label_SkinSetting_FallbackWidget] + Skin.Reset(widget.background.fallback) SetProperty(home.fallbackwidget.name,$INFO[Skin.String(home.fallbackwidget.name)],home) RunScript(script.skinshortcuts,type=widgets&grouping=widget&skinWidgetPath=home.fallbackwidget&skinWidget=home.fallbackwidget.node&skinWidgetName=home.fallbackwidget.name&skinWidgetType=home.fallbackwidget.type&skinWidgetTarget=home.fallbackwidget.target) 72 Defs_OptionButton ControlGroup(8000).HasFocus(8001) + + + + 100% + + $INFO[Skin.String(widget.background.fallback)] + Skin.SetImage(widget.background.fallback) + Skin.Reset(widget.background.fallback) + 72 + Defs_OptionButton + ControlGroup(8000).HasFocus(8001) + diff --git a/addon.xml b/addon.xml index 25866b3..6e4f148 100644 --- a/addon.xml +++ b/addon.xml @@ -1,4 +1,4 @@ - + diff --git a/language/resource.language.en_gb/strings.po b/language/resource.language.en_gb/strings.po index 1140784..7224379 100644 --- a/language/resource.language.en_gb/strings.po +++ b/language/resource.language.en_gb/strings.po @@ -1210,3 +1210,13 @@ msgstr "" msgctxt "#31281" msgid "Show media flags with controls" msgstr "" + +#: /16x9/SkinSettings.xml +msgctxt "#31282" +msgid "Replace fallback widget with image" +msgstr "" + +#: /16x9/Includes_Label.xml +msgctxt "#31283" +msgid "Fallback image" +msgstr ""