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
This commit is contained in:
@@ -35,8 +35,9 @@ public class BatteryHistoryPreference extends Preference {
|
||||
|
||||
private CharSequence mSummary;
|
||||
private TextView mSummaryView;
|
||||
private boolean hideSummary;
|
||||
|
||||
@VisibleForTesting
|
||||
boolean hideSummary;
|
||||
@VisibleForTesting
|
||||
BatteryInfo mBatteryInfo;
|
||||
|
||||
@@ -56,8 +57,10 @@ public class BatteryHistoryPreference extends Preference {
|
||||
public void setBottomSummary(CharSequence text) {
|
||||
mSummary = text;
|
||||
if (mSummaryView != null) {
|
||||
mSummaryView.setVisibility(View.VISIBLE);
|
||||
mSummaryView.setText(mSummary);
|
||||
}
|
||||
hideSummary = false;
|
||||
}
|
||||
|
||||
public void hideBottomSummary() {
|
||||
|
Reference in New Issue
Block a user