Per email feedback, we should be using "noteOp" instead of "checkOp"
when testing if caller holds OP_GET_USAGE_STATS, so that we record
that caller used the operation.
Bug: 77662908
Test: builds, boots
Exempt-From-Owner-Approval: keep tests passing
Change-Id: I3a60345d590534fdbc2c1248e0d30dc85a5d6772
The old design didn't work at all because of various
paddings. The new design adds more paddings and a
new button style
Fixes: 72814598
Test: runtest systemui
Change-Id: I4b4ac0790afe45db97f912740446c6da09620be3
ServiceManager:
- Do an event log every N getService() calls with total time spent
in getService().
where N = 100 for core UIDs and 200 for other apps.
- Do an event log if getService() takes longer than N ms.
where N = 10 for core UIDs and 50 for other apps.
... with some extra throttling.
NPMS:
- Do the basic "stats logger" log for updateNetworkEnabledNL() and
isUidNetworkingBlocked()
This CL also enhances StatsLogegr so it now can show the slowest call
and the max # of calls per-second.
Bug: 77853238
Test: Manual test:
- Insert a SIM card
- Set data limit
- toggle airplane mode
- toggle wifi
- toggle mobile data
Then
- "dumpsys netpolicy" and "dumpsys activity processes" and check the stats
- also check "adb logcat -b all | grep ' service_manager'"
Change-Id: I5789541063f95d0eac501189816c8604a4571ba0
Log the first time a notification with smart
replies is visible.
Log each click on a smart reply.
Test: atest SystemUITests
Bug: 72153458
Change-Id: I6dc498871000dbb9af978567db3d258b20978781
Updated to more descriptive title and button text.
The default message dialog will also show the suspending app name.
Test: atest \
com.android.server.pm.SuspendPackagesTest#testInterceptorActivity
Bug: 75332201
Change-Id: Ica77fb04874a8e32fe0d82ac27a9babd3b186f8d
With my previous two CLs [1][2], InputMethodUtils#isSystemIme() is
used nowhere. Hence we can safely remove this unused method.
[1]: I9c8518988787b748ebb35fc86fe6beee1d6c633d
fd70fe8fe1
[2]: I33a8489c0597bd881dd8b68b28fc0d99109c11a5
a3401f2cb0222d058f452885109071e9fd70a6be
Bug: 77730201
Test: compile
Change-Id: I959209c5fef7e9653e09333e860e763f0d4c262c
This is a follow up CL to my CL [1], which originally aimed to revert
the CL [2] that added several methods into InputMethodUtils but could
not because those methods were already used in other places.
Interestingly we already have almost the same code in
InputMethodAndSubtypeUtil in SettingsLib package on which those other
projects can depend on. Hence this CL removes InputMethodUtils' ones
to avoid code duplication.
Although in future we may move the logic back to framework internal,
at the moment it is more important to reduce code duplication.
Note that this CL also ports existing test cases for those two
functions from FrameworksCoreTests to RunSettingsLibRoboTests in
GoogleTruth style.
[1]: I122a8f69b2f75a9af85e14b66db764c5d153040e
ca7809507c
[2]: I01f5fafbbcfe3e3f5313829162ec011eaf2ad991
2028ddaa50
Fixes: 73056657
Test: atest InputMethodUtilsTest
Test: make RunSettingsLibRoboTests -j
Test: prebuilts/checkstyle/checkstyle.py -f frameworks/base/packages/SettingsLib/tests/robotests/src/com/android/settingslib/inputmethod/InputMethodAndSubtypeUtilTest.java
Change-Id: Iad926ffd9806482a5aef0d8c20d2049be40d03c9
To reduce log spam, we do not log all hidden API accesses. This CL allows
configuration of the sampling rate of the log events so it can be tweaked
later if necessary.
Test: m
Test: $ adb shell settings put global hidden_api_access_log_sampling_rate 65536
Bug: 64382372
Bug: 77517571
Change-Id: I659c22bd504564da58d972f94b774a9af4039386
A corner radius was set for the floating toolbar in
Ifcf4cff1f38fd18b7dbb4c1802390e3beb92cd3c. This produced a bug, where
the ripple effect set on the floating toolbar menu items was expanding
outside the corners when these were pressed.
This CL sets the menu items container to clip to outline, such that the
ripple effect of the menu items will be clipped.
Bug: 77547543
Test: manual testing
Change-Id: Ib43a6c719aab1403273f47e559433c9856b4f8b4
There are not a small number of files that import InputMethodUtils
just to use InputMethodUtils#isSystemIme() is necessary.
In order to make InputMethodUtils purely an internal utility library,
it would make much more sense if the logic is implemented as a private
API of InputMethodInfo, like methods like
InputMethodInfo#isAuxiliaryIme(), rather than in a static method of
InputMethodUtils.
This is a purely mechanical refactoring. There should be no behavior
change.
Bug: 77730201
Test: atest FrameworksCoreTests:com.android.internal.inputmethod.InputMethodUtilsTest
Change-Id: I9c8518988787b748ebb35fc86fe6beee1d6c633d
Treated return value from mStats.getScreenDozeTime as ms, but indeed it
is us.
Fixes: 77655868
Test: manual
Change-Id: Ic9838a2fca3f49a6f5a669bd1970dcc7560fb5e2
Because we are expecting usage of Person across
other surfaces, we migrate the class out
of he Notification class which is already incredibly
huge.
Test: Migrated existing cts test
Change-Id: Ia487ae7965b5ca2b016245d21faa63e3b4628344
Fixes: 75980526
Added an AlertActivity to intercept the start for an activity belonging
to a suspended app. More details will be shown if the suspending app
also defines an activity to handle the API action
SHOW_SUSPENDED_APP_DETAILS.
Test: Added tests to existing classes. Can be run via:
atest com.android.server.pm.SuspendPackagesTest
atest com.android.server.pm.PackageManagerSettingsTests
atest com.android.server.pm.PackageUserStateTest
Bug: 75332201
Change-Id: I85dc4e9efd15eedba306ed5b856f651e3abd3e99
Cannot find class when registering Usb connection broadcast receiver
in AndroidManifest, causing system process to crash. Switch to
register receiver at runtime when boot complete.
Fixes: 77274266
Test: Manually plug & unplug usb cable, and reboot device
Test: Verify usb_data appears in batterystats dump
Test: Verify there is no crash log
Change-Id: If4a9e85aa81173ad6d8cb6ce28cc030814c520a5