Merge changes I93d4d089,I4f09f9e5 into tm-qpr-dev
* changes: Fix b/248686898: Battery Usage list renders items on top of each other after swiping back from an app Fix broken battery usage Robolectric tests
This commit is contained in:
@@ -108,6 +108,7 @@ public class BatteryChartPreferenceController extends AbstractPreferenceControll
|
||||
|
||||
private boolean mIs24HourFormat;
|
||||
private boolean mIsFooterPrefAdded = false;
|
||||
private boolean mHourlyChartVisible = true;
|
||||
private View mBatteryChartViewGroup;
|
||||
private View mCategoryTitleView;
|
||||
private PreferenceScreen mPreferenceScreen;
|
||||
@@ -690,9 +691,10 @@ public class BatteryChartPreferenceController extends AbstractPreferenceControll
|
||||
}
|
||||
|
||||
private void animateBatteryHourlyChartView(final boolean visible) {
|
||||
if (mHourlyChartView == null) {
|
||||
if (mHourlyChartView == null || mHourlyChartVisible == visible) {
|
||||
return;
|
||||
}
|
||||
mHourlyChartVisible = visible;
|
||||
|
||||
if (visible) {
|
||||
mHourlyChartView.setVisibility(View.VISIBLE);
|
||||
|
Reference in New Issue
Block a user