Fix keep screen on property path for Android/iOS/UWP

(cherry picked from commit d18235bc38)
This commit is contained in:
volzhs 2018-07-16 23:09:22 +09:00 committed by Rémi Verschelde
parent e08eb964c4
commit 5dd8f775f9
3 changed files with 3 additions and 3 deletions

View File

@ -300,7 +300,7 @@ public class Godot extends Activity implements SensorEventListener, IDownloaderC
runOnUiThread(new Runnable() { runOnUiThread(new Runnable() {
@Override @Override
public void run() { public void run() {
view.setKeepScreenOn("True".equals(GodotLib.getGlobal("display/driver/keep_screen_on"))); view.setKeepScreenOn("True".equals(GodotLib.getGlobal("display/window/energy_saving/keep_screen_on")));
} }
}); });
} }

View File

@ -643,7 +643,7 @@ static int frame_count = 0;
view_controller.view = glView; view_controller.view = glView;
window.rootViewController = view_controller; window.rootViewController = view_controller;
_set_keep_screen_on(bool(GLOBAL_DEF("display/window/keep_screen_on", true)) ? YES : NO); _set_keep_screen_on(bool(GLOBAL_DEF("display/window/energy_saving/keep_screen_on", true)) ? YES : NO);
glView.useCADisplayLink = glView.useCADisplayLink =
bool(GLOBAL_DEF("display.iOS/use_cadisplaylink", true)) ? YES : NO; bool(GLOBAL_DEF("display.iOS/use_cadisplaylink", true)) ? YES : NO;
printf("cadisaplylink: %d", glView.useCADisplayLink); printf("cadisaplylink: %d", glView.useCADisplayLink);

View File

@ -297,7 +297,7 @@ Error OSUWP::initialize(const VideoMode &p_desired, int p_video_driver, int p_au
if (is_keep_screen_on()) if (is_keep_screen_on())
display_request->RequestActive(); display_request->RequestActive();
set_keep_screen_on(GLOBAL_DEF("display/window/keep_screen_on", true)); set_keep_screen_on(GLOBAL_DEF("display/window/energy_saving/keep_screen_on", true));
return OK; return OK;
} }