Languages

Menu
Sites
Language
How do I know my web app is running in background ?

It's like a chat app,need a notifacation when app runs background.

so how can I know web app is running in background ?

Edited by: Brock Boland on 17 Mar, 2014 Reason: Paragraph tags added automatically from tizen_format_fix module.

Responses

5 Replies
Vineet Tiwari
Hi xi chen, The notification widget shows a pop-up window on the screen to provide notifications. Use the following sample code to add notification in your web app:

text1

text2

Thanks, Vineet Tiwari
Vineet Tiwari
Hi xi chen, The notification widget shows a pop-up window on the screen to provide notifications. Use the following sample code to add notification in your web app:

text1

text2

Thanks, Vineet Tiwari
xi chen
I want to know app is running in background ,not notifacation . #4 have given a answer ,thank you all the same
Lakshmi Grandhi
Hi xi chen, You have use focusin and focusout events to know whether your application is foreground or background. $("#page1").focusin(function (){ console.log("received focus In Event") ; }) $("#page1").focusout(function (){ console.log("received focus Out Event") ; })
xi chen
I will have a try ,thanks very much