Kodi Community Forum

Full Version: visability isemty question
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
trying to skip a flag position if the there ain't no flag in folder. is this possible?
in file IncludesCodecFlagging.xml
Code:
<include name="StudioFlaggingConditions">
<control type="image">
  <description>Studio Image</description>
  <width>60</width>
  <height>33</height>
  <aspectratio>keep</aspectratio>
  <texture>$INFO[ListItem.Studio,flagging/studio/,.png]</texture>
  <visible>!IsEmpty(ListItem.Studio,flagging/studio/,.png)</visible>
</control>
</include>
result is no studioflags get shown.
No but if there's nothing there what's the problem?
it reserves the spot so there is a blank spot in the flaglist.
Give it an id and fallback then use stringcompare.

PHP Code:
<include name="StudioFlaggingConditions">
 <
control type="image" id="9999">
  <
description>Studio Image</description>
  <
width>60</width>
  <
height>33</height>
  <
aspectratio>keep</aspectratio>
  <
texture fallback="empty">$INFO[ListItem.Studio,flagging/studio/,.png]</texture>
  <
visible>!StringCompare(Control.GetLabel(9999),empty)</visible>
 </
control
did not work. when empty the flags keep jumping back and forth over the empty spot.
If you're talking about my skin, the <grouplist> does automatically adjust if there isnt a match. The only time you'd get a blank spot is if it 'hits' a correct match but doesnt have an image to correspond to that match.

While answering this I noticed I get a blank space when video resolution is "576" because it's getting a match but there is no image to display...

To test its working swap these around - Viewtype_Poster.xml:
Quote:<include>VideoCodecFlaggingConditions</include>
<include>AudioCodecFlaggingConditions</include>
<include>AspectCodecFlaggingConditions</include>
<include>VideoTypeHackFlaggingConditions</include>

to

Quote:<include>VideoTypeHackFlaggingConditions</include>
<include>VideoCodecFlaggingConditions</include>
<include>AudioCodecFlaggingConditions</include>
<include>AspectCodecFlaggingConditions</include>

If you dont have a match on those blueray filename matches, which I dont personally use, you dont get a blank spot on the first slot. The <grouplist> automatically adjusts...
yep i'm playing around with ur skin mcborzu.

Code:
        <control type="grouplist"><!--flags-->
            <visible>Control.IsVisible(55) + [Container.Content(movies) | Container.Content(episodes) ] + !Skin.HasSetting(clean_poster) + !Skin.HasSetting(no_media_flags) + !Control.IsVisible(68)</visible>
            <description>Media Codec Flagging Images</description>
            <posx>5</posx>
            <posy>680</posy>
            <width>1280</width>
            <align>left</align>
            <itemgap>0</itemgap>
            <orientation>horizontal</orientation>
            <include>StudioFlaggingConditions</include>
            <include>VideoCodecFlaggingConditions</include>
            <include>AudioCodecFlaggingConditions</include>
            <include>AspectCodecFlaggingConditions</include>
            <include>VideoTypeHackFlaggingConditions</include>
            <include>VideoMPAAFlaggingConditions</include>
            <include>Animation_HiddenByInfo</include>
            <include>Animation_ZoomInZoomOut</include>
        </control>

this ain't working for studioflags. ur videotypehackflags works perfectly however.
This works:

PHP Code:
<control type="grouplist">
            <
visible>Control.IsVisible(55) + Container.Content(movies) + !Skin.HasSetting(clean_poster) + !Skin.HasSetting(no_media_flags) + !Control.IsVisible(68)</visible>
            <
description>Media Codec Flagging Images</description>
            <
animation effect="slide" start="0,0" end="-70,0" time="0" tween="cubic" easing="inout" condition="IsEmpty(Control.GetLabel(7179))">Conditional</animation>
            <
posx>20</posx>
            <
posy>680</posy>
            <
width>1280</width>
            <
align>left</align>
            <
itemgap>0</itemgap>
            <
orientation>horizontal</orientation>
            <
control type="image" id="7179">
                <
posx>0</posx>
                <
posy>0</posy>
                <
width>70</width>
                <
height>47</height>
                <
texture>$INFO[listitem.studio,extras/Studios/,.png]</texture>
                <
colordiffuse>ff67ffff</colordiffuse>
            </
