From: <dan...@us...> - 2006-11-27 16:38:20
|
Revision: 826 http://svn.sourceforge.net/cegcc/?rev=826&view=rev Author: dannybackx Date: 2006-11-27 08:38:00 -0800 (Mon, 27 Nov 2006) Log Message: ----------- Another submission by Kevin. There is a function GetSystemPowerStatusEx2 defined for CE. Structure definition: http://msdn.microsoft.com/library/default.asp?url=/library/en-us/wceshellui5/html/wce50lrfsystempowerstatusex2.asp Function definition: http://msdn.microsoft.com/library/default.asp?url=/library/en-us/wceshellui5/html/wce50lrfGetSystemPowerStatusEx2.asp Modified Paths: -------------- trunk/cegcc/src/w32api/ChangeLog.ce trunk/cegcc/src/w32api/include/winbase.h Modified: trunk/cegcc/src/w32api/ChangeLog.ce =================================================================== --- trunk/cegcc/src/w32api/ChangeLog.ce 2006-11-27 16:36:20 UTC (rev 825) +++ trunk/cegcc/src/w32api/ChangeLog.ce 2006-11-27 16:38:00 UTC (rev 826) @@ -1,5 +1,10 @@ 2006-11-26 Kevin O'Connor <ke...@ko...> + * include/winbase.h: Add SYSTEM_POWER_STATUS_EX2 structure. + Add GetSystemPowerStatusEx2 function definition. + +2006-11-26 Kevin O'Connor <ke...@ko...> + * include/tlhelp32.h (MODULEENTRY32): szModule is of MAX_PATH size on CE. Modified: trunk/cegcc/src/w32api/include/winbase.h =================================================================== --- trunk/cegcc/src/w32api/include/winbase.h 2006-11-27 16:36:20 UTC (rev 825) +++ trunk/cegcc/src/w32api/include/winbase.h 2006-11-27 16:38:00 UTC (rev 826) @@ -992,6 +992,30 @@ WORD wCertificateType; BYTE bCertificate[1]; } WIN_CERTIFICATE, *LPWIN_CERTIFICATE; +#ifdef _WIN32_WCE +typedef struct _SYSTEM_POWER_STATUS_EX2 { + BYTE ACLineStatus; + BYTE BatteryFlag; + BYTE BatteryLifePercent; + BYTE Reserved1; + DWORD BatteryLifeTime; + DWORD BatteryFullLifeTime; + BYTE Reserved2; + BYTE BackupBatteryFlag; + BYTE BackupBatteryLifePercent; + BYTE Reserved3; + DWORD BackupBatteryLifeTime; + DWORD BackupBatteryFullLifeTime; + DWORD BatteryVoltage; + DWORD BatteryCurrent; + DWORD BatteryAverageCurrent; + DWORD BatteryAverageInterval; + DWORD BatterymAHourConsumed; + DWORD BatteryTemperature; + DWORD BackupBatteryVoltage; + BYTE BatteryChemistry; +} SYSTEM_POWER_STATUS_EX2, *PSYSTEM_POWER_STATUS_EX2, *LPSYSTEM_POWER_STATUS_EX2; +#endif #if (_WIN32_WINNT >= 0x0501) typedef struct tagACTCTXA { ULONG cbSize; @@ -1547,6 +1571,9 @@ WINBASEAPI UINT WINAPI GetSystemDirectoryW(LPWSTR,UINT); WINBASEAPI VOID WINAPI GetSystemInfo(LPSYSTEM_INFO); WINBASEAPI BOOL WINAPI GetSystemPowerStatus(LPSYSTEM_POWER_STATUS); +#ifdef _WIN32_WCE +WINBASEAPI DWORD GetSystemPowerStatusEx2(PSYSTEM_POWER_STATUS_EX2,DWORD,BOOL); +#endif #if (_WIN32_WINNT >= 0x0502) WINBASEAPI BOOL WINAPI GetSystemRegistryQuota(PDWORD,PDWORD); #endif This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |