Commit 2ce96b45 authored by Rein Klazes's avatar Rein Klazes Committed by Alexandre Julliard

Implemented GetDaylightFlag.

parent 589e1152
......@@ -381,7 +381,7 @@
@ stdcall GetCurrentThreadId()
@ stdcall GetDateFormatA(long long ptr str ptr long)
@ stdcall GetDateFormatW(long long ptr wstr ptr long)
@ stub GetDaylightFlag
@ stdcall GetDaylightFlag()
@ stdcall GetDefaultCommConfigA(str ptr long)
@ stdcall GetDefaultCommConfigW(wstr ptr long)
@ stub GetDefaultSortkeySize
......
......@@ -155,6 +155,7 @@ BOOL WINAPI SetSystemTimeAdjustment(
* RETURNS
* Success: TIME_ZONE_ID_STANDARD. tzinfo contains the time zone info.
* Failure: TIME_ZONE_ID_INVALID.
* FIXME: return TIME_ZONE_ID_DAYLIGHT when daylight saving is on.
*/
DWORD WINAPI GetTimeZoneInformation(
LPTIME_ZONE_INFORMATION tzinfo) /* [out] Destination for time zone information */
......@@ -871,3 +872,18 @@ VOID WINAPI GetSystemTime(LPSYSTEMTIME systime) /* [O] Destination for current t
ft.dwHighDateTime = t.u.HighPart;
FileTimeToSystemTime(&ft, systime);
}
/*********************************************************************
* GetDaylightFlag (KERNEL32.@)
*
* returns TRUE if daylight saving time is in operation
*
* Note: this function is called from the Win98's control applet
* timedate.cpl
*/
BOOL WINAPI GetDaylightFlag(void)
{
time_t t = time(NULL);
struct tm *ptm = localtime( &t);
return ptm->tm_isdst > 0;
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment