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

Unified Diff: chrome/browser/ui/gtk/tabs/tab_strip_gtk.cc

Issue 8743021: GTK: Move to gtk_widget_get_allocation() for some of chrome/browser/ui/gtk/ (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: comment nit Created 9 years, 1 month 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 | « chrome/browser/ui/gtk/custom_button.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/gtk/tabs/tab_strip_gtk.cc
diff --git a/chrome/browser/ui/gtk/tabs/tab_strip_gtk.cc b/chrome/browser/ui/gtk/tabs/tab_strip_gtk.cc
index 1edc5adf3355f7ca03695bfec8d4a9ff77322cc2..272d741857345cd1dae210827a65d5e3d0211562 100644
--- a/chrome/browser/ui/gtk/tabs/tab_strip_gtk.cc
+++ b/chrome/browser/ui/gtk/tabs/tab_strip_gtk.cc
@@ -1451,7 +1451,7 @@ void TabStripGtk::LayoutNewTabButton(double last_tab_right,
// We're shrinking tabs, so we need to anchor the New Tab button to the
// right edge of the TabStrip's bounds, rather than the right edge of the
// right-most Tab, otherwise it'll bounce when animating.
- bounds.set_x(bounds_.width() - newtab_button_->width());
+ bounds.set_x(bounds_.width() - newtab_button_->WidgetWidth());
} else {
bounds.set_x(Round(last_tab_right - kTabHOffset) + kNewTabButtonHOffset);
}
@@ -1486,7 +1486,7 @@ void TabStripGtk::GetDesiredTabWidths(int tab_count,
if (available_width_for_tabs_ < 0) {
available_width = bounds_.width();
available_width -=
- (kNewTabButtonHOffset + newtab_button_->width());
+ (kNewTabButtonHOffset + newtab_button_->WidgetWidth());
} else {
// Interesting corner case: if |available_width_for_tabs_| > the result
// of the calculation in the conditional arm above, the strip is in
« no previous file with comments | « chrome/browser/ui/gtk/custom_button.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698