2014-02-05 18:17:27 +00:00
|
|
|
#ifndef _INTL_H
|
|
|
|
#define _INTL_H
|
|
|
|
|
2013-01-24 23:00:42 +00:00
|
|
|
#include <stdarg.h>
|
2015-09-12 15:25:36 +00:00
|
|
|
#include <stdlib.h>
|
2014-01-19 10:31:28 +00:00
|
|
|
|
|
|
|
#define WIN32_NO_STATUS
|
2013-01-24 23:00:42 +00:00
|
|
|
#include <windef.h>
|
|
|
|
#include <winbase.h>
|
|
|
|
#include <winnls.h>
|
|
|
|
#include <winreg.h>
|
|
|
|
#include <winuser.h>
|
2009-01-20 15:13:32 +00:00
|
|
|
#include <cpl.h>
|
2011-07-28 14:54:48 +00:00
|
|
|
#include <setupapi.h>
|
2015-09-03 20:37:17 +00:00
|
|
|
#include <ndk/exfuncs.h>
|
2011-07-28 14:54:48 +00:00
|
|
|
|
|
|
|
#include "resource.h"
|
2009-01-20 15:13:32 +00:00
|
|
|
|
2009-10-28 23:20:28 +00:00
|
|
|
#define DECIMAL_RADIX 10
|
|
|
|
|
2011-11-29 14:55:58 +00:00
|
|
|
/* Limits */
|
2009-10-28 23:20:28 +00:00
|
|
|
#define MAX_FMT_SIZE 30
|
2007-09-02 20:42:08 +00:00
|
|
|
#define MAX_STR_SIZE 128
|
2009-10-28 23:20:28 +00:00
|
|
|
#define MAX_SAMPLES_STR_SIZE 70
|
|
|
|
|
2015-10-04 21:57:03 +00:00
|
|
|
#define MAX_NUMDECIMALSEP 4
|
|
|
|
#define MAX_NUMTHOUSANDSEP 4
|
|
|
|
#define MAX_NUMNEGATIVESIGN 5
|
|
|
|
#define MAX_NUMPOSITIVESIGN 5
|
|
|
|
#define MAX_NUMLISTSEP 4
|
|
|
|
#define MAX_NUMNATIVEDIGITS 11
|
|
|
|
|
|
|
|
#define MAX_CURRSYMBOL 13
|
|
|
|
#define MAX_CURRDECIMALSEP 4
|
|
|
|
#define MAX_CURRTHOUSANDSEP 4
|
|
|
|
#define MAX_CURRGROUPING 10
|
2009-10-28 23:20:28 +00:00
|
|
|
|
|
|
|
#define MAX_TIMEFORMAT 80
|
2015-10-04 21:57:03 +00:00
|
|
|
#define MAX_TIMESEPARATOR 4
|
|
|
|
#define MAX_TIMEAMSYMBOL 15
|
|
|
|
#define MAX_TIMEPMSYMBOL 15
|
2009-10-28 23:20:28 +00:00
|
|
|
|
2015-10-04 21:57:03 +00:00
|
|
|
#define MAX_SHORTDATEFORMAT 80
|
|
|
|
#define MAX_LONGDATEFORMAT 80
|
|
|
|
#define MAX_DATESEPARATOR 4
|
2009-10-28 23:20:28 +00:00
|
|
|
#define MAX_YEAR_EDIT 4
|
2004-10-30 12:33:51 +00:00
|
|
|
|
2015-10-04 21:57:03 +00:00
|
|
|
#define MAX_MISCCOUNTRY 80
|
|
|
|
#define MAX_MISCLANGUAGE 80
|
|
|
|
|
2015-10-11 18:36:22 +00:00
|
|
|
#define MAX_GROUPINGFORMATS 3
|
|
|
|
|
2015-10-04 21:57:03 +00:00
|
|
|
|
2004-10-30 12:33:51 +00:00
|
|
|
typedef struct _APPLET
|
|
|
|
{
|
2008-02-23 17:48:50 +00:00
|
|
|
UINT idIcon;
|
|
|
|
UINT idName;
|
|
|
|
UINT idDescription;
|
|
|
|
APPLET_PROC AppletProc;
|
2004-10-30 12:33:51 +00:00
|
|
|
} APPLET, *PAPPLET;
|
|
|
|
|
2007-09-10 20:46:27 +00:00
|
|
|
typedef struct _GLOBALDATA
|
|
|
|
{
|
2017-05-06 14:41:50 +00:00
|
|
|
/* General */
|
|
|
|
WCHAR szNumPositiveSign[MAX_NUMPOSITIVESIGN];
|
|
|
|
WCHAR szNumNativeDigits[MAX_NUMNATIVEDIGITS];
|
|
|
|
|
2015-10-04 21:57:03 +00:00
|
|
|
/* Number */
|
|
|
|
WCHAR szNumDecimalSep[MAX_NUMDECIMALSEP];
|
|
|
|
WCHAR szNumThousandSep[MAX_NUMTHOUSANDSEP];
|
|
|
|
WCHAR szNumNegativeSign[MAX_NUMNEGATIVESIGN];
|
|
|
|
WCHAR szNumListSep[MAX_NUMLISTSEP];
|
|
|
|
INT nNumNegFormat;
|
|
|
|
INT nNumDigits;
|
|
|
|
INT nNumLeadingZero;
|
|
|
|
INT nNumGrouping;
|
|
|
|
INT nNumMeasure;
|
|
|
|
INT nNumShape;
|
|
|
|
|
|
|
|
/* Currency */
|
|
|
|
WCHAR szCurrSymbol[MAX_CURRSYMBOL];
|
|
|
|
WCHAR szCurrDecimalSep[MAX_CURRDECIMALSEP];
|
|
|
|
WCHAR szCurrThousandSep[MAX_CURRTHOUSANDSEP];
|
|
|
|
INT nCurrPosFormat;
|
|
|
|
INT nCurrNegFormat;
|
|
|
|
INT nCurrDigits;
|
|
|
|
INT nCurrGrouping;
|
|
|
|
|
|
|
|
/* Time */
|
|
|
|
WCHAR szTimeFormat[MAX_TIMEFORMAT];
|
|
|
|
WCHAR szTimeSep[MAX_TIMESEPARATOR];
|
|
|
|
WCHAR szTimeAM[MAX_TIMEAMSYMBOL];
|
|
|
|
WCHAR szTimePM[MAX_TIMEPMSYMBOL];
|
|
|
|
INT nTime;
|
|
|
|
INT nTimePrefix;
|
|
|
|
INT nTimeLeadingZero;
|
|
|
|
|
|
|
|
/* Date */
|
|
|
|
WCHAR szLongDateFormat[MAX_LONGDATEFORMAT];
|
|
|
|
WCHAR szShortDateFormat[MAX_SHORTDATEFORMAT];
|
|
|
|
WCHAR szDateSep[MAX_DATESEPARATOR];
|
|
|
|
INT nFirstDayOfWeek;
|
|
|
|
INT nFirstWeekOfYear;
|
|
|
|
INT nDate;
|
|
|
|
INT nCalendarType;
|
2017-05-06 14:41:50 +00:00
|
|
|
BOOL bEnableYearNotification;
|
2015-10-04 21:57:03 +00:00
|
|
|
|
|
|
|
/* Other */
|
|
|
|
WCHAR szMiscCountry[MAX_MISCCOUNTRY];
|
|
|
|
WCHAR szMiscLanguage[MAX_MISCLANGUAGE];
|
|
|
|
INT nMiscCountry;
|
|
|
|
|
|
|
|
LCID UserLCID;
|
2015-10-10 13:54:00 +00:00
|
|
|
LCID SystemLCID;
|
2017-04-30 15:39:41 +00:00
|
|
|
BOOL bUserLocaleChanged;
|
2015-09-19 12:14:35 +00:00
|
|
|
BOOL bApplyToDefaultUser;
|
|
|
|
|
2015-09-12 15:25:36 +00:00
|
|
|
GEOID geoid;
|
2017-04-30 15:39:41 +00:00
|
|
|
BOOL bGeoIdChanged;
|
2015-09-12 15:25:36 +00:00
|
|
|
|
2016-01-10 21:12:23 +00:00
|
|
|
/* Misc */
|
|
|
|
BOOL bIsUserAdmin;
|
2007-09-10 20:46:27 +00:00
|
|
|
} GLOBALDATA, *PGLOBALDATA;
|
|
|
|
|
2015-10-11 18:36:22 +00:00
|
|
|
typedef struct
|
|
|
|
{
|
|
|
|
UINT nInteger;
|
|
|
|
PWSTR pszString;
|
|
|
|
} GROUPINGDATA;
|
|
|
|
|
2004-10-30 12:33:51 +00:00
|
|
|
extern HINSTANCE hApplet;
|
2007-08-29 20:13:27 +00:00
|
|
|
extern DWORD IsUnattendedSetupEnabled;
|
|
|
|
extern DWORD UnattendLCID;
|
2015-10-11 18:36:22 +00:00
|
|
|
extern GROUPINGDATA GroupingFormats[MAX_GROUPINGFORMATS];
|
2004-10-30 12:33:51 +00:00
|
|
|
|
2007-09-02 20:42:08 +00:00
|
|
|
/* intl.c */
|
2014-02-02 19:31:07 +00:00
|
|
|
VOID PrintErrorMsgBox(UINT msg);
|
2007-09-02 20:42:08 +00:00
|
|
|
|
2017-04-30 15:39:41 +00:00
|
|
|
INT
|
2015-09-19 12:14:35 +00:00
|
|
|
ResourceMessageBox(
|
|
|
|
HWND hwnd,
|
|
|
|
UINT uType,
|
|
|
|
UINT uCaptionId,
|
|
|
|
UINT uMessageId);
|
|
|
|
|
2007-09-02 20:42:08 +00:00
|
|
|
/* languages.c */
|
|
|
|
INT_PTR CALLBACK
|
2008-02-23 17:48:50 +00:00
|
|
|
LanguagesPageProc(HWND hwndDlg, UINT uMsg, WPARAM wParam, LPARAM lParam);
|
2007-10-19 23:21:45 +00:00
|
|
|
|
2007-09-02 20:42:08 +00:00
|
|
|
/* advanced.c */
|
|
|
|
INT_PTR CALLBACK
|
2008-02-23 17:48:50 +00:00
|
|
|
AdvancedPageProc(HWND hwndDlg, UINT uMsg, WPARAM wParam, LPARAM lParam);
|
2007-09-02 20:42:08 +00:00
|
|
|
|
2004-10-30 12:33:51 +00:00
|
|
|
/* currency.c */
|
|
|
|
INT_PTR CALLBACK
|
2008-02-23 17:48:50 +00:00
|
|
|
CurrencyPageProc(HWND hwndDlg, UINT uMsg, WPARAM wParam, LPARAM lParam);
|
2004-10-30 12:33:51 +00:00
|
|
|
|
|
|
|
/* date.c */
|
|
|
|
INT_PTR CALLBACK
|
2008-02-23 17:48:50 +00:00
|
|
|
DatePageProc(HWND hwndDlg, UINT uMsg, WPARAM wParam, LPARAM lParam);
|
2004-10-30 12:33:51 +00:00
|
|
|
|
|
|
|
/* general.c */
|
|
|
|
INT_PTR CALLBACK
|
2008-02-23 17:48:50 +00:00
|
|
|
GeneralPageProc(HWND hwndDlg, UINT uMsg, WPARAM wParam, LPARAM lParam);
|
2004-10-30 12:33:51 +00:00
|
|
|
|
2015-10-04 21:57:03 +00:00
|
|
|
PWSTR
|
|
|
|
GetLocaleString(
|
|
|
|
PWSTR *pLocaleArray,
|
|
|
|
LCTYPE lcType);
|
|
|
|
|
2004-10-30 12:33:51 +00:00
|
|
|
/* locale.c */
|
|
|
|
INT_PTR CALLBACK
|
2008-02-23 17:48:50 +00:00
|
|
|
InpLocalePageProc(HWND hwndDlg, UINT uMsg, WPARAM wParam, LPARAM lParam);
|
2004-10-30 12:33:51 +00:00
|
|
|
|
|
|
|
/* numbers.h */
|
|
|
|
INT_PTR CALLBACK
|
2008-02-23 17:48:50 +00:00
|
|
|
NumbersPageProc(HWND hwndDlg, UINT uMsg, WPARAM wParam, LPARAM lParam);
|
2004-10-30 12:33:51 +00:00
|
|
|
|
|
|
|
/* time.c */
|
|
|
|
INT_PTR CALLBACK
|
2008-02-23 17:48:50 +00:00
|
|
|
TimePageProc(HWND hwndDlg, UINT uMsg, WPARAM wParam, LPARAM lParam);
|
2004-10-30 12:33:51 +00:00
|
|
|
|
2007-09-08 22:27:41 +00:00
|
|
|
/* sort.c */
|
|
|
|
BOOL
|
|
|
|
IsSortPageNeeded(LCID lcid);
|
2006-08-12 19:32:57 +00:00
|
|
|
|
2007-09-08 22:27:41 +00:00
|
|
|
INT_PTR CALLBACK
|
2008-02-23 17:48:50 +00:00
|
|
|
SortPageProc(HWND hwndDlg, UINT uMsg, WPARAM wParam, LPARAM lParam);
|
2006-08-12 19:32:57 +00:00
|
|
|
|
2007-09-02 20:42:08 +00:00
|
|
|
/* misc.c */
|
2015-09-20 19:00:10 +00:00
|
|
|
PWSTR
|
|
|
|
InsSpacesFmt(PCWSTR szSourceStr, PCWSTR szFmtStr);
|
2007-09-02 20:42:08 +00:00
|
|
|
|
2015-09-20 19:00:10 +00:00
|
|
|
PWSTR
|
|
|
|
ReplaceSubStr(PCWSTR szSourceStr, PCWSTR szStrToReplace, PCWSTR szTempl);
|
2007-09-02 20:42:08 +00:00
|
|
|
|
2017-05-06 14:41:50 +00:00
|
|
|
VOID
|
|
|
|
GetSelectedComboBoxText(
|
|
|
|
HWND hwndDlg,
|
|
|
|
INT nIdDlgItem,
|
|
|
|
PWSTR Buffer,
|
|
|
|
UINT uSize);
|
|
|
|
|
|
|
|
VOID
|
|
|
|
GetSelectedComboBoxIndex(
|
|
|
|
HWND hwndDlg,
|
|
|
|
INT nIdDlgItem,
|
|
|
|
PINT pValue);
|
|
|
|
|
2009-01-20 15:13:32 +00:00
|
|
|
/* kblayouts.c */
|
|
|
|
VOID AddNewKbLayoutsByLcid(LCID Lcid);
|
|
|
|
|
2014-02-05 18:17:27 +00:00
|
|
|
#endif /* _INTL_H */
|