Greetings,
Help wanted Re: http://bugs.winehq.org/show_bug.cgi?id=3023
Short summary: Commenting line 934 of dlls/user32/dialog.c in EndDialog makes OrCad usable.
EndDialog( HWND hwnd, INT_PTR retval ) { ... // comment the following line if (hwnd == GetActiveWindow()) WINPOS_ActivateOtherWindow( hwnd ); ... }
MSDN says "HWND A handle to the dialog box to be destroyed.
Dialog boxes created by the DialogBox, DialogBoxParam, DialogBoxIndirect, and DialogBoxIndirectParam functions must be destroyed using the EndDialog function. An application calls EndDialog from within the dialog box procedure; the function must not be used for any other purpose. "
Now, can anybody explain what the purpose of the suspect line is? or what possible bad things might happen if it was removed.
I have run Wine for several years with this one line patch, and seen no ill effects AFAIK.
If removing the line completely is not an option, is there a way to conditinally avoid executing it based on environment or registry? eg if (!ALLOW_ORCAD_TO_WORK) { original code }
thanks