2011-03-23, 18:09
I'm totally new to skinning and have finally decided to have a go and turn my Photoshop work into something that lives but I need a bit of help and wondered if someone can help.
I have a list which has a PNG image that I use as a button and as apposed to jumping from one item to the other, it animates up and down the list like the Apple TV UI. The problem is that when it scrolls from one item to another, the image layer order causes gets messed up and the button image obscures the item it’s leaving focus.
So in other words let’s say I have a list with two lines of text, 'TV Shows' and 'Movies'. If 'TV Shows' has focus then the image is behind the text which is correct. If I then scroll down to 'Movies' the image jumps in front of the 'TV Shows' text and then scrolls down behind 'Movies' and the same things repeats if I have something else in the list.
What I'm after is a way to always have the image behind the text even when it’s animated. Is this possible with the skinning engine?
Also I’m trying to achieve the middle item in a list scrolling effect like the Apple TV (sorry I don’t know how else to describe it). In other words I have a list with twenty items but only 10 are visible in the screen. When I scroll down to the sixth item, the button stops moving and the list starts to scroll. When the last item in the list is visible, the list stops scrolling and the button scrolls to the bottom.
I’ve been using code from another skin which is below but I said I’m new and have never coded anything in my life so I would love some help?
<focusedlayout height="50" width="300">
<control type="image">
<posy>0</posy>
<width>500</width>
<height>54</height>
<texture>button_scrolling.png</texture>
<aspectratio>keep</aspectratio>
<visible>Control.HasFocus(100)</visible>
<animation effect="slide" start="0,-50" end="0,0" time="200" reversible="false" easing="out" condition="Container(300).OnNext">Focus</animation>
<animation effect="slide" start="0,50" end="0,0" time="200" reversible="false" easing="out" condition="Container(300).OnPrevious">Focus</animation>
</control>
<control type="label">
<posy>24</posy>
<posx>324</posx>
<width>500</width>
<height>28</height>
<aligny>center</aligny>
<info>ListItem.Label</info>
<textcolor>White</textcolor>
<scroll>false</scroll>
<font>list1</font>
<align>center</align>
</control>
</focusedlayout>
I have a list which has a PNG image that I use as a button and as apposed to jumping from one item to the other, it animates up and down the list like the Apple TV UI. The problem is that when it scrolls from one item to another, the image layer order causes gets messed up and the button image obscures the item it’s leaving focus.
So in other words let’s say I have a list with two lines of text, 'TV Shows' and 'Movies'. If 'TV Shows' has focus then the image is behind the text which is correct. If I then scroll down to 'Movies' the image jumps in front of the 'TV Shows' text and then scrolls down behind 'Movies' and the same things repeats if I have something else in the list.
What I'm after is a way to always have the image behind the text even when it’s animated. Is this possible with the skinning engine?
Also I’m trying to achieve the middle item in a list scrolling effect like the Apple TV (sorry I don’t know how else to describe it). In other words I have a list with twenty items but only 10 are visible in the screen. When I scroll down to the sixth item, the button stops moving and the list starts to scroll. When the last item in the list is visible, the list stops scrolling and the button scrolls to the bottom.
I’ve been using code from another skin which is below but I said I’m new and have never coded anything in my life so I would love some help?
<focusedlayout height="50" width="300">
<control type="image">
<posy>0</posy>
<width>500</width>
<height>54</height>
<texture>button_scrolling.png</texture>
<aspectratio>keep</aspectratio>
<visible>Control.HasFocus(100)</visible>
<animation effect="slide" start="0,-50" end="0,0" time="200" reversible="false" easing="out" condition="Container(300).OnNext">Focus</animation>
<animation effect="slide" start="0,50" end="0,0" time="200" reversible="false" easing="out" condition="Container(300).OnPrevious">Focus</animation>
</control>
<control type="label">
<posy>24</posy>
<posx>324</posx>
<width>500</width>
<height>28</height>
<aligny>center</aligny>
<info>ListItem.Label</info>
<textcolor>White</textcolor>
<scroll>false</scroll>
<font>list1</font>
<align>center</align>
</control>
</focusedlayout>