diff --git a/dlls/riched20/editor.c b/dlls/riched20/editor.c index 09feb960da4..93d0c34b9f8 100644 --- a/dlls/riched20/editor.c +++ b/dlls/riched20/editor.c @@ -2018,11 +2018,14 @@ ME_FilterEvent(ME_TextEditor *editor, UINT msg, WPARAM* wParam, LPARAM* lParam) { MSGFILTER msgf; + if (!editor->hWnd) return FALSE; + msgf.nmhdr.hwndFrom = editor->hWnd; + msgf.nmhdr.idFrom = GetWindowLongW(editor->hWnd, GWLP_ID); msgf.nmhdr.code = EN_MSGFILTER; msgf.msg = msg; msgf.wParam = *wParam; msgf.lParam = *lParam; - if (ITextHost_TxNotify(editor->texthost, msgf.nmhdr.code, &msgf) == S_OK) + if (SendMessageW(GetParent(editor->hWnd), WM_NOTIFY, msgf.nmhdr.idFrom, (LPARAM)&msgf)) return FALSE; *wParam = msgf.wParam; *lParam = msgf.lParam; diff --git a/dlls/riched20/txthost.c b/dlls/riched20/txthost.c index 5032e8729f6..8fabd8388d1 100644 --- a/dlls/riched20/txthost.c +++ b/dlls/riched20/txthost.c @@ -452,8 +452,6 @@ HRESULT WINAPI ITextHostImpl_TxNotify(ITextHost *iface, HWND parent = GetParent(hwnd); UINT id = GetWindowLongW(hwnd, GWLP_ID); - /* Note: EN_MSGFILTER is documented as not being sent to TxNotify */ - switch (iNotify) { case EN_DROPFILES: @@ -492,6 +490,9 @@ HRESULT WINAPI ITextHostImpl_TxNotify(ITextHost *iface, SendMessageW(parent, WM_COMMAND, MAKEWPARAM(id, iNotify), (LPARAM)hwnd); break; + case EN_MSGFILTER: + FIXME("EN_MSGFILTER is documented as not being sent to TxNotify\n"); + /* fall through */ default: return E_FAIL; }