Commit Graph

10 Commits

Author SHA1 Message Date
jeffreyhuang
2fee251634 Update BatteryHeaderPreferenceCtrlTest to sdk 26
Test: make RunSettingsRoboTests -j40
Change-Id: I514918b528984881d983bee6248e909e7b7824da
2017-11-28 17:13:57 -08:00
Tony Mantler
94a7c7d21c Convert SettingsLib Lifecycle to Flatfoot
Bug: 69257739
Test: m -j RunSettingsRoboTests
Change-Id: I27e7850c39afb9c09297007e8cc352f410665653
2017-11-14 11:04:40 -08:00
Fan Zhang
e3535d9998 Delete DynamicindexableContentMonitor & all refs to it
Convert input device search into a search query loader

And remove old logic from DynamicIndexableContentMonitor

Change-Id: If652b1ea7c8add9185bbd025055e14925d3a8eec
Bug: 64310452
Bug: 63831980
Test: robotests
2017-08-09 17:27:02 -07:00
jackqdyulei
19648756cb Add quickUpdate method to BatteryHeaderPrefCtrl
This cl adds a method called quickUpdateHeaderPreference, which will
update the following items immediately without waiting for the
BatteryInfo:
1. Battery level
2. Battery charging status(whether to show lighting bolt)
3. Clear the charging summary

Note: this cl doesn't optimize the BatteryInfo loading time.

This cl also rename "TimeText" to "BatteryPercentText" because in
new UI that textview is used to display battery percentage.

Bug: 63029231
Test: RunSettingsRoboTests
Change-Id: I8cc886b35e937d73b46e47e303ff0994ccdcb61c
2017-06-27 13:35:41 -07:00
Andrew Sapperstein
9f1e911759 Refactor test runner to use static list of resource paths
Previously everything lived in an inner class method of
SettingsRobolectricTestRunner. That method has now been turned into
a static method so that it can be called by other runners.

Bug: 62460102
Test: robotests
Change-Id: I6612b1f26404587301c534c8ba60e39d59d6c840
2017-06-09 09:21:26 -07:00
Salvador Martinez
f4727ea07f Add ability to see both battery estimates on long press
If the enhanced estimate is being used in battery settings
it is now possible to long press on the text to have it display
both instead of the string that is normally used.

Adds another loader to enable this since it needs both the old
and the new estimates simultaneously.

Feature is hidden behind a feature flag that only googlers will
have enabled.

Test: robotests
Bug: 38399275
Change-Id: I5caf26513baada27efd50ddb0e72d3868da47150
2017-06-05 16:26:32 -07:00
Fan Zhang
fe23da579d Misc layout fixes
- Apply entity header effect to battery summary screen.
- BidiWrap wifi ap name is it's correctly displayed in RLT languages
- Remove footer preference layout - settingslib already has one

Fix: 62039146
Fix: 62138362
Fix: 37920219
Test: make RunSettingsRoboTests

Change-Id: Idf1385ee40772c63075e5f81eb039c6da56256ab
2017-06-05 11:25:49 -07:00
Fan Zhang
af91c1f6bf Update suggestion rules and string description
Change-Id: I55025094b9a0e71710db726bcf7fc810a3705c65
Fix: 62262851
Fix: 62283797
Test: make RunSettingsRoboTests
2017-06-03 18:05:15 -07:00
Salvador Martinez
0e8c88376c Move BatteryInfo to settings from settingslib
This CL simply moves BatteryInfo from settingslib to settings and
makes sure the tests still pass. No other changes are made other than
imports or minor changes needed to make sure existing code does not
break.

Test: Robotests still pass
Bug: 38399275
Bug: 38398949
Bug: 38399654
Change-Id: I59803348e2780b7676ccc6c43234a586c184d71f
2017-06-01 11:34:08 -07:00
jackqdyulei
605dbc66be Split loading process for battery header
This cl creates BatteryHeaderPreferenceController, which will first
load the battery level in ui thread(in displayPreference()), then
display the remaining time once we get the battery stats.

This is the best we can do to avoid ui flashing while removing the
animation

Bug: 38349587
Test: RunSettingsRoboTests

Change-Id: Ic3622bb73562ba42e69b37e5674a724c03c45f12
2017-05-23 13:22:42 -07:00