Bug 110 - When you close an app on Android you see a JS error in logcat.

This commit is contained in:
Bryce Curtis
2011-03-18 17:27:36 -05:00
parent 04de2052fd
commit 935295c9b8
2 changed files with 33 additions and 1 deletions
+4 -1
View File
@@ -649,7 +649,10 @@ public class DroidGap extends PhonegapActivity {
// Make sure pause event is sent if onPause hasn't been called before onDestroy
this.appView.loadUrl("javascript:try{PhoneGap.onPause.fire();}catch(e){};");
// Send destroy event to JavaScript
this.appView.loadUrl("javascript:try{PhoneGap.onDestroy.fire();}catch(e){};");
// Load blank page so that JavaScript onunload is called
this.appView.loadUrl("about:blank");