Get xbmcgui Window properties
#1
Hi,

Anyone familiair with getting (all) available Window properties to be read in Python?
I tried the following examples:

a = str(xbmcgui.Window(getCurrentWindowId()).getProperty('Addon.Description'))
b = str(xbmcgui.Window(getCurrentWindowId()).getProperty('Category'))
c = str(xbmcgui.Window(getCurrentWindowId()).getListItem('1'))
d = str(xbmcgui.Window(getCurrentWindowId()).getListItem(1))
e = str(xbmcgui.Window(getCurrentWindowId()).getListSize)
f = str(xbmcgui.Window(getCurrentWindowId()).getListItem('Icon'))

None of them seem to return anything.

Kind regards,
Jeroen
Reply
#2
see: http://mirrors.xbmc.org/docs/python-docs...etProperty

i'm not sure what you're trying to accomplish though...
by default there aren't any window properties, at least not set by kodi.
they need to be set by an addon or skin first before you can get them
Do not PM or e-mail Team-Kodi members directly asking for support.
Always read the Forum rules, Kodi online-manual, FAQ, Help and Search the forum before posting.
Reply
#3
You can find the Python documentation links here.
For window properties it's this one.
Reply
#4
Tanks ronie / BigNoid!

What I'm trying to accomplish is a deeplink to my skin settings.
By default, you need to navigate thru => Settings => Add ons => MyAddon => Configure.

I tried to make a shortcut like button, which does; ActivateWindow(addonsettings)
But this only works if the above path has been followed before. (It seems that variables are then set).
After reboot and direct selection kodi blanks out and hangs.

Therefore I'd want to catch these vars, so I can set them manually which should make my direct link usable.

So far I seem to be on a dead trail.
Only getting some <xbmcgui.ListItem object at 0x6157....> values

Isn't the addon.xml id of any use for direct approach?
<addon
id="skin.audi_rns"



If this is not going to work, I'll design a custom .xml, where at least I could try to reuse the getSettings / setSettings options as mentioned in the Python docs.
Reply
#5
ActivateWindow(skinsettings) for skins and Addon.OpenSettings(id) for other add-ons
Donate: https://kodi.tv/contribute/donate (foundation), 146Gr48FqHM7TPB9q33HHv6uWpgQqdz1yk (BTC personal)
Estuary: Kodis new default skin - ExtendedInfo Script - KodiDevKit
Reply
#6
That easy!? Thanks!!

(Boy... was I on a wrong track..)
Reply

Logout Mark Read Team Forum Stats Members Help
Get xbmcgui Window properties0