Make the peak refresh rate with rounding

To ensure accurate comparison of peak refresh rates, it is essential
to consider the peak refresh rate after rounding. This eliminates the
risk of unexpected triggers that could activate the Smooth Display
settings UI.

Bug: 312121651
Test: check the settings with Smooth Display
Change-Id: I4cd68efbcf4fdb9d4664c96332901661a23f4f09
This commit is contained in:
Peter Lin
2023-11-30 10:09:03 +00:00
parent 9f03501179
commit f59044d827

View File

@@ -65,7 +65,7 @@ public class PeakRefreshRatePreferenceController extends TogglePreferenceControl
updateState(mPreference);
}
};
mPeakRefreshRate = findHighestRefreshRateForDefaultDisplay(context);
mPeakRefreshRate = Math.round(findHighestRefreshRateForDefaultDisplay(context));
Log.d(
TAG,
"DEFAULT_REFRESH_RATE : "