| 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 125 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 136 ClockLayout clock_layout = | 136 ClockLayout clock_layout = |
| 137 ash::Shell::GetInstance()->system_tray()->shelf_alignment() == | 137 ash::Shell::GetInstance()->system_tray()->shelf_alignment() == |
| 138 SHELF_ALIGNMENT_BOTTOM ? | 138 SHELF_ALIGNMENT_BOTTOM ? |
| 139 HORIZONTAL_CLOCK : VERTICAL_CLOCK; | 139 HORIZONTAL_CLOCK : VERTICAL_CLOCK; |
| 140 time_tray_ = new tray::TimeView(clock_layout); | 140 time_tray_ = new tray::TimeView(clock_layout); |
| 141 views::View* view = new TrayItemView; | 141 views::View* view = new TrayItemView; |
| 142 view->AddChildView(time_tray_); | 142 view->AddChildView(time_tray_); |
| 143 return view; | 143 return view; |
| 144 } | 144 } |
| 145 | 145 |
| 146 views::View* TrayDate::CreateDefaultView(user::LoginStatus status) { | 146 views::View* TrayDate::CreateDefaultView(user::LoginStatus status, |
| 147 int bubble_width) { |
| 147 return new DateDefaultView(status); | 148 return new DateDefaultView(status); |
| 148 } | 149 } |
| 149 | 150 |
| 150 views::View* TrayDate::CreateDetailedView(user::LoginStatus status) { | 151 views::View* TrayDate::CreateDetailedView(user::LoginStatus status) { |
| 151 return NULL; | 152 return NULL; |
| 152 } | 153 } |
| 153 | 154 |
| 154 void TrayDate::DestroyTrayView() { | 155 void TrayDate::DestroyTrayView() { |
| 155 time_tray_ = NULL; | 156 time_tray_ = NULL; |
| 156 } | 157 } |
| (...skipping 20 matching lines...) Expand all Loading... |
| 177 time_tray_->UpdateTimeFormat(); | 178 time_tray_->UpdateTimeFormat(); |
| 178 } | 179 } |
| 179 | 180 |
| 180 void TrayDate::Refresh() { | 181 void TrayDate::Refresh() { |
| 181 if (time_tray_) | 182 if (time_tray_) |
| 182 time_tray_->UpdateText(); | 183 time_tray_->UpdateText(); |
| 183 } | 184 } |
| 184 | 185 |
| 185 } // namespace internal | 186 } // namespace internal |
| 186 } // namespace ash | 187 } // namespace ash |
| OLD | NEW |