Restrict tooltips triggered by mouse move events to widget area.
Tooltips may occur outside the widget area when it has mouse grab. Task-number: QTBUG-40261 Change-Id: I68c1e28ad264fc5aaeb7d96273342f1d4bca8ce6 Reviewed-by: David Faure <david.faure@kdab.com>bb10
parent
07bbc4da32
commit
fc16dcce9d
|
|
@ -3246,7 +3246,8 @@ bool QApplication::notify(QObject *receiver, QEvent *e)
|
|||
// feature without choice of opting-in or out, you ALWAYS have to have
|
||||
// tracking enabled. Therefore, the other properties give a false sense of
|
||||
// performance enhancement.
|
||||
if (e->type() == QEvent::MouseMove && mouse->buttons() == 0) {
|
||||
if (e->type() == QEvent::MouseMove && mouse->buttons() == 0
|
||||
&& w->rect().contains(relpos)) { // Outside due to mouse grab?
|
||||
d->toolTipWidget = w;
|
||||
d->toolTipPos = relpos;
|
||||
d->toolTipGlobalPos = mouse->globalPos();
|
||||
|
|
|
|||
Loading…
Reference in New Issue