From cf48a4897071c62c4f0557a878d791122610a448 Mon Sep 17 00:00:00 2001 From: OV2 Date: Fri, 27 Dec 2019 03:00:04 +0100 Subject: [PATCH] win32: use date/time functions also available in winxp --- win32/CSaveLoadWithPreviewDlg.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/win32/CSaveLoadWithPreviewDlg.cpp b/win32/CSaveLoadWithPreviewDlg.cpp index fc4cb73b..92373b4e 100644 --- a/win32/CSaveLoadWithPreviewDlg.cpp +++ b/win32/CSaveLoadWithPreviewDlg.cpp @@ -145,13 +145,13 @@ void CSaveLoadWithPreviewDlg::load_slot_image_text(int slot, HWND hDlg) // reserve space for date and time (both received individually) std::vector date_string; date_string.resize(max( - GetDateFormatEx(LOCALE_NAME_USER_DEFAULT, DATE_AUTOLAYOUT | DATE_LONGDATE, &stLocal, NULL, NULL, 0, NULL), - GetTimeFormatEx(LOCALE_NAME_USER_DEFAULT, 0, &stLocal, NULL, NULL, 0) + GetDateFormat(LOCALE_USER_DEFAULT, DATE_AUTOLAYOUT | DATE_LONGDATE, &stLocal, NULL, NULL, 0), + GetTimeFormat(LOCALE_USER_DEFAULT, 0, &stLocal, NULL, NULL, 0) )); - GetDateFormatEx(LOCALE_NAME_USER_DEFAULT, DATE_AUTOLAYOUT | DATE_LONGDATE, &stLocal, NULL, &date_string[0], 100, NULL); + GetDateFormat(LOCALE_USER_DEFAULT, DATE_AUTOLAYOUT | DATE_LONGDATE, &stLocal, NULL, &date_string[0], 100); static_text.append(L"\n").append(&date_string[0]); - GetTimeFormatEx(LOCALE_NAME_USER_DEFAULT, 0, &stLocal, NULL, &date_string[0], 100); + GetTimeFormat(LOCALE_USER_DEFAULT, 0, &stLocal, NULL, &date_string[0], 100); static_text.append(L" ").append(&date_string[0]); } }