From 4daa7647c99ff95c511def9875f1aa50acfd37e3 Mon Sep 17 00:00:00 2001 From: John Scipione Date: Thu, 3 May 2012 01:13:16 -0400 Subject: [PATCH] After setting the tooltip text, invalidate the layout. This fixes a bug introduced in hrev44075 (I think) where the internal tooltip window wouldn't resize itself after setting new tooltip text. So if you set the tooltip to a short string then set it to a long string the tooltip would get cut-off or if you set it to a long string and then set it to a short string the tooltip window would be too wide. The result can be seen in Deskbar in the following screenshot: http://30.media.tumblr.com/tumblr_m3fg327NsV1r0f0hfo1_400.png After invalidating the layout the internal tooltip window gets resized correctly. --- src/kits/interface/ToolTip.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/src/kits/interface/ToolTip.cpp b/src/kits/interface/ToolTip.cpp index 21db081c99..2885c4732e 100644 --- a/src/kits/interface/ToolTip.cpp +++ b/src/kits/interface/ToolTip.cpp @@ -207,6 +207,7 @@ BTextToolTip::SetText(const char* text) return; fTextView->SetText(text); + fTextView->InvalidateLayout(); Unlock(); }