Fix bug #166 ('FileDialog returns empty string or error in run from the start menu').

svn path=/trunk/; revision=7809
This commit is contained in:
Filip Navara 2004-01-21 18:38:53 +00:00
parent 593f004966
commit 74722e09f0

View file

@ -240,12 +240,13 @@ INT_PTR CALLBACK RunDlgProc (HWND hwnd, UINT message, WPARAM wParam, LPARAM lPar
return TRUE ;
}
ofnProc (&ofn) ;
SetFocus (GetDlgItem (hwnd, IDOK)) ;
SetWindowTextA (GetDlgItem (hwnd, 12298), szFName) ;
SendMessageA (GetDlgItem (hwnd, 12298), CB_SETEDITSEL, 0, MAKELPARAM (0, -1)) ;
SetFocus (GetDlgItem (hwnd, IDOK)) ;
if (ofnProc (&ofn))
{
SetFocus (GetDlgItem (hwnd, IDOK)) ;
SetWindowTextA (GetDlgItem (hwnd, 12298), szFName) ;
SendMessageA (GetDlgItem (hwnd, 12298), CB_SETEDITSEL, 0, MAKELPARAM (0, -1)) ;
SetFocus (GetDlgItem (hwnd, IDOK)) ;
}
FreeLibrary (hComdlg) ;