PDA

View Full Version : Kodi skin support



hsbrown2
05-18-2018, 02:21 PM
Hi, folks,

Is there a way to set up your own config files or something to support Kodi skins?

Right now, IIRC, Aeon Nox and Confluence are the only skins that have configurations, so I can't set up defaults that match a particular skin.

I'd like to have one for Black Glass Nova, but how?

Thanks!
hsbrown2

Peter
05-21-2018, 10:02 AM
In the Mezzmo Kodi Plugin there is a function that translates the selected view mode into the view mode code for the skin https://github.com/Conceiva/MezzmoKodiPlugin/blob/89f2f3b2aafbc5c401b427acd45b68570424dd15/resources/lib/mezzmo.py#L202, you could modify this to add the skin name that you want to use and the view modes that it supports. You would need to look at the code for the skin you want to use to see what view modes are supported and their codes.

hsbrown2
05-31-2018, 02:22 PM
Hmmm... So I took a stab at this, but I'm not getting any joy thus far. I added the following to mezzmo.py:

elif current_skin_name == 'skin.blackglassnova':
blackglassnova_views = { 'List' : 50 ,
'Panel' : 51 ,
'BigList' : 52 ,
'Grid' : 53 ,
'LowList' : 54 ,
'BigPanel' : 55 ,
'BannerList' : 56 ,
'ShowcaseEpisode' : 57 ,
'ShowcaseSquare' : 58 ,
'ShowcasePoster' : 59 ,
'CardList' : 5050 }

view_mode = addon.getSetting(contentType + '_view_mode' + '_blackglassnova')
if view_mode != 'Default':

selected_mode = blackglassnova_views[view_mode]
xbmc.executebuiltin('Container.SetViewMode(' + str(selected_mode) + ')')

In the skin xml I found the following:

In addon.xml:
<addon provider-name="Tgx" name="Black Glass Nova" version="7.0.1" id="skin.blackglassnova">

In views.xml:
-<views>

<view type="movies,setmovies,tvshows,musicvideos,seasons,sets, episodes,artists,albums,songs,tvchannels,tvrecordi ngs,programs,pictures" languageid="535" value="50" id="list"/>

<view type="movies,setmovies,tvshows,musicvideos,seasons,sets, episodes,artists,albums,songs,programs,pictures" languageid="31095" value="5050" id="cardlist"/>

<view type="movies,setmovies,tvshows,musicvideos,seasons,sets, episodes,artists,albums,songs,programs,pictures" languageid="31090" value="51" id="panel"/>

<view type="movies,setmovies,tvshows,musicvideos,seasons,sets, episodes,artists,albums,songs,tvchannels,tvrecordi ngs,programs,pictures" languageid="31091" value="52" id="biglist"/>

<view type="movies,setmovies,tvshows,musicvideos,seasons,sets, episodes,artists,albums,songs,programs,pictures" languageid="536" value="53" id="grid"/>

<view type="movies,setmovies,tvshows,musicvideos,seasons,sets, episodes,artists,albums,songs,tvchannels,tvrecordi ngs,programs,pictures" languageid="31092" value="54" id="lowlist"/>

<view type="movies,setmovies,tvshows,musicvideos,seasons,sets, episodes,artists,albums,songs,programs,pictures" languageid="31093" value="55" id="bigpanel"/>

<view type="movies,setmovies,tvshows,musicvideos,seasons,sets, episodes" languageid="31095" value="56" id="bannerlist"/>

<view type="movies,setmovies,tvshows,musicvideos,seasons,sets" languageid="20445" value="59" id="showcaseposter"/>

<view type="artists,albums,songs" languageid="20445" value="58" id="showcasesquare"/>

<view type="episodes" languageid="20445" value="57" id="showcaseepisode"/>

</views>

But when I go into the Mezzmo add-on settings, I am able to only select from the aeon(s), estuary, and confluence skins.

What am I missing?

hsbrown2
05-31-2018, 02:47 PM
Ah... It looks like settings.xml may need some mods to select the views available in order to set it up in the settings (duh).

Any pointers for adding this support?

Thanks!
hsbrown2

Peter
05-31-2018, 03:47 PM
You will need to edit settings.xml in the Mezzmo plugin to add blackglassnova to the skin names:
<setting id="skinname" type="enum" label="30061" values="Estuary|Confluence|Aeon Nox 5" default="Estuary"/>

Then you will need to add the supported modes for each value:
<setting id="top_view_mode_blackglassnova " type="labelenum" label="30349" values="Default blackglassnova|List|InfoWall|Landscape|ShowCase1|S howCase2|TriPanel|Posters|Shift|BannerWall|Logo|Wa ll|LowList|BigList" default="List" subsetting="true" visible="eq(-15,0)" enable="eq(-15,0)"/>
<setting id="folders_view_mode_blackglassnova " type="labelenum" label="30342" values="Default|List|InfoWall|Landscape|ShowCase1|ShowCase 2|TriPanel|Posters|Shift|BannerWall|Logo|Wall|LowL ist|BigList" default="List" subsetting="true" visible="eq(-16,0)" enable="eq(-16,0)"/>
<setting id="files_view_mode_blackglassnova " type="labelenum" label="30343" values="Default|List|InfoWall|Landscape|ShowCase1|ShowCase 2|TriPanel|Posters|Shift|BannerWall|Logo|Wall|LowL ist|BigList" default="List" subsetting="true" visible="eq(-17,0)" enable="eq(-17,0)"/>
<setting id="servers_view_mode_blackglassnova " type="labelenum" label="30344" values="Default|List|InfoWall|Landscape|ShowCase1|ShowCase 2|TriPanel|Posters|Shift|BannerWall|Logo|Wall|LowL ist|BigList" default="List" subsetting="true" visible="eq(-18,0)" enable="eq(-18,0)"/>
<setting id="movies_view_mode_blackglassnova " type="labelenum" label="30330" values="Default|List|InfoWall|Landscape|ShowCase1|ShowCase 2|TriPanel|Posters|Shift|BannerWall|Logo|Wall|LowL ist|BigList" default="Shift" subsetting="true" visible="eq(-19,0)" enable="eq(-19,0)"/>
<setting id="episodes_view_mode_blackglassnova " type="labelenum" label="30341" values="Default|List|InfoWall|Landscape|ShowCase1|ShowCase 2|TriPanel|Posters|Shift|BannerWall|Logo|Wall|LowL ist|Episode|BigList" default="Episode" subsetting="true" visible="eq(-20,0)" enable="eq(-20,0)"/>
<setting id="songs_view_mode_blackglassnova " type="labelenum" label="30365" values="Default|List|InfoWall|Landscape|ShowCase1|ShowCase 2|TriPanel|Posters|Shift|BannerWall|Logo|Wall|LowL ist|BigList" default="List" subsetting="true" visible="eq(-21,0)" enable="eq(-21,0)"/>