Skip to content
Snippets Groups Projects
Commit 73d169a4 authored by hjk's avatar hjk
Browse files

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

parent 4c27ee1c
No related branches found
No related tags found
No related merge requests found
...@@ -61,6 +61,8 @@ public: ...@@ -61,6 +61,8 @@ public:
int computeHeight(const QModelIndex &index) const; int computeHeight(const QModelIndex &index) const;
Q_SLOT void computeSize(); Q_SLOT void computeSize();
void leaveEvent(QEvent *ev);
private: private:
QSize m_size; QSize m_size;
}; };
...@@ -161,6 +163,13 @@ void ToolTipWidget::run(const QPoint &point, QAbstractItemModel *model, ...@@ -161,6 +163,13 @@ void ToolTipWidget::run(const QPoint &point, QAbstractItemModel *model,
//viewport()->setPalette(pal); //viewport()->setPalette(pal);
} }
void ToolTipWidget::leaveEvent(QEvent *ev)
{
Q_UNUSED(ev);
if (QApplication::keyboardModifiers() == Qt::NoModifier)
hide();
}
void showDebuggerToolTip(const QPoint &point, QAbstractItemModel *model, void showDebuggerToolTip(const QPoint &point, QAbstractItemModel *model,
const QModelIndex &index, const QString &msg) const QModelIndex &index, const QString &msg)
{ {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment