shell32: RunFileDlg: use symbolic constants for control IDs and use correct hInstance when creating it.
This commit is contained in:
parent
032423760d
commit
13866e81f7
|
@ -111,8 +111,7 @@ void WINAPI RunFileDlgW(
|
|||
return;
|
||||
}
|
||||
|
||||
DialogBoxIndirectParamW((HINSTANCE)GetWindowLongPtrW( hwndOwner,
|
||||
GWLP_HINSTANCE ),
|
||||
DialogBoxIndirectParamW(shell32_hInstance,
|
||||
template, hwndOwner, RunDlgProc, (LPARAM)&rfdp);
|
||||
|
||||
}
|
||||
|
@ -130,8 +129,8 @@ static INT_PTR CALLBACK RunDlgProc (HWND hwnd, UINT message, WPARAM wParam, LPAR
|
|||
SetClassLongPtrW (hwnd, GCLP_HICON, (LPARAM)prfdp->hIcon) ;
|
||||
SendMessageW (GetDlgItem (hwnd, 12297), STM_SETICON,
|
||||
(WPARAM)LoadIconW (NULL, (LPCWSTR)IDI_WINLOGO), 0);
|
||||
FillList (GetDlgItem (hwnd, 12298), NULL) ;
|
||||
SetFocus (GetDlgItem (hwnd, 12298)) ;
|
||||
FillList (GetDlgItem (hwnd, IDC_RUNDLG_EDITPATH), NULL) ;
|
||||
SetFocus (GetDlgItem (hwnd, IDC_RUNDLG_EDITPATH)) ;
|
||||
return TRUE ;
|
||||
|
||||
case WM_COMMAND :
|
||||
|
@ -140,7 +139,7 @@ static INT_PTR CALLBACK RunDlgProc (HWND hwnd, UINT message, WPARAM wParam, LPAR
|
|||
case IDOK :
|
||||
{
|
||||
int ic ;
|
||||
HWND htxt = GetDlgItem (hwnd, 12298); /* edit control */
|
||||
HWND htxt = GetDlgItem (hwnd, IDC_RUNDLG_EDITPATH);
|
||||
if ((ic = GetWindowTextLengthW (htxt)))
|
||||
{
|
||||
WCHAR *psz ;
|
||||
|
@ -181,7 +180,7 @@ static INT_PTR CALLBACK RunDlgProc (HWND hwnd, UINT message, WPARAM wParam, LPAR
|
|||
EndDialog (hwnd, 0) ;
|
||||
return TRUE ;
|
||||
|
||||
case 12288 :
|
||||
case IDC_RUNDLG_BROWSE :
|
||||
{
|
||||
HMODULE hComdlg = NULL ;
|
||||
LPFNOFN ofnProc = NULL ;
|
||||
|
|
|
@ -159,10 +159,10 @@ FONT 8, "MS Shell Dlg"
|
|||
ICON "", 12297, 7, 11, 18, 20, WS_VISIBLE
|
||||
LTEXT "Type the name of a program, folder, document, or Internet resource, and Wine will open it for you.", 12289, 36, 11, 182, 18
|
||||
LTEXT "&Open:", 12305, 7, 39, 24, 10
|
||||
CONTROL "", 12298, "COMBOBOX", WS_TABSTOP | WS_GROUP | WS_VSCROLL | WS_VISIBLE | CBS_DISABLENOSCROLL | CBS_AUTOHSCROLL | CBS_DROPDOWN, 36, 37, 183, 100
|
||||
CONTROL "", IDC_RUNDLG_EDITPATH, "COMBOBOX", WS_TABSTOP | WS_GROUP | WS_VSCROLL | WS_VISIBLE | CBS_DISABLENOSCROLL | CBS_AUTOHSCROLL | CBS_DROPDOWN, 36, 37, 183, 100
|
||||
DEFPUSHBUTTON "OK", IDOK, 62, 63, 50, 14, WS_TABSTOP
|
||||
PUSHBUTTON "Cancel", IDCANCEL, 116, 63, 50, 14, WS_TABSTOP
|
||||
PUSHBUTTON "&Browse...", 12288, 170, 63, 50, 14, WS_TABSTOP
|
||||
PUSHBUTTON "&Browse...", IDC_RUNDLG_BROWSE, 170, 63, 50, 14, WS_TABSTOP
|
||||
}
|
||||
|
||||
STRINGTABLE
|
||||
|
|
|
@ -172,4 +172,8 @@ FIXME: Need to add them, but for now just let them use the same: searching.avi
|
|||
#define IDC_ABOUT_STATIC_TEXT2 101
|
||||
#define IDC_ABOUT_STATIC_TEXT3 102
|
||||
|
||||
/* run dialog */
|
||||
#define IDC_RUNDLG_BROWSE 12288
|
||||
#define IDC_RUNDLG_EDITPATH 12298
|
||||
|
||||
#endif
|
||||
|
|
Loading…
Reference in New Issue