Index: device/bluetooth/bluetooth_adapter_factory.h |
diff --git a/device/bluetooth/bluetooth_adapter_factory.h b/device/bluetooth/bluetooth_adapter_factory.h |
index 3b6a2c27ea5cbe417a46a3b8432c51d3d1b053c5..1f07140f942494b4d4da3ac7f4fd479d70c70eef 100644 |
--- a/device/bluetooth/bluetooth_adapter_factory.h |
+++ b/device/bluetooth/bluetooth_adapter_factory.h |
@@ -18,9 +18,14 @@ namespace device { |
// adapter" which may change depending on availability. |
class BluetoothAdapterFactory { |
public: |
+ typedef base::Callback<void(BluetoothAdapter* adapter)> AdapterInitializer; |
typedef base::Callback<void(scoped_refptr<BluetoothAdapter> adapter)> |
AdapterCallback; |
+ // Sets a global initializer to run just after the default adapter instance is |
+ // created. |
+ static void SetAdapterInitializer(AdapterInitializer initializer); |
+ |
// Returns true if the Bluetooth adapter is available for the current |
// platform. |
static bool IsBluetoothAdapterAvailable(); |
@@ -35,6 +40,9 @@ class BluetoothAdapterFactory { |
// but may or may not have been initialized. |
// It returns NULL if no adapter has been created at the time. |
static scoped_refptr<BluetoothAdapter> MaybeGetAdapter(); |
+ |
+ private: |
+ AdapterInitializer adapter_initializer_; |
}; |
} // namespace device |