24 HBITMAP hbmColor, hbmMono, hBmpOld;
39 szBuf[0] = szBuf[1] =
L'?';
51 if (!
hdc || !hbmColor || !hbmMono)
130 if (iDefault >= nCount)
141 BOOL bIsLeaf, bCanRemove, bCanProp;
144 item.hItem = hSelected;
181 if (hImeInst ==
NULL)
201 item.pszText = szText;
205 if (
_wcsicmp(szText, pszLangName) == 0)
220 WCHAR szKeyboard[64];
228 INT LangImageIndex = -1;
240 item.iImage = LangImageIndex;
241 item.iSelectedImage = LangImageIndex;
256 item.pszText = szKeyboard;
302 item.iImage = ImeImageIndex;
303 item.iSelectedImage = ImeImageIndex;
333 HICON hKeyboardIcon, hDotIcon;
402 if (hLayoutImageList !=
NULL)
453 if (
item.lParam == 0)
INT_PTR CALLBACK AddDialogProc(HWND hwndDlg, UINT uMsg, WPARAM wParam, LPARAM lParam)
BOOL WINAPI LookupPrivilegeValueW(LPCWSTR lpSystemName, LPCWSTR lpPrivilegeName, PLUID lpLuid)
BOOL WINAPI AdjustTokenPrivileges(HANDLE TokenHandle, BOOL DisableAllPrivileges, PTOKEN_PRIVILEGES NewState, DWORD BufferLength, PTOKEN_PRIVILEGES PreviousState, PDWORD ReturnLength)
BOOL WINAPI OpenProcessToken(HANDLE ProcessHandle, DWORD DesiredAccess, PHANDLE TokenHandle)
BOOL WINAPI ImageList_Destroy(HIMAGELIST himl)
HIMAGELIST WINAPI ImageList_Create(INT cx, INT cy, UINT flags, INT cInitial, INT cGrow)
#define GetCurrentProcess()
HINSTANCE WINAPI DECLSPEC_HOTPATCH LoadLibraryExW(LPCWSTR lpLibFileName, HANDLE hFile, DWORD dwFlags)
UINT WINAPI GetSystemDirectoryW(OUT LPWSTR lpBuffer, IN UINT uSize)
BOOL WINAPI EnumResourceNamesW(HMODULE hmod, LPCWSTR type, ENUMRESNAMEPROCW lpfun, LONG_PTR lparam)
INT WINAPI GetLocaleInfoW(LCID lcid, LCTYPE lctype, LPWSTR buffer, INT len)
INT_PTR CALLBACK EditDialogProc(HWND hwndDlg, UINT uMsg, WPARAM wParam, LPARAM lParam)
_Out_opt_ PICONINFO IconInfo
VOID LayoutList_Create(VOID)
VOID LayoutList_Destroy(VOID)
VOID LocaleList_Destroy(VOID)
LOCALE_LIST_NODE * LocaleList_Create(VOID)
static DWORD *static HFONT(WINAPI *pCreateFontIndirectExA)(const ENUMLOGFONTEXDVA *)
INT WINAPI DrawTextW(HDC hdc, LPCWSTR str, INT count, LPRECT rect, UINT flags)
#define PropSheet_Changed(d, w)
#define TreeView_DeleteAllItems(hwnd)
#define TreeView_Expand(hwnd, hitem, code)
#define TreeView_GetChild(hwnd, hitem)
#define TreeView_GetParent(hwnd, hitem)
#define TreeView_GetImageList(hwnd, iImage)
#define TreeView_GetSelection(hwnd)
#define TreeView_GetItem(hwnd, pitem)
#define ImageList_RemoveAll(himl)
#define TreeView_GetRoot(hwnd)
#define TreeView_GetNextSibling(hwnd, hitem)
#define ImageList_AddIcon(himl, hicon)
#define TVN_ITEMEXPANDING
#define TreeView_SetImageList(hwnd, himl, iImage)
#define TreeView_InsertItem(hwnd, lpis)
#define TVIF_SELECTEDIMAGE
#define TreeView_SetItem(hwnd, pitem)
_Check_return_ _CRTIMP int __cdecl _wcsicmp(_In_z_ const wchar_t *_Str1, _In_z_ const wchar_t *_Str2)
static HICON LoadIMEIcon(LPCTSTR pszImeFile)
static INT_PTR OnNotifySettingsPage(HWND hwndDlg, LPARAM lParam)
static VOID ExpandTreeItem(HWND hwndTree, HTREEITEM hItem)
BOOL EnableProcessPrivileges(LPCWSTR lpPrivilegeName, BOOL bEnable)
static VOID InitDefaultLangComboBox(HWND hwndCombo)
INT_PTR CALLBACK SettingsPageProc(HWND hwndDlg, UINT uMsg, WPARAM wParam, LPARAM lParam)
static VOID AddToInputListView(HWND hwndList, INPUT_LIST_NODE *pInputNode)
static BOOL CALLBACK EnumResNameProc(HMODULE hModule, LPCWSTR lpszType, LPWSTR lpszName, LONG_PTR lParam)
static INT s_nAliveLeafCount
static VOID OnInitSettingsPage(HWND hwndDlg)
static INT s_iKeyboardImage
static VOID OnDestroySettingsPage(HWND hwndDlg)
static VOID UpdateInputListView(HWND hwndList)
VOID OnCommandSettingsPage(HWND hwndDlg, WPARAM wParam)
static HICON CreateLayoutIcon(LANGID LangID)
static HTREEITEM FindLanguageInList(HWND hwndList, LPCTSTR pszLangName)
static VOID SetControlsState(HWND hwndDlg)
STRSAFEAPI StringCchPrintfW(STRSAFE_LPWSTR pszDest, size_t cchDest, STRSAFE_LPCWSTR pszFormat,...)
LUID_AND_ATTRIBUTES Privileges[ANYSIZE_ARRAY]
_Must_inspect_result_ _In_ WDFUSBDEVICE _In_opt_ WDFREQUEST _In_opt_ PWDF_REQUEST_SEND_OPTIONS _Out_writes_opt_ NumCharacters PUSHORT _Inout_ PUSHORT _In_ UCHAR _In_opt_ USHORT LangID
COLORREF WINAPI SetDCBrushColor(_In_ HDC hdc, _In_ COLORREF crColor)
#define DONT_RESOLVE_DLL_REFERENCES
HGDIOBJ WINAPI GetStockObject(_In_ int)
HBITMAP WINAPI CreateBitmap(_In_ INT cx, _In_ INT cy, _In_ UINT cPlanes, _In_ UINT cBitsPerPel, _In_opt_ const VOID *pvBits)
HGDIOBJ WINAPI SelectObject(_In_ HDC, _In_ HGDIOBJ)
HDC WINAPI CreateCompatibleDC(_In_opt_ HDC hdc)
BOOL WINAPI PatBlt(_In_ HDC, _In_ int, _In_ int, _In_ int, _In_ int, _In_ DWORD)
HBITMAP WINAPI CreateCompatibleBitmap(_In_ HDC hdc, _In_ INT cx, _In_ INT cy)
int WINAPI FillRect(HDC, LPCRECT, HBRUSH)
HFONT WINAPI CreateFontIndirectW(_In_ const LOGFONTW *)
int WINAPI SetBkMode(_In_ HDC, _In_ int)
COLORREF WINAPI SetTextColor(_In_ HDC, _In_ COLORREF)
BOOL WINAPI DeleteDC(_In_ HDC)
#define LOCALE_NOUSEROVERRIDE
#define LOCALE_SABBREVLANGNAME
int WINAPI ReleaseDC(_In_opt_ HWND, _In_ HDC)
DWORD WINAPI GetSysColor(_In_ int)
HICON WINAPI CreateIconIndirect(_In_ PICONINFO)
int WINAPI LoadStringW(_In_opt_ HINSTANCE hInstance, _In_ UINT uID, _Out_writes_to_(cchBufferMax, return+1) LPWSTR lpBuffer, _In_ int cchBufferMax)
#define DialogBoxW(i, t, p, f)
HANDLE WINAPI LoadImageW(_In_opt_ HINSTANCE hInst, _In_ LPCWSTR name, _In_ UINT type, _In_ int cx, _In_ int cy, _In_ UINT fuLoad)
#define SPI_GETICONTITLELOGFONT
HWND WINAPI GetDlgItem(_In_opt_ HWND, _In_ int)
struct tagNMHDR * LPNMHDR
BOOL WINAPI EnableWindow(_In_ HWND, _In_ BOOL)
#define COLOR_HIGHLIGHTTEXT
HDC WINAPI GetDC(_In_opt_ HWND)
BOOL WINAPI SystemParametersInfoW(_In_ UINT uiAction, _In_ UINT uiParam, _Inout_opt_ PVOID pvParam, _In_ UINT fWinIni)
HWND WINAPI GetParent(_In_ HWND)
BOOL WINAPI InvalidateRect(_In_opt_ HWND, _In_opt_ LPCRECT, _In_ BOOL)
#define MAKEINTRESOURCEW(i)
#define SetWindowLongPtrW
int WINAPI GetSystemMetrics(_In_ int)
LRESULT WINAPI SendMessageW(_In_ HWND, _In_ UINT, _In_ WPARAM, _In_ LPARAM)
BOOL WINAPI SetRect(_Out_ LPRECT, _In_ int, _In_ int, _In_ int, _In_ int)
INT_PTR WINAPI DialogBoxParamW(_In_opt_ HINSTANCE, _In_ LPCWSTR, _In_opt_ HWND, _In_opt_ DLGPROC, _In_ LPARAM)
BOOL WINAPI DestroyIcon(_In_ HICON)
#define TOKEN_ADJUST_PRIVILEGES
#define SE_PRIVILEGE_ENABLED