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/chromeos/power/tray_power.h" | 5 #include "ash/system/chromeos/power/tray_power.h" |
6 | 6 |
7 #include <utility> | 7 #include <utility> |
8 | 8 |
9 #include "ash/accessibility_delegate.h" | 9 #include "ash/accessibility_delegate.h" |
10 #include "ash/ash_switches.h" | 10 #include "ash/ash_switches.h" |
(...skipping 169 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
180 void TrayPower::DestroyTrayView() { | 180 void TrayPower::DestroyTrayView() { |
181 power_tray_ = NULL; | 181 power_tray_ = NULL; |
182 } | 182 } |
183 | 183 |
184 void TrayPower::DestroyDefaultView() { | 184 void TrayPower::DestroyDefaultView() { |
185 } | 185 } |
186 | 186 |
187 void TrayPower::UpdateAfterLoginStatusChange(user::LoginStatus status) { | 187 void TrayPower::UpdateAfterLoginStatusChange(user::LoginStatus status) { |
188 } | 188 } |
189 | 189 |
190 void TrayPower::UpdateAfterShelfAlignmentChange(ShelfAlignment alignment) { | 190 void TrayPower::UpdateAfterShelfAlignmentChange(wm::ShelfAlignment alignment) { |
191 SetTrayImageItemBorder(power_tray_, alignment); | 191 SetTrayImageItemBorder(power_tray_, alignment); |
192 } | 192 } |
193 | 193 |
194 void TrayPower::OnPowerStatusChanged() { | 194 void TrayPower::OnPowerStatusChanged() { |
195 bool battery_alert = UpdateNotificationState(); | 195 bool battery_alert = UpdateNotificationState(); |
196 if (power_tray_) | 196 if (power_tray_) |
197 power_tray_->UpdateStatus(battery_alert); | 197 power_tray_->UpdateStatus(battery_alert); |
198 | 198 |
199 // Factory testing may place the battery into unusual states. | 199 // Factory testing may place the battery into unusual states. |
200 if (base::CommandLine::ForCurrentProcess()->HasSwitch( | 200 if (base::CommandLine::ForCurrentProcess()->HasSwitch( |
(...skipping 155 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
356 } | 356 } |
357 NOTREACHED(); | 357 NOTREACHED(); |
358 return false; | 358 return false; |
359 } | 359 } |
360 | 360 |
361 void TrayPower::NotifyUsbNotificationClosedByUser() { | 361 void TrayPower::NotifyUsbNotificationClosedByUser() { |
362 usb_notification_dismissed_ = true; | 362 usb_notification_dismissed_ = true; |
363 } | 363 } |
364 | 364 |
365 } // namespace ash | 365 } // namespace ash |
OLD | NEW |