weird image display due to animations, possibly a bug
#1
Hi, I am having trouble with a button displaying as I would like it to... the code is:
Code:
<control type="image">
                    <animation type="WindowOpen" reversible="false">
                        <effect type="fade" start="0" end="30" time="500" tween="sine" />
                        <effect type="zoom" start="0" end="70" center="auto" time="500" tween="back" />
                    </animation>
                    <animation type="WindowClose" reversible="false">
                        <effect type="fade" start="30" end="0" time="200" tween="sine" />
                    </animation>
                    <animation type="Conditional" condition="Control.HasFocus(555)" reversible="true">
                        <effect type="fade" start="30" end="100" time="400" tween="sine" />
                        <effect type="zoom" start="70" end="100" center="auto" time="400" tween="back" />
                    </animation>
                    <posx>40</posx>
                    <posy>1000</posy>
                    <width>48</width>
                    <height>48</height>
                    <texture>home1/power.png</texture>
                 </control>
As you can see, I would like the image to default to being a bit smaller and transparent until you select the button, at which point the size and opacity should be 100%. However this doesn't happen, and on selection, the image stays at 30 and 70, and decreases further when moving away. The control is just a hidden button. Logically, at least to me, the above should work ...is this a bug? And what do you recommend as a workaround?
Reply
#2
The effects are multiplicative, not additive. Thus, the maximum opacity will be 30% as you currently have it. Changing the end to 100 on the WindowOpen will fix it for that I should think.
Always read the XBMC online-manual, FAQ and search the forum before posting.
Do not e-mail XBMC-Team members directly asking for support. Read/follow the forum rules.
For troubleshooting and bug reporting please make sure you read this first.


Image
Reply
#3
Doesn't seem to work...setting the end to 100 just makes the image completely opaque for the default, as opposed to slightly transparent (since the button is not focused). Thanks anyways, I guess I'll have to come up with a different design.
Reply
#4
You don't have to. Just change the animations to

PHP Code:
<animation type="WindowOpen" reversible="false">
    <
effect type="fade" start="0" end="100" time="500" tween="sine" easing="inout" />
    <
effect type="zoom" start="0" end="100" center="auto" time="500" tween="back" easing="out" />
</
animation>
<
animation type="WindowClose" reversible="false">
    <
effect type="fade" start="100" end="0" time="200" tween="sine" easing="inout" />
</
animation>
<
animation type="Conditional" condition="!Control.HasFocus(555)">
    <
effect type="fade" start="100" end="30" time="400" tween="sine" easing="inout" />
    <
effect type="zoom" start="100" end="70" center="auto" time="400" tween="back" easing="in" />
</
animation
Image
Reply
#5
(2013-06-20, 19:49)`Black Wrote: You don't have to. Just change the animations to
Smile
Thanks a lot Black, that worked.
Reply

Logout Mark Read Team Forum Stats Members Help
weird image display due to animations, possibly a bug0