2016-04-28, 11:25
Hi.
Looking to make a list of all the window properties I use between the script and my skin - for debugging purposes.
Skinning it... is possible, but would be an almost unbearable labour.. knowing that python should be able to do it in a breeze.
I would like to send a list of listitems with the relevant data to a panelcontainer and let is show my parameters. But any automation that works is welcomed.
Through pure XML it works nicely. Here is the syntax of a panel showing the dynamically changing values of a property:
Now, what would be sweeter than to fill this list through code? ..Nothing!.. well.. pretty much anything really, but it would count as something...
The python working-but-not-working code:
It does transfer the strings to the list, but Label2 ends up as it is, showing the SYNTAX ( aka $INFO[Window(Home).Property(PROPERTY)] ) and not the translated values..
much dissapoint!
What do?
Looking to make a list of all the window properties I use between the script and my skin - for debugging purposes.
Skinning it... is possible, but would be an almost unbearable labour.. knowing that python should be able to do it in a breeze.
I would like to send a list of listitems with the relevant data to a panelcontainer and let is show my parameters. But any automation that works is welcomed.
Through pure XML it works nicely. Here is the syntax of a panel showing the dynamically changing values of a property:
Code:
<control type="panel" ...
<itemlayout>..
<control type="label">
<info>Listitem.Label</info>
...
<control type="label">
<label>$INFO[Listitem.Label2]</label>
...
<contents>
<item>
<label>PROPERTY</label>
<label2>$INFO[Window(Home).Property(PROPERTY)]</label2>
<onclick>noop</onclick>
</item>
....
Now, what would be sweeter than to fill this list through code? ..Nothing!.. well.. pretty much anything really, but it would count as something...
The python working-but-not-working code:
Code:
L = ('PROPERTY','PROPERTY2'.... etc... 'PROPERTY[N]')
for propertyname in L:
li = xbmcgui.ListItem(label=propertyname, label2='$INFO[Window(Home).Property(' + propertyname + ')]')
LS.append(li)
ACTIVEWINDOW.getControl(91122).setStaticContent(LS)
It does transfer the strings to the list, but Label2 ends up as it is, showing the SYNTAX ( aka $INFO[Window(Home).Property(PROPERTY)] ) and not the translated values..
much dissapoint!
What do?