XWidgetSoft Forum https://bbs.xwidget.com/ |
|
The Script is ok? https://bbs.xwidget.com/viewtopic.php?f=8&t=5217 |
Page 1 of 1 |
Author: | Jimking [ November 8th, 2014, 3:05 pm ] |
Post subject: | The Script is ok? |
I would like to create an animation weather widget like this one: viewtopic.php?f=11&t=4931&hilit=minions but this time with only weather icons (I have a number of png for each weather condition, so they will be animpng again). There will be two differences with the "Despicable Me Weather HD ANIMATED" widget: 1) I will use this tag for current weather "${curWeatherIcon}" so they will be 18 animpngs 2)The animations will have "0" loop count so they will play continuously. This is the script by @hamid from the minions weather widget: ---------------------------------- var WeatherNames=[sun,cloudy,fog,rain,lightning,snow,moon,moon_cloudy] function accweathercore1OnUpdate(Sender) { var weathertmp=eval(accweathercore1.get("${curSimpleWeatherIcon}")) if(weathertmp.Visible==false) { for(var i in WeatherNames) { WeatherNames[i].Visible=0 WeatherNames[i].Src="" } var listtmp="" var imgtmp=GetFileList(WidgetPath+"\\"+weathertmp.Name,"png",0).split("|") for(var j=1;j<imgtmp.length;j++) { listtmp+=weathertmp.Name+"\\"+j+".png"+"|" } listtmp+=weathertmp.Name+"\\"+imgtmp.length+".png" weathertmp.Src=listtmp weathertmp.OnClick="StartAnimating" weathertmp.Visible=1 StartAnimating(weathertmp) } } --------------------------------- My question is: I will need to change only the two parts of the script with the red color..? Or I need to change anything else... |
Author: | hamid [ November 11th, 2014, 6:36 am ] |
Post subject: | Re: The Script is ok? |
Author: | Jimking [ November 11th, 2014, 6:53 am ] |
Post subject: | Re: The Script is ok? |
Ok I will test it as soon as possible.. Thanks mate! |
Author: | Jimking [ November 11th, 2014, 5:48 pm ] |
Post subject: | Re: The Script is ok? |
Author: | hamid [ November 11th, 2014, 7:54 pm ] | ||
Post subject: | Re: The Script is ok? | ||
|
Author: | Jimking [ November 11th, 2014, 8:12 pm ] |
Post subject: | Re: The Script is ok? |
Ok... because I took the weather names from here: viewtopic.php?f=10&t=4837 I'll reply as soon as possible hamid.. Edit: All seem to work properly now. Thanks man! |
Author: | Jimking [ November 14th, 2014, 8:03 am ] |
Post subject: | Re: The Script is ok? |
I added city name and temp and edited the animpng properties with "inverse on finish" to give the effect of a continuous movement. |
Author: | hamid [ November 15th, 2014, 5:34 am ] |
Post subject: | Re: The Script is ok? |
i don't think the "inverse on finish" effect will be good for it, even i'm not sure if the infinite loop would be so good, but i think adding infinite loop as RightClick option will be fine |
Author: | Jimking [ November 15th, 2014, 5:55 am ] |
Post subject: | Re: The Script is ok? |
Author: | hamid [ November 17th, 2014, 9:41 pm ] |
Post subject: | Re: The Script is ok? |
ok, it's ready: animated_weather_hd [test3] [2014.11.18]0901.xwp [1.63 KiB] Downloaded 226 times =========== Changes: Added: RightClickMenu for Enable/Disable Animation Loop ============== |
Author: | Jimking [ November 18th, 2014, 3:00 am ] |
Post subject: | Re: The Script is ok? |
Thanks man! The widget is ready now: * Unchecked the "inverse onfinish" * Added city/temp info viewtopic.php?f=11&t=5260&p=10634#p10634 |
Page 1 of 1 | All times are UTC - 8 hours |
Powered by phpBB® Forum Software © phpBB Group http://www.phpbb.com/ |