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 "device/bluetooth/bluetooth_task_manager_win.h" | 5 #include "device/bluetooth/bluetooth_task_manager_win.h" |
6 | 6 |
7 #include <stddef.h> | 7 #include <stddef.h> |
8 #include <winsock2.h> | 8 #include <winsock2.h> |
9 | 9 |
10 #include <string> | 10 #include <string> |
(...skipping 122 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
133 authenticated(false), | 133 authenticated(false), |
134 bluetooth_class(0) { | 134 bluetooth_class(0) { |
135 } | 135 } |
136 | 136 |
137 BluetoothTaskManagerWin::DeviceState::~DeviceState() { | 137 BluetoothTaskManagerWin::DeviceState::~DeviceState() { |
138 } | 138 } |
139 | 139 |
140 BluetoothTaskManagerWin::BluetoothTaskManagerWin( | 140 BluetoothTaskManagerWin::BluetoothTaskManagerWin( |
141 scoped_refptr<base::SequencedTaskRunner> ui_task_runner) | 141 scoped_refptr<base::SequencedTaskRunner> ui_task_runner) |
142 : ui_task_runner_(ui_task_runner), | 142 : ui_task_runner_(ui_task_runner), |
| 143 adapter_handle_(NULL), |
143 discovering_(false), | 144 discovering_(false), |
144 current_logging_batch_count_(0), | 145 current_logging_batch_count_(0) {} |
145 adapter_handle_(NULL) {} | |
146 | 146 |
147 BluetoothTaskManagerWin::~BluetoothTaskManagerWin() { | 147 BluetoothTaskManagerWin::~BluetoothTaskManagerWin() { |
148 win::BluetoothLowEnergyWrapper::DeleteInstance(); | 148 win::BluetoothLowEnergyWrapper::DeleteInstance(); |
149 win::BluetoothClassicWrapper::DeleteInstance(); | 149 win::BluetoothClassicWrapper::DeleteInstance(); |
150 } | 150 } |
151 | 151 |
152 void BluetoothTaskManagerWin::AddObserver(Observer* observer) { | 152 void BluetoothTaskManagerWin::AddObserver(Observer* observer) { |
153 DCHECK(observer); | 153 DCHECK(observer); |
154 DCHECK(ui_task_runner_->RunsTasksOnCurrentThread()); | 154 DCHECK(ui_task_runner_->RunsTasksOnCurrentThread()); |
155 observers_.AddObserver(observer); | 155 observers_.AddObserver(observer); |
(...skipping 562 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
718 break; | 718 break; |
719 } | 719 } |
720 } | 720 } |
721 } | 721 } |
722 } | 722 } |
723 | 723 |
724 return true; | 724 return true; |
725 } | 725 } |
726 | 726 |
727 } // namespace device | 727 } // namespace device |
OLD | NEW |