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

Unified Diff: chrome/browser/views/bookmark_bar_view.cc

Issue 165172: Fix for bookmark bar text not being correct in subsequent Windows. I believe ... (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 11 years, 4 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/views/bookmark_bar_view.cc
===================================================================
--- chrome/browser/views/bookmark_bar_view.cc (revision 22787)
+++ chrome/browser/views/bookmark_bar_view.cc (working copy)
@@ -567,11 +567,18 @@
void BookmarkBarView::ViewHierarchyChanged(bool is_add,
View* parent,
View* child) {
- if (is_add && child == this && height() > 0) {
- // We only layout while parented. When we become parented, if our bounds
- // haven't changed, DidChangeBounds won't get invoked and we won't layout.
- // Therefore we always force a layout when added.
- Layout();
+ if (is_add && child == this) {
+ // We may get inserted into a heirarchy with a profile - this typically
Miranda Callahan 2009/08/07 22:35:46 nit: hierarchy
+ // occurs when the bar's contents get populated fast enough that the
+ // buttons are created before the bar is attached to a frame.
+ UpdateButtonColors();
+
+ if (height() > 0) {
+ // We only layout while parented. When we become parented, if our bounds
+ // haven't changed, DidChangeBounds won't get invoked and we won't layout.
+ // Therefore we always force a layout when added.
+ Layout();
+ }
}
}
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698