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

Unified Diff: ash/common/system/date/date_view.cc

Issue 2661023006: Remove unused references to NativeTheme in TrayPopupItemStyle. (Closed)
Patch Set: slight improvement Created 3 years, 11 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 | « ash/common/system/date/date_view.h ('k') | ash/common/system/tray/hover_highlight_view.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ash/common/system/date/date_view.cc
diff --git a/ash/common/system/date/date_view.cc b/ash/common/system/date/date_view.cc
index ccba13c5ae5f906e02e22e9ab510d241be680c76..1abbea60a64981f124b48ff59ed8a619da4c8984 100644
--- a/ash/common/system/date/date_view.cc
+++ b/ash/common/system/date/date_view.cc
@@ -183,6 +183,8 @@ DateView::DateView(SystemTrayItem* owner)
if (!UseMd())
date_label_->SetEnabledColor(kHeaderTextColorNormal);
UpdateTextInternal(base::Time::Now());
+ TrayPopupItemStyle style(TrayPopupItemStyle::FontStyle::SYSTEM_INFO);
+ style.SetupLabel(date_label_);
AddChildView(date_label_);
}
@@ -228,12 +230,6 @@ void DateView::SetActive(bool active) {
SchedulePaint();
}
-void DateView::UpdateStyle() {
- TrayPopupItemStyle style(GetNativeTheme(),
- TrayPopupItemStyle::FontStyle::SYSTEM_INFO);
- style.SetupLabel(date_label_);
-}
-
void DateView::UpdateTextInternal(const base::Time& now) {
BaseDateTimeView::UpdateTextInternal(now);
date_label_->SetText(l10n_util::GetStringFUTF16(
@@ -275,10 +271,6 @@ void DateView::OnGestureEvent(ui::GestureEvent* event) {
BaseDateTimeView::OnGestureEvent(event);
}
-void DateView::OnNativeThemeChanged(const ui::NativeTheme* theme) {
- UpdateStyle();
-}
-
///////////////////////////////////////////////////////////////////////////////
TimeView::TimeView(ClockLayout clock_layout) : BaseDateTimeView(nullptr) {
« no previous file with comments | « ash/common/system/date/date_view.h ('k') | ash/common/system/tray/hover_highlight_view.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698