summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorfinnur@chromium.org <finnur@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-05-11 23:24:10 +0000
committerfinnur@chromium.org <finnur@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-05-11 23:24:10 +0000
commita4c97f1690aff9d343bb30c0fb178707fcb6c9c3 (patch)
treeafc24c286ef438bc8210535472f6dd5e507f7832
parent1c3cf8be7f9bbc0ca7ac6aab9a278bf79c392652 (diff)
downloadchromium_src-a4c97f1690aff9d343bb30c0fb178707fcb6c9c3.zip
chromium_src-a4c97f1690aff9d343bb30c0fb178707fcb6c9c3.tar.gz
chromium_src-a4c97f1690aff9d343bb30c0fb178707fcb6c9c3.tar.bz2
For extension apps, disable the bookmark bar from the launcher page.
BUG=None TEST=With --enable-extension-apps, make sure you don't get the bookmark bar. Review URL: http://codereview.chromium.org/1990015 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@46980 0039d316-1c4b-4281-b951-d872f2087c98
-rw-r--r--chrome/browser/views/bookmark_bar_view.cc11
1 files changed, 10 insertions, 1 deletions
diff --git a/chrome/browser/views/bookmark_bar_view.cc b/chrome/browser/views/bookmark_bar_view.cc
index 20a307a..5cf5469 100644
--- a/chrome/browser/views/bookmark_bar_view.cc
+++ b/chrome/browser/views/bookmark_bar_view.cc
@@ -33,6 +33,7 @@
#include "chrome/browser/views/event_utils.h"
#include "chrome/browser/views/frame/browser_view.h"
#include "chrome/browser/views/location_bar/location_bar_view.h"
+#include "chrome/common/chrome_switches.h"
#include "chrome/common/notification_service.h"
#include "chrome/common/page_transition_types.h"
#include "chrome/common/pref_names.h"
@@ -460,7 +461,15 @@ void BookmarkBarView::SetPageNavigator(PageNavigator* navigator) {
}
gfx::Size BookmarkBarView::GetPreferredSize() {
- return LayoutItems(true);
+ // We don't want the bookmark bar view in the app launcher new tab page.
+ static bool extension_apps = CommandLine::ForCurrentProcess()->HasSwitch(
+ switches::kEnableExtensionApps);
+ bool show_bookmark_bar = !(extension_apps && OnNewTabPage());
+
+ if (show_bookmark_bar)
+ return LayoutItems(true);
+ else
+ return gfx::Size();
}
gfx::Size BookmarkBarView::GetMinimumSize() {