Remove deprecated code

Fixes: 137106225
Test: rebuild
Change-Id: If978f765fd1f6ec0fded1eb0f7e93e386c5d3163
This commit is contained in:
Raff Tsai
2019-07-11 11:15:39 +08:00
parent cde0fa3f85
commit 5fe166075f

View File

@@ -106,7 +106,6 @@ public class PowerUsageSummary extends PowerUsageBase implements OnLongClickList
boolean mNeedUpdateBatteryTip;
@VisibleForTesting
BatteryTipPreferenceController mBatteryTipPreferenceController;
private int mStatsType = BatteryStats.STATS_SINCE_CHARGED;
@VisibleForTesting
final ContentObserver mSettingsObserver = new ContentObserver(new Handler()) {
@@ -290,13 +289,6 @@ public class PowerUsageSummary extends PowerUsageBase implements OnLongClickList
public boolean onOptionsItemSelected(MenuItem item) {
switch (item.getItemId()) {
case MENU_STATS_TYPE:
if (mStatsType == BatteryStats.STATS_SINCE_CHARGED) {
// TODO: STATS_SINCE_UNPLUGGED is deprecated in Q, so this accomplishes nothing,
// but mStatsType doesn't seem to be hooked up to anything anyway.
mStatsType = BatteryStats.STATS_SINCE_UNPLUGGED;
} else {
mStatsType = BatteryStats.STATS_SINCE_CHARGED;
}
refreshUi(BatteryUpdateType.MANUAL);
return true;
case MENU_ADVANCED_BATTERY: