Commit Graph

18981 Commits

Author SHA1 Message Date
Lei Yu
5963ffd4e3 Merge "Add anomaly detection method to AnomalyUtils" into oc-dr1-dev 2017-07-25 20:48:02 +00:00
Christine Franks
a0dd987d20 Restrict changing wi-fi networks
Bug: 31852835
Test: manual - verify unrestricted as regular user, but that a password
is required in demo mode.
Change-Id: I60f95ccbb10ba728b384b9c8c2ae723934fb2928
2017-07-25 13:31:12 -07:00
Antony Sargent
5d137f0f2c Allow open password dialog for wrong-password wifi access points
When we're failing to connect to a wifi access point due to an incorrect
password, we want to allow an intent from a notification to open up the
wifi settings page and bring up the dialog for entering a different
password. We already have code in settings to do this for not-yet-saved
access points, so this CL just changes it slightly to also allow it for
saved access points.

Unfortunately WifiSettings can't be tested with Robolectric due to it
not supporting PreferenceScreen, so this adds a test to
WifiSettingsUiTest. There were some existing test failures in that file
which I've fixed while I was in there:

-The TestAccessPointBuilder class wasn't being found at runtime because
 it was getting stripped out at build time due to not being used in
 settings.

-The changingSecurityStateOnApShouldNotCauseMultipleListItems test was
 asserting that we don't end up with multiple entries for the same SSID
 in the access point list when changing the security state for the AP,
 but it was accidentally passing multiple AP's with the same name the
 first time.

Bug: 33245941
Test: runtest --path WifiSettingsUiTest.java
Change-Id: I929ca6892242059df157c01d6e9ea30e8d1c5e78
2017-07-25 20:25:59 +00:00
Fan Zhang
84dd783c36 Fix a monkey crash in Developer settings.
- DevSetting shouldn't add switchbar listener if it's a Monkey test run
- DevSetting shouldn't remove switchbar listener if it's not registered
- Refactor some switchbar logic in order to create test

Change-Id: Ie65ff9b04778075789010169039393bd0551acfb
Fix: 64021498
Test: robotests
2017-07-25 13:06:32 -07:00
Doris Ling
5df37ec7b9 Disable Wallpaper setting when Wallpaper is disabled.
Check whether the wallpaper picker is enabled in
WallpaperPreferenceController.isAvailable() instead of always returning
true.

Change-Id: I1afba6639a2b94f9d57f546c220f417092f92387
Merged-In: Ie3a4a68b728ccab1a7aa50c0018a5153907c49b4
Bug: 63939450
Test: make RunSettingsRoboTests
2017-07-25 11:33:40 -07:00
Matthew Fritze
458bb887e1 Add default value to inline payloads
If we try to set an inline result when it has not yet been
accessed in settings, nothing is read from Settings.
Thus, include a default value for a fallback.

Manual merge for: ag/2588219/

Change-Id: I3b8eea4f82764852cea642db4455ba57f10a7d37
Fixes: 63955012
Test: robotests
2017-07-25 10:44:15 -07:00
Doris Ling
4427cd7e22 Disable Wallpaper setting when Wallpaper is disabled.
Check whether the wallpaper picker is enabled in
WallpaperPreferenceController.isAvailable() instead of always returning
true.

Bug: 63939450
Test: make RunSettingsRoboTests
Change-Id: Ie3a4a68b728ccab1a7aa50c0018a5153907c49b4
2017-07-25 10:38:22 -07:00
jackqdyulei
8dba5a03a1 Add anomaly detection method to AnomalyUtils
So we could reuse it in different loaders.

Bug: 63900914
Test: robotests still pass
Change-Id: I038085f53b9d0a05b8c4849c7544567434885821
2017-07-25 10:20:10 -07:00
Bartosz Fabianowski
9294472953 Merge "Fix "max failed login attempts" disclosure" into oc-dr1-dev am: 262aacd353 am: cfc3ccdb82
am: e0a9eb0cad

Change-Id: Ib0f669e85f6cd44653dcb1227d4d0aec14296f74
2017-07-25 10:25:40 +00:00
Bartosz Fabianowski
e0a9eb0cad Merge "Fix "max failed login attempts" disclosure" into oc-dr1-dev am: 262aacd353
am: cfc3ccdb82

