Index: device/bluetooth/bluetooth_adapter_win.h |
diff --git a/device/bluetooth/bluetooth_adapter_win.h b/device/bluetooth/bluetooth_adapter_win.h |
index de76b18e8eb7719b0994d5c782dd90685655601f..0524bb73d5692aa089f3d90e456718afdf8a16f3 100644 |
--- a/device/bluetooth/bluetooth_adapter_win.h |
+++ b/device/bluetooth/bluetooth_adapter_win.h |
@@ -13,9 +13,11 @@ |
namespace device { |
class BluetoothAdapterFactory; |
+class BluetoothAdapterWinTest; |
class BluetoothDevice; |
class BluetoothAdapterWin : public BluetoothAdapter { |
+ public: |
// BluetoothAdapter override |
virtual void AddObserver(BluetoothAdapter::Observer* observer) OVERRIDE; |
virtual void RemoveObserver(BluetoothAdapter::Observer* observer) OVERRIDE; |
@@ -38,11 +40,23 @@ class BluetoothAdapterWin : public BluetoothAdapter { |
const BluetoothOutOfBandPairingDataCallback& callback, |
const ErrorCallback& error_callback) OVERRIDE; |
+ protected: |
+ BluetoothAdapterWin(); |
+ virtual ~BluetoothAdapterWin(); |
+ |
+ virtual void UpdateAdapterState(); |
+ |
private: |
friend class device::BluetoothAdapterFactory; |
+ friend class device::BluetoothAdapterWinTest; |
- BluetoothAdapterWin(); |
- virtual ~BluetoothAdapterWin(); |
+ // Obtains the default adapter info (the first bluetooth radio info) and |
+ // tracks future changes to it. |
+ void TrackDefaultAdapter(); |
+ |
+ void PollAdapterState(); |
+ |
+ static const int kPollIntervalMs; |
// NOTE: This should remain the last member so it'll be destroyed and |
// invalidate its weak pointers before any other members are destroyed. |