Transition BatteryAppListPreferences to BatteryUsageStats API
Bug: 173745486 Test: make RunSettingsRoboTests Test: male RunSettingsGoogleRoboTests Change-Id: I7af8cbcd27433b89cb2184750c6854aa74761d0d
This commit is contained in:
@@ -50,7 +50,6 @@ public class PowerUsageAdvanced extends PowerUsageBase {
|
||||
|
||||
@VisibleForTesting
|
||||
BatteryHistoryPreference mHistPref;
|
||||
private BatteryUtils mBatteryUtils;
|
||||
private PowerUsageFeatureProvider mPowerUsageFeatureProvider;
|
||||
private BatteryAppListPreferenceController mBatteryAppListPreferenceController;
|
||||
@VisibleForTesting
|
||||
@@ -64,7 +63,6 @@ public class PowerUsageAdvanced extends PowerUsageBase {
|
||||
mHistPref = (BatteryHistoryPreference) findPreference(KEY_BATTERY_GRAPH);
|
||||
mPowerUsageFeatureProvider = FeatureFactory.getFactory(context)
|
||||
.getPowerUsageFeatureProvider(context);
|
||||
mBatteryUtils = BatteryUtils.getInstance(context);
|
||||
|
||||
// init the summary so other preferences won't have unnecessary move
|
||||
updateHistPrefSummary(context);
|
||||
@@ -155,7 +153,7 @@ public class PowerUsageAdvanced extends PowerUsageBase {
|
||||
updatePreference(mHistPref);
|
||||
updateHistPrefSummary(context);
|
||||
|
||||
mBatteryAppListPreferenceController.refreshAppListGroup(mStatsHelper, mShowAllApps);
|
||||
mBatteryAppListPreferenceController.refreshAppListGroup(mBatteryUsageStats, mShowAllApps);
|
||||
}
|
||||
|
||||
private void updateHistPrefSummary(Context context) {
|
||||
|
||||
Reference in New Issue
Block a user