How do I use alt button images for cast/plot in VideoInfo
#1
Question 
Hi Guys,

Sorry if this is a noob type question, but I searched thru the forums and could not find anything that I thought would help. What I'm trying to do is to show an alternate set of button images when the user presses the plot/cast button (id="5"). That is a set (focused and unfocused) for when button shows "plot" and another set when button shows "cast" as its label. Now ordinarily I would just use a toggle button in this case, but my understanding is that "bad things"™ will happen if I use anything other that a ordinary button for this particular control.

How do people generally solve this type of problem?

Wyrm (xTV-SAF)
If required a FULL debug log can now be submitted from the skin in settings->skin settings->support. Or follow instructions here if you can't access skin settings.

FAQ's located at :- http://kodi.wiki/view/Add-on:AppTV
Reply
#2
Code:
<texturefocus>CastFocus.png</texturefocus>
<texturenofocus>CastNoFocus.png</texturenofocus>
<alttexturefocus>PlotFocus.png</alttexturefocus>
<alttexturenofocus>PlotNoFocus.png</alttexturenofocus>
<usealttexture>StringCompare(Control.GetLabel(5),$LOCALIZE[207]</usealttexture>

or

Code:
<usealttexture>Control.IsVisible(50)</usealttexture>
Reply
#3
(2014-12-18, 19:50)Hitcher Wrote:
Code:
<texturefocus>CastFocus.png</texturefocus>
<texturenofocus>CastNoFocus.png</texturenofocus>
<alttexturefocus>PlotFocus.png</alttexturefocus>
<alttexturenofocus>PlotNoFocus.png</alttexturenofocus>
<usealttexture>StringCompare(Control.GetLabel(5),$LOCALIZE(207)</usealttexture>

or

Code:
<usealttexture>Control.IsVisible(50)</usealttexture>
Hitcher,

Thanks for the reply mate, but sorry that did not work (I always thought that would only work in a toggle button control). The only idea I had was to have two controls with id="5" with different visible conditions, but that always seem to throw errors into the log, and I would prefer to avoid that. I don't suppose you have any other ideas? I have also tried placing conditions in the texture tags and that did not work either.

Wyrm (xTV-SAF)
If required a FULL debug log can now be submitted from the skin in settings->skin settings->support. Or follow instructions here if you can't access skin settings.

FAQ's located at :- http://kodi.wiki/view/Add-on:AppTV
Reply
#4
Made a typo, try -

Code:
<usealttexture>StringCompare(Control.GetLabel(5),$LOCALIZE[207])</usealttexture>
Reply
#5
(2014-12-19, 11:27)Hitcher Wrote: Made a typo, try -

Code:
<usealttexture>StringCompare(Control.GetLabel(5),$LOCALIZE[207])</usealttexture>
No sorry mate, still does not work. About the only other thing I can think of is to have another Togglebutton that sends a keyclick to the plot/cast button (which I hide), but not sure how to code this idea. How would I code the send key click in the togglebutton?

Wyrm (xTV-SAF)
If required a FULL debug log can now be submitted from the skin in settings->skin settings->support. Or follow instructions here if you can't access skin settings.

FAQ's located at :- http://kodi.wiki/view/Add-on:AppTV
Reply
#6
I guess you could use normal button without any textures to serve the function (similar to hidden button), while you could have a toggle button that would be placed and drawn over button="5" but with onclick>-</onclick> for the sole purpose of using different textures - if you know what I mean?
My skins:

Amber
Quartz

Reply
#7
(2014-12-19, 14:05)wyrm Wrote:
(2014-12-19, 11:27)Hitcher Wrote: Made a typo, try -

Code:
<usealttexture>StringCompare(Control.GetLabel(5),$LOCALIZE[207])</usealttexture>
No sorry mate, still does not work. About the only other thing I can think of is to have another Togglebutton that sends a keyclick to the plot/cast button (which I hide), but not sure how to code this idea. How would I code the send key click in the togglebutton?

Wyrm (xTV-SAF)

Works in XeeBo although I used !StringCompare(Control.GetLabel(5),$LOCALIZE[206]).
Reply
#8
(2014-12-19, 16:29)Hitcher Wrote:
(2014-12-19, 14:05)wyrm Wrote:
(2014-12-19, 11:27)Hitcher Wrote: Made a typo, try -

Code:
<usealttexture>StringCompare(Control.GetLabel(5),$LOCALIZE[207])</usealttexture>
No sorry mate, still does not work. About the only other thing I can think of is to have another Togglebutton that sends a keyclick to the plot/cast button (which I hide), but not sure how to code this idea. How would I code the send key click in the togglebutton?

Wyrm (xTV-SAF)

Works in XeeBo although I used !StringCompare(Control.GetLabel(5),$LOCALIZE[206]).

@Hitcher, no mate grabed the code from Xeebo exactly as you had listed and still no go. It would seem the dev's plugged that 'hack' in Helix. No matter managed to get this working, see next part of this message.

@pecinko, <Facepalm>, your suggestion reminded me that I did something very similar in PlayerControls.xml . Thought I had seen a solution to the problem somewhere ;-)

Thanks guys, as always your help is much appreciated.

Wyrm (xTV-SAF)
If required a FULL debug log can now be submitted from the skin in settings->skin settings->support. Or follow instructions here if you can't access skin settings.

FAQ's located at :- http://kodi.wiki/view/Add-on:AppTV
Reply
#9
(2014-12-20, 17:32)wyrm Wrote:
(2014-12-19, 16:29)Hitcher Wrote:
(2014-12-19, 14:05)wyrm Wrote: No sorry mate, still does not work. About the only other thing I can think of is to have another Togglebutton that sends a keyclick to the plot/cast button (which I hide), but not sure how to code this idea. How would I code the send key click in the togglebutton?

Wyrm (xTV-SAF)

Works in XeeBo although I used !StringCompare(Control.GetLabel(5),$LOCALIZE[206]).

@Hitcher, no mate grabed the code from Xeebo exactly as you had listed and still no go. It would seem the dev's plugged that 'hack' in Helix. No matter managed to get this working, see next part of this message.

Just tested XeeBo on Helix and it still works. Huh
Reply
#10
(2014-12-20, 18:42)Hitcher Wrote:
(2014-12-20, 17:32)wyrm Wrote:
(2014-12-19, 16:29)Hitcher Wrote: Works in XeeBo although I used !StringCompare(Control.GetLabel(5),$LOCALIZE[206]).

@Hitcher, no mate grabed the code from Xeebo exactly as you had listed and still no go. It would seem the dev's plugged that 'hack' in Helix. No matter managed to get this working, see next part of this message.

Just tested XeeBo on Helix and it still works. Huh
Hitcher,

Alright problem is probably at my end (off my face on pain meds for my back at the moment). I'm about to send a special e-mail to our one eyed mate, so will release with what I currently have and revisit this for my next release. One control using your suggestion, or about twelve using what I have at the moment, I know which way I would prefer to do things.

Thanks again mate.
Wyrm (xTV-SAF)
If required a FULL debug log can now be submitted from the skin in settings->skin settings->support. Or follow instructions here if you can't access skin settings.

FAQ's located at :- http://kodi.wiki/view/Add-on:AppTV
Reply

Logout Mark Read Team Forum Stats Members Help
How do I use alt button images for cast/plot in VideoInfo0