From 6b1f3a1486f8be094eef9778cf976033b05b1f8c Mon Sep 17 00:00:00 2001 From: Skylar Ittner Date: Tue, 10 Sep 2019 20:34:05 -0600 Subject: [PATCH] Use full wakelock instead of partial --- www/assets/js/platform.js | 6 +++--- www/assets/js/settings.js | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/www/assets/js/platform.js b/www/assets/js/platform.js index 622b384..91fc97d 100644 --- a/www/assets/js/platform.js +++ b/www/assets/js/platform.js @@ -74,10 +74,10 @@ function initCordova() { document.addEventListener("deviceready", function () { if (localStorage.getItem("wakelock") == "true") { - window.powerManagement.dim(function () { - console.log('Partial wakelock acquired'); + window.powerManagement.acquire(function () { + console.log('Wakelock acquired'); }, function () { - console.log('Failed to acquire partial wakelock'); + console.log('Failed to acquire wakelock'); }); } else { window.powerManagement.release(function () { diff --git a/www/assets/js/settings.js b/www/assets/js/settings.js index 107b06a..ecd9f57 100644 --- a/www/assets/js/settings.js +++ b/www/assets/js/settings.js @@ -24,10 +24,10 @@ $('.item-content[data-setting=wakelock] .toggle input').on("change", function () if (platform_type == "cordova") { if (localStorage.getItem("wakelock") == "true") { - window.powerManagement.dim(function () { - console.log('Partial wakelock acquired'); + window.powerManagement.acquire(function () { + console.log('Wakelock acquired'); }, function () { - console.log('Failed to acquire partial wakelock'); + console.log('Failed to acquire wakelock'); }); } else { window.powerManagement.release(function () {