OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #ifndef ASH_SYSTEM_DATE_DATE_VIEW_H_ | 5 #ifndef ASH_SYSTEM_DATE_DATE_VIEW_H_ |
6 #define ASH_SYSTEM_DATE_DATE_VIEW_H_ | 6 #define ASH_SYSTEM_DATE_DATE_VIEW_H_ |
7 | 7 |
8 #include "ash/ash_export.h" | 8 #include "ash/ash_export.h" |
9 #include "ash/system/date/tray_date.h" | 9 #include "ash/system/date/tray_date.h" |
10 #include "ash/system/tray/actionable_view.h" | 10 #include "ash/system/tray/actionable_view.h" |
(...skipping 26 matching lines...) Expand all Loading... |
37 void SetTimer(const base::Time& now); | 37 void SetTimer(const base::Time& now); |
38 | 38 |
39 // Updates labels to display the current time. | 39 // Updates labels to display the current time. |
40 virtual void UpdateTextInternal(const base::Time& now) = 0; | 40 virtual void UpdateTextInternal(const base::Time& now) = 0; |
41 | 41 |
42 // Overridden from views::View. | 42 // Overridden from views::View. |
43 void ChildPreferredSizeChanged(views::View* child) override; | 43 void ChildPreferredSizeChanged(views::View* child) override; |
44 void OnLocaleChanged() override; | 44 void OnLocaleChanged() override; |
45 | 45 |
46 // Invokes UpdateText() when the displayed time should change. | 46 // Invokes UpdateText() when the displayed time should change. |
47 base::OneShotTimer<BaseDateTimeView> timer_; | 47 base::OneShotTimer timer_; |
48 | 48 |
49 DISALLOW_COPY_AND_ASSIGN(BaseDateTimeView); | 49 DISALLOW_COPY_AND_ASSIGN(BaseDateTimeView); |
50 }; | 50 }; |
51 | 51 |
52 // Popup view used to display the date and day of week. | 52 // Popup view used to display the date and day of week. |
53 class ASH_EXPORT DateView : public BaseDateTimeView { | 53 class ASH_EXPORT DateView : public BaseDateTimeView { |
54 public: | 54 public: |
55 DateView(); | 55 DateView(); |
56 ~DateView() override; | 56 ~DateView() override; |
57 | 57 |
(...skipping 72 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
130 | 130 |
131 base::HourClockType hour_type_; | 131 base::HourClockType hour_type_; |
132 | 132 |
133 DISALLOW_COPY_AND_ASSIGN(TimeView); | 133 DISALLOW_COPY_AND_ASSIGN(TimeView); |
134 }; | 134 }; |
135 | 135 |
136 } // namespace tray | 136 } // namespace tray |
137 } // namespace ash | 137 } // namespace ash |
138 | 138 |
139 #endif // ASH_SYSTEM_DATE_DATE_VIEW_H_ | 139 #endif // ASH_SYSTEM_DATE_DATE_VIEW_H_ |
OLD | NEW |