From 74033e86bb44b9b4ad3fe8383ff71fdb73481a15 Mon Sep 17 00:00:00 2001 From: Vadim Zeitlin Date: Tue, 3 Nov 2009 14:11:01 +0000 Subject: [PATCH] Avoid redraws of the window under tooltip when its text is changed. Backport the change of r59198 (and correction from r59235) from trunk. Closes #10520. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/branches/WX_2_8_BRANCH@62542 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- src/msw/tooltip.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/msw/tooltip.cpp b/src/msw/tooltip.cpp index af75de2935..ebf8535b2d 100644 --- a/src/msw/tooltip.cpp +++ b/src/msw/tooltip.cpp @@ -453,8 +453,10 @@ void wxToolTip::SetTip(const wxString& tip) { // update the tip text shown by the control wxToolInfo ti(GetHwndOf(m_window)); - ti.lpszText = (wxChar *)m_text.c_str(); + ti.lpszText = (wxChar *)wxT(""); + (void)SendTooltipMessage(GetToolTipCtrl(), TTM_UPDATETIPTEXT, &ti); + ti.lpszText = (wxChar *)m_text.c_str(); (void)SendTooltipMessage(GetToolTipCtrl(), TTM_UPDATETIPTEXT, &ti); } }