Fixed battery chart flickering

- Hide the hourly chart view by default to avoid the calculate the
  space.
- Remove the alpha animation in chart group which causes the flickering
  when open the battery page.

Bug: 378997970
Flag: EXEMPT bugfix
Test: atest BatteryChartPreferenceControllerTest
Change-Id: I1b7e5f74fe63ebcae9f9737b0797d870fd56b134
This commit is contained in:
David Liu
2024-12-11 23:37:15 +00:00
committed by mxyyiyi
parent 0ca6d53458
commit aad7bf5ea8
2 changed files with 2 additions and 4 deletions

View File

@@ -274,7 +274,6 @@ public class BatteryChartPreferenceController extends AbstractPreferenceControll
}
if (mDailyChartView != dailyChartView || mHourlyChartView != hourlyChartView) {
mHandler.post(() -> setBatteryChartViewInner(dailyChartView, hourlyChartView));
animateBatteryChartViewGroup();
}
if (mBatteryChartViewGroup != null) {
final View grandparentView = (View) mBatteryChartViewGroup.getParent();