OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 #include "content/child/bluetooth/web_bluetooth_impl.h" | 5 #include "content/child/bluetooth/web_bluetooth_impl.h" |
6 | 6 |
7 #include "content/child/bluetooth/bluetooth_dispatcher.h" | 7 #include "content/child/bluetooth/bluetooth_dispatcher.h" |
8 #include "content/child/thread_safe_sender.h" | 8 #include "content/child/thread_safe_sender.h" |
9 | 9 |
10 namespace content { | 10 namespace content { |
(...skipping 16 matching lines...) Expand all Loading... |
27 } | 27 } |
28 | 28 |
29 void WebBluetoothImpl::getPrimaryService( | 29 void WebBluetoothImpl::getPrimaryService( |
30 const blink::WebString& device_instance_id, | 30 const blink::WebString& device_instance_id, |
31 const blink::WebString& service_uuid, | 31 const blink::WebString& service_uuid, |
32 blink::WebBluetoothGetPrimaryServiceCallbacks* callbacks) { | 32 blink::WebBluetoothGetPrimaryServiceCallbacks* callbacks) { |
33 GetDispatcher()->getPrimaryService(device_instance_id, service_uuid, | 33 GetDispatcher()->getPrimaryService(device_instance_id, service_uuid, |
34 callbacks); | 34 callbacks); |
35 } | 35 } |
36 | 36 |
| 37 void WebBluetoothImpl::getCharacteristic( |
| 38 const blink::WebString& service_instance_id, |
| 39 const blink::WebString& characteristic_uuid, |
| 40 blink::WebBluetoothGetCharacteristicCallbacks* callbacks) { |
| 41 GetDispatcher()->getCharacteristic(service_instance_id, characteristic_uuid, |
| 42 callbacks); |
| 43 } |
| 44 |
37 BluetoothDispatcher* WebBluetoothImpl::GetDispatcher() { | 45 BluetoothDispatcher* WebBluetoothImpl::GetDispatcher() { |
38 return BluetoothDispatcher::GetOrCreateThreadSpecificInstance( | 46 return BluetoothDispatcher::GetOrCreateThreadSpecificInstance( |
39 thread_safe_sender_.get()); | 47 thread_safe_sender_.get()); |
40 } | 48 } |
41 | 49 |
42 } // namespace content | 50 } // namespace content |
OLD | NEW |