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

Unified Diff: chrome/browser/ui/views/apps/app_info_dialog/app_info_footer_panel.cc

Issue 1978403003: [MD] Eliminate as many SetStyle(STYLE_BUTTON) calls as possible. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase Created 4 years, 7 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: chrome/browser/ui/views/apps/app_info_dialog/app_info_footer_panel.cc
diff --git a/chrome/browser/ui/views/apps/app_info_dialog/app_info_footer_panel.cc b/chrome/browser/ui/views/apps/app_info_dialog/app_info_footer_panel.cc
index c412b0cac69fc4f87d81cc6d6d80e6ad278d1621..2bebb9ce09fa2cf5be1a804eb9e1a19fe25b76c9 100644
--- a/chrome/browser/ui/views/apps/app_info_dialog/app_info_footer_panel.cc
+++ b/chrome/browser/ui/views/apps/app_info_dialog/app_info_footer_panel.cc
@@ -14,7 +14,7 @@
#include "extensions/common/extension.h"
#include "ui/base/l10n/l10n_util.h"
#include "ui/events/event.h"
-#include "ui/views/controls/button/label_button.h"
+#include "ui/views/controls/button/md_text_button.h"
#include "ui/views/layout/box_layout.h"
#include "ui/views/layout/layout_constants.h"
#include "ui/views/view.h"
@@ -51,29 +51,24 @@ AppInfoFooterPanel::~AppInfoFooterPanel() {
void AppInfoFooterPanel::CreateButtons() {
if (CanCreateShortcuts()) {
- create_shortcuts_button_ = new views::LabelButton(
- this,
- l10n_util::GetStringUTF16(
- IDS_APPLICATION_INFO_CREATE_SHORTCUTS_BUTTON_TEXT));
- create_shortcuts_button_->SetStyle(views::Button::STYLE_BUTTON);
+ create_shortcuts_button_ = views::MdTextButton::CreateSecondaryUiButton(
+ this, l10n_util::GetStringUTF16(
+ IDS_APPLICATION_INFO_CREATE_SHORTCUTS_BUTTON_TEXT));
}
#if defined(USE_ASH)
if (CanSetPinnedToShelf()) {
- pin_to_shelf_button_ = new views::LabelButton(
+ pin_to_shelf_button_ = views::MdTextButton::CreateSecondaryUiButton(
this, l10n_util::GetStringUTF16(IDS_APP_LIST_CONTEXT_MENU_PIN));
- pin_to_shelf_button_->SetStyle(views::Button::STYLE_BUTTON);
- unpin_from_shelf_button_ = new views::LabelButton(
+ unpin_from_shelf_button_ = views::MdTextButton::CreateSecondaryUiButton(
this, l10n_util::GetStringUTF16(IDS_APP_LIST_CONTEXT_MENU_UNPIN));
- unpin_from_shelf_button_->SetStyle(views::Button::STYLE_BUTTON);
}
#endif
if (CanUninstallApp()) {
- remove_button_ = new views::LabelButton(
+ remove_button_ = views::MdTextButton::CreateSecondaryUiButton(
this,
l10n_util::GetStringUTF16(IDS_APPLICATION_INFO_UNINSTALL_BUTTON_TEXT));
- remove_button_->SetStyle(views::Button::STYLE_BUTTON);
}
}

Powered by Google App Engine
This is Rietveld 408576698