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

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

Issue 2480813003: Reduce views::Border creation verbosity by promoting factory functions (Closed)
Patch Set: fix bad merge Created 4 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/image_button_unittest.cc ('k') | ui/views/controls/button/toggle_button.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/views/controls/button/md_text_button.cc
diff --git a/ui/views/controls/button/md_text_button.cc b/ui/views/controls/button/md_text_button.cc
index 7d160e840076334df11e440708e405af23118de2..359d756427e600232c417e50b6923bf84388e5c8 100644
--- a/ui/views/controls/button/md_text_button.cc
+++ b/ui/views/controls/button/md_text_button.cc
@@ -214,7 +214,7 @@ MdTextButton::MdTextButton(ButtonListener* listener)
void MdTextButton::UpdatePadding() {
// Don't use font-based padding when there's no text visible.
if (GetText().empty()) {
- SetBorder(Border::NullBorder());
+ SetBorder(NullBorder());
return;
}
@@ -243,8 +243,8 @@ void MdTextButton::UpdatePadding() {
// TODO(estade): can we get rid of the platform style border hoopla if
// we apply the MD treatment to all buttons, even GTK buttons?
const int kHorizontalPadding = 16;
- SetBorder(Border::CreateEmptyBorder(top_padding, kHorizontalPadding,
- bottom_padding, kHorizontalPadding));
+ SetBorder(CreateEmptyBorder(top_padding, kHorizontalPadding, bottom_padding,
+ kHorizontalPadding));
}
void MdTextButton::UpdateColors() {
« no previous file with comments | « ui/views/controls/button/image_button_unittest.cc ('k') | ui/views/controls/button/toggle_button.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698