diff options
| author | John Reck <jreck@google.com> | 2010-12-16 17:30:34 -0800 |
|---|---|---|
| committer | John Reck <jreck@google.com> | 2010-12-17 14:19:05 -0800 |
| commit | 30c714c853a4239e72ab1e238ce2a92472d06ab0 (patch) | |
| tree | 397e4e02aa9404f008d65d24fa1d3e6ae039ccd9 /src/com/android/browser/PageDialogsHandler.java | |
| parent | 39772c83f8e210eed1186b66f5f4841aa41776ee (diff) | |
| download | packages_apps_Browser-30c714c853a4239e72ab1e238ce2a92472d06ab0.tar.gz packages_apps_Browser-30c714c853a4239e72ab1e238ce2a92472d06ab0.tar.bz2 packages_apps_Browser-30c714c853a4239e72ab1e238ce2a92472d06ab0.zip | |
Overhaul handling tab data updates
Bug: 2127502, 3191165
Pushed some state tracking to the tab for URL, title, favicon,
and lock status. This allowed me to remove many duplicate methods
of updating that data, preventing the UI from getting out of sync
with the web view.
Change-Id: I995caa98068ad03ca37710207b5ab57bb9d801ab
Diffstat (limited to 'src/com/android/browser/PageDialogsHandler.java')
| -rw-r--r-- | src/com/android/browser/PageDialogsHandler.java | 18 |
1 files changed, 3 insertions, 15 deletions
diff --git a/src/com/android/browser/PageDialogsHandler.java b/src/com/android/browser/PageDialogsHandler.java index 6843a10fc..2dbddf32d 100644 --- a/src/com/android/browser/PageDialogsHandler.java +++ b/src/com/android/browser/PageDialogsHandler.java @@ -97,7 +97,7 @@ public class PageDialogsHandler { mHttpAuthenticationDialog.setCancelListener(new HttpAuthenticationDialog.CancelListener() { public void onCancel() { handler.cancel(); - mController.resetTitleAndRevertLockIcon(tab); + mController.onUpdatedLockIcon(tab); mHttpAuthenticationDialog = null; } }); @@ -138,20 +138,8 @@ public class PageDialogsHandler { final WebView view = tab.getWebView(); - String url = null; - String title = null; - - if (view == null) { - url = tab.getUrl(); - title = tab.getTitle(); - } else if (view == mController.getCurrentWebView()) { - // Use the cached title and url if this is the current WebView - url = tab.getCurrentUrl(); - title = tab.getCurrentTitle(); - } else { - url = view.getUrl(); - title = view.getTitle(); - } + String url = tab.getUrl(); + String title = tab.getTitle(); if (url == null) { url = ""; |
