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

Unified Diff: ui/views/controls/button/checkbox.cc

Issue 371633002: LabelButton: cache the last computed preferred size (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase Created 6 years, 5 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
Index: ui/views/controls/button/checkbox.cc
diff --git a/ui/views/controls/button/checkbox.cc b/ui/views/controls/button/checkbox.cc
index 22c5f88e2d6c6a61783212485a2873df25d34231..0c212c43ef98d14e412da9e20f2d90fab10fe24c 100644
--- a/ui/views/controls/button/checkbox.cc
+++ b/ui/views/controls/button/checkbox.cc
@@ -67,7 +67,7 @@ Checkbox::Checkbox(const base::string16& label)
// Limit the checkbox height to match the legacy appearance.
const gfx::Size preferred_size(LabelButton::GetPreferredSize());
- set_min_size(gfx::Size(0, preferred_size.height() + 4));
+ SetMinSize(gfx::Size(0, preferred_size.height() + 4));
}
Checkbox::~Checkbox() {

Powered by Google App Engine
This is Rietveld 408576698