Change-Id: I2c73cf6895da1188027d0f8704f795490f1e7be1
2017-07-25 10:22:09 +00:00
Bartosz Fabianowski
cfc3ccdb82 Merge "Fix "max failed login attempts" disclosure" into oc-dr1-dev
am: 262aacd353

Change-Id: I24ffc75897c92124cf9416ea79ff4c704a733c0e
2017-07-25 10:18:41 +00:00
Bartosz Fabianowski
96a14ff07e Merge "Fix "max failed login attempts" disclosure" into oc-dr1-dev
am: 262aacd353

Change-Id: I66fbaf0f98dd22679068f1fdefce0e7dbfc81939
2017-07-25 10:18:41 +00:00
Tadashi G. Takaoka
38a58371a0 Remove SHOW_INPUT_METHOD_PICKER receiver
Although there is a security check for IMM#showInputMethodPicker() [1],
any background application can virtually call the method via explicit
broadcast intent to Settings app.

Since showing IME picker from the notification has implemented in
InputMethodManagerService using protected-broadcast [2], the receiver in
Settings app isn't necessary and should be removed to close the security
bypass.

Note that this broadcast receiver stops working from Android-O due to
background check [3].

 [1]: I4f0fc21268200c64d12b31ca54416acfbf62f37b
 [2]: Id36c8c34159bea8b72557b40bcf024d401f580b6
 [3]: https://developer.android.com/preview/features/background.html#broadcasts

Test: The following broadcast intent will not show IME picker.
  $ adb shell am broadcast \
        -a android.settings.SHOW_INPUT_METHOD_PICKER \
        com.android.settings
Fixes: 64008672
Bug: 63644555
Change-Id: Id990c66516c9b3ed7ada6891746ec0e0eecbe545
2017-07-25 19:17:57 +09:00
Bartosz Fabianowski
262aacd353 Merge "Fix "max failed login attempts" disclosure" into oc-dr1-dev 2017-07-25 10:14:50 +00:00
Kevin Chyn
936680ab3e Merge "Fingerprint swipe settings and suggestions should not show if hardware unavailable" into oc-dr1-dev
am: 5e707ccb3d

Change-Id: Ib988ae3439dbbaed2c84d906b6e88412ce27461f
2017-07-25 05:36:32 +00:00
Kevin Chyn
5e707ccb3d Merge "Fingerprint swipe settings and suggestions should not show if hardware unavailable" into oc-dr1-dev 2017-07-25 05:31:53 +00:00
Kevin Chyn
6e873a8fb6 Merge "Fingerprint swipe settings and suggestions should not show if hardware unavailable" into oc-mr1-dev am: af63fc249e
am: 06fa3638ec

Change-Id: I7805293b17139ff9e4c2071c3ff7df9999a9454d
2017-07-25 02:50:32 +00:00
Kevin Chyn
2a2dcb52cb Fingerprint swipe settings and suggestions should not show if hardware unavailable
Fixes: 63589121

Test: remove FP driver, make sure swipe setting and suggestions
don't show anymore && make -j RunSettingsRoboTests

Merged-In: I2539128daff8df52d040606141f772fc9edffa57
Change-Id: I2539128daff8df52d040606141f772fc9edffa57
2017-07-25 02:33:30 +00:00
TreeHugger Robot
af63fc249e Merge "Fingerprint swipe settings and suggestions should not show if hardware unavailable" into oc-mr1-dev 2017-07-25 02:32:31 +00:00
Kevin Chyn
df872a5f0a Default-off FP Swipe am: 8f5de15ba1 am: 0d378e04ca
am: a3874cf593

Change-Id: Ib2d312d36a5200ed4b677eb2a4d79f9e84b12d75
2017-07-25 01:13:04 +00:00
Kevin Chyn
e4fed2ee05 Default-off FP Swipe
am: 8f5de15ba1

Change-Id: Ie575c4a6335b83b00d8f2614bba532843a88534d
2017-07-25 01:07:31 +00:00
Kevin Chyn
0d378e04ca Default-off FP Swipe
am: 8f5de15ba1

