API addition: The timestamps are represented as nanoseconds from some
arbitrary time point. Like the SurfaceTexture transform matrix, the
timestamp retrieved by getTimestamp is for the last frame sent to the
GL texture using updateTexImage().
Camera HAL change: Expect vendors to set these timestamps using
native_window_set_buffers_timestamp(). For now, they are
autogenerated by SurfaceTextureClient if set_buffers_timestamp() is
never called, but such timing is likely not accurate enough to pass a
CTS test.
bug:3300707
Change-Id: Ife131a0c2a826ac27342e11b8a6c42ff49e1bea7
Fixes an ANR that occurred if we got a USB disconnected event
before the MTP service had started.
Bug: 4118033
Change-Id: I6cad4281a5911a9926cae923f34d3a6bf98346c5
Signed-off-by: Mike Lockwood <lockwood@android.com>
Do not call directly into AudioSystem in setBluetoothScoOn() but
send a message to the AudioService handler instead. As the
procedure to switch audio path to BT SCO can last some time we should
not block the caller which can run in the UI thread.
Change-Id: I6ac4b5a934d69781db3aebe5d0e8137b52a0ada4
* commit '75c95e9a6d5a91b660af62f72b5a3bac0f5c3811':
UsbManager: Hide APIs not needed for USB host or accessory support.
Remove MtpClient class from framework and public API
UsbDevice: Move IO related methods to new UsbDeviceConnection class
After reviewing this class I decided it would be best not to include it in the public API
since it adds no functionality that cannot be done using MtpDevice and other APIs directly.
So I am moving it to the CameraBrowser sample instead.
Also changed CameraBrowser to build against the SDK to ensure all the necessary APIs for
PTP support have been made public.
Bug: 4067029
Change-Id: I585b06104084953176d018ced08bba0cb4607490
Signed-off-by: Mike Lockwood <lockwood@android.com>
UsbDevice is now just an immutable parcelable object like UsbInterface and
UsbEndpoint.
All IO related functionality is now contained in UsbDeviceConnection
and UsbRequest.
Bug: 4067029
Change-Id: Ia84da0b512a697acc940eee0c3566711c62e1a68
Signed-off-by: Mike Lockwood <lockwood@android.com>
* commit '093cf07f3c58a6553c415d750edba1a75b269f05':
Close USB dialogs if their corresponding accessory or device has disconnected
USB: Add API and dialog for apps to request permissions for USB devices and accessories
UsbService: Automatically use system apps by default if it is the only choice
New APIs:
UsbManager.hasPermission returns true if the caller has permission
for the given device or accessory
UsbManager.requestPermission poses a dialog to allow the user to give the caller
permission for the device or accessory.
Result is returned via a PendingIntent.
No dialog is displayed if the caller already has permission.
Also moved UsbResolverActivity to SystemUI package
BUG: 4069037
Change-Id: I93be769501a8776b49ac26e468af19f8fa2114c9
Use a death handler when audio focus changes are caused by audio
mode changes.
The bug comes from the fact that audio focus clients that use the
audio mode for automatic focus handling didn't register a death
handler, which was set to null. When such a client died, this
handler was compared against the one to remove from the
audio focus stack, which resulted in an NPE.
The fix consists in registering a valid IBinder object in the
audio focus stack, even for clients whose focus requests originate
from a change in audio mode, as implemented in the
handleFocusForCalls() method.
Change-Id: Id9e1d3d10afcd99969285f6d60fc4d7dde1e4a10
sqlite3 is overkill for what we are doing here, and more fragile.
BUG: 3512856
Change-Id: I83d86127949d894a3887db3456d91b013060e852
Signed-off-by: Mike Lockwood <lockwood@android.com>
Release all sco audio clients when the intent indicating
STATE_AUDIO_DISCONNECTED state is received.
Also clear mScoClients array when clients are released.
Change-Id: I63ec9d70fe72a102e09a4a473a367fb2e550b171
The heap memory dump is enabled when libc.debug.malloc property is 1.
Two .dump files are created in predefined path.
Memory leak report can be generated using nativeheapdump tool.
Change-Id: Ie03928b5a05993e72d4700a158657c514478ecd3