2015-03-04, 13:22
Sorry ahead of time if this is a dumb question and I'm just not figuring out the right process to use.
I searched through "http://mirrors.xbmc.org/docs/python-docs" and could not find anything in there for an onUnFocus event.
Using a WindowXML window there is...def onClick(self, controlID):, def onFocus(self, controlID): and such.
How would one define onUnFocus? The reason I ask is because I'm using an alarmclock...
on Initialization of the window to cycle through a top artists list but I want to cancel the alarm and stop cycling when the list has focus.
I tried putting ...
in the XML for the list like you would do for a regular window but it don't work.
I can add...
to stop the cycle when the list has focus and that works, but I can't figure out the right process to use to get it to start cycling again after the list loses focus like you could do for a regular window using onFocus and onUnfocus. So I suppose I am just asking if there is something equivalent to use for onUnFocus in a WindowXML window? Thanks.
I searched through "http://mirrors.xbmc.org/docs/python-docs" and could not find anything in there for an onUnFocus event.
Using a WindowXML window there is...def onClick(self, controlID):, def onFocus(self, controlID): and such.
How would one define onUnFocus? The reason I ask is because I'm using an alarmclock...
PHP Code:
xbmc.executebuiltin('AlarmClock(topartists,Control.Move(7010,1),00:08,silent,loop)')
on Initialization of the window to cycle through a top artists list but I want to cancel the alarm and stop cycling when the list has focus.
I tried putting ...
PHP Code:
<onfocus>CancelAlarm(topartists,true)</onfocus>
<onunfocus>AlarmClock(topartists,Control.Move(7010,1),00:08,silent,loop)</onunfocus>
in the XML for the list like you would do for a regular window but it don't work.
I can add...
PHP Code:
def onFocus(self, controlID):
if controlID == 7010:
xbmc.executebuiltin( 'CancelAlarm(topartists,true)')
to stop the cycle when the list has focus and that works, but I can't figure out the right process to use to get it to start cycling again after the list loses focus like you could do for a regular window using onFocus and onUnfocus. So I suppose I am just asking if there is something equivalent to use for onUnFocus in a WindowXML window? Thanks.