Commit Graph

1899 Commits

Author SHA1 Message Date
Fan Zhang
f6e6ae2441 Fix a bug where bt name is updated to wrong preference.
Change-Id: Ica0ef6763e8868fc33773f2db917aba29193b632
Fix: 63772093
Test: robotests
2017-07-17 23:06:07 +00:00
TreeHugger Robot
edad87c4b0 Merge "Add background color to suggestion/condition view." into oc-dr1-dev 2017-07-17 22:18:31 +00:00
Matthew Fritze
469e4ea228 Add gestures as inline actions for Phone Buddy
Add the following gestures as inline:
- Assist gesture
- Double tap power
- Double tap screen
- Pickup
- Swipe for notification

Bug:62022517
Test: make RunSettingsRoboTests
Change-Id: Ib246b97a0b924bf18f464d3548b7e4c393fc1931
2017-07-17 08:48:42 -07:00
Doris Ling
1b6685f4a4 Add background color to suggestion/condition view.
- also remove "new_ui" from the condition tile and suggestion tile
layout file name.

Change-Id: I2a1fe4ea2ed69768f6e7c464608039c9c962c9f1
Fix: 63674319
Test: visual
2017-07-14 15:34:42 -07:00
TreeHugger Robot
77a34f69c6 Merge "Fix crash on expanding settings conditions." into oc-dr1-dev 2017-07-14 22:18:26 +00:00
TreeHugger Robot
4d3b534325 Merge "Fix enhanced estimate discharge text showing while charging" into oc-dr1-dev 2017-07-14 21:47:50 +00:00
Doris Ling
01fe5b45b4 Fix crash on expanding settings conditions.
Check for non-empty suggestions instead of non-null suggestions when
trying to determine whether to show conditions or suggestions list.

Change-Id: Icdb8ad485af436f5d84ce0a746081fc59bd613db
Merged-In: Icdb8ad485af436f5d84ce0a746081fc59bd613db
Fix: 63674269
Test: make RunSettingsRoboTests
2017-07-14 13:04:30 -07:00
Salvador Martinez
8ccb5a4698 Fix enhanced estimate discharge text showing while charging
In the PowerUsageAdvanced screen the text showing whether your time
remaining information is enhanced or not should not show when the
device is plugged in. This CL fixes a bug in that logic that would
show the text when it wasn't supposed to.

Test: robotests still pass, manual verification
Bug: 63176050
Change-Id: I33fb31671cd9c29aed20483301e51ae1ded1f1b6
2017-07-14 10:30:29 -07:00
TreeHugger Robot
98f83d6129 Merge "Don't show "Wipe eSIMs" checkbox for developers." into oc-dr1-dev 2017-07-14 01:02:07 +00:00
TreeHugger Robot
a7f5953a02 Merge "Fix mokey crash on swiping settings condition." into oc-dr1-dev 2017-07-13 21:14:45 +00:00
TreeHugger Robot
c0ca084622 Merge "UI refresh on bluetooth list page" into oc-dr1-dev 2017-07-13 20:05:25 +00:00
Fan Zhang
7b9568c10d UI refresh on bluetooth list page
- xml layout clean up
- add "Device name" preference, tapping will bring up rename dialog
- Remove tap target from original device_name pref

Merged-In: I6e9764dbb6c51f94be6d6a61d5a6401141407409
Change-Id: I9cb67cc557a9b932d7cf795a8d4a6fb5215c4365
Fix: 62890841
Fix: 62891178
Test: robotests
2017-07-13 11:08:18 -07:00
Doris Ling
84c7739986 Fix mokey crash on swiping settings condition.
When the condition card is being swiped, add null check for the
retrieved Condition to ensure it is still valid before trying to
dismiss it.

Change-Id: I265091a5fe290e359fa9a6e16b1d87c03894c1b8
Fix: 63624859
Test: make RunSettingsRoboTests
2017-07-13 11:00:29 -07:00
Antony Sargent
4d7df06eb4 Make sure PIN edit control is focused
When doing Bluetooth pairing and the dialog reqesting a PIN comes up, we
want the PIN field to be focused and the keyboard to be shown. This fixes
a regression from N.

Bug: 62857671
Test: make RunSettingsRoboTests
Change-Id: I00dabfda737b6ac61b50518e11f21e5f9a5a1be1
2017-07-12 17:34:36 -07:00
TreeHugger Robot
0e467d594e Merge "Fix bug in DevicePickerFragment" into oc-dr1-dev 2017-07-12 22:20:00 +00:00
TreeHugger Robot
ab2d96de83 Merge "Fix mistake in conditional + test" into oc-dr1-dev 2017-07-12 20:41:27 +00:00
jackqdyulei
5fbdfddb13 Fix bug in DevicePickerFragment
BluetoothProgressCategory will add a no device preference if it is
not scanning and no device is added to the list. Since
DeviceListFragment doesn't report its scanning status correctly, it will
show "No nearby device" even though it is scanning.

This cl add control code for BluetoothProgressCategory in
DeviceListFragment, which avoid the unnecessary no device preference.

