Best way I can put it is that Container(9000).ListItem.Property() works everywhere but inside a list control.
It works here
but it doesn't work here or in any control inside this control
The second one is always false, it has no access to the content in control 9000.
I flattened the Home.xml of Metropolis to the minimum so I could demonstrate this (no includes or variables outside of this window view other than script.skin.helper.widgets for the content of the widget).
Is that short enough to not need a paste bin link?
It could be that I missed a change to the skinning engine and I need to change the way I do it.
Any ideas?
It works here
Code:
<control type="image">
<visible>String.IsEqual(Container(9000).ListItem.Property(submenuVisibility),movies)</visible>
</control>
Code:
<control type="list" id="8000">
<control
<visible>String.IsEqual(Container(9000).ListItem.Property(submenuVisibility),movies)</visible>
</control>
</control>
The second one is always false, it has no access to the content in control 9000.
I flattened the Home.xml of Metropolis to the minimum so I could demonstrate this (no includes or variables outside of this window view other than script.skin.helper.widgets for the content of the widget).
Code:
<?xml version="1.0" encoding="UTF-8"?>
<window>
<defaultcontrol always="true">9000</defaultcontrol>
<controls>
<!-- Sub-menus and upper-menus -->
<control type="group" id="9004">
<!-- Widgets for all home views -->
<control type="group">
<!-- Widget arrow for all home views -->
<control type="image">
<posx>625</posx>
<posy>420</posy>
<width>30</width>
<height>30</height>
<texture>ArrowUp.png</texture>
<colordiffuse>HelpArrowDiffuse</colordiffuse>
<visible>!String.IsEmpty(Container(9000).ListItem.Property(widget))</visible>
<visible>![Control.HasFocus(8000)]</visible>
</control>
<!-- Widget titles for all home views -->
<control type="label">
<posx>355</posx>
<posy>400</posy>
<width>570</width>
<height>25</height>
<align>center</align>
<aligny>center</aligny>
<font>METF_RecentlyAddedTitle</font>
<textcolor>HomeMenuText</textcolor>
<label>[b]$INFO[Container(9000).ListItem.Property(widgetName)][/b]</label>
<shadowcolor>ff000000</shadowcolor>
<visible>!String.IsEmpty(Container(9000).ListItem.Property(widget))</visible>
<visible>![Control.HasFocus(8000)]</visible>
</control>
</control>
<!-- Widgets -->
<control type="group" id="9002">
<control type="image">
<visible>String.IsEqual(Container(9000).ListItem.Property(submenuVisibility),movies)</visible>
<posx>265</posx>
<posy>560</posy>
<width>250</width>
<height>140</height>
<aspectratio align="right" aligny="center">keep</aspectratio>
<bordertexture border="6">frames/thumb_border_round.png</bordertexture>
<bordersize>6</bordersize>
<texture diffuse="frames/EpisodeMatte.png">$INFO[Container(8000).ListItem.Icon]</texture>
</control>
<control type="list" id="8000">
<visible>String.IsEqual(Container(9000).ListItem.Property(submenuVisibility),movies)</visible>
<posx>522</posx>
<posy>563</posy>
<width>510</width>
<height>135</height>
<onup>8000</onup>
<ondown>8000</ondown>
<onleft>9000</onleft>
<onright>9000</onright>
<viewtype>list</viewtype>
<orientation>vertical</orientation>
<scrolltime>200</scrolltime>
<itemlayout width="510" height="27">
<control type="label">
<posx>10</posx>
<posy>-2</posy>
<width>500</width>
<height>27</height>
<align>left</align>
<aligny>center</aligny>
<scrollout>false</scrollout>
<pauseatend>600</pauseatend>
<scrollspeed>20</scrollspeed>
<font>METF_RecentlyAddedListText</font>
<textcolor>RecentlyAddedNF</textcolor>
<label>$INFO[ListItem.Label]</label>
<visible>[!String.IsEmpty(Container(9000).ListItem.Property(widget))] | [Control.HasFocus(8000)]</visible>
</control>
</itemlayout>
<focusedlayout width="510" height="27">
<!-- Focus Bar -->
<control type="image">
<posx>0</posx>
<posy>0</posy>
<width>510</width>
<height>27</height>
<aligny>center</aligny>
<texture>FocusLine.png</texture>
<colordiffuse>FocusBar</colordiffuse>
<visible>[!String.IsEmpty(Container(9000).ListItem.Property(widget))] | [Control.HasFocus(8000)]</visible>
</control>
<control type="label">
<posx>10</posx>
<posy>-2</posy>
<width>500</width>
<height>27</height>
<align>left</align>
<aligny>center</aligny>
<scrollout>false</scrollout>
<pauseatend>600</pauseatend>
<scrollspeed>20</scrollspeed>
<font>METF_RecentlyAddedListText</font>
<textcolor>FocusBarText</textcolor>
<label>$INFO[ListItem.Label]</label>
<visible>[!String.IsEmpty(Container(9000).ListItem.Property(widget))] | [Control.HasFocus(8000)]</visible>
</control>
</focusedlayout>
<content target="videos">plugin://script.skin.helper.widgets/?action=recent&mediatype=movies&reload=$INFO[Window(home).Property(widgetreload-movies)]</content>
</control>
</control>
</control>
<!-- Main Menu -->
<control type="wraplist" id="9000">
<posx>0</posx>
<posy>450</posy>
<height>450</height>
<width>1280</width>
<onup>9002</onup>
<ondown>9001</ondown>
<onleft>9000</onleft>
<onright>9000</onright>
<viewtype>list</viewtype>
<orientation>horizontal</orientation>
<focusposition>2</focusposition>
<scrolltime>200</scrolltime>
<itemgap>0</itemgap>
<preloaditems>2</preloaditems>
<itemlayout height="60" width="300">
<control type="label">
<left>-110</left>
<top>0</top>
<width>298</width>
<height>60</height>
<font>METF_HorizMenu</font>
<textcolor>SubmenuText</textcolor>
<align>center</align>
<aligny>center</aligny>
<label>$INFO[ListItem.Label]</label>
</control>
</itemlayout>
<focusedlayout height="60" width="300">
<control type="label">
<left>-110</left>
<top>0</top>
<width>298</width>
<height>60</height>
<font>METF_HorizMenu</font>
<textcolor>SubmenuTextFocused</textcolor>
<shadowcolor>ff000000</shadowcolor>
<align>center</align>
<aligny>center</aligny>
<label>$INFO[ListItem.Label]</label>
</control>
</focusedlayout>
<content>
<item id="1">
<property name="id">$NUMBER[1]</property>
<label>$LOCALIZE[342]</label>
<label2>Common menu item</label2>
<icon>home_icons/movies.png</icon>
<thumb />
<property name="labelID">movies</property>
<property name="defaultID">movies</property>
<property name="widget">RecentMovies</property>
<property name="widgetName">20386</property>
<property name="widgetType">movies</property>
<property name="widgetPath">plugin://script.skin.helper.widgets/?action=recent&mediatype=movies&reload=$INFO[Window(home).Property(widgetreload-movies)]</property>
<property name="widgetTarget">videos</property>
<property name="background">home\movies\</property>
<property name="backgroundName">342</property>
<visible>Library.HasContent(Movies)</visible>
<onclick>ActivateWindow(Videos,MovieTitles,return)</onclick>
<property name="path">ActivateWindow(Videos,MovieTitles,return)</property>
<property name="list">MovieTitles</property>
<property name="submenuVisibility">movies</property>
<property name="group">mainmenu</property>
<property name="hasSubmenu">False</property>
</item>
<item id="2">
<property name="id">$NUMBER[2]</property>
<label>$LOCALIZE[31334]</label>
<label2>Common menu item</label2>
<icon>home_icons/trailers.png</icon>
<thumb />
<property name="labelID">plugin.video.itunes_trailers</property>
<property name="defaultID">trailers</property>
<property name="background">home\trailers\</property>
<property name="backgroundName">31334</property>
<visible>System.HasAddon(plugin.video.itunes_trailers)</visible>
<onclick>ActivateWindow(Videos,plugin://plugin.video.itunes_trailers,return)</onclick>
<property name="path">ActivateWindow(Videos,plugin://plugin.video.itunes_trailers,return)</property>
<property name="list">plugin://plugin.video.itunes_trailers</property>
<property name="submenuVisibility">plugin-video-itunes-trailers</property>
<property name="group">mainmenu</property>
<property name="hasSubmenu">False</property>
</item>
<item id="3">
<property name="id">$NUMBER[3]</property>
<label>$LOCALIZE[10004]</label>
<label2>Common menu item</label2>
<icon>home_icons/settings.png</icon>
<thumb />
<property name="labelID">settings</property>
<property name="defaultID">settings</property>
<property name="background">home\settings\</property>
<property name="backgroundName">10004</property>
<onclick>ActivateWindow(Settings)</onclick>
<property name="path">ActivateWindow(Settings)</property>
<property name="list">Settings</property>
<property name="submenuVisibility">settings</property>
<property name="group">mainmenu</property>
<property name="hasSubmenu">False</property>
</item>
<item id="4">
<property name="id">$NUMBER[4]</property>
<label>$LOCALIZE[13005]</label>
<label2>Common menu item</label2>
<icon>home_icons/shutdown.png</icon>
<thumb />
<property name="labelID">13005</property>
<property name="defaultID">shutdown</property>
<property name="background">home\shutdown\</property>
<property name="backgroundName">13005</property>
<onclick>ShutDown</onclick>
<property name="path">ShutDown</property>
<property name="list">ShutDown</property>
<property name="submenuVisibility">num-13005</property>
<property name="group">mainmenu</property>
<property name="hasSubmenu">True</property>
</item>
</content>
</control>
</controls>
</window>
It could be that I missed a change to the skinning engine and I need to change the way I do it.
Any ideas?