Chromium Code Reviews| Index: content/browser/bluetooth/bluetooth_dispatcher_host.h |
| diff --git a/content/browser/bluetooth/bluetooth_dispatcher_host.h b/content/browser/bluetooth/bluetooth_dispatcher_host.h |
| index 8a8714f17bf49c1a84d065a7ba5dfe001ec64d03..83e4a45bb6abf40c0fa8ebdafb682337d1e1b965 100644 |
| --- a/content/browser/bluetooth/bluetooth_dispatcher_host.h |
| +++ b/content/browser/bluetooth/bluetooth_dispatcher_host.h |
| @@ -7,6 +7,7 @@ |
| #include "base/basictypes.h" |
| #include "base/id_map.h" |
| +#include "base/memory/scoped_vector.h" |
| #include "base/memory/weak_ptr.h" |
| #include "content/public/browser/bluetooth_chooser.h" |
| #include "content/public/browser/browser_message_filter.h" |
| @@ -187,6 +188,10 @@ class CONTENT_EXPORT BluetoothDispatcherHost final |
| // sessions when other sessions are active. |
| base::Timer discovery_session_timer_; |
| + // Retain BluetoothGattConnection objects to keep connections open. |
| + // TODO(scheib): Destroy as connections are closed. http://crbug.com/539643 |
| + ScopedVector<device::BluetoothGattConnection> connections_; |
|
ortuno
2015/10/06 19:45:46
Should we clean this when we call setAdapter? Othe
scheib
2015/10/06 20:30:37
Done.
|
| + |
| // |weak_ptr_on_ui_thread_| provides weak pointers, e.g. for callbacks, and |
| // because it exists and has been bound to the UI thread enforces that all |
| // copies verify they are also used on the UI thread. |