UI: Fix Qt 6 position deprecations
This commit is contained in:
parent
49e37db952
commit
05c6a408e3
7 changed files with 53 additions and 21 deletions
|
|
@ -319,8 +319,9 @@ bool OBSBasicInteraction::HandleMouseClickEvent(QMouseEvent *event)
|
|||
//if (event->flags().testFlag(Qt::MouseEventCreatedDoubleClick))
|
||||
// clickCount = 2;
|
||||
|
||||
bool insideSource = GetSourceRelativeXY(event->x(), event->y(),
|
||||
mouseEvent.x, mouseEvent.y);
|
||||
QPoint pos = event->pos();
|
||||
bool insideSource = GetSourceRelativeXY(pos.x(), pos.y(), mouseEvent.x,
|
||||
mouseEvent.y);
|
||||
|
||||
if (mouseUp || insideSource)
|
||||
obs_source_send_mouse_click(source, &mouseEvent, button,
|
||||
|
|
@ -337,7 +338,8 @@ bool OBSBasicInteraction::HandleMouseMoveEvent(QMouseEvent *event)
|
|||
|
||||
if (!mouseLeave) {
|
||||
mouseEvent.modifiers = TranslateQtMouseEventModifiers(event);
|
||||
mouseLeave = !GetSourceRelativeXY(event->x(), event->y(),
|
||||
QPoint pos = event->pos();
|
||||
mouseLeave = !GetSourceRelativeXY(pos.x(), pos.y(),
|
||||
mouseEvent.x, mouseEvent.y);
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue