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

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

Issue 340003002: Revert of views: Move MenuButton from TextButton to LabelButton. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 6 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 | « ui/views/controls/button/label_button.h ('k') | ui/views/controls/button/menu_button.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/views/controls/button/label_button.cc
diff --git a/ui/views/controls/button/label_button.cc b/ui/views/controls/button/label_button.cc
index 860d1b17f623324d8a97e168b93358983b6e9681..d6647de6b6882cc2264fe6ebd356f6692cdfe767 100644
--- a/ui/views/controls/button/label_button.cc
+++ b/ui/views/controls/button/label_button.cc
@@ -100,10 +100,6 @@
explicitly_set_colors_[for_state] = true;
}
-void LabelButton::SetHaloColor(SkColor color) {
- label_->set_halo_color(color);
-}
-
bool LabelButton::GetTextMultiLine() const {
return label_->is_multi_line();
}
@@ -226,7 +222,7 @@
adjusted_alignment = (adjusted_alignment == gfx::ALIGN_LEFT) ?
gfx::ALIGN_RIGHT : gfx::ALIGN_LEFT;
- gfx::Rect child_area(GetChildAreaBounds());
+ gfx::Rect child_area(GetLocalBounds());
child_area.Inset(GetInsets());
gfx::Size image_size(image_->GetPreferredSize());
@@ -277,10 +273,6 @@
void LabelButton::SetBorder(scoped_ptr<Border> border) {
border_is_themed_border_ = false;
View::SetBorder(border.Pass());
-}
-
-gfx::Rect LabelButton::GetChildAreaBounds() {
- return GetLocalBounds();
}
void LabelButton::OnPaint(gfx::Canvas* canvas) {
@@ -374,7 +366,7 @@
views::LinuxUI* linux_ui = views::LinuxUI::instance();
if (linux_ui) {
SetBorder(linux_ui->CreateNativeBorder(
- this, label_button_border.Pass()));
+ this, label_button_border.PassAs<Border>()));
} else
#endif
{
« no previous file with comments | « ui/views/controls/button/label_button.h ('k') | ui/views/controls/button/menu_button.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698