summaryrefslogtreecommitdiffstats
path: root/src/com/android/browser
diff options
context:
space:
mode:
authorJohn Reck <jreck@google.com>2011-07-27 13:19:08 -0700
committerJohn Reck <jreck@google.com>2011-07-27 13:20:45 -0700
commitcf1df73719e171915eed887a5f06916158e42f04 (patch)
tree83b4d669233f17f508b9a1e4b0744b06cbef6ff4 /src/com/android/browser
parentff6a748ae78165cc2298f5120a4374b4ed6f836b (diff)
downloadpackages_apps_Browser-cf1df73719e171915eed887a5f06916158e42f04.zip
packages_apps_Browser-cf1df73719e171915eed887a5f06916158e42f04.tar.gz
packages_apps_Browser-cf1df73719e171915eed887a5f06916158e42f04.tar.bz2
Fix dialog crash
Bug: 5007226 This is sort of a "nuke it from orbit" fix to prevent the crash as it is a test blocker. Bug 5086504 filed to track a "proper" fix Change-Id: Ifd02a1fee05a05d61d70724a1ae758701679fc27
Diffstat (limited to 'src/com/android/browser')
-rw-r--r--src/com/android/browser/GoogleAccountLogin.java10
1 files changed, 9 insertions, 1 deletions
diff --git a/src/com/android/browser/GoogleAccountLogin.java b/src/com/android/browser/GoogleAccountLogin.java
index cd96346..3896560 100644
--- a/src/com/android/browser/GoogleAccountLogin.java
+++ b/src/com/android/browser/GoogleAccountLogin.java
@@ -274,7 +274,15 @@ public class GoogleAccountLogin implements Runnable,
Log.d(LOGTAG, "Finished login attempt for " + mAccount.name);
mActivity.runOnUiThread(mRunnable);
- mProgressDialog.dismiss();
+ try {
+ mProgressDialog.dismiss();
+ } catch (Exception e) {
+ // TODO: Switch to a managed dialog solution (DialogFragment?)
+ // Also refactor this class, it doesn't
+ // play nice with the activity lifecycle, leading to issues
+ // with the dialog it manages
+ Log.w(LOGTAG, "Failed to dismiss mProgressDialog: " + e.getMessage());
+ }
mRunnable = null;
mActivity.runOnUiThread(new Runnable() {
@Override