Rather than recalculating it again. Also align logic on
listing and details pages.
Test: NotificationBackendTest, NotificationPreferenceControllerTest
Bug: 231662091
Fixes: 231815850
Change-Id: If9572766666620008afb839ecb0828ace8d6073d
- Activity#getCallingPackage will return null in some special cases, use the launched package instead.
Bug: 194709435
Test: manual test
make RunSettingsRoboTests ROBOTEST_FILTER=WifiScanModeActivityTest
Change-Id: I4f22bab7592dedf75dd36daf5e18dbc934bc8655
When it's in a multi-window mode, force stopping an app will lead to an
activity recreate, and the dialog fragment will also be recreated.
That's why the dialog still shows after the button is clicked.
Hence, dismiss the dialog before stopping the app to fix it.
Fixes: 231529730
Test: robotest
Change-Id: I75d27624f0c60bb617e7d1a92ffe01d3c0fbf7be
Both "Mobile data usage" & "Non-carrier data usage".
By,
1. Use summary placeholder for usage amount to avoid shift
2. Before fix CycleListener's onItemSelected() is called multiple times,
cause the app list to flash, let DataUsageList to handle the dedup
logic to better handling.
3. Before fix if return from App Usage page, no loading view is
displayed (only first enter has it), move this to onResume() to fix.
4. Before fix the cycles passed to App Usage page is cached (even when
the cycles are changed), clear the cache when onResume() to fix.
5. Listener in SpinnerPreference could be null, add safety guard to it.
Fix: 187019210
Test: manual visual test
Change-Id: I95e544c46333496f4f30ed77dafa4779b4d66019
Storage settings will crash because there is no emulated primary volume found after private internal volume is Ejected.
Below change in Settings impacted Storage dashboard screen behavior as
it Query storage size instead of calculate size of installed APP. Due to
this design change now MediaProvider is queried for file sizes, but due
to unmounting of primary emulated volume it crashes.
We should not show Eject option for private Internal volume.
Author: ramneek.kalra@mediatek.com
Bug: 230689829
Test: atest com.android.settings.deviceinfo.VolumeOptionMenuControllerTest
manual
1. Insert sdcard or generate virtual disk using command : adb shell "sm set-virtual-disk true"
2. Go to Settings -> Storage -> Sdcard/virtual disk -> Format as Internal -> do migrate data
3. After above process completed, go to Settings-> Storage -> sd card/virtual disk and chose Eject menu option.
4. Eject page gets open, Click on Eject button.
Change-Id: I98d09f75ee7c2cd5aae10808bd0e0cdf10da7582
Hide the running time information for "Android System" entry, since this
entry will combine multiple system components together. It will provide
incorrect running time information. The getRealUid() method maps many
UIDs to Process.SYSTEM_UID(1000), which results in combining all of
those UIDs into one "Android System" entry. This is the expected behavior.
Bug: 220717612
Test: make RunSettingsRoboTests -j56 ROBOTEST_FILTER="com.android.settings.fuelgauge"
Change-Id: I9d44fe8490ad5c684419b8ebf8d7d5576a42788a
- Don't let device be discovered when the user launch "Connected Devices
settings" through SliceDeepLinkTrampoline.
Bug: 228450811
Test: make -j42 RunSettingsRoboTests and use test apk to manually test
to verify the device is not discoversable when open "Connected settings"
through test apk.
Change-Id: I5490b58675b1fd9fc36305766867f65caa6ccb6c
Hide some Preference which requires mobile data on device didn't support
it.
Bug: 221999174
Test: local
Change-Id: I7dd6e13aea0ed4467c7c7edeada564e42ea78349
Prior to this cl, we allow user to tap on those
setting items which belong to another user profile app.
However, we already observed some functional broken cases now.
Such as, device can't get the storage data/screen time/mobile data
battery, notification for those apps from another user profile.
Therefore, we decide to grey out those setting items,
and we don't allow user to tap on unsupported setting items.
Test: Download apk in different user profile, and see setting items
is disabled/enabled correctly. and run robo test.
Fix: 230303570
Change-Id: I1bb6b1d8b52f6a00088b2f0e4279b896d568f8a6
- Currently per app language use opt-out by default. This change is to
add a new idea to have a way to change opt-out to opt-in, and let
user be able to use LocaleConfig.xml to control the feature more
precise.
- If app does not support locale picker or there is no locale provided, remove entries' UI.
Bug: b/231396734
Bug: b/230688538
Test: local
Change-Id: I2661fffab804a2816744711130b26aa2ec47f820
The injection dynamic data was loaded in the background and then post to
main thread to update UI. However, it usually updates after
Fragement.onResume(), which causes the flicker.
To make it more smooth, DashboardFragment to wait for the dynamic data
observers to update UI for a short period, which eliminates the flicker
in most cases.
Also skip the repeated tiles refresh called by onCategoriesChanged in
onResume after all preferences refreshed.
Test: robotest, visual
Bug: 229177114
Change-Id: I04650af9692703f1fc1e6e5ad2090f051b1eeb81