mirror of
https://github.com/godotengine/godot.git
synced 2025-11-01 14:11:15 +00:00
Fix windows compilability
This commit is contained in:
parent
8d61817293
commit
64704ecbc5
4 changed files with 19 additions and 29 deletions
|
|
@ -442,10 +442,14 @@ String OSWinrt::get_name() {
|
|||
return "WinRT";
|
||||
}
|
||||
|
||||
OS::Date OSWinrt::get_date() const {
|
||||
OS::Date OSWinrt::get_date(bool utc) const {
|
||||
|
||||
SYSTEMTIME systemtime;
|
||||
GetLocalTime(&systemtime);
|
||||
if (utc)
|
||||
GetSystemTime(&systemtime);
|
||||
else
|
||||
GetLocalTime(&systemtime);
|
||||
|
||||
Date date;
|
||||
date.day=systemtime.wDay;
|
||||
date.month=Month(systemtime.wMonth);
|
||||
|
|
@ -485,14 +489,11 @@ OS::TimeZoneInfo OS_Windows::get_time_zone_info() const {
|
|||
return ret;
|
||||
}
|
||||
|
||||
uint64_t OSWinrt::get_unix_time(bool utc) const {
|
||||
uint64_t OSWinrt::get_unix_time() const {
|
||||
|
||||
FILETIME ft;
|
||||
SYSTEMTIME st;
|
||||
if (utc)
|
||||
GetSystemTime(&systemtime);
|
||||
else
|
||||
GetLocalTime(&systemtime);
|
||||
GetSystemTime(&systemtime);
|
||||
SystemTimeToFileTime(&st, &ft);
|
||||
|
||||
SYSTEMTIME ep;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue