Hi Sinthuja,
Yes, currently there's no use of user preference 'updateInterval'.

Initial plan was to read refresh interval as a user preference. Due some
diffuculties we moved the gadget refreshing logic to gadget level. So we
left property definition there so that it could be used in the future.
Anyway we'll remove it from index.xml since there's no current usage and
it'll make confusion.

Nirodha,

I believe your requirement can be achieved using something like below.

var REFRESH_INTERVAL = 5000;

setInterval(function() {
        renderGadget();
    },REFRESH_INTERVAL);

This code needs to be inside your gadget.

On Mon, May 2, 2016 at 12:46 PM, Sinthuja Ragendran <[email protected]>
wrote:

> Hi Dunith,
>
> If we don't use the the update interval at all, then it should not be in
> the user pref element. :) We need to correct this behaviour.
>
> Thanks,
> Sinthuja.
>
> On Mon, May 2, 2016 at 12:36 PM, Nirodha Gallage <[email protected]> wrote:
>
>> Hi Dunith,
>>
>> Then I guess the term "Update Interval" is a bit confusing. Even sinthuja
>> understood it the same way.
>>
>>
>>
>>
>> On Mon, May 2, 2016 at 12:24 PM, Dunith Dhanushka <[email protected]>
>> wrote:
>>
>>> Hi Nirodha,
>>>
>>> I assume you are referring to the gadget user preference called 'Update
>>> Interval'. In fact, that was just a placeholder property which has no
>>> effect on gadget's polling interval.
>>>
>>> For wizard generated gadget, polling interval is configured in
>>> js/main.js file as follows.
>>>
>>> var REFRESH_INTERVAL = 5000;
>>>
>>>
>>> Thanks,
>>> Dunith
>>>
>>> On Mon, May 2, 2016 at 12:14 PM, Sinthuja Ragendran <[email protected]>
>>> wrote:
>>>
>>>> Hi Nirodha,
>>>>
>>>> Yeah, AFAIU it'll fetch the data from the DAS based on the time
>>>> interval provided here and reload the gadget. @Dunith, please confirm.
>>>>
>>>> Thanks,
>>>> Sinthuja.
>>>>
>>>> On Mon, May 2, 2016 at 11:47 AM, Nirodha Gallage <[email protected]>
>>>> wrote:
>>>>
>>>>> Hi,
>>>>>
>>>>> What's the usage of 'update interval' option given for gadgets in
>>>>> Dashboard server. Is it that gadget should be reloaded automatically in 
>>>>> the
>>>>> given intervals?
>>>>>
>>>>> Thanks,
>>>>> Nirodha
>>>>>
>>>>> --
>>>>>
>>>>> *Nirodha Gallage*
>>>>> Associate Technical Lead
>>>>> WSO2 Inc.: http://wso2.com/
>>>>> Mobile: +94716429078
>>>>>
>>>>
>>>>
>>>>
>>>> --
>>>> *Sinthuja Rajendran*
>>>> Associate Technical Lead
>>>> WSO2, Inc.:http://wso2.com
>>>>
>>>> Blog: http://sinthu-rajan.blogspot.com/
>>>> Mobile: +94774273955
>>>>
>>>>
>>>>
>>>
>>>
>>> --
>>> Regards,
>>>
>>> Dunith Dhanushka,
>>> Senior Software Engineer
>>> WSO2 Inc,
>>>
>>> Mobile - +94 71 8615744
>>> Blog - dunithd.wordpress.com <http://blog.dunith.com>
>>> Twitter - @dunithd <http://twitter.com/dunithd>
>>>
>>
>>
>>
>> --
>>
>> *Nirodha Gallage*
>> Associate Technical Lead
>> WSO2 Inc.: http://wso2.com/
>> Mobile: +94716429078
>>
>
>
>
> --
> *Sinthuja Rajendran*
> Associate Technical Lead
> WSO2, Inc.:http://wso2.com
>
> Blog: http://sinthu-rajan.blogspot.com/
> Mobile: +94774273955
>
>
>


-- 
Regards,

Dunith Dhanushka,
Senior Software Engineer
WSO2 Inc,

Mobile - +94 71 8615744
Blog - dunithd.wordpress.com <http://blog.dunith.com>
Twitter - @dunithd <http://twitter.com/dunithd>
_______________________________________________
Dev mailing list
[email protected]
http://wso2.org/cgi-bin/mailman/listinfo/dev

Reply via email to