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

Side by Side Diff: ash/mus/system_tray_delegate_mus.cc

Issue 2351893002: mash: Fix system tray clock 12/24 hour time setting (Closed)
Patch Set: tweak Created 4 years, 3 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 unified diff | Download patch
OLDNEW
(Empty)
1 // Copyright 2016 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #include "ash/mus/system_tray_delegate_mus.h"
6
7 #include "ash/common/system/tray/system_tray_notifier.h"
8 #include "ash/common/wm_shell.h"
9 #include "base/i18n/time_formatting.h"
10
11 namespace ash {
12
13 SystemTrayDelegateMus::SystemTrayDelegateMus()
14 : hour_clock_type_(base::GetHourClockType()) {}
15
16 SystemTrayDelegateMus::~SystemTrayDelegateMus() {}
17
18 base::HourClockType SystemTrayDelegateMus::GetHourClockType() const {
19 return hour_clock_type_;
20 }
21
22 void SystemTrayDelegateMus::SetUse24HourClock(bool use_24_hour) {
23 hour_clock_type_ = use_24_hour ? base::k24HourClock : base::k12HourClock;
24 WmShell::Get()->system_tray_notifier()->NotifyDateFormatChanged();
25 }
26
27 } // namespace ash
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698