OSDN Git Service

Add USB_HOST_CONNECTED extra to ACTION_USB_STATE sticky intent.
authorDaichi Hirono <hirono@google.com>
Thu, 17 Mar 2016 05:14:32 +0000 (14:14 +0900)
committerDaichi Hirono <hirono@google.com>
Thu, 17 Mar 2016 05:14:32 +0000 (14:14 +0900)
commit618fa6ffc154fd131697b6107b431b4557ec118c
tree6ee947630c808506dda0c1e794c98d1e8d4507f2
parent62006a72a66ddc5849b28d7ceaaa304b66aa3dc9
Add USB_HOST_CONNECTED extra to ACTION_USB_STATE sticky intent.

Previously UsbModeChooser activity is automatically closed when Android
is connected to another Android and works as host. This is because
ACTION_USB_STATE intent does not include the information whether Android
is connected as host and UsbModeChooser regards Android is not connected
USB devices.

The CL introduce the HOST_CONNECTED extra to ACTION_USB_STATE so that
UsbModeChooser can refer it.

BUG=27535640

Change-Id: Ie29583b78319078430f6d9a8390787780410ac8c
core/java/android/hardware/usb/UsbManager.java
services/usb/java/com/android/server/usb/UsbDeviceManager.java