Chromium Code Reviews| Index: chrome/browser/ui/views/bookmarks/bookmark_bar_instructions_view.cc |
| diff --git a/chrome/browser/ui/views/bookmarks/bookmark_bar_instructions_view.cc b/chrome/browser/ui/views/bookmarks/bookmark_bar_instructions_view.cc |
| index 5a0223518b3e73464623bf0115fac160cf59f7c2..80e7626228aafc8cb47b51b0493230aebcad625f 100644 |
| --- a/chrome/browser/ui/views/bookmarks/bookmark_bar_instructions_view.cc |
| +++ b/chrome/browser/ui/views/bookmarks/bookmark_bar_instructions_view.cc |
| @@ -40,7 +40,6 @@ BookmarkBarInstructionsView::BookmarkBarInstructionsView( |
| : delegate_(delegate), |
| instructions_(NULL), |
| import_link_(NULL), |
| - baseline_(-1), |
| updated_colors_(false) { |
| instructions_ = new views::Label( |
| l10n_util::GetStringUTF16(IDS_BOOKMARKS_NO_ITEMS)); |
| @@ -87,14 +86,8 @@ void BookmarkBarInstructionsView::Layout() { |
| for (int i = 0; i < child_count(); ++i) { |
| views::View* view = child_at(i); |
| gfx::Size pref = view->GetPreferredSize(); |
| - int baseline = view->GetBaseline(); |
| - int y; |
| - if (baseline != -1 && baseline_ != -1) |
| - y = baseline_ - baseline; |
| - else |
| - y = (height() - pref.height()) / 2; |
| int view_width = std::min(remaining_width, pref.width()); |
| - view->SetBounds(x, y, view_width, pref.height()); |
| + view->SetBounds(x, 0, view_width, height()); |
|
Peter Kasting
2016/06/13 20:49:00
How does this look in the attached bookmark bar?
kylix_rd
2016/06/13 20:59:43
I'll admit that I'm not sure. How is attached vs.
Peter Kasting
2016/06/13 21:06:06
Toggle with ctrl-shift-b.
kylix_rd
2016/06/13 21:17:20
Ok, the alignment remains correct.
|
| x += view_width + GetViewPadding(); |
| remaining_width = std::max(0, width() - x); |
| } |