Merge "DM: use the right terminology for divisor" into tm-dev
diff --git a/services/core/java/com/android/server/display/DisplayManagerService.java b/services/core/java/com/android/server/display/DisplayManagerService.java
index f5001102..a7b49f1 100644
--- a/services/core/java/com/android/server/display/DisplayManagerService.java
+++ b/services/core/java/com/android/server/display/DisplayManagerService.java
@@ -204,8 +204,8 @@
private static final String PROP_DEFAULT_DISPLAY_TOP_INSET = "persist.sys.displayinset.top";
private static final long WAIT_FOR_DEFAULT_DISPLAY_TIMEOUT = 10000;
// This value needs to be in sync with the threshold
- // in RefreshRateConfigs::getFrameRateDivider.
- private static final float THRESHOLD_FOR_REFRESH_RATES_DIVIDERS = 0.0009f;
+ // in RefreshRateConfigs::getFrameRateDivisor.
+ private static final float THRESHOLD_FOR_REFRESH_RATES_DIVISORS = 0.0009f;
private static final int MSG_REGISTER_DEFAULT_DISPLAY_ADAPTERS = 1;
private static final int MSG_REGISTER_ADDITIONAL_DISPLAY_ADAPTERS = 2;
@@ -895,13 +895,13 @@
return info;
}
- // Override the refresh rate only if it is a divider of the current
+ // Override the refresh rate only if it is a divisor of the current
// refresh rate. This calculation needs to be in sync with the native code
- // in RefreshRateConfigs::getFrameRateDivider
+ // in RefreshRateConfigs::getFrameRateDivisor
Display.Mode currentMode = info.getMode();
float numPeriods = currentMode.getRefreshRate() / frameRateHz;
float numPeriodsRound = Math.round(numPeriods);
- if (Math.abs(numPeriods - numPeriodsRound) > THRESHOLD_FOR_REFRESH_RATES_DIVIDERS) {
+ if (Math.abs(numPeriods - numPeriodsRound) > THRESHOLD_FOR_REFRESH_RATES_DIVISORS) {
return info;
}
frameRateHz = currentMode.getRefreshRate() / numPeriodsRound;
@@ -913,9 +913,9 @@
continue;
}
- if (mode.getRefreshRate() >= frameRateHz - THRESHOLD_FOR_REFRESH_RATES_DIVIDERS
+ if (mode.getRefreshRate() >= frameRateHz - THRESHOLD_FOR_REFRESH_RATES_DIVISORS
&& mode.getRefreshRate()
- <= frameRateHz + THRESHOLD_FOR_REFRESH_RATES_DIVIDERS) {
+ <= frameRateHz + THRESHOLD_FOR_REFRESH_RATES_DIVISORS) {
if (DEBUG) {
Slog.d(TAG, "found matching modeId " + mode.getModeId());
}