Remove the tool tip if an empty or NULL string is set.
This commit is contained in:
@@ -4821,6 +4821,9 @@ BView::SetToolTip(const char* text)
|
|||||||
HideToolTip();
|
HideToolTip();
|
||||||
SetToolTip(static_cast<BToolTip*>(NULL));
|
SetToolTip(static_cast<BToolTip*>(NULL));
|
||||||
|
|
||||||
|
if (text == NULL || text[0] == '\0')
|
||||||
|
return;
|
||||||
|
|
||||||
if (BTextToolTip* tip = dynamic_cast<BTextToolTip*>(fToolTip))
|
if (BTextToolTip* tip = dynamic_cast<BTextToolTip*>(fToolTip))
|
||||||
tip->SetText(text);
|
tip->SetText(text);
|
||||||
else
|
else
|
||||||
|
|||||||
Reference in New Issue
Block a user