summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/com/android/browser/Controller.java3
-rw-r--r--src/com/android/browser/PieControl.java9
-rw-r--r--src/com/android/browser/UiController.java2
3 files changed, 13 insertions, 1 deletions
diff --git a/src/com/android/browser/Controller.java b/src/com/android/browser/Controller.java
index 2fb465c..493583d 100644
--- a/src/com/android/browser/Controller.java
+++ b/src/com/android/browser/Controller.java
@@ -429,7 +429,8 @@ public class Controller
mUi = ui;
}
- BrowserSettings getSettings() {
+ @Override
+ public BrowserSettings getSettings() {
return mSettings;
}
diff --git a/src/com/android/browser/PieControl.java b/src/com/android/browser/PieControl.java
index 7c4291c..a33f8c6 100644
--- a/src/com/android/browser/PieControl.java
+++ b/src/com/android/browser/PieControl.java
@@ -118,6 +118,15 @@ public class PieControl implements PieMenu.PieController, OnClickListener {
if (tab != null) {
mForward.setEnabled(tab.canGoForward());
}
+ WebView view = mUiController.getCurrentWebView();
+ if (view != null) {
+ ImageView icon = (ImageView) mRDS.getView();
+ if (mUiController.getSettings().hasDesktopUseragent(view)) {
+ icon.setImageResource(R.drawable.ic_mobile);
+ } else {
+ icon.setImageResource(R.drawable.ic_desktop_holo_dark);
+ }
+ }
return true;
}
diff --git a/src/com/android/browser/UiController.java b/src/com/android/browser/UiController.java
index 5be2343..b3d4631 100644
--- a/src/com/android/browser/UiController.java
+++ b/src/com/android/browser/UiController.java
@@ -105,4 +105,6 @@ public interface UiController {
void toggleUserAgent();
+ BrowserSettings getSettings();
+
}