Internally, DownloadManager synchronizes its contents with MediaStore,
which relies heavily on using file extensions to determine MIME types.
To prevent these two databases from getting confused, this change
adjusts DownloadManager to force the MIME type of already-completed
downloads based on the file extension, matching what MediaStore does.
Bug: 159594536
Test: atest PublicApiAccessTest#testAddCompletedWithoutExtension
Change-Id: I60c613eafcfe55007dffcac2d7d1fe375b753c19
This change does the following
0. Robustly enforce setDeviceVolumeBehavior.
Prior to this change, setDeviceVolumeBehavior could have been overridden
in cases like HDMI_CEC enable/disable, HDMI re-plug, etc.
1. Persist setDeviceVolumeBehavior across AudioService restarts and
system reboots.
Prior to this change, setDeviceVolumeBehavior was lost on AudioService
crash/restart, or system restart.
2. Persist software volume across reboots.
Prior to this change, HDMI_OUT device was initialized as a "Fixed"
Volume device and then updated to either full volume device or
"variable" volume device based on the outcome of HDMI-Sink's CEC
capabilities. However, when connected to a non-CEC capable sink this
would result in audio resetting to 100% on each reboot.
3. Some refactoring around how mFixedVolumeDevices and
mFullVolumeDevices are updated in some instances.
Bug: 153193369
Bug: 155482023
Test: Locally on ADT3
Change-Id: I4adb38c64fe1ae7713992ab83acbd66bce4524a4
Previously we didn't clip when at height 0, but we still
need to as very often the view ill have height 0.
The clipRect should always be up to date.
Also, removing inactive players when resumption is off
to avoid this completely
Fixes: 159414197
Test: turn off resumption, swipe away media, observe no weird clipping
Change-Id: I30a2fa4fe19d142c8a6472f8368d64e6ac4074d8
When collapsing QS, the player should remain in the qs panel,
since notifications are invisible, which would look odd.
Similarly, when unlocking using fingerprint, we should
keep the media experience where it is.
Fixes: 157553726
Fixes: 156105562
Test: expand qs on lock, directly collapse
Change-Id: I1abd1561e878ad57b8cdc435bfacd40897616ff1
Add Statsd logging for notification controls and app ops controls.
Logging with UiEventLogger events with instance IDs.
A UiEventLogger is injected into NotificationGutsManager which sends
it to NotificationInfo and AppOpsInfo when binding to SBN.
Add tests for both.
Bug: 156398451
Test: atest NotificationInfoTest
Change-Id: I0e77519d7612634faab7666f3b14614b1bbfcb41
Merged-In: I0e77519d7612634faab7666f3b14614b1bbfcb41
Bug: 159648065
Test: N/A
Change the setting key to be 'backup_skip_user_facing_packages'. See the
bug for context.
Change-Id: I315141a509976821c7db311544a5c0f4e6fd1917
When removing a lock task, LockTaskController callbacks status bar on
the lock task mode state change. On the receiver side, SysUI queries
ActivityTaskManager#getLockTaskModeState to updates its SysUiState.
This raises a race condition that SysUI gets a staled lock task state
and uses that info to disable Recents.
PinnedStackTests#testPinnedStackWithDockedStack is flaky since it's
running after PinnedStackTests#testDisallowEnterPipActivityLocked and
relies on Recents being functional.
Bug: 156003518
Test: atest --iteration 5 PinnedStackTests
Change-Id: I1ff3c75c4ad37ee8f3951b8f2d7f2a3b0f8334ce
Currently we rely on libc to call std::free on the malloced pointer to
the overlay table entry. Rather than relying on the libc implementation
to call std::free instead of trying to delete the pointer as if it was
created using "new", explicitly pass std::free as the deleter to the
data held by the std::shared_ptr.
Bug: 159562360
Test: Observed no heap growth while looping infinitely and retrieving
a string resource overlaid using an inline xml value
Change-Id: I9a2ebaf9a993ad9c44fab8f052430c8142d4347d