Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(4711)

Unified Diff: chrome/browser/ui/toolbar/toolbar_actions_bar.cc

Issue 1246643004: [Extensions UI] Highlight toolbar extensions when the redesign bubble is active (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: chrome/browser/ui/toolbar/toolbar_actions_bar.cc
diff --git a/chrome/browser/ui/toolbar/toolbar_actions_bar.cc b/chrome/browser/ui/toolbar/toolbar_actions_bar.cc
index 31600f6974fe2f5f51648ce5fd554cd2bec938fc..d720fcb613cd2bb144e1c992fc2c1a0ab73769d0 100644
--- a/chrome/browser/ui/toolbar/toolbar_actions_bar.cc
+++ b/chrome/browser/ui/toolbar/toolbar_actions_bar.cc
@@ -372,7 +372,9 @@ void ToolbarActionsBar::CreateActions() {
// CreateActions() can be called multiple times, so we need to make sure we
// haven't already shown the bubble.
- if (!checked_extension_bubble_) {
+ // Extension bubbles can also highlight a subset of actions, so don't show the
+ // bubble if the toolbar is already highlighting a different set.
+ if (!checked_extension_bubble_ && !is_highlighting()) {
checked_extension_bubble_ = true;
// CreateActions() can be called as part of the browser window set up, which
// we need to let finish before showing the actions.
@@ -664,6 +666,8 @@ void ToolbarActionsBar::ResizeDelegate(gfx::Tween::Type tween_type,
}
void ToolbarActionsBar::OnToolbarHighlightModeChanged(bool is_highlighting) {
+ if (!model_->extensions_initialized())
+ return;
// It's a bit of a pain that we delete and recreate everything here, but given
// everything else going on (the lack of highlight, [n] more extensions
// appearing, etc), it's not worth the extra complexity to create and insert
« no previous file with comments | « chrome/browser/ui/toolbar/toolbar_actions_bar.h ('k') | chrome/browser/ui/views/toolbar/browser_actions_container.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698