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

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

Issue 1561283003: Revert of Implement basic USB device enumeration on Android. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: 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_interface_android.cc ('k') | device/usb/usb_service_android.cc » ('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 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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_SERVICE_ANDROID_H_ 5 #ifndef DEVICE_USB_USB_SERVICE_ANDROID_H_
6 #define DEVICE_USB_USB_SERVICE_ANDROID_H_ 6 #define DEVICE_USB_USB_SERVICE_ANDROID_H_
7 7
8 #include <string>
9
10 #include "base/android/scoped_java_ref.h"
11 #include "device/usb/usb_service.h" 8 #include "device/usb/usb_service.h"
12 9
13 namespace device { 10 namespace device {
14 11
15 // USB service implementation for Android. This is a stub implementation that 12 // USB service implementation for Android. This is a stub implementation that
16 // does not return any devices. 13 // does not return any devices.
17 class UsbServiceAndroid : public UsbService { 14 class UsbServiceAndroid : public UsbService {
18 public: 15 public:
19 // Register C++ methods exposed to Java using JNI.
20 static bool RegisterJNI(JNIEnv* env);
21
22 UsbServiceAndroid(); 16 UsbServiceAndroid();
23 ~UsbServiceAndroid() override; 17 ~UsbServiceAndroid() override;
24 18
25 // UsbService:
26 scoped_refptr<UsbDevice> GetDevice(const std::string& guid) override; 19 scoped_refptr<UsbDevice> GetDevice(const std::string& guid) override;
27 void GetDevices(const GetDevicesCallback& callback) override; 20 void GetDevices(const GetDevicesCallback& callback) override;
28
29 private:
30 // Java object org.chromium.device.usb.ChromeUsbService.
31 base::android::ScopedJavaGlobalRef<jobject> j_object_;
32 }; 21 };
33 22
34 } // namespace device 23 } // namespace device
35 24
36 #endif // DEVICE_USB_USB_SERVICE_ANDROID_H_ 25 #endif // DEVICE_USB_USB_SERVICE_ANDROID_H_
OLDNEW
« no previous file with comments | « device/usb/usb_interface_android.cc ('k') | device/usb/usb_service_android.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698