X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/14fca7389aa93dee91a68cd0a25789c2b4b42879..4aaef122cbbd5bbe0e70b824e320458e2329dd13:/src/msw/fdrepdlg.cpp?ds=inline diff --git a/src/msw/fdrepdlg.cpp b/src/msw/fdrepdlg.cpp index 13c4062c8c..5cc89364cd 100644 --- a/src/msw/fdrepdlg.cpp +++ b/src/msw/fdrepdlg.cpp @@ -197,10 +197,9 @@ void wxFindReplaceDialogImpl::SubclassDialog(HWND hwnd) // check that we don't subclass the parent twice: this would be a bad idea // as then we'd have infinite recursion in wxFindReplaceWindowProc - WNDPROC oldParentWndProc = (WNDPROC)::GetWindowLong(hwnd, GWL_WNDPROC); - - if ( oldParentWndProc != wxFindReplaceWindowProc ) + if ( !wxCheckWindowWndProc((WXHWND)hwnd, (WXFARPROC)wxFindReplaceWindowProc) ) { + WNDPROC oldParentWndProc = (WNDPROC)::GetWindowLong(hwnd, GWL_WNDPROC); // save old wnd proc elsewhere to access it from // wxFindReplaceWindowProc m_oldParentWndProc = oldParentWndProc;