win32 - record movie dialog - OK button doesn't work until user specifies a filename
This commit is contained in:
parent
7253fe7775
commit
aa8baf0686
|
@ -103,8 +103,11 @@ static BOOL CALLBACK RecordDialogProc(HWND hwndDlg, UINT uMsg, WPARAM wParam, LP
|
||||||
case IDOK: {
|
case IDOK: {
|
||||||
author = GetDlgItemTextW<500>(hwndDlg,IDC_EDIT_AUTHOR);
|
author = GetDlgItemTextW<500>(hwndDlg,IDC_EDIT_AUTHOR);
|
||||||
std::string fname = GetDlgItemText<MAX_PATH>(hwndDlg,IDC_EDIT_FILENAME);
|
std::string fname = GetDlgItemText<MAX_PATH>(hwndDlg,IDC_EDIT_FILENAME);
|
||||||
FCEUI_SaveMovie(fname.c_str(), author);
|
if (fname.length())
|
||||||
EndDialog(hwndDlg, 0);
|
{
|
||||||
|
FCEUI_SaveMovie(fname.c_str(), author);
|
||||||
|
EndDialog(hwndDlg, 0);
|
||||||
|
}
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue