From 3e69e498bb0db4bc975201604bc0dc59da560a22 Mon Sep 17 00:00:00 2001 From: yellows8 Date: Thu, 22 May 2014 14:21:39 -0400 Subject: [PATCH] Adjusted sleep-mode code so that on leaving sleep-mode, GSPGPU_SetLcdForceBlack() is only used when the status was APP_RUNNING(also removed GSPGPU_SetLcdForceBlack call for prepare sleep-mode signal). --- libctru/source/APT.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/libctru/source/APT.c b/libctru/source/APT.c index 4b28fcd..f58a8de 100644 --- a/libctru/source/APT.c +++ b/libctru/source/APT.c @@ -214,7 +214,6 @@ void aptEventHandler(u32 arg) case 0x3: //preparing to enter sleep-mode aptStatus_beforesleepmode = aptGetStatus(); - GSPGPU_SetLcdForceBlack(NULL, 1); aptOpenSession(); APT_ReplySleepQuery(NULL, currentAppId, 0x1); aptCloseSession(); @@ -234,7 +233,7 @@ void aptEventHandler(u32 arg) case 0x6: //leaving sleep-mode if(aptGetStatus()==APP_SLEEPMODE) { - GSPGPU_SetLcdForceBlack(NULL, 0); + if(aptStatus_beforesleepmode == APP_RUNNING)GSPGPU_SetLcdForceBlack(NULL, 0); aptSetStatus(aptStatus_beforesleepmode); } break;