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 #include "ash/system/date/tray_date.h" | 5 #include "ash/system/date/tray_date.h" |
6 | 6 |
7 #include "ash/shell.h" | 7 #include "ash/shell.h" |
8 #include "ash/system/date/date_view.h" | 8 #include "ash/system/date/date_view.h" |
9 #include "ash/system/tray/system_tray.h" | 9 #include "ash/system/tray/system_tray.h" |
10 #include "ash/system/tray/system_tray_delegate.h" | 10 #include "ash/system/tray/system_tray_delegate.h" |
(...skipping 20 matching lines...) Expand all Loading... |
31 #include "ui/views/layout/fill_layout.h" | 31 #include "ui/views/layout/fill_layout.h" |
32 #include "ui/views/painter.h" | 32 #include "ui/views/painter.h" |
33 #include "ui/views/view.h" | 33 #include "ui/views/view.h" |
34 #include "ui/views/widget/widget.h" | 34 #include "ui/views/widget/widget.h" |
35 #include "unicode/datefmt.h" | 35 #include "unicode/datefmt.h" |
36 #include "unicode/fieldpos.h" | 36 #include "unicode/fieldpos.h" |
37 #include "unicode/fmtable.h" | 37 #include "unicode/fmtable.h" |
38 | 38 |
39 namespace { | 39 namespace { |
40 | 40 |
41 const int kPaddingVertical = 10; | 41 const int kPaddingVertical = 6; |
42 | 42 |
43 class DateDefaultView : public views::View, | 43 class DateDefaultView : public views::View, |
44 public views::ButtonListener { | 44 public views::ButtonListener { |
45 public: | 45 public: |
46 explicit DateDefaultView(ash::user::LoginStatus login) | 46 explicit DateDefaultView(ash::user::LoginStatus login) |
47 : help_(NULL), | 47 : help_(NULL), |
48 shutdown_(NULL), | 48 shutdown_(NULL), |
49 lock_(NULL) { | 49 lock_(NULL) { |
50 SetLayoutManager(new views::FillLayout); | 50 SetLayoutManager(new views::FillLayout); |
51 | 51 |
(...skipping 126 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
178 time_tray_->UpdateTimeFormat(); | 178 time_tray_->UpdateTimeFormat(); |
179 } | 179 } |
180 | 180 |
181 void TrayDate::Refresh() { | 181 void TrayDate::Refresh() { |
182 if (time_tray_) | 182 if (time_tray_) |
183 time_tray_->UpdateText(); | 183 time_tray_->UpdateText(); |
184 } | 184 } |
185 | 185 |
186 } // namespace internal | 186 } // namespace internal |
187 } // namespace ash | 187 } // namespace ash |
OLD | NEW |