| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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/common/system/tray/default_system_tray_delegate.h" | 5 #include "ash/common/system/tray/default_system_tray_delegate.h" |
| 6 | 6 |
| 7 #include <string> | 7 #include <string> |
| 8 #include <utility> | 8 #include <utility> |
| 9 | 9 |
| 10 #include "ash/common/system/networking_config_delegate.h" | 10 #include "ash/common/system/networking_config_delegate.h" |
| 11 #include "ash/common/system/volume_control_delegate.h" | |
| 12 #include "base/message_loop/message_loop.h" | 11 #include "base/message_loop/message_loop.h" |
| 13 #include "base/time/time.h" | 12 #include "base/time/time.h" |
| 14 | 13 |
| 15 namespace ash { | 14 namespace ash { |
| 16 | 15 |
| 17 DefaultSystemTrayDelegate::DefaultSystemTrayDelegate() | 16 DefaultSystemTrayDelegate::DefaultSystemTrayDelegate() |
| 18 : bluetooth_enabled_(true) {} | 17 : bluetooth_enabled_(true) {} |
| 19 | 18 |
| 20 DefaultSystemTrayDelegate::~DefaultSystemTrayDelegate() {} | 19 DefaultSystemTrayDelegate::~DefaultSystemTrayDelegate() {} |
| 21 | 20 |
| (...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 57 } | 56 } |
| 58 | 57 |
| 59 bool DefaultSystemTrayDelegate::GetBluetoothEnabled() { | 58 bool DefaultSystemTrayDelegate::GetBluetoothEnabled() { |
| 60 return bluetooth_enabled_; | 59 return bluetooth_enabled_; |
| 61 } | 60 } |
| 62 | 61 |
| 63 bool DefaultSystemTrayDelegate::GetBluetoothDiscovering() { | 62 bool DefaultSystemTrayDelegate::GetBluetoothDiscovering() { |
| 64 return false; | 63 return false; |
| 65 } | 64 } |
| 66 | 65 |
| 67 VolumeControlDelegate* DefaultSystemTrayDelegate::GetVolumeControlDelegate() | |
| 68 const { | |
| 69 return volume_control_delegate_.get(); | |
| 70 } | |
| 71 | |
| 72 void DefaultSystemTrayDelegate::SetVolumeControlDelegate( | |
| 73 std::unique_ptr<VolumeControlDelegate> delegate) { | |
| 74 volume_control_delegate_ = std::move(delegate); | |
| 75 } | |
| 76 | |
| 77 int DefaultSystemTrayDelegate::GetSystemTrayMenuWidth() { | 66 int DefaultSystemTrayDelegate::GetSystemTrayMenuWidth() { |
| 78 // This is the default width for English languages. | 67 // This is the default width for English languages. |
| 79 return 300; | 68 return 300; |
| 80 } | 69 } |
| 81 | 70 |
| 82 } // namespace ash | 71 } // namespace ash |
| OLD | NEW |