IsEmpty(Control.GetLabel(7014)) doesn't work on XBOX
#1
I know team XBMC doesn't support XBOX but hopefully arnova takes a peek..

My upcoming skin works pretty well on XBOX but my logo-label fallback doesn't. And I use that type of code alot to make things work automatically instead of having a bunch of skin settings.

Simply put it's:

image 1 id="7500"
image 2 id="7501"
Label fallback="IsEmpty(Control.GetLabel(7500)) + IsEmpty(Control.GetLabel(7501))"

Below is actual code block:
PHP Code:
<control type="largeimage" id="7018">
                <
posx>20</posx>
                <
posy>0</posy>
                <
width>230</width>
                <
height>89</height>
                <
texture>$INFO[ListItem.path]logo.png</texture>
                <
fadetime>200</fadetime>
                <
aspectratio scalediffuse="false">stretch</aspectratio>
                <include>
Animation_Viewtype_3dland_Lefttop</include>
                <
visible></visible>
            </
control>
            <
control type="largeimage" id="9018">
                <
posx>20</posx>
                <
posy>0</posy>
                <
width>230</width>
                <
height>89</height>
                <
texture>$INFO[ListItem.path]../logo.png</texture>
                <
fadetime>200</fadetime>
                <
aspectratio scalediffuse="false">stretch</aspectratio>
                <include>
Animation_Viewtype_3dland_Lefttop</include>
                <
visible></visible>
            </
control>
            <
control type="label">
                <
posx>20</posx>
                <
posy>0</posy>
                <
width>1200</width>
                <
height>50</height>
                <
aligny>center</aligny>
                <
font>Font_Bartowski_Landscape_TV_Title</font>
                <
textcolor>ff67ffff</textcolor>
                <
label>[b]$INFO[ListItem.TVShowTitle][/b]</label>
                <include>
Animation_Viewtype_3dland_Lefttop</include>
                <
visible>IsEmpty(Control.GetLabel(7018)) + IsEmpty(Control.GetLabel(9018))</visible>
            </
control

The skin seems to work good but not having that type of label fallback means it's either all logo's or no logo's, there can't be any in between...Thx for any replies.
Image

Check out The Carmichael - A Skin For XBMC

Check out Night - A Skin For XBMC

Check out Unfinished - A Skin For XBMC
#2
You're not setting any label for it to check, so IsEmpty will not work properly when defined as such.

Try setting the visibility of the images based on the path you're using to generate those images.

<visible>!isEmpty($INFO[ListItem.path]logo.png)</visible>

Then change your fallback bool to Isvisible for each label number.

Syntax is probably wrong, been a while since I've coded, but I think this will do what you're looking for.
#3
Thx for the reply...That sort of works, as in, now both label and logo don't show like before but that label fallback doesn't show when logo is not there. Plus IsEmpty($INFO[ListItem.path]logo.png) doesn't work on non-xbox versions like the original code...
Image

Check out The Carmichael - A Skin For XBMC

Check out Night - A Skin For XBMC

Check out Unfinished - A Skin For XBMC
#4
mcborzu Wrote:Thx for the reply...That sort of works, as in, now both label and logo don't show like before but that label fallback doesn't show when logo is not there. Plus IsEmpty($INFO[ListItem.path]logo.png) doesn't work on non-xbox versions like the original code...

I see...you're pulling an image based on the path of the listitem. When I tried doing this, I found that custom images like this don't work for Xbox at all unless they're locally stored.

What does "Control.GetLabel(9018)" return if you were to place it in a string label when it has a valid image to point to??
#5
digitalhigh Wrote:What does "Control.GetLabel(9018)" return if you were to place it in a string label when it has a valid image to point to??

D:\Big TV Shows\Bones\logo.png
Image

Check out The Carmichael - A Skin For XBMC

Check out Night - A Skin For XBMC

Check out Unfinished - A Skin For XBMC
#6
Well, the problem would seem to be that the path is always going to be not empty because you're adding the "logo.png" bit to the texture. Therefore, even when invalid (and not displaying a picture) it's gonna show up with a texture assigned.

I could be wrong, but I think you'd have to have the image assigned to the DB so that it can be checked as being there or not. The generic workaround will display the images, but XBMC cannot check if the image is really there or not, so you can't tell the label to display based on that.

I think a skin setting is about the only workaround...unless you have the label hidden by the image.

Edit: Sexy skin BTW...lemme know if you need any beta testers.
#7
It seems to check fine and display the label fallback if there is no logo on Main XBMC just not XBOX version...I'm on XBOX 28766 BTW.
Image

Check out The Carmichael - A Skin For XBMC

Check out Night - A Skin For XBMC

Check out Unfinished - A Skin For XBMC
#8
Fascinating...

I apologize if my information is inaccurate...it has been a good stretch of time since I've actively skinned, and my brain is still operating with what it knew XBMC as being capable of since then.

So, on the xbox, what does that test string label return when there is no image present?
#9
Yea, I don't know the underlying reason why things work.Smile Ronie actually found that trick...

On XBOX both the logo and the label show at the same time....
Image

Check out The Carmichael - A Skin For XBMC

Check out Night - A Skin For XBMC

Check out Unfinished - A Skin For XBMC
#10
What I'm saying is, what does "Control.GetLabel(9018)" return if you were to place it in a string label when it has no valid image to point to?
#11
digitalhigh Wrote:What I'm saying is, what does "Control.GetLabel(9018)" return if you were to place it in a string label when it has no valid image to point to?

Just returns blank...
Image

Check out The Carmichael - A Skin For XBMC

Check out Night - A Skin For XBMC

Check out Unfinished - A Skin For XBMC
#12
Code:
<control type="largeimage" id="7018">
                <posx>20</posx>
                <posy>0</posy>
                <width>230</width>
                <height>89</height>
                <texture>$INFO[ListItem.path]logo.png</texture>
                <fadetime>200</fadetime>
                <aspectratio scalediffuse="false">stretch</aspectratio>
                <include>Animation_Viewtype_3dland_Lefttop</include>
                [i]<visible>!Control.GetLabel(7018)</visible>[/i]
            </control>
            <control type="largeimage" id="9018">
                <posx>20</posx>
                <posy>0</posy>
                <width>230</width>
                <height>89</height>
                <texture>$INFO[ListItem.path]../logo.png</texture>
                <fadetime>200</fadetime>
                <aspectratio scalediffuse="false">stretch</aspectratio>
                <include>Animation_Viewtype_3dland_Lefttop</include>
                [i]<visible>!Control.GetLabel(9018)</visible>[/i]
            </control>
            <control type="label">
                <posx>20</posx>
                <posy>0</posy>
                <width>1200</width>
                <height>50</height>
                <aligny>center</aligny>
                <font>Font_Bartowski_Landscape_TV_Title</font>
                <textcolor>ff67ffff</textcolor>
                <label>[b]$INFO[ListItem.TVShowTitle][/b]</label>
                <include>Animation_Viewtype_3dland_Lefttop</include>
                [i]<visible>!Control.Isvisible(7018) + !Control.Isvisible(9018)</visible>[/i]
            </control>

Try this out...changed the visibility of the two images based on Getlabel function, then the vis. of the label depending on when the images are visible. By all logic, it should work.
#13
Thx for taking the time, by the look of it the code seems good but didn't work...
Image

Check out The Carmichael - A Skin For XBMC

Check out Night - A Skin For XBMC

Check out Unfinished - A Skin For XBMC

Logout Mark Read Team Forum Stats Members Help
IsEmpty(Control.GetLabel(7014)) doesn't work on XBOX0