Bug: 62492822
Test: RunSettingsRoboTests
Change-Id: Ic49f21cb58a80dcd37c5737800181263ae876ebc
2017-07-12 12:38:12 -07:00
Salvador Martinez
433288a76e Fix mistake in conditional + test
This CL fixes a mixup that was in a conditional that determined
what was shown on the battery settings page. Additionally, it adds
a simple test to help ensure that this does not regress in the
future.

Test: Robotest
Bug: 63158794
Change-Id: I8af4843ef6d798b5114c97b2f1b99dd29fa5f412
2017-07-12 11:31:02 -07:00
Ajay Nadathur
0bde6dcb18 Merge "Do not show options if screen lock types is empty" into oc-dr1-dev 2017-07-12 17:53:07 +00:00
Geoffrey Pitsch
00ac782f3e Merge "Disable lift-to-wake when always-on is checked" into oc-dr1-dev 2017-07-12 16:50:48 +00:00
TreeHugger Robot
91ca9f60e9 Merge "Update spacing and background color for condition/suggestion." into oc-dr1-dev 2017-07-12 02:58:28 +00:00
Ajay Nadathur
17d66bea42 Do not show options if screen lock types is empty
Bug: 63311251
Test: Manually tested on device
Change-Id: Ia56a0791b89635efb4f8305f39b586b8054271cf
2017-07-11 18:09:49 -07:00
TreeHugger Robot
c2e0e41446 Merge "Remove obsolete bluetooth pages" into oc-dr1-dev 2017-07-12 00:01:47 +00:00
Doris Ling
df055c8655 Update spacing and background color for condition/suggestion.
- changed suggestion/condition and searchbox background color to
  #F2F2F2
- changed condition card background color to #F8F8F8
- removed Suggestion header
- reduced space above condition header/footer by 9dp

Fix: 63393599
Test: visual
Change-Id: I4317781c93e23c6d019928b9fe9af16177f81c07
Merged-In: I268934e3a573b542480c0b21dbab68b7217295b5
2017-07-11 15:50:48 -07:00
TreeHugger Robot
4e4c73bfc7 Merge "Bind service in onCreate" into oc-dr1-dev 2017-07-11 22:02:35 +00:00
jackqdyulei
07fffc3877 Remove obsolete bluetooth pages
1. Remove BluetoothSettingsObsolete
2. Remove DeviceListPreferenceObsoleteFragment
3. Update master swtich, now constantly point to new page
4. Update the tests

Future cl will remove the page switch API in BluetoothFeatureProvider

Bug: 63444548
Test: Test still pass
Change-Id: I24fb5cd03cf30044edb7201426e11e0a818f0a7f
Merged-In: I24fb5cd03cf30044edb7201426e11e0a818f0a7f
2017-07-11 15:01:59 -07:00
TreeHugger Robot
89fdea9807 Merge "Adjust UX for toggles when active scorer is not set." into oc-dr1-dev 2017-07-11 20:21:01 +00:00
jackqdyulei
50b0daee90 Bind service in onCreate
This cl puts the binding to onCreate instead of constructor, so
preference controller won't bind/unbind service without registering
Lifecycle.

Bug: 62105045
Test: RunSettingsRoboTests
Change-Id: I1e60d4b6ad7270aa5d04b7ec9fae1d3200fccc5f
Merged-In: I1e60d4b6ad7270aa5d04b7ec9fae1d3200fccc5f
2017-07-11 13:17:38 -07:00
Daniel Nishi
64acb2906c Merge "Expand ASM activation warning." into oc-dr1-dev 2017-07-11 19:46:19 +00:00
Geoffrey Pitsch
57adc290d2 Disable lift-to-wake when always-on is checked
The setting has little to no meaning when AOD is on.

Test: make
ROBOTEST_FILTER=AmbientDisplayAlwaysOnPreferenceControllerTest
RunSettingsRoboTests -j
Bug:62391405
Change-Id:If5492227755ca81ec0bcf921a81e2bfd33a85b9c
2017-07-11 14:05:03 -04:00
Daniel Nishi
8f345d7fd6 Expand ASM activation warning.
If the device had ASM enabled by default but still opted to disable ASM
for policy reasons, we need to start warning the user.

Change-Id: I6a296e95d00413308de3ddc565b42c5f605087e9
Fixes: 62105682
Test: Settings robotest
2017-07-11 09:51:14 -07:00
TreeHugger Robot
9e2984b035 Merge "Add location as a Inline list payload" into oc-dr1-dev 2017-07-10 23:23:13 +00:00
Matthew Fritze
0609c4c281 Add location as a Inline list payload
The inline payload is added to security settings because
security settings indexes the setting with the key
"location" which corresponds with the correct
PreferenceController, LocationPreferenceController.

However, we suppress the Location search result, so to
avoid confusion later, we don't include the ResultPayload
in the search indexing.

Bug: 62022517
Test: make RunSettingsRoboTests
Change-Id: Ica9b775fe7b43259e651f95b079b8cccb29d0ea8
Merged-In: Ic5515d38064498ae908f4cefedfeb3c2a2af449c
2017-07-10 18:21:15 +00:00
jackqdyulei
116fec5b25 Init BatteryUtils in constructor
In this case we won't have the NPE.