Change-Id: Iac3a85ac3e0d6f30d32b2823f168f3123d375f08
2017-07-25 01:07:31 +00:00
Kevin Chyn
8f5de15ba1 Default-off FP Swipe
Fixes: 63992836

Test: adb shell settings delete secure system_navigation_keys_enabled
&& make -j RunSettingsRoboTests

Change-Id: I3245c7b8844df5edaea311c1871b1dd05b8b7784
2017-07-24 14:00:18 -07:00
Andrew Sapperstein
c8c42838ca Make AirplaneModePrefController.isAvailable static.
Allows calling without instantiating the pref controller.
Also some minor cleanup of MobileNetworkPrefController.

Bug: 62022517
Test: robotests
Change-Id: I34ff5d3729d06158bff3cc125de4c114bf4861d5
2017-07-24 13:42:19 -07:00
Kevin Chyn
82792cc5b3 Fingerprint swipe settings and suggestions should not show if hardware unavailable
Fixes: 63589121

Test: remove FP driver, make sure swipe setting and suggestions
don't show anymore && make -j RunSettingsRoboTests

Change-Id: I2539128daff8df52d040606141f772fc9edffa57
2017-07-24 13:40:34 -07:00
Fan Zhang
a4a3833a08 Fix search indexing for encryption_and_credential page
- Rewrite search index provider to include all possible keys through
  getXmlResourcesToIndex()
- Add isPageSearchEnabled() to disable all keys if user is not admin
- Add getNonIndexableKeys to suppress unrelated keys based on current
  device state

Change-Id: I2c6943483789bf4c9f3931d344cf279fec0edaee
Fix: 37650170
Test: robotests
2017-07-24 12:34:34 -07:00
Michael Wachenschwanz
bd891f5813 Merge "Add Foreground Service time to battery usage" into oc-mr1-dev am: a47a3f58bf
am: 4a36ff9338

Change-Id: I2dd6202d0e6650735d4d0f08fac36472ccc4dc08
2017-07-24 19:09:08 +00:00
Michael Wachenschwanz
a47a3f58bf Merge "Add Foreground Service time to battery usage" into oc-mr1-dev 2017-07-24 19:02:12 +00:00
Ajay Nadathur
7af28ecb66 Use fingerprint icons during setupwizard flow
Use fingerprint icon when lock screens are loaded on
fingerprint setup's behalf.

bug: 63809908
Test: Manually tested and verified. Also added robolectric tests
Change-Id: I773a1eec2466e7ab626cc3330f5ce987a21b048f
2017-07-24 11:45:13 -07:00
Lei Yu
a0b1fa6120 Merge "Add log for anomaly." into oc-dr1-dev am: 6666bf5605 am: 0f9fa63c3a
am: d98275c7dc

Change-Id: I2f619171a42aca61f1d8e913005f9f0d44095118
2017-07-24 18:23:05 +00:00
Lei Yu
d98275c7dc Merge "Add log for anomaly." into oc-dr1-dev am: 6666bf5605
am: 0f9fa63c3a

Change-Id: Ibb11b891799815a3ec2f8c8961b197ffadeaf9db
2017-07-24 18:14:13 +00:00
Lei Yu
0f9fa63c3a Merge "Add log for anomaly." into oc-dr1-dev
am: 6666bf5605

Change-Id: I7ca4b466c6f175192bebb2b9a7807ebf783a249e
2017-07-24 18:07:13 +00:00
Lei Yu
5e48ea193b Merge "Add log for anomaly." into oc-dr1-dev
am: 6666bf5605

Change-Id: I4903e3617b2fab64831b6e0ad8b5214ea5dd5317
2017-07-24 18:07:12 +00:00
Lei Yu
6666bf5605 Merge "Add log for anomaly." into oc-dr1-dev 2017-07-24 17:56:35 +00:00
Andrew Sapperstein
cfb2b87d03 Add ResultPayload for always-on ambient display.
am: eb1a45b95b

Change-Id: Ie00201adc19b7da516e3bb64fe857a17f8282d28
2017-07-24 17:34:10 +00:00
Andrew Sapperstein
92c100e02d Add ResultPayload for always-on ambient display. am: 36af00bb21
am: e77497ce6a

