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 #ifndef CHROME_BROWSER_EXTENSIONS_BLUETOOTH_EVENT_ROUTER_H_ | 5 #ifndef CHROME_BROWSER_EXTENSIONS_API_BLUETOOTH_BLUETOOTH_EVENT_ROUTER_H_ |
6 #define CHROME_BROWSER_EXTENSIONS_BLUETOOTH_EVENT_ROUTER_H_ | 6 #define CHROME_BROWSER_EXTENSIONS_API_BLUETOOTH_BLUETOOTH_EVENT_ROUTER_H_ |
7 | 7 |
8 #include <map> | 8 #include <map> |
9 | 9 |
10 #include "base/memory/ref_counted.h" | 10 #include "base/memory/ref_counted.h" |
11 #include "base/memory/scoped_vector.h" | 11 #include "base/memory/scoped_vector.h" |
12 #include "chrome/browser/profiles/profile.h" | |
13 #include "chrome/common/extensions/api/bluetooth.h" | 12 #include "chrome/common/extensions/api/bluetooth.h" |
14 #include "device/bluetooth/bluetooth_adapter.h" | 13 #include "device/bluetooth/bluetooth_adapter.h" |
15 #include "device/bluetooth/bluetooth_socket.h" | 14 #include "device/bluetooth/bluetooth_socket.h" |
16 | 15 |
| 16 class Profile; |
| 17 |
17 namespace extensions { | 18 namespace extensions { |
18 | 19 |
19 class ExtensionBluetoothEventRouter | 20 class ExtensionBluetoothEventRouter |
20 : public device::BluetoothAdapter::Observer { | 21 : public device::BluetoothAdapter::Observer { |
21 public: | 22 public: |
22 explicit ExtensionBluetoothEventRouter(Profile* profile); | 23 explicit ExtensionBluetoothEventRouter(Profile* profile); |
23 virtual ~ExtensionBluetoothEventRouter(); | 24 virtual ~ExtensionBluetoothEventRouter(); |
24 | 25 |
25 // adapter() will return NULL if the bluetooth adapter is not supported in the | 26 // adapter() will return NULL if the bluetooth adapter is not supported in the |
26 // current platform. | 27 // current platform. |
(...skipping 65 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
92 | 93 |
93 typedef ScopedVector<extensions::api::bluetooth::Device> | 94 typedef ScopedVector<extensions::api::bluetooth::Device> |
94 DeviceList; | 95 DeviceList; |
95 DeviceList discovered_devices_; | 96 DeviceList discovered_devices_; |
96 | 97 |
97 DISALLOW_COPY_AND_ASSIGN(ExtensionBluetoothEventRouter); | 98 DISALLOW_COPY_AND_ASSIGN(ExtensionBluetoothEventRouter); |
98 }; | 99 }; |
99 | 100 |
100 } // namespace extensions | 101 } // namespace extensions |
101 | 102 |
102 #endif // CHROME_BROWSER_EXTENSIONS_BLUETOOTH_EVENT_ROUTER_H_ | 103 #endif // CHROME_BROWSER_EXTENSIONS_API_BLUETOOTH_BLUETOOTH_EVENT_ROUTER_H_ |
OLD | NEW |