Kodi Community Forum
Access to Skin.String from itemlayout - Printable Version

+- Kodi Community Forum (https://forum.kodi.tv)
+-- Forum: Development (https://forum.kodi.tv/forumdisplay.php?fid=32)
+--- Forum: Skinning (https://forum.kodi.tv/forumdisplay.php?fid=12)
+--- Thread: Access to Skin.String from itemlayout (/showthread.php?tid=207508)



Access to Skin.String from itemlayout - im85288 - 2014-10-28

Does anyone know of a workaround for getting skin variables when in the itemlayout and focusedlayout sections of for example a panel?

From my testing this returns empty in an itemlayout:

Code:
$INFO[Skin.String(variablename)]

But can be accessed with no issues out of the item and focused layouts.


RE: Access to Skin.String from itemlayout - phil65 - 2014-10-28

either use

$INFO[Skin.String(stringname)]

(not sure atm if skin strings work in container layouts)

or

$VAR[VariableName]


RE: Access to Skin.String from itemlayout - BigNoid - 2014-10-28

Skin strings dont work inside containers. iirc this is done because of performance issues.


RE: Access to Skin.String from itemlayout - im85288 - 2014-10-28

Thanks guys, I managed to get around it by setting a property on the content for the container.

So for example:

<property name="propertyname">$INFO[Skin.String(variablename)]</property>

And then accessing it via the ListItem.Property(propertyname) method.

Thanks for the replys.