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

Unified Diff: device/usb/usb_descriptors.h

Issue 2821813002: Use Mojo enum types in the C++ USB interface (Closed)
Patch Set: Fix up //device/usb dependencies in //extensions/browser/api Created 3 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
« no previous file with comments | « device/usb/public/interfaces/device.mojom ('k') | device/usb/usb_descriptors.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: device/usb/usb_descriptors.h
diff --git a/device/usb/usb_descriptors.h b/device/usb/usb_descriptors.h
index 9039c957100108c790a848284882deb2a8d7cdf6..b0f5be6b6f4904313e1ec5707093f841afb7b206 100644
--- a/device/usb/usb_descriptors.h
+++ b/device/usb/usb_descriptors.h
@@ -14,22 +14,14 @@
#include "base/callback_forward.h"
#include "base/memory/ref_counted.h"
#include "base/strings/string16.h"
+#include "device/usb/public/interfaces/device.mojom.h"
namespace device {
class UsbDeviceHandle;
-enum UsbTransferType {
- USB_TRANSFER_CONTROL = 0,
- USB_TRANSFER_ISOCHRONOUS,
- USB_TRANSFER_BULK,
- USB_TRANSFER_INTERRUPT,
-};
-
-enum UsbEndpointDirection {
- USB_DIRECTION_INBOUND = 0,
- USB_DIRECTION_OUTBOUND,
-};
+using UsbTransferType = mojom::UsbTransferType;
+using UsbTransferDirection = mojom::UsbTransferDirection;
enum UsbSynchronizationType {
USB_SYNCHRONIZATION_NONE = 0,
@@ -61,7 +53,7 @@ struct UsbEndpointDescriptor {
~UsbEndpointDescriptor();
uint8_t address;
- UsbEndpointDirection direction;
+ UsbTransferDirection direction;
uint16_t maximum_packet_size;
UsbSynchronizationType synchronization_type;
UsbTransferType transfer_type;
« no previous file with comments | « device/usb/public/interfaces/device.mojom ('k') | device/usb/usb_descriptors.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698