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

Unified Diff: ui/views/controls/button/text_button.h

Issue 82483003: Add GetMinimumSize() for Borders, and make LabelButton auto-size to at least as (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Created 7 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 | « ui/views/controls/button/label_button_border.cc ('k') | ui/views/controls/button/text_button.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/views/controls/button/text_button.h
===================================================================
--- ui/views/controls/button/text_button.h (revision 236640)
+++ ui/views/controls/button/text_button.h (working copy)
@@ -31,6 +31,7 @@
// Border:
virtual gfx::Insets GetInsets() const OVERRIDE;
+ virtual gfx::Size GetMinimumSize() const OVERRIDE;
private:
// Border:
@@ -62,6 +63,7 @@
private:
// TextButtonBorder:
virtual void Paint(const View& view, gfx::Canvas* canvas) OVERRIDE;
+ virtual gfx::Size GetMinimumSize() const OVERRIDE;
scoped_ptr<Painter> normal_painter_;
scoped_ptr<Painter> hot_painter_;
@@ -83,6 +85,8 @@
// TextButtonBorder:
virtual void Paint(const View& view, gfx::Canvas* canvas) OVERRIDE;
+ // We don't override GetMinimumSize(), since there's no easy way to calculate
+ // the minimum size required by the various theme components.
private:
// The delegate the controls the appearance of this border.
« no previous file with comments | « ui/views/controls/button/label_button_border.cc ('k') | ui/views/controls/button/text_button.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698