[PATCH v3 2/3] msi: Disable parent dialogs while modal dialog is open
Fabian Maurer
dark.shadow4 at web.de
Sat Sep 11 18:56:59 CDT 2021
Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=51717
Signed-off-by: Fabian Maurer <dark.shadow4 at web.de>
---
v3: Add missing call to SetForegroundWindow
---
dlls/msi/dialog.c | 10 ++++++++++
1 file changed, 10 insertions(+)
diff --git a/dlls/msi/dialog.c b/dlls/msi/dialog.c
index 6463c3062ac..a99a9076946 100644
--- a/dlls/msi/dialog.c
+++ b/dlls/msi/dialog.c
@@ -3881,6 +3881,11 @@ static LRESULT WINAPI MSIDialog_WndProc( HWND hwnd, UINT msg,
return SendMessageW( (HWND) lParam, WM_CTLCOLORSTATIC, wParam, lParam );
case WM_DESTROY:
+ if (dialog->parent)
+ {
+ EnableWindow(dialog->parent->hwnd, TRUE);
+ SetForegroundWindow(dialog->parent->hwnd);
+ }
dialog->hwnd = NULL;
return 0;
case WM_NOTIFY:
@@ -3928,6 +3933,11 @@ static UINT dialog_run_message_loop( msi_dialog *dialog )
return ERROR_FUNCTION_FAILED;
}
+ if (parent)
+ {
+ EnableWindow(parent, FALSE);
+ }
+
ShowWindow( hwnd, SW_SHOW );
/* UpdateWindow( hwnd ); - and causes the transparent static controls not to paint */
--
2.33.0
More information about the wine-devel
mailing list