Commit 7311a9fc authored by David Hedberg's avatar David Hedberg Committed by Alexandre Julliard

comdlg32: Populate psia_results before making any callbacks.

parent 062f92a9
...@@ -536,9 +536,6 @@ static HRESULT on_default_action(FileDialogImpl *This) ...@@ -536,9 +536,6 @@ static HRESULT on_default_action(FileDialogImpl *This)
break; break;
case ONOPEN_OPEN: case ONOPEN_OPEN:
if(events_OnFileOk(This) != S_OK)
break;
hr = SHGetDesktopFolder(&psf_desktop); hr = SHGetDesktopFolder(&psf_desktop);
if(SUCCEEDED(hr)) if(SUCCEEDED(hr))
{ {
...@@ -547,10 +544,11 @@ static HRESULT on_default_action(FileDialogImpl *This) ...@@ -547,10 +544,11 @@ static HRESULT on_default_action(FileDialogImpl *This)
hr = SHCreateShellItemArray(NULL, psf_desktop, file_count, (PCUITEMID_CHILD_ARRAY)pidla, hr = SHCreateShellItemArray(NULL, psf_desktop, file_count, (PCUITEMID_CHILD_ARRAY)pidla,
&This->psia_results); &This->psia_results);
if(SUCCEEDED(hr))
ret = S_OK;
IShellFolder_Release(psf_desktop); IShellFolder_Release(psf_desktop);
if(SUCCEEDED(hr) && events_OnFileOk(This) == S_OK)
ret = S_OK;
} }
break; break;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment