Deprecate HAPTIC_FEEDBACK_ENABLED in favor or HAPTIC_FEEDBACK_INTENSITY,
and VIBRATE_WHEN_RINGING in favor or RING_VIBRATION_INTENSITY.
Introduce hidden flag
VibrationAttributes.FLAG_BYPASS_USER_VIBRATION_INTENSITY_OFF
to represent HapticFeedbackConstants.FLAG_IGNORE_GLOBAL_SETTING in the
vibrator service. This is applied by:
- PhoneWindowManager, that converts HapticFeedbackConstants into
(VibrationEffect, VibrationAttributes).
- CellBroadcastAlertAudio, that triggers alerts using AudioAttributes
with flags FLAG_BYPASS_INTERRUPTION_POLICY (that translates to same flag
in VibratorManager, to bypass DnD) and FLAG_BYPASS_MUTE (that translates
to this new flag, to bypass the new alarm intensity settings).
The new flag is erased from request that are not from privileged apps,
similar to the other bypass flag. The public
HapticFeedbackConstants.FLAG_IGNORE_GLOBAL_SETTING has also been
deprecated in T with a documentation explaining the removal of platform
support.
Remove SysUI dependencies on the deprecated settings, it should use the
USAGE_TOUCH attribute and rely on the vibrator service to apply the user
settings.
Keep other SysUI dependencies that needs to run in older Android
versions (like Launcher3).
Bug: 185351540
Test: VibrationSettingsTest + manual
Change-Id: I0372e4db19e09523795d7e79b9f7a15ae48a8cd9
Introduce new setting keys for media and alarm vibration intensity.
Merge all default vibration intensity getters into a helper class that
receives the VibrationAttributes usage int and applies the default logic
to all usages.
Also update the usage of boolean settings for haptic feedback and ringtone
to disable vibrations in VibrationSettings.
Bug: 198346559
Bug: 207477604
Test: VibratorTest & VibrationSettingsTest
Change-Id: I69ba05a8bc35657637b1f351f4c19d2d96efc9e3
Remove the concept of relative frequency and the mapping logic from
VibratorInfo and receive absolute frequency values, in hertz, from
WaveformBuilder.
The clipping logic to make all PWLE amplitudes fit the HAL bandwidth map
still remains.
Bug: 203785430
Test: com.android.server.vibrator.*
Change-Id: Ic01a08d84e66d88acad6db5c704251394afbf1f6
Also converted following APIs to SystemAPI:
android.os.UserManager.REMOVE_RESULT_ALREADY_BEING_REMOVED
android.os.UserManager.REMOVE_RESULT_ERROR
android.os.UserManager.REMOVE_RESULT_DEFERRED
android.os.UserManager.REMOVE_RESULT_REMOVED
Remaining task: remove all occurance of UserManager.removeUserOrSetEphemeral
Bug: 197181121
Bug: 199446770
Bug: 199446810
CTS-Coverage-Bug: 199446770
Test: m system-api-stubs-docs-non-updatable-update-current-api
m module-lib-api-stubs-docs-non-updatable-update-current-api
Change-Id: Iea7867268950050f90d8509d7f3d09725d850a5e
* changes:
[MS09] Expose NetworkTemplate APIs which are needed by NetworkPolicy
[MS34.1] Replace TelephonyManager#getSubscriberId(subId) with public API
[MS40.1] Remove Clock dependencies from NetworkStatsService
[MS27] Expose noteUntaggedSocket SystemApi
This includes:
1. Re-implement the BestClock in the static library.
2. Expose SystemClock#currentNetworkTimeClock as public Api
Test: TH
Bug: 204830222
CTS-Coverage-Bug: 213393821
Exempt-From-Owner-Approval: 1. Owner approved the change with
explicitly granted submission after adderessing the
straight-forward comment. 2. Owner is OOO for 3 months.
Change-Id: I08c0162a7101cc6184f3eca3d4a59211183fb843
While Data usage related codes are moving to mainline module,
StrictMode#vmUntaggedSocketEnabled() and onUntaggedSocket()
can no longer be accessed from NetworkManagementSocketTagger.
Thus, expose alternative SystemApi to allow invocations from
the module.
Test: TH
Bug: 204830222
Exempt-From-Owner-Approval: 1. Owner approved the change with
explicitly granted submission after adderessing the
straight-forward comment. 2. Owner is OOO for 3 months.
Change-Id: Ib54ff54ce3617ae0d04080a1740e78b086bbb039
To make it more developer friendly.
Bug: 210622224
Test: m
Test: atest StorageManagerTest#testGetPrimaryVolume
Change-Id: I023d91b5940a8dabff15d53401529f1be43697f3
PowerManager will now treat changes in the device state from
DeviceStateManager as user-activity for the purposes of calculating
idle timeouts.
Bug: 199993642
Test: Check logs to verify that user-activity is updated when
changing device states.
Test: atest PowerManagerServiceMockingTest
Change-Id: Ib5e543dd502d6b9b8ef1fef7e1b0f8a188f3cf1e
Bug: 152453213
Tag: #refactor
This commit prepares PropertyInvalidatedCache to function as a system
api. Specifically, the methods recompute() and bypass() which may be
overridden by clients are now public (instead of protected). This
forces an update to all existing clients, to accommodate the change in
method visibility.
Two small changes have been made as cleanup:
1. The awkwardly named debugCompareQueryResults() is now
resultEquals(), which is more or less consistent with how other
equality tests are named in Android. This name change affects two
clients.
2. PackageManager has changed to use resultEquals() instead of
maybeCheckConsistency(). This provides a simpler and more
consistent use of the APIs. maybeCheckConsistency() has been made
private.
Test: atest PropertyInvalidatedCacheTests
Change-Id: I4110f8e887a4fd8c784141e8892557a9d1b80a94