[PATCH] riched20: Process WM_GETMINMAXINFO which arrives before WM_NCCREATE.
austin.lund at gmail.com
Tue Jul 6 07:04:22 CDT 2010
On 6 July 2010 17:39, Dmitry Timoshkov <dmitry at codeweavers.com> wrote:
> Austin Lund <austin.lund at gmail.com> wrote:
>> --- a/dlls/riched20/editor.c
>> +++ b/dlls/riched20/editor.c
>> @@ -4406,7 +4406,7 @@ static LRESULT RichEditWndProc_common(HWND hWnd, UINT msg, WPARAM wParam,
>> texthost = ME_CreateTextHost(hWnd, pcs, FALSE);
>> return texthost != NULL;
>> - else if (msg != WM_NCDESTROY)
>> + else if ((msg != WM_NCDESTROY) && (msg != WM_GETMINMAXINFO))
>> ERR("called with invalid hWnd %p - application bug?\n", hWnd);
>> return 0;
> This code is completely broken. An app can decide to not even pass these
> messages to a subclassed richedit control.
I'm not sure how that's relevant because if the messages aren't passed
then as long as a WM_NCCREATE is passed then the editor variable is
initialised by this.
I'm reading this comment carefully for a suggestion as to how to "fix"
things, but it seems totally obfuscated.
More information about the wine-devel