A few Qt6 deprecation fixes for use of QMouseEvent::globalPos.
This commit is contained in:
parent
3062cadb84
commit
e4908b5a2e
|
@ -492,7 +492,11 @@ void fceuCustomToolTip::mouseMoveEvent(QMouseEvent *event)
|
|||
|
||||
if (!w->rect().isNull())
|
||||
{
|
||||
#if QT_VERSION >= QT_VERSION_CHECK(6,0,0)
|
||||
QPoint pos = event->globalPosition().toPoint();
|
||||
#else
|
||||
QPoint pos = event->globalPos();
|
||||
#endif
|
||||
pos = mapFromGlobal(pos);
|
||||
|
||||
//printf("QEvent::MouseMove: (%i,%i) (%i,%i)\n",
|
||||
|
|
|
@ -858,7 +858,11 @@ void BOOKMARKS::mouseMoveEvent(QMouseEvent * event)
|
|||
emit imageIndexChanged(item);
|
||||
}
|
||||
imageItem = item;
|
||||
#if QT_VERSION >= QT_VERSION_CHECK(6,0,0)
|
||||
imagePos = event->globalPosition().toPoint();
|
||||
#else
|
||||
imagePos = event->globalPos();
|
||||
#endif
|
||||
imageTimer->start();
|
||||
QToolTip::hideText();
|
||||
}
|
||||
|
|
|
@ -690,7 +690,11 @@ void BRANCHES::mouseMoveEvent(QMouseEvent * event)
|
|||
emit imageIndexChanged(item);
|
||||
}
|
||||
imageItem = item;
|
||||
#if QT_VERSION >= QT_VERSION_CHECK(6,0,0)
|
||||
imagePos = event->globalPosition().toPoint();
|
||||
#else
|
||||
imagePos = event->globalPos();
|
||||
#endif
|
||||
imageTimer->start();
|
||||
QToolTip::hideText();
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue