Previously, we generally required fully qualified names for referring
to inner class constructors (like #Notification.Builder()) despite that
not being valid javadoc. Now, we properly support #Builder() syntax and
the old syntax will error.
Bug: 6963924
Test: make doc-comment-check-docs
Exempt-From-Owner-Approval: cherry-picked from master
Change-Id: Ib2e4360493275b79c72487ee1cb173bb5e0fd35f
Merged-In: Ib2e4360493275b79c72487ee1cb173bb5e0fd35f
(cherry picked from commit 4c4aa41272)
These were previously being suppressed by doclava but with this change,
all failures are fixed and the suppression logic has been removed.
To fix the issues, there were a few possible changes made:
- broken reference to a public API (such as incorrect parameters): fixed
- unnecessary @link inside an @see tag: fixed
- @see referring to an @hide or @SystemApi: reference removed
- broken references to inner class constructors
- worked around by fully qualifying the constructor
Bug: 6963924
Test: make doc-comment-check-docs
Exempt-From-Owner-Approval: cherry-picked from master
Change-Id: Ifbdce2de96cdffa560bd90f549fa7184d1f9af85
Merged-In: Ifbdce2de96cdffa560bd90f549fa7184d1f9af85
(cherry picked from commit e0624c7a40)
Under the new MtpStorageManager design,
media info like MP3 Track title, album and artist, Genre, etc
can not be retrieved via MTP
by Windows Media Player, Linux Rhythmbox and Some Car Kits
Bug: 112635346
Test: atest MtpTests
Test: atest MediaProviderTests
Test: Manual test: Windows Media Player
Change-Id: I57a947fe6d3a583a0990be5bd2b0678f39d948f2
In RecordingActivityMonitor, compare audio device type and address to
know if legacy remote submix is active, which requires querying audio
patches. When there is a recording callback event, the audio patches in
AudioManager may not be up to date. In that case, when getting a
recording callback event, reset audio port generation if the patch
handle is not found in the cached audio patches.
Test: repro steps in the bug
Bug: 144063329
Change-Id: Ife5c9a65243d2e85e4cd9480e3b415f8bfddc6f5
It will call back onSessionCreated or onRequestFailed with
the correct arguments.
Bug: 152932787
Test: manually by cast -> phone multiple times via Output Switcher.
It includes the case that the target route changes (phone -> BT).
Change-Id: Icc324f3e7d6dfde71faa6d3bc919be383e7a5216
Due to a binder limitation (b/150808347), any unexpected exception
thrown by a binder service while processing an RPC call, will be
silently discarded and the client will get back a default-initialized
result parcelable (i.e. in most cases, won't know that anything wrong
happened).
We work around this issue by throwing a ServiceSpecificException,
which does get delivered, having a special code to designate an
internal error. Errors resulting from a HAL malfunctions will result
in a HAL reboot, which leads to recovery.
Bug: 154089179
Test: Manual verification of basic error recovery scenarios by
injecting HAL error codes and crashes.
Change-Id: Ib5dbe08a362e545501c04204bebad5ab95f5d632
Fix issue with A2DP connection/disconnection during media
playback by modifying:
- how messages related to A2DP connection/disconnection are
removed from the AudioDeviceBroker message handler: have
.equals() be used when checking which object to remove,
and correct which class is used for the messages in the
queue:
* MSG_IL_SET_A2DP_SINK_CONNECTION_STATE_*CONNECTED is
using BtHelper.BluetoothA2dpDeviceInfo
* MSG_L_A2DP_DEVICE_CONNECTION_CHANGE_EXT_CONNECTION
is using BtDeviceConnectionInfo
- locking: use the AudioDeviceBroker main lock, mDeviceStateLock
to synchronize posting events on the handler, and removing
some of those messages to avoid race conditions the thread
in which events are posted (e.g. BT's event thread) and the
AudioDeviceBroker handler thread.
Cleanup: annotation around audio formats from native defined
in AudioSystem, moved conversions to AudioSystem.
Bug: 142293357
Test: atest AudioDeviceBrokerTest
Change-Id: I2e8dc813354829fb1b2c7ca95ad395a14f8b70cf
Previously when MediaRouter2#transferTo(route) is called, it directly
released current controller. This CL changes the release timing to
when the actual transfer result comes.
Also, this CL prevents a RoutingController instance from being passed
both to:
- As 'oldController' in onTransfer()
- As 'controller' in onStop()
These works make TransferCallback easy to use: when onStop() is called,
app can just stop playing media.
Bug: 154680146
Test: Passed CTS / Checked logs in onTransfer/onStop
with output switcher
Change-Id: I4449021f98ca887252e05398356df9b53592c145
This CL clears routes when the last callback of MediaRouter2Manager
is unregistered. By doing this, we can ensure
MediaRouter2Manager#getAvailableRoutes() returns correct routes
during at least a single callback is registered.
A test for the behavior is added as well.
This CL also fixed a bug that unregistering a callback from MediaRouter2
disconnects it when multiple callback is used.
Bug: 153515567
Test: atest mediaroutertest & cts test & manually
using MediaRouter2Demo and Sample OutputSwitcher to see
if forgotten BT device is correctly removed.
(w/o this CL forgotten BT device remains)
Change-Id: I31a5001115f1f163c8971bbd906516551b860252
When MR2Manager requests to create a routing session, it should pass
session hints to the target provider.
This CL adds a logic that MR2Manager asks media router instance to
get session hints to be passed to the provider.
Bug: 152851868
Test: atest mediaroutertest
Change-Id: Ib421f61f663090c6ed95c8b1a2f7deeb80e5be16
Fix access by reference to listener list outside of
synchronized block by cloning the list.
Bug: 154341343
Test: AudioPolicyTest#testAudioPorts, AudioManagerTest#testVolumeGroupCallback, AudioRoutingTest
Change-Id: I1f0fd62c1894dc0dbb07b01f2fd78899e48b4932
Gamepad-specific API is a separtate input path from standard "remote"
service. Specifically it adds:
- openGamepad that creates a virtual input device with
gamepad-specific suport
- send gamepad keys
- send gamepad axis updates, which support joysticks, analog triggers
and HAT axis (as an alternative to DPAD buttons).
Bug: 150764186
Test: atest media/lib/tvremote/tests/src/com/android/media/tv/remoteprovider/TvRemoteProviderTest.java
Test: flashed a ADT-3 device after the changes. Android TV Remote
on my phone still worked in controlling the UI.
Merged-In: I49612fce5e74c4e00ca60c715c6c72954e73b7a3
Change-Id: I49612fce5e74c4e00ca60c715c6c72954e73b7a3
(cherry picked from commit 9b9f556af1)
This can unblock tune/scan CTS test cases.
If a frontend resource is acquired in a test case and not released,
it cannot be used by another test case.
Bug: 150952758
Test: atest android.media.tv.tuner.cts.TunerTest
Change-Id: Ib9bab003fc81fe008091a9d1aaefc43e454c3230
Bug: 153934282
Test: Checked the logs that the method is called only once
Also ran CTS / atest mediaroutertest
Change-Id: I0c27ecd5b1c83be241fcebe71a7e0ea9f1c9e349
Since ExifInterface supports multi-thread, SimpleDateFormat
should be thread-safe.
Bug: 152801859
Test: N/A
Change-Id: I9ad5a035162f5e3caff2a2d4aaff2ae0cd870cd2