cordova-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bows...@apache.org
Subject [13/13] android commit: CB-6315: Wrapping this so it runs on the UI thread
Date Fri, 23 May 2014 21:23:51 GMT
CB-6315: Wrapping this so it runs on the UI thread


Project: http://git-wip-us.apache.org/repos/asf/cordova-android/repo
Commit: http://git-wip-us.apache.org/repos/asf/cordova-android/commit/404d3e09
Tree: http://git-wip-us.apache.org/repos/asf/cordova-android/tree/404d3e09
Diff: http://git-wip-us.apache.org/repos/asf/cordova-android/diff/404d3e09

Branch: refs/heads/4.0.x
Commit: 404d3e0959383fcc3c1ca253944c44fdce36bca9
Parents: f77b20b
Author: Joe Bowser <bowserj@apache.org>
Authored: Thu May 22 12:00:11 2014 -0700
Committer: Joe Bowser <bowserj@apache.org>
Committed: Fri May 23 11:31:13 2014 -0700

----------------------------------------------------------------------
 framework/src/org/apache/cordova/App.java | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cordova-android/blob/404d3e09/framework/src/org/apache/cordova/App.java
----------------------------------------------------------------------
diff --git a/framework/src/org/apache/cordova/App.java b/framework/src/org/apache/cordova/App.java
index ead99bc..4b15906 100755
--- a/framework/src/org/apache/cordova/App.java
+++ b/framework/src/org/apache/cordova/App.java
@@ -190,7 +190,11 @@ public class App extends CordovaPlugin {
      * Clear page history for the app.
      */
     public void clearHistory() {
-        this.webView.clearHistory();
+        cordova.getActivity().runOnUiThread(new Runnable() {
+            public void run() {
+                webView.clearHistory();
+            }
+        });
     }
 
     /**


Mime
View raw message