Bug: 63526637
Test: RunSettingsRoboTests
Change-Id: I20375e535ba07deddacf74052f31476e0cb28e56
2017-07-10 11:08:12 -07:00
TreeHugger Robot
69d6f2840f Merge "Update summary for "Voice Calls"" into oc-dr1-dev 2017-07-07 23:52:58 +00:00
TreeHugger Robot
50535da16d Merge "Add public intent filters to indexing" into oc-dr1-dev 2017-07-07 22:39:20 +00:00
jackqdyulei
85e771da78 Update summary for "Voice Calls"
Change it from "Screen usage 2m" to "2m", since this is not a screen
usage. This cl has effect on all non-app batterySipper.

Bug: 63443732
Test: RunSettingsRoboTests
Change-Id: I027b3234bd7b56738ab31c5dfbc0d8bd7f19186e
2017-07-07 14:52:27 -07:00
TreeHugger Robot
db522a539d Merge "Get rid of spurious gear icon in BT details page" into oc-dr1-dev 2017-07-07 21:12:58 +00:00
TreeHugger Robot
062dedb072 Merge "Create BatterySaverReceiver" into oc-dr1-dev 2017-07-07 19:31:47 +00:00
Antony Sargent
2efec86bae Get rid of spurious gear icon in BT details page
The problem is that we were calling done() on the EntityHeaderController
and passing false for whether to rebind the action buttons, which means
we were getting the default behavior including a visible gear
icon. Passing true to request rebinding causes that icon to be hidden.

Bug: 63405635
Test: make RunSettingsRoboTests
Change-Id: I031f4a2d176ff3be025cc2675d7026a679936b03
2017-07-07 11:31:43 -07:00
Stephen Chen
cb3dfb91e8 Adjust UX for toggles when active scorer is not set.
This change fixes two issues: when wakeup is not available, update the
number of items to show above the fold in wifi preferences. When scorer
is not set, grey out wakeup toggle and set summary to reflect the
status.

Bug: 62410973
Bug: 62343859
Test: make RunSettingsRoboTests -j40
Merged-In: I5f4131c6a86eab6c0fb03ea2b5101ba107a9189f
Change-Id: I5f4131c6a86eab6c0fb03ea2b5101ba107a9189f
2017-07-07 11:06:20 -07:00
Ajay Kumar Nadathur Sreenivasan
9afa37ac3c Merge "Screen lock type metrics are not reported if user goes back" into oc-dr1-dev 2017-07-07 17:30:15 +00:00
jackqdyulei
aea085bc96 Create BatterySaverReceiver
This cl elicits BatterySaverReceiver that listen to the change about
battery state and battery saver state.

BatterySaverController and BatterySaverSettings will use this receiver
to update the UI.

Bug: 32410757
Test: RunSettingsRoboTests
Change-Id: Ia92c6776985b89fe6a8d5b8d80898e502942b9b5
Merged-In: Ia92c6776985b89fe6a8d5b8d80898e502942b9b5
2017-07-07 10:01:52 -07:00
TreeHugger Robot
690accadc7 Merge "Update Anomaly detection framework" into oc-dr1-dev 2017-07-07 02:13:37 +00:00
TreeHugger Robot
21423623bd Merge "Add a confirmation dialog when forgetting BT device" into oc-dr1-dev 2017-07-06 23:46:39 +00:00
Matthew Fritze
473b6b45de Add public intent filters to indexing
Adds a public intent action to the index so that intents
can be created for callers outside of settings.

Change-Id: I9f87263f213b6de40542e8735c931ee1f0d82094
Fixes: 63136008
Test: make RunSettingsRoboTests
2017-07-06 23:12:21 +00:00
jackqdyulei
bfc2b11b93 Update Anomaly detection framework
This cl make it could have multiple actions for each anomaly type.

This includes:
1. Add field "targetSdkVersion", "bgRestrictionEnabled" in Anomaly
2. Add new action which includes "force stop" and "background check"
3. Add "sdkVersion" and "bgRestrictionEnabled" method in BatteryUtils
4. Update BackgroundCheckAction to check sdkVersion first
5. Update serveral tests and add new test

Bug: 63037765
Test: RunSettingsRoboTests
Change-Id: Iea7a131ee57d501f7737ae4a3ba672d948d05cd8
2017-07-06 15:53:28 -07:00
TreeHugger Robot
55ad60d1ff Merge "Add util method to get battery stats" into oc-dr1-dev 2017-07-06 21:58:33 +00:00
Ajay Nadathur
3d9fffed16 Screen lock type metrics are not reported if user goes back
bug: 63116381
Test: Manually tested and verified that metrics are passed back to
setupwizard. Also added robolectric tests
Change-Id: I9d095754addc34121a2a0a12b3e5d1479ff15a78
2017-07-06 14:56:34 -07:00
Daniel Nishi
fa47cebd55 Merge "Update the Storage icons." into oc-dr1-dev 2017-07-06 21:50:49 +00:00