[ToolTipArea] Add "aboutToShow" signal

This is emitted just before the tooltip is shown and allows the user to defer heavy lifting to when the dialog is actually shown.

Differential Revision: https://phabricator.kde.org/D10381
This commit is contained in:
Kai Uwe Broulik 2018-03-27 17:37:56 +02:00
parent 42d3fde1ee
commit e5dcc0b47f
2 changed files with 8 additions and 0 deletions

View File

@ -130,6 +130,8 @@ void ToolTip::showToolTip()
return;
}
emit aboutToShow();
ToolTipDialog *dlg = tooltipDialogInstance();
if (!mainItem()) {

View File

@ -187,6 +187,12 @@ Q_SIGNALS:
void locationChanged();
void activeChanged();
void interactiveChanged();
/**
* Emitted just before the tooltip dialog is shown.
*
* @since 5.45
*/
void aboutToShow();
private Q_SLOTS:
void settingsChanged(const QString &file);