aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNebuleon Fumika2013-01-26 20:31:11 -0500
committerNebuleon Fumika2013-01-26 20:31:11 -0500
commitdded2161378bdf0ead156f47f2473872854fc129 (patch)
tree3826cd65156f5abfacbc771cce832716df7cb0ab
parente473daf461ed5c32e9629f51bd1009a1270ec8db (diff)
downloadsnesemu-dded2161378bdf0ead156f47f2473872854fc129.tar.gz
snesemu-dded2161378bdf0ead156f47f2473872854fc129.tar.bz2
snesemu-dded2161378bdf0ead156f47f2473872854fc129.zip
Turn off the lower screen's backlight when returning from suspend during emulation.
-rw-r--r--source/nds/entry.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/source/nds/entry.cpp b/source/nds/entry.cpp
index 13486b0..45360a8 100644
--- a/source/nds/entry.cpp
+++ b/source/nds/entry.cpp
@@ -1081,6 +1081,10 @@ unsigned int S9xReadJoypad (int which1)
mdelay(1);
} while (inputdata.key & KEY_LID);
ds2_wakeup();
+ // Before starting to emulate again, turn off the lower
+ // screen's backlight.
+ mdelay(100); // needed to avoid ds2_setBacklight crashing
+ ds2_setBacklight(2);
set_cpu_clock(clock_speed_number);
}