+#if wxUSE_UNICODE_MSLU
+ static unsigned long s_lastMsgFlags = 0;
+
+ // This flag helps us to identify the bogus ANSI message
+ // sent by UNICOWS.DLL (see below)
+ // while we're sending our message to the dialog
+ // we ignore possible messages sent in between
+ static bool s_blockMsg = false;
+#endif // wxUSE_UNICODE_MSLU
+
+ wxASSERT_MSG( nMsg == ms_msgFindDialog, _T("unexpected message received") );
+
+ FINDREPLACE *pFR = (FINDREPLACE *)lParam;
+
+#if wxUSE_UNICODE_MSLU
+ // This is a hack for a MSLU problem: Versions up to 1.0.4011
+ // of UNICOWS.DLL send the correct UNICODE item after button press
+ // and a bogus ANSI mode item right after this, so lets ignore
+ // the second bogus message
+ if ( wxUsingUnicowsDll() && s_lastMsgFlags == pFR->Flags )