From 531b8f641ff1dc9b7e4228c1a5beea457d1844ca Mon Sep 17 00:00:00 2001 From: Joe Bowser Date: Fri, 13 Apr 2012 15:43:17 -0700 Subject: [PATCH] Adding old code back, we can't access webViewClient methods without them being on the UI thread. :( --- framework/src/org/apache/cordova/DroidGap.java | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/framework/src/org/apache/cordova/DroidGap.java b/framework/src/org/apache/cordova/DroidGap.java index 04cd01dd..9b77e028 100755 --- a/framework/src/org/apache/cordova/DroidGap.java +++ b/framework/src/org/apache/cordova/DroidGap.java @@ -407,11 +407,10 @@ public class DroidGap extends Activity implements CordovaInterface { // If timeout, then stop loading and handle error if (me.loadUrlTimeout == currentLoadUrlTimeout) { - /* - me.appView.stopLoading(); - LOG.e(TAG, "DroidGap: TIMEOUT ERROR! - calling webViewClient"); - me.webViewClient.onReceivedError(me.appView, -6, "The connection to the server was unsuccessful.", url); - */ + me.appView.stopLoading(); + LOG.e(TAG, "DroidGap: TIMEOUT ERROR! - calling webViewClient"); + //We need another mechanism for handling timeout errors, we can't use webViewClient.onReceivedError anymore. + //me.webViewClient.onReceivedError(me.appView, -6, "The connection to the server was unsuccessful.", url); } } };