This is a migrated thread and some comments may be shown as answers.

Handle the event when the app is brought back from background

1 Answer 13 Views
General Discussion
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Andrzej
Top achievements
Rank 1
Andrzej asked on 14 Jul 2015, 03:30 AM

Hi,

My app allows the use to drag and drop rows of a table. If the app is suspended when the user is dragging a row (phone call etc), I need to be able to reset the dragging when the user gets back to the app. Otherwise, the dragging mechanism gets screwed up because it never registers the end touch event.

Is there anyway to do this?

1 Answer, 1 is accepted

Sort by
0
Tina Stancheva
Telerik team
answered on 16 Jul 2015, 12:35 PM
Hi Andrzej,

If you are building a hybrid application in AppBuilder, then you should be able to use Cordova's resume event to track when the app is retrieved from the background:
document.addEventListener("resume", function(){
  //your custom logic
}, false);

If that is not what you are looking for, please elaborate on your scenario a bit more and I will suggest more to-the-point solutions.

Regards,
Tina Stancheva
Telerik
 

Visit the Telerik Verified Plugins Marketplace and get the custom Cordova plugin you need, already tweaked to work seamlessly with AppBuilder.

 
Tags
General Discussion
Asked by
Andrzej
Top achievements
Rank 1
Answers by
Tina Stancheva
Telerik team
Share this question
or