mirror of
https://invent.kde.org/network/falkon.git
synced 2024-12-20 02:36:34 +01:00
Port away from old QContextMenuEvent constructor
GIT_SILENT Signed-off-by: Juraj Oravec <jurajoravec@mailo.com>
This commit is contained in:
parent
71e37d7985
commit
6cc870be1d
@ -1242,10 +1242,11 @@ void WebView::contextMenuEvent(QContextMenuEvent *event)
|
|||||||
return;
|
return;
|
||||||
|
|
||||||
const QPoint pos = event->pos();
|
const QPoint pos = event->pos();
|
||||||
|
const QPoint globalPos = event->globalPos();
|
||||||
const QContextMenuEvent::Reason reason = event->reason();
|
const QContextMenuEvent::Reason reason = event->reason();
|
||||||
|
|
||||||
QTimer::singleShot(0, this, [this, pos, reason]() {
|
QTimer::singleShot(0, this, [this, pos, globalPos, reason]() {
|
||||||
QContextMenuEvent ev(reason, pos);
|
QContextMenuEvent ev(reason, pos, globalPos);
|
||||||
_contextMenuEvent(&ev);
|
_contextMenuEvent(&ev);
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user