debugger: remove 'tooltip' widget as soon as the mouse leaves the widget

This commit is contained in:
hjk
2010-04-29 16:11:14 +02:00
parent 4c27ee1c65
commit 73d169a4db

View File

@@ -61,6 +61,8 @@ public:
int computeHeight(const QModelIndex &index) const;
Q_SLOT void computeSize();
void leaveEvent(QEvent *ev);
private:
QSize m_size;
};
@@ -161,6 +163,13 @@ void ToolTipWidget::run(const QPoint &point, QAbstractItemModel *model,
//viewport()->setPalette(pal);
}
void ToolTipWidget::leaveEvent(QEvent *ev)
{
Q_UNUSED(ev);
if (QApplication::keyboardModifiers() == Qt::NoModifier)
hide();
}
void showDebuggerToolTip(const QPoint &point, QAbstractItemModel *model,
const QModelIndex &index, const QString &msg)
{