summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorMichael Kolb <kolby@google.com>2011-11-23 10:34:27 -0800
committerAndroid Git Automerger <android-git-automerger@android.com>2011-11-23 10:34:27 -0800
commit9ac672c759915a161a45c113da0957bfbba85cbb (patch)
tree1ecb474d7c24771a4cb83fcb77fb71f43da164bc /src
parent686d4812922ad12c5b7ca2e15021a49a56a58fc6 (diff)
parent63faec479010e77762d5ffa517fdc65f3474383c (diff)
downloadpackages_apps_browser-9ac672c759915a161a45c113da0957bfbba85cbb.zip
packages_apps_browser-9ac672c759915a161a45c113da0957bfbba85cbb.tar.gz
packages_apps_browser-9ac672c759915a161a45c113da0957bfbba85cbb.tar.bz2
am 63faec47: Merge "Add more options to Quick Controls on phone" into ics-mr1
* commit '63faec479010e77762d5ffa517fdc65f3474383c': Add more options to Quick Controls on phone
Diffstat (limited to 'src')
-rw-r--r--src/com/android/browser/PieControlPhone.java14
1 files changed, 13 insertions, 1 deletions
diff --git a/src/com/android/browser/PieControlPhone.java b/src/com/android/browser/PieControlPhone.java
index f12c49a..2b6a3c5 100644
--- a/src/com/android/browser/PieControlPhone.java
+++ b/src/com/android/browser/PieControlPhone.java
@@ -24,6 +24,7 @@ import android.view.View.OnClickListener;
import android.widget.PopupMenu;
import android.widget.PopupMenu.OnMenuItemClickListener;
+import com.android.browser.UI.ComboViews;
import com.android.browser.view.PieItem;
import com.android.browser.view.PieMenu.PieView.OnLayoutListener;
import com.android.browser.view.PieStackView;
@@ -40,6 +41,8 @@ public class PieControlPhone extends PieControlBase implements OnClickListener,
private PieItem mUrl;
private PieItem mShowTabs;
private PieItem mOptions;
+ private PieItem mNewTab;
+ private PieItem mBookmarks;
private TabAdapter mTabAdapter;
private PopupMenu mPopup;
@@ -67,10 +70,14 @@ public class PieControlPhone extends PieControlBase implements OnClickListener,
1);
// level 1
+ mNewTab = makeItem(R.drawable.ic_new_window_holo_dark, 1);
+ mBookmarks = makeItem(R.drawable.ic_bookmarks_holo_dark, 1);
+ mPie.addItem(mNewTab);
mPie.addItem(mShowTabs);
mPie.addItem(mUrl);
+ mPie.addItem(mBookmarks);
mPie.addItem(mOptions);
- setClickListener(this, mUrl, mShowTabs, mOptions);
+ setClickListener(this, mUrl, mShowTabs, mOptions, mNewTab, mBookmarks);
mPopup = new PopupMenu(mActivity, mUi.getTitleBar());
Menu menu = mPopup.getMenu();
mPopup.getMenuInflater().inflate(R.menu.browser, menu);
@@ -105,6 +112,11 @@ public class PieControlPhone extends PieControlBase implements OnClickListener,
mUi.showNavScreen();
} else if (mOptions.getView() == v) {
showMenu();
+ } else if (mNewTab.getView() == v) {
+ mUiController.openTabToHomePage();
+ mUi.editUrl(false);
+ } else if (mBookmarks.getView() == v) {
+ mUiController.bookmarksOrHistoryPicker(ComboViews.Bookmarks);
}
}