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

Side by Side Diff: public/platform/WebBluetoothDevice.h

Issue 876623003: bluetooth: New WebBluetoothDevice attributes plumbed to BluetoothDevice. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@bt-1-
Patch Set: Created 5 years, 10 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 unified diff | Download patch
« no previous file with comments | « Source/modules/bluetooth/BluetoothDevice.idl ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 #ifndef WebBluetoothDevice_h 5 #ifndef WebBluetoothDevice_h
6 #define WebBluetoothDevice_h 6 #define WebBluetoothDevice_h
7 7
8 #include "WebString.h" 8 #include "WebString.h"
9 #include "WebVector.h" 9 #include "WebVector.h"
10 10
11 namespace blink { 11 namespace blink {
12 12
13 // Information describing a Bluetooth device provided by the platform. 13 // Information describing a Bluetooth device provided by the platform.
14 struct WebBluetoothDevice { 14 struct WebBluetoothDevice {
15 enum class VendorIDSource { 15 enum class VendorIDSource {
16 Unknown, 16 Unknown,
17 Bluetooth, 17 Bluetooth,
18 USB 18 USB
19 }; 19 };
20 20
21 // FIXME: Remove after crrev.com/885723002 lands.
22 WebBluetoothDevice(const WebString& instanceID)
23 : instanceID(instanceID)
24 , deviceClass(0)
25 , vendorIDSource(VendorIDSource::Unknown)
26 , vendorID(0)
27 , productID(0)
28 , productVersion(0)
29 , paired(false)
30 , connected(false)
31 , uuids()
32 {
33 }
34
35 WebBluetoothDevice(const WebString& instanceID, 21 WebBluetoothDevice(const WebString& instanceID,
36 const WebString& name, 22 const WebString& name,
37 int32_t deviceClass, 23 int32_t deviceClass,
38 VendorIDSource vendorIDSource, 24 VendorIDSource vendorIDSource,
39 uint16_t vendorID, 25 uint16_t vendorID,
40 uint16_t productID, 26 uint16_t productID,
41 uint16_t productVersion, 27 uint16_t productVersion,
42 bool paired, 28 bool paired,
43 bool connected, 29 bool connected,
44 const WebVector<WebString>& uuids) 30 const WebVector<WebString>& uuids)
(...skipping 19 matching lines...) Expand all
64 const uint16_t productID; 50 const uint16_t productID;
65 const uint16_t productVersion; 51 const uint16_t productVersion;
66 const bool paired; 52 const bool paired;
67 const bool connected; 53 const bool connected;
68 const WebVector<WebString> uuids; 54 const WebVector<WebString> uuids;
69 }; 55 };
70 56
71 } // namespace blink 57 } // namespace blink
72 58
73 #endif // WebBluetoothDevice_h 59 #endif // WebBluetoothDevice_h
OLDNEW
« no previous file with comments | « Source/modules/bluetooth/BluetoothDevice.idl ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698