summaryrefslogtreecommitdiff
path: root/src/com/android/browser/Controller.java
diff options
context:
space:
mode:
authorLeon Scroggins <scroggo@google.com>2011-02-15 10:19:04 -0800
committerAndroid (Google) Code Review <android-gerrit@google.com>2011-02-15 10:19:04 -0800
commit6eb5077fa54d88530ce88ef5db44365f3079b615 (patch)
tree910c9104d0ef39aa96074f0e1d669448882208c7 /src/com/android/browser/Controller.java
parent417f3be57344584bb46d8c6ae6b4d5100b75fbab (diff)
parent8198376342e04934eb953317a4ba31d2dd84da9f (diff)
Merge "Do not allow saving a web archive of a web archive."
Diffstat (limited to 'src/com/android/browser/Controller.java')
-rw-r--r--src/com/android/browser/Controller.java5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/com/android/browser/Controller.java b/src/com/android/browser/Controller.java
index 745a0f4b..b2738e1f 100644
--- a/src/com/android/browser/Controller.java
+++ b/src/com/android/browser/Controller.java
@@ -1467,6 +1467,11 @@ public class Controller
final MenuItem newtab = menu.findItem(R.id.new_tab_menu_id);
newtab.setEnabled(getTabControl().canCreateNewTab());
+ MenuItem archive = menu.findItem(R.id.save_webarchive_menu_id);
+ String url = getCurrentTopWebView().getUrl();
+ archive.setVisible(!TextUtils.isEmpty(url)
+ && !url.endsWith("webarchivexml"));
+
break;
}
mCurrentMenuState = mMenuState;