mirror of
https://github.com/apache/cordova-android.git
synced 2025-01-19 07:02:51 +08:00
CB-3766: Javascript uses loadUrl, not loadUrlIntoView, which is only for documents
This commit is contained in:
parent
e2a090bbba
commit
a021adb7fd
@ -806,7 +806,7 @@ public class CordovaWebView extends WebView {
|
||||
{
|
||||
// Send destroy event to JavaScript
|
||||
// Since baseUrl is set in loadUrlIntoView, if user hit Back button before loadUrl was called, we'll get an NPE on baseUrl (CB-2458)
|
||||
this.loadUrlIntoView("javascript:try{cordova.require('cordova/channel').onDestroy.fire();}catch(e){console.log('exception firing destroy event from native');};");
|
||||
this.loadUrl("javascript:try{cordova.require('cordova/channel').onDestroy.fire();}catch(e){console.log('exception firing destroy event from native');};");
|
||||
|
||||
// Load blank page so that JavaScript onunload is called
|
||||
this.loadUrl("about:blank");
|
||||
|
Loading…
Reference in New Issue
Block a user