Kodi Community Forum
Need help with animation code... - Printable Version

+- Kodi Community Forum (https://forum.kodi.tv)
+-- Forum: Development (https://forum.kodi.tv/forumdisplay.php?fid=32)
+--- Forum: Skinning (https://forum.kodi.tv/forumdisplay.php?fid=12)
+--- Thread: Need help with animation code... (/showthread.php?tid=31136)



Need help with animation code... - Livin - 2008-02-10

I'd appreciate if someone can help me get this working.

Trying to get the Time & Weather to fade in and out, opposite of each other in the same location... while pausing at full visibility for a time period; not sure of the best # yet but using 200 for now.

Thanks for the help! Big Grin

Code:
    <control type="label" id="70">
        <include>timeformat</include>
        <label>$INFO[System.Date]  |  $INFO[System.Time]</label>
        <scrollout>false</scrollout>
        <pauseatend>6000</pauseatend>
        <visible>Skin.HasSetting(timepanel)</visible>
        <animation effect="fade" pulse="true" start="20" time="200" condition="!Control.IsVisible(71)">Conditional</animation>
    </control>
    <control type="label" id="71">
        <include>timeformat</include>
        <font>font13s</font>
        <align>left</align>
        <label>$INFO[Weather.Location]  |  $INFO[Weather.Conditions]  $INFO[Weather.Temperature]</label>
        <animation effect="fade" pulse="true" delay="200" start="20" time="200" condition="!Control.IsVisible(70)">Conditional</animation>
    </control>
    <control type="image" id="71">
        <description>Weather image</description>
        <include>timeformat</include>
        <width>33</width>
        <height>38</height>
        <aspectratio>keep</aspectratio>
        <info>Weather.Conditions</info>
        <animation effect="fade" pulse="true" delay="200" start="20" time="200" condition="!Control.IsVisible(70)">Conditional</animation>
    </control>



- Nuka1195 - 2008-02-10

does the fadelabel take multiple <label> entries?


- Livin - 2008-02-10

Nuka1195 Wrote:does the fadelabel take multiple <label> entries?

does not work with Images.


- jmarshall - 2008-02-11

For a start, two controls with id 71 is bad practise.


- Livin - 2008-02-11

I can change the ID but I don't think that will get it working.

Can you help with the code?


- jmarshall - 2008-02-11

I can possibly help if you set it up on the PM3 homepage and tell me exactly what you want it to do.

Cheers,
Jonathan


- Livin - 2008-02-11

jmarshall Wrote:I can possibly help if you set it up on the PM3 homepage and tell me exactly what you want it to do.

Cheers,
Jonathan

I'd like Loop a pulse (fade in & out) between two sets of objects...

Set1: System.Date + System.Time

Set2: Weather.Location + Weather.Conditions + Weather.Conditions Image

... in the same screen location (upper right side).

Loop...
{Set1 fades in to full Vis, pauses at full viz a few seconds, fades out
Set2 fades in to full Vis, pauses at full viz a few seconds, fades out }

If fadelabel worked for Images would that be a solution to the goal?


Do you mean you want me to integrate it into the PM3 home.xml? I can do that.


Code:
    <control type="label" id="70">
        <include>timeformat</include>
        <label>$INFO[System.Date]  |  $INFO[System.Time]</label>
        <scrollout>false</scrollout>
        <pauseatend>6000</pauseatend>
        <visible>Skin.HasSetting(timepanel)</visible>
        <animation effect="fade" delay="200" pulse="true" start="20" time="400" condition="!Control.IsVisible(71) + !Control.IsVisible(72)">Conditional</animation>
    </control>
    <control type="label" id="71">
        <include>timeformat</include>
        <font>font13s</font>
        <align>left</align>
        <label>$INFO[Weather.Location]  |  $INFO[Weather.Conditions]  $INFO[Weather.Temperature]</label>
        <animation effect="fade" pulse="true" start="20" time="400" condition="!Control.IsVisible(70)">Conditional</animation>
    </control>
    <control type="image" id="72">
        <description>Weather image</description>
        <include>timeformat</include>
        <width>33</width>
        <height>38</height>
        <aspectratio>keep</aspectratio>
        <info>Weather.Conditions</info>
        <animation effect="fade" pulse="true" start="20" time="400" condition="!Control.IsVisible(70)">Conditional</animation>
    </control>



- jmarshall - 2008-02-11

Yes. Integrate it into PM3 homepage will make it far easier for me to test and see what (if anything) is wrong.

I don't believe PM3 has <include>timeformat</include> for instance.


- Livin - 2008-02-12

I integrated the Includes to both XMLs. Please use this link to DL zip file.

sections marked as <!-- ADDED FOR TEST denote the areas I changed.