Change-Id: I7690018fb294fddf0322f6eed061e1e3e71683c6
2017-07-24 17:22:08 +00:00
Andrew Sapperstein
36af00bb21 Add ResultPayload for always-on ambient display.
Bug: 62022517
Test: robotest
Change-Id: Ib4ee4d8d999e5a1f9edf34ea6068644b41fc4838
2017-07-23 06:11:22 +00:00
Andrew Sapperstein
eb1a45b95b Add ResultPayload for always-on ambient display.
Bug: 62022517
Test: robotest
Change-Id: Ib6382030ffa0c159ab6ca4b45dd966ee9287181f
Merged-In: Ib4ee4d8d999e5a1f9edf34ea6068644b41fc4838
2017-07-22 20:57:07 -07:00
Fan Zhang
2c7b00d101 Merge "Reindex db when package w/ searchIndexProvider changes" into oc-dr1-dev
am: 6fcc38975c

Change-Id: Iacb3b689d1099bb12e43ff42e2f17166428ddfc5
2017-07-22 17:59:38 +00:00
TreeHugger Robot
6fcc38975c Merge "Reindex db when package w/ searchIndexProvider changes" into oc-dr1-dev 2017-07-22 17:54:31 +00:00
TreeHugger Robot
60bb1d39eb Merge "Post preference update logic to main thread" 2017-07-22 02:23:48 +00:00
Michael Wachenschwanz
987711712c Add Foreground Service time to battery usage
Add foreground service time to foreground usage time of apps. This will
account for app usage that user is aware of but is not being displayed
on screen, such as playing music while screen is locked.

Change-Id: Ica9fe0819e46b50299eb2eab7f0483ea01441fb0
Fixes: 38313557
Test: RunSettingsRoboTests
2017-07-21 17:37:00 -07:00
Andrew Sapperstein
ca87892984 Merge "Add help uri for process stats summary and apps." into oc-dr1-dev am: 59a66d9b77
am: 80a5336b25

Change-Id: Ib32bcfa22706abf89633b86333498f77328daebb
2017-07-22 00:36:03 +00:00
Andrew Sapperstein
ebd8308698 Merge "Add help uri for process stats summary and apps." into oc-dr1-dev
am: 59a66d9b77

Change-Id: I2b279d3a1562e693caeaf64f2f91ab629b4e294f
2017-07-22 00:33:13 +00:00
Fan Zhang
715f0956f4 Merge "Tweak bluetooth name preference" into oc-dr1-dev am: 03c595ce24
am: ef0e290e65

Change-Id: I77ca5052477a9e1efee01c7022378164096669b8
2017-07-22 00:32:48 +00:00
Fan Zhang
3ecdee573b Merge "Tweak bluetooth name preference" into oc-dr1-dev
am: 03c595ce24

Change-Id: I1d2f8d65fb7ba48bac656222c4501306103b385c
2017-07-22 00:32:42 +00:00
Andrew Sapperstein
80a5336b25 Merge "Add help uri for process stats summary and apps." into oc-dr1-dev
am: 59a66d9b77

Change-Id: I7513463a50ddef4f49d8d7ab06ed8fd9e19d3a52
2017-07-22 00:32:32 +00:00
Lei Yu
c857c195cf Merge "Make anomaly item refresh in battery" into oc-dr1-dev am: 0ec3e4e626
am: 454131cdb0

Change-Id: I3feacbe94bca351809341e60464a6834e6980a12
2017-07-22 00:32:27 +00:00
Lei Yu
ab7a4db9df Merge "Make anomaly item refresh in battery" into oc-dr1-dev
am: 0ec3e4e626

Change-Id: Ie3e4b7ead145b22c44383443229043722b9e86d9
2017-07-22 00:32:21 +00:00
Antony Sargent
75512a3215 Merge "Switch to using gray icon for Bluetooth imaging devices" into oc-dr1-dev am: a6ac4890ed
am: 62b7527da5

Change-Id: Ibfe8afab3bf662c2855a28c27d636da17444eb79
2017-07-22 00:32:07 +00:00