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

Side by Side Diff: device/usb/usb_descriptors.h

Issue 1565313002: Reland of Implement basic USB device enumeration on Android. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Dependency fix added to reland. Created 4 years, 11 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 | « device/usb/usb_configuration_android.cc ('k') | device/usb/usb_device.h » ('j') | 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 DEVICE_USB_USB_DESCRIPTORS_H_ 5 #ifndef DEVICE_USB_USB_DESCRIPTORS_H_
6 #define DEVICE_USB_USB_DESCRIPTORS_H_ 6 #define DEVICE_USB_USB_DESCRIPTORS_H_
7 7
8 #include <stdint.h> 8 #include <stdint.h>
9 #include <vector> 9 #include <vector>
10 10
11 #include "base/strings/string16.h" 11 #include "base/strings/string16.h"
12 12
13 namespace device { 13 namespace device {
14 14
15 // A Java counterpart will be generated for this enum.
16 // GENERATED_JAVA_ENUM_PACKAGE: org.chromium.device.usb
15 enum UsbTransferType { 17 enum UsbTransferType {
16 USB_TRANSFER_CONTROL = 0, 18 USB_TRANSFER_CONTROL = 0,
17 USB_TRANSFER_ISOCHRONOUS, 19 USB_TRANSFER_ISOCHRONOUS,
18 USB_TRANSFER_BULK, 20 USB_TRANSFER_BULK,
19 USB_TRANSFER_INTERRUPT, 21 USB_TRANSFER_INTERRUPT,
20 }; 22 };
21 23
24 // A Java counterpart will be generated for this enum.
25 // GENERATED_JAVA_ENUM_PACKAGE: org.chromium.device.usb
22 enum UsbEndpointDirection { 26 enum UsbEndpointDirection {
23 USB_DIRECTION_INBOUND = 0, 27 USB_DIRECTION_INBOUND = 0,
24 USB_DIRECTION_OUTBOUND, 28 USB_DIRECTION_OUTBOUND,
25 }; 29 };
26 30
27 enum UsbSynchronizationType { 31 enum UsbSynchronizationType {
28 USB_SYNCHRONIZATION_NONE = 0, 32 USB_SYNCHRONIZATION_NONE = 0,
29 USB_SYNCHRONIZATION_ASYNCHRONOUS, 33 USB_SYNCHRONIZATION_ASYNCHRONOUS,
30 USB_SYNCHRONIZATION_ADAPTIVE, 34 USB_SYNCHRONIZATION_ADAPTIVE,
31 USB_SYNCHRONIZATION_SYNCHRONOUS, 35 USB_SYNCHRONIZATION_SYNCHRONOUS,
(...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after
75 std::vector<UsbInterfaceDescriptor> interfaces; 79 std::vector<UsbInterfaceDescriptor> interfaces;
76 std::vector<uint8_t> extra_data; 80 std::vector<uint8_t> extra_data;
77 }; 81 };
78 82
79 bool ParseUsbStringDescriptor(const std::vector<uint8_t>& descriptor, 83 bool ParseUsbStringDescriptor(const std::vector<uint8_t>& descriptor,
80 base::string16* output); 84 base::string16* output);
81 85
82 } // namespace device 86 } // namespace device
83 87
84 #endif // DEVICE_USB_USB_DESCRIPTORS_H_ 88 #endif // DEVICE_USB_USB_DESCRIPTORS_H_
OLDNEW
« no previous file with comments | « device/usb/usb_configuration_android.cc ('k') | device/usb/usb_device.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698