Make screen_get_refresh_rate() respect iOS Low Power Mode
This commit is contained in:
parent
80de898d72
commit
6a8f6bae4c
1 changed files with 5 additions and 1 deletions
|
@ -443,7 +443,11 @@ int DisplayServerIOS::screen_get_dpi(int p_screen) const {
|
|||
}
|
||||
|
||||
float DisplayServerIOS::screen_get_refresh_rate(int p_screen) const {
|
||||
return [UIScreen mainScreen].maximumFramesPerSecond;
|
||||
float fps = [UIScreen mainScreen].maximumFramesPerSecond;
|
||||
if ([NSProcessInfo processInfo].lowPowerModeEnabled) {
|
||||
fps = 60;
|
||||
}
|
||||
return fps;
|
||||
}
|
||||
|
||||
float DisplayServerIOS::screen_get_scale(int p_screen) const {
|
||||
|
|
Loading…
Reference in a new issue