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 b5e6c1b0e1e98ef5c9151ffb11d85053fe5f3ecb..4453f2a2aa72f428b0e7519f9061938bcb93d4fb 100644 |
--- a/ui/views/controls/button/md_text_button.cc |
+++ b/ui/views/controls/button/md_text_button.cc |
@@ -193,8 +193,8 @@ MdTextButton::MdTextButton(ButtonListener* listener) |
set_has_ink_drop_action_on_click(true); |
SetHorizontalAlignment(gfx::ALIGN_CENTER); |
SetFocusForPlatform(); |
- const int minimum_width = |
- ViewsDelegate::GetInstance()->GetButtonMinimumWidth(); |
+ const int minimum_width = ViewsDelegate::GetInstance()->GetDistanceMetric( |
+ DistanceMetric::DIALOG_BUTTON_MINIMUM_WIDTH); |
SetMinSize(gfx::Size(minimum_width, 0)); |
SetFocusPainter(nullptr); |
label()->SetAutoColorReadabilityEnabled(false); |
@@ -241,7 +241,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 horizontal_padding = |
- ViewsDelegate::GetInstance()->GetButtonHorizontalPadding(); |
+ ViewsDelegate::GetInstance()->GetDistanceMetric( |
+ DistanceMetric::BUTTON_HORIZONTAL_PADDING); |
SetBorder(CreateEmptyBorder(top_padding, horizontal_padding, bottom_padding, |
horizontal_padding)); |
} |