From 565256c53b6cdd23fedb1afd4e6d75b84c0872eb Mon Sep 17 00:00:00 2001 From: pagefault <> Date: Sat, 1 Oct 2005 20:53:15 +0000 Subject: [PATCH] Function to read battery info in windows --- zsnes/src/win/winlink.cpp | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/zsnes/src/win/winlink.cpp b/zsnes/src/win/winlink.cpp index 481fc5e7..b7946ff6 100644 --- a/zsnes/src/win/winlink.cpp +++ b/zsnes/src/win/winlink.cpp @@ -3089,4 +3089,13 @@ void InitDebugger() } } +unsigned int WinCheckBatteryTime() +{ + SYSTEM_POWER_STATUS SysPowerStat; + + GetSystemPowerStatus(&SysPowerStat); + + return SysPowerStat.BatteryLifeTime; +} + }