control>
            <include>
VideoCodecFlaggingConditions</include>
            <include>
AudioCodecFlaggingConditions</include>
            <include>
AspectCodecFlaggingConditions</include>
            <include>
VideoTypeHackFlaggingConditions</include>
            <include>
Animation_HiddenByInfo</include>
            <include>
Animation_ZoomInZoomOut</include>
        </
control
i still get a empty spot where there ain't no flags.
zwat Wrote:i still get a empty spot where there ain't no flags.

Which flags? Studios? What I posted works.

Give it a slide effect:

Quote:<animation effect="slide" start="0,0" end="-70,0" time="0" tween="cubic" easing="inout" condition="IsEmpty(Control.GetLabel(7179))">Conditional</animation>

and give the image for studios an unique id
Quote:<control type="image" id="7179">
hmm still ain't working at all for me Sad what is id 68 btw?

seems to me that it is only the videotypehackflagging that does not take a spot when noting is there. all other icons have set space.
Should be 65 not 68, it's the scrollbar id....

Post both your studio include and then the flag code block
Code:
        <control type="grouplist"><!--flags-->
            <visible>Control.IsVisible(55) + [Container.Content(movies) | Container.Content(tvshows) | Container.Content(seasons) | Container.Content(episodes) ] + !Skin.HasSetting(clean_poster) + !Skin.HasSetting(no_media_flags) + !Control.IsVisible(65)</visible>
            <description>Media Codec Flagging Images</description>
            <posx>5</posx>
            <posy>680</posy>
            <width>1280</width>
            <align>left</align>
            <itemgap>0</itemgap>
            <orientation>horizontal</orientation>
            <include>VideoCodecFlaggingConditions</include>
            <include>AudioCodecFlaggingConditions</include>
            <include>AspectCodecFlaggingConditions</include>
            <include>VideoTypeHackFlaggingConditions</include>
            <control type="image" id="9999999">
                <posx>0</posx>
                <posy>0</posy>
                <width>70</width>
                <height>47</height>
                <animation effect="slide" start="0,0" end="-70,0" time="0" tween="cubic" easing="inout" condition="IsEmpty(Control.GetLabel(9999999))">Conditional</animation>
                <texture>$INFO[listitem.studio,flagging/studio/,.png]</texture>
            </control>
            <include>VideoMPAAFlaggingConditions</include>
            <include>Animation_HiddenByInfo</include>
            <include>Animation_ZoomInZoomOut</include>
        </control>

Code:
    <include name="StudioFlaggingConditions">
        <control type="image">
            <description>Studio Image</description>
            <width>60</width>
            <height>33</height>
            <aspectratio>keep</aspectratio>
            <texture>$INFO[ListItem.Studio,flagging/studio/,.png]</texture>
        </control>
    </include>
You got your slide in the wrong place:

Quote:<control type="grouplist"><!--flags-->
<visible>Control.IsVisible(55) + [Container.Content(movies) | Container.Content(episodes) ] + !Skin.HasSetting(clean_poster) + !Skin.HasSetting(no_media_flags) + !Control.IsVisible(68)</visible>
<description>Media Codec Flagging Images</description>
<animation effect="slide" start="0,0" end="-70,0" time="0" tween="cubic" easing="inout" condition="IsEmpty(Control.GetLabel(7176))">Conditional</animation>
<posx>5</posx>
<posy>680</posy>
<width>1280</width>
<align>left</align>
<itemgap>0</itemgap>
<orientation>horizontal</orientation>
<include>StudioFlaggingConditions</include>
<include>VideoCodecFlaggingConditions</include>
<include>AudioCodecFlaggingConditions</include>
<include>AspectCodecFlaggingConditions</include>
<include>VideoTypeHackFlaggingConditions</include>
<include>VideoMPAAFlaggingConditions</include>
<include>Animation_HiddenByInfo</include>
<include>Animation_ZoomInZoomOut</include>
</control>

Quote:<include name="StudioFlaggingConditions">
<control type="image" id="7176">
<description>Studio Image</description>
<width>60</width>
<height>33</height>
<aspectratio>keep</aspectratio>
<texture>$INFO[ListItem.Studio,flagging/studio/,.png]</texture>
</control>
</include>
tnx that did the trick Big Grin