See build/soong/README.md for more information.
Also converts the rest of frameworks/base/tools/streaming_proto.
Bug: 122332340
Test: m checkbuild
Change-Id: I87c500c5464fb1722b4b518d89065f5e1ee29a97
Merged-In: Ieb54feb3902bddfd5a571369fbf50161ae646647
See build/soong/README.md for more information.
Bug: 122332340
Test: m media
Test: m RunBackupFrameworksServicesRoboTests
Change-Id: Ieb54feb3902bddfd5a571369fbf50161ae646647
In order to avoid direct AIDL usages in framework, this CL introduces a
new public class ControllerCallbackLink which can prevent usages of
ISessionControllerCallback.
Bug: 122337578
Test: make update-api -j / make -j
atest CtsMediaTestCases:android.media.cts.MediaSessionTest
atest CtsMediaTestCases:android.media.cts.MediaControllerTest
Change-Id: Id674576aa071b7fdbd0082bf6189fef2af2d919b
This CL makes MediaController.PlaybackInfo implement Parcelable, and
replaces ParcelableVolumeInfo with the class.
Bug: 122243794
Test: make update-api -j; make -j;
Change-Id: I89d3df721a43e8c1454dbb3bdcb0b34c943339ce
This reverts commit e521669b5d7aa6ce32bf965bd0bb9a84a2cdb19b.
Reason for revert: Another CL will be uploaded which makes the APIs public, not @SystemApi.
Bug: 122169124
Change-Id: Ie9ed1067596fe1724879e81d768ac8252eda7841
In order to avoid direct AIDL usages in framework, this CL introduces a
new class ControllerCallbackLink which can prevent usages of
ISessionControllerCallback.
Bug: 122169124
Test: make update-api -j / make -j
atest CtsMediaTestCases:android.media.cts.MediaSessionTest
atest CtsMediaTestCases:android.media.cts.MediaControllerTest
Change-Id: I860ea56afc046dd91e065ef207d374c0aa490c8f
MediaSession#getCurrentControllerInfo() can have more fine grained
differentiation for multiple MediaController in a package/process
Bug: 79728675
Test: Run CtsMediaTestCases
Change-Id: I81e94736e795ee5e7fbd28cb6cd834cc3a3b8f98
Current limitation is that we cannot distinguish between key events
from Window#injectInputEvent() and key presses from physical devices.
Bug: 79185725
Test: Manually verified with the test app, and Cts
Change-Id: I1c3da4a963238512eec8b57fbc2d825c7436b140
Without this, exec()ing these fails.
Found with `grep -L bin/sh $(grep -Rl Script)`
Bug: None
Test: exec()ed each of these scripts; I no longer get "exec format
error" for any of them.
Change-Id: I47db5007e5cc14ab91eb846b7bffecb925d37874
The old --set did not take a parameter for volume and was
defaulting to volume index of 5.
The old --index option allowed the user to set the volume to
a specified value.
This CL removes the old --set that had limited usefulness, and
renames --index to --set, so --set now takes a parameter for
volume.
For backward compatibility the --index option is kept around
to allow scripts time to switch to --set
Bug: 33791633
Test: adb shell media volume --set 4
Change-Id: I43a87a878439b3416efa746708b62a869023acdc
Add --get option to media volume to fetch the specified
stream volume and output it on the console.
Also displays the min and max volume for that stream.
Bug: 33559057
Test: adb shell media volume --stream 3 --get
Change-Id: Icc82ba1349dd75e07ccff4872e104843a69e5f17
Add option to the "media" command to set or adjust the volume.
Run "adb shell media" for options and examples.
Test: adb shell media
Change-Id: I434f9cd33a9fefb2cd21a3415ec8b2e0a569482e
Some legacy apps registered their media button receiver in a thread
without a looper. If this happens we need to use the main looper to
prevent a crash.
bug: 16306226
Change-Id: Idf472e649393e2a7ce2a3e1cbb3476003ab17f34
This adds some fields for display purposes to MediaMetadata and also
makes the default for all text CharSequence instead of String. Also
adds a hidden method for getting a Description for the metadata.
bug: 11708293
Change-Id: I0ed58d9ac3aeff41325c4ccf5fed0539bbf03b4d
This also adds a convenience method to MediaSession to allow getting
a controller instead of having to create and cache your own.
bug:16561220
Change-Id: I87f551a7474e71f1cf2f07e0e541c3a4515cd977
This removes the MediaSessionInfo class and adds a method on the
controller to get the package name. This also converts code that
depended on the session's UUID to use the token for comparison or
the Tag in the case of test code that needs a string identifier.
Change-Id: Icb8dc76c70e23e897da8fd07651c524b96372bf9
This makes the MediaSession/Controller constructors public and registers
with the system behind the scenes.
This also adds a bit about needing to call setActive(true) to start receiving
commands in MediaSession's docs.
Change-Id: If882d229b54c36bf0831aca0255052dda667a2bc
Removes some more hidden apis from AudioService/Manager. This also
fixes up Media.java to support commands for the new service to help
with debugging. Also fixes a couple bugs that were found while fixing
up Media.
Change-Id: I68e4aa80a4de430b98236aafc883664b9432c62b
Registration of a RemoteController may succeed only if:
- the caller has the MEDIA_CONTENT_CONTROL permission,
- or if the RemoteController.OnClientUpdateListener it
registers if one of the enabled notification listeners.
For using the "enabled notification listener" functionality,
the CL involved:
- making OnClientUpdateListener an interface so a 3rd-party
application may have its implementation extend
NotificationListenerService, which is required for a
listener to be enabled by the user.
- add the concept of "enabled" status in an
IRemoteControlDisplay, so a RemoteController (which
encapsulates the IRemoteControlDisplay implementation)
may be registered, but later temporarily disabled by
the user, as a result of a user action in the security
settings, or a user switch.
- making MediaFocusControl, the component tied to
AudioService, monitor changes in enabled notification
listeners, and act upon enable/disable changes.
Bug 8209392
Change-Id: Ia8dfa2156c65668b2b0d4ae92048005912652d84
The new media button receiver with only a pending intent (no
component name) could be left hanging if the process that
registered it went away. These semantically need to be tied
to the calling process's lifetime; we now clean them up when
the calling process goes away.
Also added some additional cleanup of media button receivers
when packages change (updated, cleared).
And on top of that, a new "media" command for doing media
things. Currently lets you send media keys and monitor
remote display data.
Oh and finally added a new BaseCommand base class for
implementing these command line utilities.
Change-Id: Iba1d56f10bab1eec4a94a7bb1d1c2ae614c8bcf5