Try to avoid sending a string through mbstowcs() when already Unicode
(added #if wxUSE_UNICODE etc). git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/branches/WX_2_2_BRANCH@6945 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -707,6 +707,9 @@ bool wxToolBar::MSWOnNotify(int WXUNUSED(idCtrl),
|
||||
}
|
||||
else
|
||||
{
|
||||
#if wxUSE_UNICODE
|
||||
ttText->lpszText = (wxChar *)help.c_str();
|
||||
#else
|
||||
// VZ: I don't know why it happens, but the versions of
|
||||
// comctl32.dll starting from 4.70 sometimes send TTN_NEEDTEXTW
|
||||
// even to ANSI programs (normally, this message is supposed
|
||||
@@ -733,6 +736,7 @@ bool wxToolBar::MSWOnNotify(int WXUNUSED(idCtrl),
|
||||
dst[lenUnicode] = 0;
|
||||
|
||||
delete [] pwz;
|
||||
#endif
|
||||
}
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user