语言

Menu
Sites
Language
Gear S2 Background tick update

Hello,

I'm developing watch faces for the Gear S2 using WEB apps. I want to know if there is a way to add a meta data or anything like that to the config file so that it updates the watch face before the screen turns on? Right now, users are complaining that my watch faces have a small delay when the screen turns on. Basically, they jump from the time when the screen is off to the time when the screen wakes up.

Thanks a lot!

响应

7 回复
daniel kim

Hi,

I've obseved such phenomenon very often on other watchface as well. and I think that such thing is due to battery comsumption.

Regards

Le Hoang

According to this post, it is possible to tweak the background update, but it is for native apps. I hope there is a way to do it for web apps as well

 

http://developer.samsung.com/forum/board/thread/view.do?boardName=SDK&messageId=285670&startId=zzzzz~&curPage=2&searchSubId=0000000032

AVSukhov

Hello,

I did not see such feature in the official documentation.

At the moment, there is no way to do what you want to use Web API.

I hope such functionality will add in future SDK releases.

Seoghyun Kang

Hello,

 

If you use the visibilitychange event  , I assume that you can reduce the delay.

document.addEventListener("visibilitychange", function() {
    if (!document.hidden) {
         // REDRAW
    }
});

 

 

AVSukhov

Hello,

As i understand, listener for visibilitychange event is callback for "resume" state.

but it is necessary events that occur before "resume" to update watch face.

Seoghyun Kang

This is the guide from the browser team. I hope we reduce the some delay and remove some bug.

The watch samples in Tizen SDK 2.3.1  will be updated for applying the visibilitychange  event.

 

AVSukhov

Hello,

Thanks for sharing.

I will have to look at this example and understand. I may have missed something.

I hope this information will help submiter.