summaryrefslogtreecommitdiffstats
path: root/src/com/android/browser/TabControl.java
diff options
context:
space:
mode:
authorMichael Kolb <kolby@google.com>2010-08-19 12:42:01 -0700
committerMichael Kolb <kolby@google.com>2010-09-03 15:37:06 -0700
commit68775756e20243d73f273e4ce25ff3edeb148e41 (patch)
treec9d1833b04cec4ca8941588392affa1349682ee5 /src/com/android/browser/TabControl.java
parent9ff6bfc39003783e148c04188a3af7e031e4a75a (diff)
downloadpackages_apps_browser-68775756e20243d73f273e4ce25ff3edeb148e41.zip
packages_apps_browser-68775756e20243d73f273e4ce25ff3edeb148e41.tar.gz
packages_apps_browser-68775756e20243d73f273e4ce25ff3edeb148e41.tar.bz2
disable zoom buttons
Change-Id: I6b99b74bb1930c6a66903bd4894f51f3aaf33e89
Diffstat (limited to 'src/com/android/browser/TabControl.java')
-rw-r--r--src/com/android/browser/TabControl.java12
1 files changed, 12 insertions, 0 deletions
diff --git a/src/com/android/browser/TabControl.java b/src/com/android/browser/TabControl.java
index 7377a1e..d7435d7 100644
--- a/src/com/android/browser/TabControl.java
+++ b/src/com/android/browser/TabControl.java
@@ -48,6 +48,8 @@ class TabControl {
private final BrowserActivity mActivity;
// Directory to store thumbnails for each WebView.
private final File mThumbnailDir;
+ // Use on screen zoom buttons
+ private boolean mDisplayZoomControls;
/**
* Construct a new TabControl object that interfaces with the given
@@ -58,6 +60,7 @@ class TabControl {
TabControl(BrowserActivity activity) {
mActivity = activity;
mThumbnailDir = activity.getDir("thumbnails", 0);
+ mDisplayZoomControls = true;
}
File getThumbnailDir() {
@@ -69,6 +72,14 @@ class TabControl {
}
/**
+ * Set if the webview should use the on screen zoom controls
+ * @param enabled
+ */
+ void setDisplayZoomControls(boolean enabled) {
+ mDisplayZoomControls = enabled;
+ }
+
+ /**
* Return the current tab's main WebView. This will always return the main
* WebView for a given tab and not a subwindow.
* @return The current tab's WebView.
@@ -597,6 +608,7 @@ class TabControl {
w.setMapTrackballToArrowKeys(false); // use trackball directly
// Enable the built-in zoom
w.getSettings().setBuiltInZoomControls(true);
+ w.getSettings().setDisplayZoomControls(mDisplayZoomControls);
// Add this WebView to the settings observer list and update the
// settings
final BrowserSettings s = BrowserSettings.getInstance();