summaryrefslogtreecommitdiffstats
path: root/src/com/android/browser/BaseUi.java
diff options
context:
space:
mode:
authorPatrick Scott <phanna@android.com>2011-03-10 08:46:27 -0500
committerPatrick Scott <phanna@android.com>2011-03-10 08:46:27 -0500
commit9206677e461328f15854c5fcb1366d0e261534c6 (patch)
tree947b5120265de84ae6f85d647b5f191d8f89914d /src/com/android/browser/BaseUi.java
parentf06113a9c90b72e73af2f63d93fd2debd9b7cd3c (diff)
downloadpackages_apps_Browser-9206677e461328f15854c5fcb1366d0e261534c6.tar.gz
packages_apps_Browser-9206677e461328f15854c5fcb1366d0e261534c6.tar.bz2
packages_apps_Browser-9206677e461328f15854c5fcb1366d0e261534c6.zip
Add new auto-login UI.
When the WebView notifies us of an auto-login request, check if the account is valid. If so, use it to log into the account manager. If that fails or the account is not valid, display the login UI. Bug: 3367381 Change-Id: I5a164ef676921eec03a89860fa5be722d3d987d4
Diffstat (limited to 'src/com/android/browser/BaseUi.java')
-rw-r--r--src/com/android/browser/BaseUi.java13
1 files changed, 13 insertions, 0 deletions
diff --git a/src/com/android/browser/BaseUi.java b/src/com/android/browser/BaseUi.java
index 5084e319e..71346ae35 100644
--- a/src/com/android/browser/BaseUi.java
+++ b/src/com/android/browser/BaseUi.java
@@ -240,6 +240,7 @@ public abstract class BaseUi implements UI, WebViewFactory {
onProgressChanged(tab);
boolean incognito = mActiveTab.getWebView().isPrivateBrowsingEnabled();
getTitleBar().setIncognitoMode(incognito);
+ updateAutoLogin(tab, false);
}
Tab getActiveTab() {
@@ -546,11 +547,23 @@ public abstract class BaseUi implements UI, WebViewFactory {
&& mComboView == null;
}
+ @Override
+ public void showAutoLogin(Tab tab) {
+ updateAutoLogin(tab, true);
+ }
+
+ @Override
+ public void hideAutoLogin(Tab tab) {
+ updateAutoLogin(tab, true);
+ }
+
// -------------------------------------------------------------------------
protected void updateNavigationState(Tab tab) {
}
+ protected void updateAutoLogin(Tab tab, boolean animate) {}
+
/**
* Update the lock icon to correspond to our latest state.
*/