| 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 #ifndef DEVICE_USB_USB_DEVICE_IMPL_H_ | 5 #ifndef DEVICE_USB_USB_DEVICE_IMPL_H_ |
| 6 #define DEVICE_USB_USB_DEVICE_IMPL_H_ | 6 #define DEVICE_USB_USB_DEVICE_IMPL_H_ |
| 7 | 7 |
| 8 #include <stdint.h> | 8 #include <stdint.h> |
| 9 | 9 |
| 10 #include <string> | 10 #include <string> |
| (...skipping 29 matching lines...) Expand all Loading... |
| 40 typedef struct libusb_config_descriptor* PlatformUsbConfigDescriptor; | 40 typedef struct libusb_config_descriptor* PlatformUsbConfigDescriptor; |
| 41 typedef struct libusb_device_handle* PlatformUsbDeviceHandle; | 41 typedef struct libusb_device_handle* PlatformUsbDeviceHandle; |
| 42 | 42 |
| 43 class UsbDeviceImpl : public UsbDevice { | 43 class UsbDeviceImpl : public UsbDevice { |
| 44 public: | 44 public: |
| 45 // UsbDevice implementation: | 45 // UsbDevice implementation: |
| 46 #if defined(OS_CHROMEOS) | 46 #if defined(OS_CHROMEOS) |
| 47 void CheckUsbAccess(const ResultCallback& callback) override; | 47 void CheckUsbAccess(const ResultCallback& callback) override; |
| 48 #endif // OS_CHROMEOS | 48 #endif // OS_CHROMEOS |
| 49 void Open(const OpenCallback& callback) override; | 49 void Open(const OpenCallback& callback) override; |
| 50 const UsbConfigDescriptor* GetActiveConfiguration() override; | 50 const UsbConfigDescriptor* GetActiveConfiguration() const override; |
| 51 | 51 |
| 52 // These functions are used during enumeration only. The values must not | 52 // These functions are used during enumeration only. The values must not |
| 53 // change during the object's lifetime. | 53 // change during the object's lifetime. |
| 54 void set_manufacturer_string(const base::string16& value) { | 54 void set_manufacturer_string(const base::string16& value) { |
| 55 manufacturer_string_ = value; | 55 manufacturer_string_ = value; |
| 56 } | 56 } |
| 57 void set_product_string(const base::string16& value) { | 57 void set_product_string(const base::string16& value) { |
| 58 product_string_ = value; | 58 product_string_ = value; |
| 59 } | 59 } |
| 60 void set_serial_number(const base::string16& value) { | 60 void set_serial_number(const base::string16& value) { |
| (...skipping 68 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 129 | 129 |
| 130 scoped_refptr<base::SequencedTaskRunner> task_runner_; | 130 scoped_refptr<base::SequencedTaskRunner> task_runner_; |
| 131 scoped_refptr<base::SequencedTaskRunner> blocking_task_runner_; | 131 scoped_refptr<base::SequencedTaskRunner> blocking_task_runner_; |
| 132 | 132 |
| 133 DISALLOW_COPY_AND_ASSIGN(UsbDeviceImpl); | 133 DISALLOW_COPY_AND_ASSIGN(UsbDeviceImpl); |
| 134 }; | 134 }; |
| 135 | 135 |
| 136 } // namespace device | 136 } // namespace device |
| 137 | 137 |
| 138 #endif // DEVICE_USB_USB_DEVICE_IMPL_H_ | 138 #endif // DEVICE_USB_USB_DEVICE_IMPL_H_ |
| OLD | NEW |