// Author: Vadim Zeitlin
// Modified by:
// Created: 31.01.99
-// RCS-ID: $Id$
// Copyright: (c) 1999 Vadim Zeitlin
// Licence: wxWindows licence
///////////////////////////////////////////////////////////////////////////////
// NMTTDISPINFO struct -- and setting the tooltip here we can have tooltips
// of any length
ti.hwnd = hwnd;
- ti.lpszText = const_cast<wxChar *>(m_text.wx_str());
+ ti.lpszText = wxMSW_CONV_LPTSTR(m_text);
if ( !SendTooltipMessage(GetToolTipCtrl(), TTM_ADDTOOL, &ti) )
{
const wxString token = tokenizer.GetNextToken();
SIZE sz;
- if ( !::GetTextExtentPoint32(hdc, token.wx_str(),
+ if ( !::GetTextExtentPoint32(hdc, token.t_str(),
token.length(), &sz) )
{
wxLogLastError(wxT("GetTextExtentPoint32"));
// replace the '\n's with spaces because otherwise they appear as
// unprintable characters in the tooltip string
m_text.Replace(wxT("\n"), wxT(" "));
- ti.lpszText = const_cast<wxChar *>(m_text.wx_str());
+ ti.lpszText = wxMSW_CONV_LPTSTR(m_text);
if ( !SendTooltipMessage(GetToolTipCtrl(), TTM_ADDTOOL, &ti) )
{
// add the window itself
if ( m_window )
{
- AddOtherWindow(m_window->GetHWND());
+ DoAddHWND(m_window->GetHWND());
}
#if !defined(__WXUNIVERSAL__)
// and all of its subcontrols (e.g. radio buttons in a radiobox) as well
ti.lpszText = const_cast<wxChar *>(wxT(""));
(void)SendTooltipMessage(GetToolTipCtrl(), TTM_UPDATETIPTEXT, &ti);
- ti.lpszText = const_cast<wxChar *>(m_text.wx_str());
+ ti.lpszText = wxMSW_CONV_LPTSTR(m_text);
(void)SendTooltipMessage(GetToolTipCtrl(), TTM_UPDATETIPTEXT, &ti);
}