ReactOS 0.4.16-dev-2491-g3dc6630
settingsdlg.cpp
Go to the documentation of this file.
1/*
2 * PROJECT: ReactOS Applications Manager
3 * LICENSE: GPL-2.0-or-later (https://spdx.org/licenses/GPL-2.0-or-later)
4 * PURPOSE: Settings Dialog
5 * COPYRIGHT: Copyright 2009 Dmitry Chapyshev (dmitry@reactos.org)
6 * Copyright 2017 Alexander Shaposhnikov (sanchaez@reactos.org)
7 */
8#include "rapps.h"
9
11
12static int CALLBACK
14{
15 switch (uMsg)
16 {
19 break;
21 return TRUE;
22 }
23 return 0;
24}
25
26static BOOL
28{
29 BOOL bRet = FALSE;
30 BROWSEINFOW bi;
31 CStringW szChooseFolderText;
32
33 szChooseFolderText.LoadStringW(IDS_CHOOSE_FOLDER_TEXT);
34
35 ZeroMemory(&bi, sizeof(bi));
36 bi.hwndOwner = hwnd;
37 bi.pidlRoot = NULL;
38 bi.lpszTitle = szChooseFolderText;
39 bi.ulFlags =
40 BIF_USENEWUI | BIF_DONTGOBELOWDOMAIN | BIF_RETURNONLYFSDIRS | /* BIF_BROWSEFILEJUNCTIONS | */ BIF_VALIDATE;
41
43 {
44 WCHAR szDir[MAX_PATH];
46 {
48 bi.lParam = (LPARAM)szDir;
49 }
50
51 LPITEMIDLIST lpItemList = SHBrowseForFolderW(&bi);
52 if (lpItemList && SHGetPathFromIDListW(lpItemList, szDir))
53 {
54 if (*szDir)
55 {
57 bRet = TRUE;
58 }
59 }
60
61 CoTaskMemFree(lpItemList);
63 }
64
65 return bRet;
66}
67
68static BOOL
69IsUrlValid(const WCHAR *Url)
70{
71 URL_COMPONENTSW UrlComponmentInfo = {0};
72 UrlComponmentInfo.dwStructSize = sizeof(UrlComponmentInfo);
73 UrlComponmentInfo.dwSchemeLength = 1;
74
75 BOOL bSuccess = InternetCrackUrlW(Url, wcslen(Url), 0, &UrlComponmentInfo);
76 if (!bSuccess)
77 {
78 return FALSE;
79 }
80
81 switch (UrlComponmentInfo.nScheme)
82 {
87 // supported
88 return TRUE;
89
90 default:
91 return FALSE;
92 }
93}
94
95namespace
96{
97static inline BOOL
99{
101}
102
103static inline void
105{
107}
108
109static void
111{
113 const struct {
114 WORD Id;
115 BOOL *Setting;
116 } Map[] = {
117 { IDS_CFG_SAVE_WINDOW_POS, &Info->bSaveWndPos },
118 { IDS_CFG_UPDATE_AVLIST, &Info->bUpdateAtStart },
119 { IDS_CFG_LOG_ENABLED, &Info->bLogEnabled },
120 { IDS_CFG_SMALL_ICONS, &Info->bSmallIcons },
121 };
122
124 {
127 LVCOLUMN lvc;
128 lvc.mask = LVCF_TEXT | LVCF_SUBITEM;
129 lvc.iSubItem = 0;
130 lvc.pszText = const_cast<PWSTR>(L"");
132
134 for (SIZE_T i = 0; i < _countof(Map); ++i)
135 {
137 Item.mask = LVIF_TEXT | LVIF_PARAM;
138 Item.iItem = 0x7fff;
139 Item.iSubItem = 0;
140 Item.lParam = Map[i].Id;
141 Name.LoadStringW(Map[i].Id);
142 Item.pszText = const_cast<PWSTR>(Name.GetString());
144 }
147 }
148
149 for (SIZE_T i = 0; i < _countof(Map); ++i)
150 {
151 LVFINDINFOW FindInfo = { LVFI_PARAM, NULL, Map[i].Id };
152 int Idx = ListView_FindItem(hWndList, -1, &FindInfo);
153 if (Idx >= 0)
154 {
155 if (Load)
156 {
157 ListView_SetCheckState(hWndList, Idx, *Map[i].Setting);
158 }
159 else
160 {
161 *Map[i].Setting = ListView_GetCheckState(hWndList, Idx);
162 }
163 }
164 }
165}
166
167static VOID
169{
172
174 SetWindowTextW(hCtl, Info->szDownloadDir);
175 SendMessageW(hCtl, EM_LIMITTEXT, MAX_PATH - 1, 0);
176
178
179 if (Info->Proxy == 2)
180 {
183 }
184 else
185 {
188 }
189
191
192 EnableWindow(GetDlgItem(hDlg, IDC_SOURCE_URL), Info->bUseSource);
193
194 SetWindowTextW(GetDlgItem(hDlg, IDC_SOURCE_URL), Info->szSourceURL);
195 SetWindowTextW(GetDlgItem(hDlg, IDC_PROXY_SERVER), Info->szProxyServer);
196 SetWindowTextW(GetDlgItem(hDlg, IDC_NO_PROXY_FOR), Info->szNoProxyFor);
197}
198
199static INT_PTR CALLBACK
201{
202 SETTINGS_INFO &NewSettingsInfo = *g_pNewSettingsInfo;
203
204 switch (Msg)
205 {
206 case WM_INITDIALOG:
208 return TRUE;
209
210 case WM_SETTINGCHANGE:
211 case WM_THEMECHANGED:
215 break;
216
217 case WM_COMMAND:
218 {
219 switch (LOWORD(wParam))
220 {
221 case IDC_CHOOSE:
222 ChooseFolder(hDlg);
223 break;
224
227 break;
228
230 NewSettingsInfo.bUseSource = FALSE;
231 EnableWindow(GetDlgItem(hDlg, IDC_SOURCE_URL), NewSettingsInfo.bUseSource);
232 break;
233
234 case IDC_USE_SOURCE:
235 NewSettingsInfo.bUseSource = TRUE;
236 EnableWindow(GetDlgItem(hDlg, IDC_SOURCE_URL), NewSettingsInfo.bUseSource);
237 break;
238
240 NewSettingsInfo.Proxy = 0;
243 break;
244
245 case IDC_NO_PROXY:
246 NewSettingsInfo.Proxy = 1;
249 break;
250
251 case IDC_USE_PROXY:
252 NewSettingsInfo.Proxy = 2;
255 break;
256
258 FillDefaultSettings(&NewSettingsInfo);
259 InitSettingsControls(hDlg, &NewSettingsInfo);
260 break;
261
262 case IDOK:
263 {
264 HandleGeneralListItems(GetDlgItem(hDlg, IDC_GENERALLIST), NULL, &NewSettingsInfo);
265
266 CStringW szDir;
267 CStringW szSource;
268 CStringW szProxy;
269 CStringW szNoProxy;
270 DWORD dwAttr;
271
273 szDir.ReleaseBuffer();
274
278 szSource.ReleaseBuffer();
279
281 szProxy.ReleaseBuffer();
283 NewSettingsInfo.szProxyServer, _countof(NewSettingsInfo.szProxyServer), szProxy,
284 szProxy.GetLength() + 1);
285
287 szNoProxy.ReleaseBuffer();
289 NewSettingsInfo.szNoProxyFor, _countof(NewSettingsInfo.szNoProxyFor), szNoProxy,
290 szNoProxy.GetLength() + 1);
291
293 NewSettingsInfo.szDownloadDir, _countof(NewSettingsInfo.szDownloadDir), szDir,
294 szDir.GetLength() + 1);
295 dwAttr = GetFileAttributesW(szDir);
296 if (dwAttr == INVALID_FILE_ATTRIBUTES || !(dwAttr & FILE_ATTRIBUTE_DIRECTORY))
297 {
298 CStringW szMsgText;
299 szMsgText.LoadStringW(IDS_CHOOSE_FOLDER_ERROR);
300
301 if (MessageBoxW(hDlg, szMsgText, NULL, MB_YESNO) == IDYES)
302 {
303 if (!CreateDirectoryW(szDir, NULL))
304 {
305 ErrorBox(hDlg);
306 break;
307 }
308 }
309 else
310 {
312 break;
313 }
314 }
315
316 if (NewSettingsInfo.bUseSource && !IsUrlValid(szSource))
317 {
318 CStringW szMsgText;
319 szMsgText.LoadStringW(IDS_URL_INVALID);
320
321 MessageBoxW(hDlg, szMsgText, NULL, MB_OK);
323 break;
324 }
325 else
326 {
328 NewSettingsInfo.szSourceURL, _countof(NewSettingsInfo.szSourceURL), szSource,
329 szSource.GetLength() + 1);
330 }
331
332 if (SettingsInfo.bSmallIcons != NewSettingsInfo.bSmallIcons)
333 {
334 SendMessageW(hMainWnd, WM_SETTINGCHANGE, SPI_SETICONMETRICS, 0); // Note: WM_SETTINGCHANGE cannot be posted
336 }
337 SettingsInfo = NewSettingsInfo;
339 EndDialog(hDlg, LOWORD(wParam));
340 }
341 break;
342
343 case IDCANCEL:
344 EndDialog(hDlg, LOWORD(wParam));
345 break;
346 }
347 break;
348 }
349
350 case WM_NOTIFY:
351 {
353 if (wParam == IDC_GENERALLIST && nmia.hdr.code == NM_CLICK)
354 {
355 LVHITTESTINFO lvhti;
356 lvhti.pt = nmia.ptAction;
357 if (nmia.iItem != -1 && ListView_HitTest(nmia.hdr.hwndFrom, &lvhti) != -1)
358 {
359 if (lvhti.flags & (LVHT_ONITEMICON | LVHT_ONITEMLABEL))
362 }
363 }
364 break;
365 }
366 }
367
368 return FALSE;
369}
370} // namespace
371
372VOID
374{
375 SETTINGS_INFO NewSettingsInfo = SettingsInfo;
376 g_pNewSettingsInfo = &NewSettingsInfo;
377
379}
DWORD Id
static HWND hWndList[5+1]
Definition: SetParent.c:10
const DWORD ExStyle
Definition: appswitch.c:73
void SaveSettings(void)
Definition: settings.c:115
#define ID_REFRESH
Definition: resource.h:16
#define IDC_PROXY_SERVER
Definition: resource.h:57
#define IDC_NO_PROXY
Definition: resource.h:55
#define IDS_URL_INVALID
Definition: resource.h:111
#define IDS_CFG_LOG_ENABLED
Definition: resource.h:133
#define IDC_USE_SOURCE
Definition: resource.h:60
#define IDC_DEL_AFTER_INSTALL
Definition: resource.h:47
#define IDS_CFG_UPDATE_AVLIST
Definition: resource.h:132
#define IDC_NO_PROXY_FOR
Definition: resource.h:58
#define IDC_USE_PROXY
Definition: resource.h:56
#define IDD_SETTINGS_DIALOG
Definition: resource.h:64
#define IDC_PROXY_DEFAULT
Definition: resource.h:54
#define IDS_CHOOSE_FOLDER_TEXT
Definition: resource.h:109
#define IDC_CHOOSE
Definition: resource.h:49
#define IDS_CFG_SMALL_ICONS
Definition: resource.h:134
#define IDC_GENERALLIST
Definition: resource.h:44
#define IDC_DEFAULT_SETTINGS
Definition: resource.h:50
#define IDS_CFG_SAVE_WINDOW_POS
Definition: resource.h:131
#define IDC_SOURCE_URL
Definition: resource.h:61
#define IDC_DOWNLOAD_DIR_EDIT
Definition: resource.h:46
#define IDC_SOURCE_DEFAULT
Definition: resource.h:59
#define IDS_CHOOSE_FOLDER_ERROR
Definition: resource.h:110
SETTINGS_INFO SettingsInfo
Definition: winmain.cpp:21
VOID FillDefaultSettings(PSETTINGS_INFO pSettingsInfo)
Definition: settings.cpp:211
EXTERN_C LPITEMIDLIST WINAPI SHBrowseForFolderW(LPBROWSEINFOW lpbi)
Definition: brfolder.cpp:1460
static void __cdecl CopyChars(_Out_writes_to_(nDestLen, nChars) XCHAR *pchDest, _In_ size_t nDestLen, _In_reads_opt_(nChars) const XCHAR *pchSrc, _In_ int nChars) noexcept
Definition: atlsimpstr.h:438
void ReleaseBuffer(_In_ int nNewLength=-1)
Definition: atlsimpstr.h:387
int GetLength() const noexcept
Definition: atlsimpstr.h:362
WPARAM wParam
Definition: combotst.c:138
LPARAM lParam
Definition: combotst.c:139
struct @1751 Msg[]
LPWSTR Name
Definition: desk.c:124
#define NULL
Definition: types.h:112
#define TRUE
Definition: types.h:120
#define FALSE
Definition: types.h:117
void WINAPI DECLSPEC_HOTPATCH CoUninitialize(void)
Definition: combase.c:2842
#define MAX_PATH
Definition: compat.h:34
#define CALLBACK
Definition: compat.h:35
BOOL WINAPI CreateDirectoryW(IN LPCWSTR lpPathName, IN LPSECURITY_ATTRIBUTES lpSecurityAttributes)
Definition: dir.c:58
DWORD WINAPI GetFileAttributesW(LPCWSTR lpFileName)
Definition: fileinfo.c:636
_ACRTIMP size_t __cdecl wcslen(const wchar_t *)
Definition: wcs.c:2983
HRESULT WINAPI CoInitialize(LPVOID lpReserved)
Definition: compobj.c:531
BOOL WINAPI InternetCrackUrlW(const WCHAR *lpszUrl, DWORD dwUrlLength, DWORD dwFlags, URL_COMPONENTSW *lpUC)
Definition: internet.c:1625
#define L(x)
Definition: resources.c:13
HINSTANCE hInst
Definition: dxdiag.c:13
unsigned short WORD
Definition: ntddk_ex.h:93
unsigned int BOOL
Definition: ntddk_ex.h:94
unsigned long DWORD
Definition: ntddk_ex.h:95
static UINT ErrorBox(UINT Error=GetLastError())
Definition: geninst.cpp:198
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble const GLfloat const GLdouble const GLfloat GLint i
Definition: glfuncs.h:248
#define SUCCEEDED(hr)
Definition: intsafe.h:50
static HRESULT Load(IUnknown *pUnk, IStream *pStream)
Definition: lnktool.cpp:294
HWND hMainWnd
Definition: magnifier.c:32
void WINAPI CoTaskMemFree(void *ptr)
Definition: malloc.c:389
#define ZeroMemory
Definition: minwinbase.h:31
LONG_PTR LPARAM
Definition: minwindef.h:175
UINT_PTR WPARAM
Definition: minwindef.h:174
static void HandleGeneralListItems(HWND hWndList, PSETTINGS_INFO Load, PSETTINGS_INFO Save)
static void AdjustListViewHeader(HWND hWndList)
static INT_PTR CALLBACK SettingsDlgProc(HWND hDlg, UINT Msg, WPARAM wParam, LPARAM lParam)
static BOOL IsCheckedDlgItem(HWND hDlg, INT nIDDlgItem)
Definition: settingsdlg.cpp:98
static VOID InitSettingsControls(HWND hDlg, PSETTINGS_INFO Info)
unsigned int UINT
Definition: ndis.h:50
#define FILE_ATTRIBUTE_DIRECTORY
Definition: nt_native.h:705
#define LOWORD(l)
Definition: pedump.c:82
BOOL WINAPI SHGetPathFromIDListW(LPCITEMIDLIST pidl, LPWSTR pszPath)
Definition: pidl.c:1496
#define ListView_InsertItem(hwnd, pitem)
Definition: commctrl.h:2413
#define ListView_SetItemState(hwndLV, i, data, mask)
Definition: commctrl.h:2678
#define ListView_SetExtendedListViewStyleEx(hwndLV, dwMask, dw)
Definition: commctrl.h:2731
#define LVS_EX_LABELTIP
Definition: commctrl.h:2748
#define ListView_InsertColumn(hwnd, iCol, pcol)
Definition: commctrl.h:2641
#define ListView_SetCheckState(hwndLV, i, fCheck)
Definition: commctrl.h:2679
#define LVFI_PARAM
Definition: commctrl.h:2441
#define ListView_HitTest(hwndLV, pinfo)
Definition: commctrl.h:2521
#define ListView_SetColumnWidth(hwnd, iCol, cx)
Definition: commctrl.h:2653
#define LVS_EX_CHECKBOXES
Definition: commctrl.h:2736
#define NM_CLICK
Definition: commctrl.h:130
#define ListView_GetItemCount(hwnd)
Definition: commctrl.h:2312
#define LVIS_SELECTED
Definition: commctrl.h:2324
#define LVIF_PARAM
Definition: commctrl.h:2316
#define LVHT_ONITEMICON
Definition: commctrl.h:2499
#define LVIF_TEXT
Definition: commctrl.h:2314
#define LVCF_SUBITEM
Definition: commctrl.h:2594
#define ListView_GetCheckState(hwndLV, i)
Definition: commctrl.h:2682
#define LVSCW_AUTOSIZE_USEHEADER
Definition: commctrl.h:2650
#define LVCF_TEXT
Definition: commctrl.h:2593
#define LVIS_FOCUSED
Definition: commctrl.h:2323
#define LVHT_ONITEMLABEL
Definition: commctrl.h:2500
#define ListView_FindItem(hwnd, iStart, plvfi)
Definition: commctrl.h:2475
#define LVCOLUMN
Definition: commctrl.h:2586
#define WM_NOTIFY
Definition: richedit.h:61
static BOOL ChooseFolder(HWND hwnd)
Definition: settingsdlg.cpp:27
SETTINGS_INFO * g_pNewSettingsInfo
Definition: settingsdlg.cpp:10
VOID CreateSettingsDlg(HWND hwnd)
static int CALLBACK BrowseFolderCallback(HWND hwnd, UINT uMsg, LPARAM lParam, LPARAM lpData)
Definition: settingsdlg.cpp:13
static BOOL IsUrlValid(const WCHAR *Url)
Definition: settingsdlg.cpp:69
#define BIF_VALIDATE
Definition: shlobj.h:1229
#define BIF_DONTGOBELOWDOMAIN
Definition: shlobj.h:1225
#define BIF_RETURNONLYFSDIRS
Definition: shlobj.h:1224
#define BFFM_VALIDATEFAILED
Definition: shlobj.h:1264
#define BIF_USENEWUI
Definition: shlobj.h:1231
#define BFFM_SETSELECTIONW
Definition: shlobj.h:1253
#define BFFM_INITIALIZED
Definition: shlobj.h:1243
ITEMIDLIST UNALIGNED * LPITEMIDLIST
Definition: shtypes.idl:41
#define _countof(array)
Definition: sndvol32.h:70
WCHAR szDownloadDir[MAX_PATH]
Definition: settings.h:10
BOOL bUseSource
Definition: settings.h:24
BOOL bDelInstaller
Definition: settings.h:11
WCHAR szSourceURL[INTERNET_MAX_URL_LENGTH]
Definition: settings.h:25
WCHAR szNoProxyFor[MAX_PATH]
Definition: settings.h:22
BOOL bSmallIcons
Definition: settings.h:12
WCHAR szProxyServer[MAX_PATH]
Definition: settings.h:21
DWORD dwStructSize
Definition: wininet.h:211
INTERNET_SCHEME nScheme
Definition: wininet.h:214
DWORD dwSchemeLength
Definition: wininet.h:213
BFFCALLBACK lpfn
Definition: shlobj.h:1212
PCIDLIST_ABSOLUTE pidlRoot
Definition: shlobj.h:1208
UINT ulFlags
Definition: shlobj.h:1211
HWND hwndOwner
Definition: shlobj.h:1207
LPCWSTR lpszTitle
Definition: shlobj.h:1210
LPARAM lParam
Definition: shlobj.h:1213
UINT code
Definition: winuser.h:3267
HWND hwndFrom
Definition: winuser.h:3265
uint16_t * PWSTR
Definition: typedefs.h:56
int32_t INT_PTR
Definition: typedefs.h:64
ULONG_PTR SIZE_T
Definition: typedefs.h:80
int32_t INT
Definition: typedefs.h:58
#define INVALID_FILE_ATTRIBUTES
Definition: vfdcmd.c:23
static int Save(const char **args)
Definition: vfdcmd.c:1851
_Must_inspect_result_ _In_ WDFCHILDLIST _In_ PWDF_CHILD_LIST_ITERATOR _Out_ WDFDEVICE _Inout_opt_ PWDF_CHILD_RETRIEVE_INFO Info
Definition: wdfchildlist.h:690
_In_ WDFCOLLECTION _In_ WDFOBJECT Item
int WINAPI GetWindowTextW(HWND hWnd, LPWSTR lpString, int nMaxCount)
Definition: window.c:1382
_In_ LONG _In_ HWND hwnd
Definition: winddi.h:4023
#define INTERNET_SCHEME_FTP
Definition: winhttp.h:49
#define INTERNET_SCHEME_HTTP
Definition: winhttp.h:47
#define INTERNET_SCHEME_HTTPS
Definition: winhttp.h:48
#define INTERNET_MAX_URL_LENGTH
Definition: wininet.h:51
@ INTERNET_SCHEME_FILE
Definition: wininet.h:143
#define EM_LIMITTEXT
Definition: winuser.h:2029
#define IDCANCEL
Definition: winuser.h:842
BOOL WINAPI PostMessageW(_In_opt_ HWND, _In_ UINT, _In_ WPARAM, _In_ LPARAM)
#define DialogBoxW(i, t, p, f)
Definition: winuser.h:4553
#define WM_COMMAND
Definition: winuser.h:1768
BOOL WINAPI SetDlgItemTextW(_In_ HWND, _In_ int, _In_ LPCWSTR)
#define WM_INITDIALOG
Definition: winuser.h:1767
#define MB_YESNO
Definition: winuser.h:828
#define WM_SYSCOLORCHANGE
Definition: winuser.h:1654
int WINAPI MessageBoxW(_In_opt_ HWND hWnd, _In_opt_ LPCWSTR lpText, _In_opt_ LPCWSTR lpCaption, _In_ UINT uType)
HWND WINAPI GetDlgItem(_In_opt_ HWND, _In_ int)
#define IDOK
Definition: winuser.h:841
#define BM_SETCHECK
Definition: winuser.h:1950
LRESULT WINAPI SendDlgItemMessageW(_In_ HWND, _In_ int, _In_ UINT, _In_ WPARAM, _In_ LPARAM)
BOOL WINAPI SetWindowTextW(_In_ HWND, _In_opt_ LPCWSTR)
#define WM_SETTINGCHANGE
Definition: winuser.h:1657
HWND WINAPI SetFocus(_In_opt_ HWND)
#define SendMessage
Definition: winuser.h:6009
BOOL WINAPI EnableWindow(_In_ HWND, _In_ BOOL)
#define MB_OK
Definition: winuser.h:801
HWND WINAPI GetParent(_In_ HWND)
BOOL WINAPI CheckRadioButton(_In_ HWND, _In_ int, _In_ int, _In_ int)
_In_ int nIDDlgItem
Definition: winuser.h:4773
#define MAKEINTRESOURCEW(i)
Definition: winuser.h:582
#define IDYES
Definition: winuser.h:846
LRESULT WINAPI SendMessageW(_In_ HWND, _In_ UINT, _In_ WPARAM, _In_ LPARAM)
#define BST_CHECKED
Definition: winuser.h:197
#define BM_GETCHECK
Definition: winuser.h:1947
BOOL WINAPI EndDialog(_In_ HWND, _In_ INT_PTR)
__wchar_t WCHAR
Definition: xmlstorage.h:180