| 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 "chrome/browser/chromeos/system/ash_system_tray_delegate.h" | 5 #include "chrome/browser/chromeos/system/ash_system_tray_delegate.h" |
| 6 | 6 |
| 7 #include <algorithm> | 7 #include <algorithm> |
| 8 | 8 |
| 9 #include "ash/shell.h" | 9 #include "ash/shell.h" |
| 10 #include "ash/shell_delegate.h" | 10 #include "ash/shell_delegate.h" |
| (...skipping 252 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 263 input_method::GetInputMethodManager()->AddObserver(this); | 263 input_method::GetInputMethodManager()->AddObserver(this); |
| 264 | 264 |
| 265 system::TimezoneSettings::GetInstance()->AddObserver(this); | 265 system::TimezoneSettings::GetInstance()->AddObserver(this); |
| 266 | 266 |
| 267 if (SystemKeyEventListener::GetInstance()) | 267 if (SystemKeyEventListener::GetInstance()) |
| 268 SystemKeyEventListener::GetInstance()->AddCapsLockObserver(this); | 268 SystemKeyEventListener::GetInstance()->AddCapsLockObserver(this); |
| 269 | 269 |
| 270 network_icon_->SetResourceColorTheme(NetworkMenuIcon::COLOR_LIGHT); | 270 network_icon_->SetResourceColorTheme(NetworkMenuIcon::COLOR_LIGHT); |
| 271 network_icon_dark_->SetResourceColorTheme(NetworkMenuIcon::COLOR_DARK); | 271 network_icon_dark_->SetResourceColorTheme(NetworkMenuIcon::COLOR_DARK); |
| 272 | 272 |
| 273 device::BluetoothAdapterFactory::RunCallbackOnAdapterReady( | 273 device::BluetoothAdapterFactory::GetAdapter( |
| 274 base::Bind(&SystemTrayDelegate::InitializeOnAdapterReady, | 274 base::Bind(&SystemTrayDelegate::InitializeOnAdapterReady, |
| 275 ui_weak_ptr_factory_->GetWeakPtr())); | 275 ui_weak_ptr_factory_->GetWeakPtr())); |
| 276 } | 276 } |
| 277 | 277 |
| 278 void InitializeOnAdapterReady( | 278 void InitializeOnAdapterReady( |
| 279 scoped_refptr<device::BluetoothAdapter> adapter) { | 279 scoped_refptr<device::BluetoothAdapter> adapter) { |
| 280 bluetooth_adapter_ = adapter; | 280 bluetooth_adapter_ = adapter; |
| 281 CHECK(bluetooth_adapter_); | 281 CHECK(bluetooth_adapter_); |
| 282 bluetooth_adapter_->AddObserver(this); | 282 bluetooth_adapter_->AddObserver(this); |
| 283 | 283 |
| (...skipping 1132 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1416 DISALLOW_COPY_AND_ASSIGN(SystemTrayDelegate); | 1416 DISALLOW_COPY_AND_ASSIGN(SystemTrayDelegate); |
| 1417 }; | 1417 }; |
| 1418 | 1418 |
| 1419 } // namespace | 1419 } // namespace |
| 1420 | 1420 |
| 1421 ash::SystemTrayDelegate* CreateSystemTrayDelegate() { | 1421 ash::SystemTrayDelegate* CreateSystemTrayDelegate() { |
| 1422 return new chromeos::SystemTrayDelegate(); | 1422 return new chromeos::SystemTrayDelegate(); |
| 1423 } | 1423 } |
| 1424 | 1424 |
| 1425 } // namespace chromeos | 1425 } // namespace chromeos |
| OLD | NEW |