no changes, just some minor cleanup
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@59367 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -325,14 +325,15 @@ void wxToolTip::Add(WXHWND hWnd)
|
||||
// NMTTDISPINFO struct -- and setting the tooltip here we can have tooltips
|
||||
// of any length
|
||||
ti.hwnd = hwnd;
|
||||
ti.lpszText = (wxChar *)m_text.wx_str(); // const_cast
|
||||
ti.lpszText = const_cast<wxChar *>(m_text.wx_str());
|
||||
|
||||
if ( !SendTooltipMessage(GetToolTipCtrl(), TTM_ADDTOOL, &ti) )
|
||||
{
|
||||
wxLogDebug(_T("Failed to create the tooltip '%s'"), m_text.c_str());
|
||||
|
||||
return;
|
||||
}
|
||||
else
|
||||
{
|
||||
|
||||
#ifdef TTM_SETMAXTIPWIDTH
|
||||
if ( wxApp::GetComCtl32Version() >= 470 )
|
||||
{
|
||||
@@ -411,14 +412,13 @@ void wxToolTip::Add(WXHWND hWnd)
|
||||
// replace the '\n's with spaces because otherwise they appear as
|
||||
// unprintable characters in the tooltip string
|
||||
m_text.Replace(_T("\n"), _T(" "));
|
||||
ti.lpszText = (wxChar *)m_text.wx_str(); // const_cast
|
||||
ti.lpszText = const_cast<wxChar *>(m_text.wx_str());
|
||||
|
||||
if ( !SendTooltipMessage(GetToolTipCtrl(), TTM_ADDTOOL, &ti) )
|
||||
{
|
||||
wxLogDebug(_T("Failed to create the tooltip '%s'"), m_text.c_str());
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
void wxToolTip::SetWindow(wxWindow *win)
|
||||
|
Reference in New Issue
Block a user