Commit Graph

18 Commits

Author SHA1 Message Date
Doris Ling
03a3b518de Update preference screen title.
- Add missing title to preference screen xml so that they will be used to
set the activity title when the fragment is launched.
- Also updated some incorrect preference screen titles.
- Overrides getTitle() in preference fragments that do not use the
preference screen xml.

Bug: 64564191
Test: blaze-bin/screenshots/android/i18nscreenshots/i18nscreenshots
Change-Id: Id72d5ddf18f0962bc484de8bbd847a2e55d6371e
2017-10-25 11:02:07 -07:00
Tony Mantler
76cbd4b3b2 Make ApplicationsState.Session lifecycle-aware
Bug: 66682989
Test: RunSettingsRoboTests
Change-Id: Idf56788fcae22639b7bf604a8c73cd5f0ff2da16
2017-09-22 11:23:17 -07:00
Fyodor Kupolov
2328946b58 Tron metrics for special permissions
Added tron metrics for the following special permissions:
Battery optimisation
 - APP_SPECIAL_PERMISSION_BATTERY_ALLOW
 - APP_SPECIAL_PERMISSION_BATTERY_DENY
Device administrators
 - APP_SPECIAL_PERMISSION_ADMIN_ALLOW (when checked)
 - APP_SPECIAL_PERMISSION_ADMIN_DENY (when unchecked)
Do not disturb access
 - APP_SPECIAL_PERMISSION_DND_ALLOW
 - APP_SPECIAL_PERMISSION_DND_DENY
Daw over other apps
 - APP_SPECIAL_PERMISSION_APPDRAW_ALLOW
 - APP_SPECIAL_PERMISSION_APPDRAW_DENY
VR helper services
 - APP_SPECIAL_PERMISSION_VRHELPER_ALLOW
 - APP_SPECIAL_PERMISSION_VRHELPER_DENY
Modify system settings
 - APP_SPECIAL_PERMISSION_SETTINGS_CHANGE_ALLOW
 - APP_SPECIAL_PERMISSION_SETTINGS_CHANGE_DENY
Notification access
 - APP_SPECIAL_PERMISSION_NOTIVIEW_ALLOW
 - APP_SPECIAL_PERMISSION_NOTIVIEW_DENY
Premium SMS access
 - APP_SPECIAL_PERMISSION_PREMIUM_SMS_ALWAYS_ALLOW
 - APP_SPECIAL_PERMISSION_PREMIUM_SMS_ASK
 - APP_SPECIAL_PERMISSION_PREMIUM_SMS_DENY
Unrestricted data access
 - APP_SPECIAL_PERMISSION_UNL_DATA_ALLOW
 - APP_SPECIAL_PERMISSION_UNL_DATA_DENY
Usage access
 - APP_SPECIAL_PERMISSION_USAGE_VIEW_ALLOW
 - APP_SPECIAL_PERMISSION_USAGE_VIEW_DENY

Test: Manual + make RunSettingsRoboTests
Bug: 31008660
Change-Id: Id977e2c9f5aa811a2b0af036372b72c684621435
2017-01-18 10:54:19 -08:00
Tamas Berghammer
265d3c2a0c Update package names to work with the proto3 compiler
Bug: b/28974522
Change-Id: I5f3adf4946ee4ba1e09e4f40afe83c151405972a
2016-11-08 14:06:17 +00:00
Fan Zhang
13566f29a5 Fix crash when changing data restriction for non-app UID.
Change-Id: Ie622e8e22bade33050865fe4135534b27995d523
Fixes: 31708057
Test: make RunSettingsRoboTests
2016-09-23 15:14:18 -07:00
Fan Zhang
6507613ebc Log visibility change for all fragments.
Bug: 30681771
Test: SettingsUnitTests

Refactor visibility logging from InstrumentedFragment into a mixin. And
apply mixin in remaining fragments.

Change-Id: Ibbb59904336254a3e4bb9e8c7d0b36e5a6bc2622
2016-08-18 14:04:13 -07:00
Felipe Leme
f8265a8f1e Merge "Defined help page for Data Saver." into nyc-dev 2016-05-20 21:27:57 +00:00
Jason Monk
fd41b42487 Protect against monkey crash
When rebuild comes in after context is no longer valid

Change-Id: Ib64e93372bff4c6b0e1232ac257f3df0e9d0be0a
Fixes: 28875397
2016-05-20 14:15:10 -04:00
Felipe Leme
cf2c0b1b97 Defined help page for Data Saver.
BUG: 28865521
Change-Id: I07930232312df2775ecee5beacee6921f7245847
2016-05-20 09:08:28 -07:00
Felipe Leme
85c63f348f Listen to INetworkPolicyManager events and update UI accordingly.
BUG: 27481520

Change-Id: I09c4c586188d754ddd3ac3dcb3903217842ea0a5
2016-04-20 09:17:14 -07:00
Felipe Leme
11b06ca8bf Fixed AccessPreference listener.
When an app is blacklisted, its switch toggle is disabled, but previous
the onClick() method was still being called, which would launch the data
usage screen but also call setIsWhitelist().

BUG: 27481520
Change-Id: Id8df3d65eee286d1aecb4ae2a0417d6932d91441
2016-04-19 10:05:08 -07:00
Felipe Leme
c2ef27faf4 Handle blacklisted apps on Data Saver whitelist.
When user blacklists an app for background data access, the
"Unrestricted data access" list should not display the whitelist toggle
option, but rather explain background access is turned off and offer the
option to open the app's data usage screen to turn it back on.

It still does not handle changed received by DataSaverBackend, so the UI
will be stale when the user removes a blacklist and navigates back to
the list.

BUG: 27481520

Change-Id: I9d0fa9f0180a69ce9bd1417921bf89ec3ba31f01
2016-04-18 13:14:01 -07:00
Felipe Leme
0628e33bf2 Add metrics for Data Saver actions.
BUG: 28166693
Change-Id: Ie435db66183ef645467ffa6cc7537d54d35cab31
2016-04-14 16:14:55 -07:00
Jason Monk
9a6349a4d5 Guard against empty extraInfo
Change-Id: Iff297637edd3ebf5b6d26bc1dc51e9c17393e24f
Fixes: 27999693
2016-04-12 16:03:39 -04:00
Jason Monk
f38fb38f26 Switch to whitelist for animations
Disable animations for all SettingsPreferenceFragments, unless they
explicitly ask for them before creating their preference screens.

Turn it on for all fragments using the cached removal currently.

Bug: 27713314
Change-Id: I1bc14e7aeb3ee5b8ddb4f3547f472305cd312edf
2016-03-18 15:16:12 -04:00
Jason Monk
3e19fc5600 Move temporary metrics constants to proto
Change-Id: I8fb3ac22df7bdc52039dd640f7696ebd32281f0b
2016-03-08 14:18:30 -05:00
Jason Monk
a8b0366a02 Data saver fixes
- Correct summary for number of apps with unrestricted
 - Show system option on unrestricted access page
 - general betterness

Bug: 26796370
Bug: 27378294
Bug: 27122309
Change-Id: Ia57b56a25175182cb1a5a1231c20dc3c71cc3427
2016-03-01 10:44:16 -05:00
Jason Monk
764f45db91 Add data saver to settings
Bug: 22817899

Change-Id: Ic3055aa6a5baae1653db350313366f180c049cc7
2016-01-25 15:24:29 -05:00