Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(300)

Unified Diff: device/bluetooth/bluetooth_device_chromeos.h

Issue 267633003: Reimplement BluetoothSocketChromeOS (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: device/bluetooth/bluetooth_device_chromeos.h
diff --git a/device/bluetooth/bluetooth_device_chromeos.h b/device/bluetooth/bluetooth_device_chromeos.h
index 156d9ea1cc4c785cf87ad1cacc60022cf34046fa..8fda5472374fe06b80b7e9231192ea8608bbf277 100644
--- a/device/bluetooth/bluetooth_device_chromeos.h
+++ b/device/bluetooth/bluetooth_device_chromeos.h
@@ -7,14 +7,20 @@
#include <string>
+#include "base/memory/ref_counted.h"
#include "base/memory/scoped_ptr.h"
#include "base/memory/weak_ptr.h"
#include "base/observer_list.h"
+#include "base/sequenced_task_runner.h"
#include "chromeos/dbus/bluetooth_device_client.h"
#include "chromeos/dbus/bluetooth_gatt_service_client.h"
#include "dbus/object_path.h"
#include "device/bluetooth/bluetooth_device.h"
+namespace device {
+class BluetoothSocketThread;
+} // namespace device
+
namespace chromeos {
class BluetoothAdapterChromeOS;
@@ -90,8 +96,11 @@ class BluetoothDeviceChromeOS
private:
friend class BluetoothAdapterChromeOS;
- BluetoothDeviceChromeOS(BluetoothAdapterChromeOS* adapter,
- const dbus::ObjectPath& object_path);
+ BluetoothDeviceChromeOS(
+ BluetoothAdapterChromeOS* adapter,
+ const dbus::ObjectPath& object_path,
+ scoped_refptr<base::SequencedTaskRunner> ui_task_runner_,
armansito 2014/05/01 00:14:25 Shouldn't have underscores at the end of function
keybuk 2014/05/01 00:24:09 Done.
+ scoped_refptr<device::BluetoothSocketThread> socket_thread_);
virtual ~BluetoothDeviceChromeOS();
// BluetoothGattServiceClient::Observer overrides.
@@ -169,6 +178,10 @@ class BluetoothDeviceChromeOS
// Number of ongoing calls to Connect().
int num_connecting_calls_;
+ // UI thread task runner and socket thread object used to create sockets.
+ scoped_refptr<base::SequencedTaskRunner> ui_task_runner_;
+ scoped_refptr<device::BluetoothSocketThread> socket_thread_;
+
// During pairing this is set to an object that we don't own, but on which
// we can make method calls to request, display or confirm PIN Codes and
// Passkeys. Generally it is the object that owns this one.

Powered by Google App Engine
This is Rietveld 408576698