Skin.SetScript() & Skin.SetXBE()R
#1
nuka and i discussed this a little bit over on the x-s forum. basically, now that i am screwing around with user configurable buttons, i found a bit of "missing" functionality.
we were talking about using a built in function similair to the skin.setimage() which could be used to select a python script of xbe file.
for skin.setscript(), the behavior would be nearly identical to skin.setimage, except the file display filter would only show files name *.py.

say the filepath returned by the user's input is x:\fu\bar.py.

the builtin function would return & set to the specified skin string variable "xbmc.runscript(x:\fu\bar.py)" (obviously quotes not included).

for setxbe, i figure same thing only the display filter would only show *.xbe and *.cut files, and the returned string would be xbmc.runxbe(x:\fu\bar.xbe). whatcha think?
Catchy Signature Here
Reply
#2
no comments? Sad that makes me a sad panda...
Catchy Signature Here
Reply
#3
what ev Smile
For python coding questions first see http://mirrors.xbmc.org/docs/python-docs/
Reply
#4
in the <onfocus> just the script name and path launches the script. i imagine it's the same with <onclick>.

<onfocus>q:\scripts\kaid control pad\script.py</onfocus>

not sure if i understood what you meant, but i don't think it's necessary. if i understood.

unless this functionality is going to be taken away. i thought i read something about it.
For python coding questions first see http://mirrors.xbmc.org/docs/python-docs/
Reply
#5
i'm proposing a change to the <onclick> and <onfocus> layout for translating skin strings.

instead of just translating directly, it will go through the same routine as <label> tags do.

this will allow (for instance):

<onclick>activatewindow(myvideos,$info[skin.string(bookmark1)])</onclick>
<onclick>runxbe($info[skin.string(xbe1)])</onclick>
<onclick>runscript($info[skin.string(script1)])</onclick>

and so on.

anyone see any issues with this?

as for the setxbe() etc. things - imo a better method is:

setfile(name,mask)

which should be easy enough to add.

cheers,
jonathan
Always read the XBMC online-manual, FAQ and search the forum before posting.
Do not e-mail XBMC-Team members directly asking for support. Read/follow the forum rules.
For troubleshooting and bug reporting please make sure you read this first.


Image
Reply
#6
jon, the whole thing with "setscript" was basically identical to setxbe.
however, the setfile is a much better way to go Smile
also, as you know, i'm not mr programmer so i have no idea how easy/hard that is to do. from the design standpoint, sounds awesome. would allow for very flexible skin stuff (as in your examples).
Catchy Signature Here
Reply

Logout Mark Read Team Forum Stats Members Help
Skin.SetScript() & Skin.SetXBE()R0