summaryrefslogtreecommitdiffstats
path: root/content/app
diff options
context:
space:
mode:
authorreillyg <reillyg@chromium.org>2016-01-07 14:00:09 -0800
committerCommit bot <commit-bot@chromium.org>2016-01-07 22:00:58 +0000
commit4e17561af22e80438cd255dd5c92d64b57f4955d (patch)
tree271502639e3fd5d32adca422eb644af49e7de6d8 /content/app
parentff1966e831cce0b4a40cfa2bad90e9b6fdf4eb89 (diff)
downloadchromium_src-4e17561af22e80438cd255dd5c92d64b57f4955d.zip
chromium_src-4e17561af22e80438cd255dd5c92d64b57f4955d.tar.gz
chromium_src-4e17561af22e80438cd255dd5c92d64b57f4955d.tar.bz2
Reland of Implement basic USB device enumeration on Android. (patchset #1 id:1 of https://codereview.chromium.org/1561283003/ )
Reason for revert: Lack of GYP dependency on //device/usb Java sources fixed. Original issue's description: > Revert of Implement basic USB device enumeration on Android. (patchset #3 id:40001 of https://codereview.chromium.org/1514603006/ ) > > Reason for revert: > Speculating that this is the cause of issue 575191. > > Original issue's description: > > Implement basic USB device enumeration on Android. > > > > This patch provides a basic implementation of UsbService::GetDevices on > > Android that populates UsbDevice objects by collecting properties of the > > Java-side UsbDevice, UsbConfiguration, UsbInterface and UsbEndpoint > > objects over JNI. > > > > It does not support opening devices and does not generate device add or > > remove notifications. > > > > BUG=549257 > > > > Committed: https://crrev.com/8a310851fb144e91d1777112930ac15c0d88577b > > Cr-Commit-Position: refs/heads/master@{#367918} > > TBR=nasko@chromium.org,qinmin@chromium.org,yfriedman@chromium.org,pfeldman@chromium.org > # Skipping CQ checks because original CL landed less than 1 days ago. > NOPRESUBMIT=true > NOTREECHECKS=true > NOTRY=true > BUG=549257,575191 > > Committed: https://crrev.com/e3de6dea8003be39328bea275763daab36a8df24 > Cr-Commit-Position: refs/heads/master@{#368077} TBR=nasko@chromium.org,qinmin@chromium.org,yfriedman@chromium.org,pfeldman@chromium.org BUG=549257,575191 Review URL: https://codereview.chromium.org/1565313002 Cr-Commit-Position: refs/heads/master@{#368169}
Diffstat (limited to 'content/app')
-rw-r--r--content/app/DEPS1
-rw-r--r--content/app/android/library_loader_hooks.cc4
2 files changed, 5 insertions, 0 deletions
diff --git a/content/app/DEPS b/content/app/DEPS
index f4792db..7745238 100644
--- a/content/app/DEPS
+++ b/content/app/DEPS
@@ -3,6 +3,7 @@ include_rules = [
"+content",
"+device/battery",
"+device/bluetooth",
+ "+device/usb",
"+device/vibration",
# For loading V8's initial snapshot from external files.
"+gin/public/isolate_holder.h",
diff --git a/content/app/android/library_loader_hooks.cc b/content/app/android/library_loader_hooks.cc
index 487d973..21e51b3 100644
--- a/content/app/android/library_loader_hooks.cc
+++ b/content/app/android/library_loader_hooks.cc
@@ -26,6 +26,7 @@
#include "content/public/common/content_switches.h"
#include "content/public/common/result_codes.h"
#include "device/bluetooth/android/bluetooth_jni_registrar.h"
+#include "device/usb/android/usb_jni_registrar.h"
#include "media/base/android/media_jni_registrar.h"
#include "media/midi/midi_jni_registrar.h"
#include "net/android/net_jni_registrar.h"
@@ -75,6 +76,9 @@ bool EnsureJniRegistered(JNIEnv* env) {
if (!device::android::RegisterBluetoothJni(env))
return false;
+ if (!device::android::RegisterUsbJni(env))
+ return false;
+
if (!media::RegisterJni(env))
return false;