diff --git a/private/tooltip.cpp b/private/tooltip.cpp index c22f5e45d..fecceb2da 100644 --- a/private/tooltip.cpp +++ b/private/tooltip.cpp @@ -68,7 +68,7 @@ void ToolTip::hideEvent(QHideEvent *e) { QWidget::hideEvent(e); if (d->source) { - QMetaObject::invokeMethod(d->source, SLOT(toolTipHidden())); + QMetaObject::invokeMethod(d->source, "toolTipHidden"); } } @@ -123,9 +123,9 @@ void ToolTip::setContent(const ToolTipManager::ToolTipContent &data) } } -void ToolTip::prepareShowing() +void ToolTip::prepareShowing(bool cueUpdate) { - if (d->source) { + if (cueUpdate && d->source) { QMetaObject::invokeMethod(d->source, "toolTipAboutToShow"); } @@ -138,7 +138,6 @@ void ToolTip::prepareShowing() layout()->activate(); resize(sizeHint()); - } void ToolTip::setActivated(bool value) diff --git a/private/tooltip_p.h b/private/tooltip_p.h index 9518fb3f9..610b02c76 100644 --- a/private/tooltip_p.h +++ b/private/tooltip_p.h @@ -39,7 +39,7 @@ public: void updateTheme(); void setContent(const ToolTipManager::ToolTipContent &data); - void prepareShowing(); + void prepareShowing(bool cueUpdate); void setActivated(bool value); bool isActivated();