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

Unified Diff: chrome/browser/extensions/extension_toolbar_model.cc

Issue 798323005: [Extensions Toolbar] Fix an issue where incognito extensions were overflowed (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Latest master Created 6 years 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
« no previous file with comments | « no previous file | chrome/browser/ui/toolbar/toolbar_actions_bar.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/extensions/extension_toolbar_model.cc
diff --git a/chrome/browser/extensions/extension_toolbar_model.cc b/chrome/browser/extensions/extension_toolbar_model.cc
index 196ec8671826658acfec0c2690bf4e18461c2b35..c578535b80046b26074a02e6d871430cdab36f12 100644
--- a/chrome/browser/extensions/extension_toolbar_model.cc
+++ b/chrome/browser/extensions/extension_toolbar_model.cc
@@ -327,9 +327,6 @@ void ExtensionToolbarModel::AddExtension(const Extension* extension) {
// to the full list (|toolbar_items_|, there won't be another *visible*
// browser action, which was what the observers care about.
if (!is_highlighting_) {
- FOR_EACH_OBSERVER(
- Observer, observers_, ToolbarExtensionAdded(extension, new_index));
-
// If this is an incognito profile, we also have to check to make sure the
// overflow matches the main bar's status.
if (profile_->IsOffTheRecord()) {
@@ -350,6 +347,9 @@ void ExtensionToolbarModel::AddExtension(const Extension* extension) {
else if (!visible && all_icons_visible())
SetVisibleIconCount(visible_icon_count() - 1);
}
+
+ FOR_EACH_OBSERVER(
+ Observer, observers_, ToolbarExtensionAdded(extension, new_index));
}
}
« no previous file with comments | « no previous file | chrome/browser/ui/toolbar/toolbar_actions_bar.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698