Skip to content

Commit

Permalink
Merge branch 'jb53922' into 'mer-5.6'
Browse files Browse the repository at this point in the history
[qtwayland] Revert "Send a touch cancel event when we stop getting input". Fixes JB#53922 OMP#JOLLA-65

See merge request mer-core/qtwayland!23
  • Loading branch information
rainemak committed Apr 30, 2021
2 parents 835ed0d + 8fb9912 commit 306c7ac
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 16 deletions.
15 changes: 0 additions & 15 deletions src/compositor/compositor_api/qwaylandsurfaceitem.cpp
Expand Up @@ -228,13 +228,6 @@ void QWaylandSurfaceItem::touchEvent(QTouchEvent *event)
{
if (m_touchEventsEnabled) {
QWaylandInputDevice *inputDevice = compositor()->inputDeviceFor(event);

if (event->type() == QEvent::TouchBegin) {
QQuickItem *grabber = window()->mouseGrabberItem();
if (grabber != this)
grabMouse();
}

QPoint pointPos;
const QList<QTouchEvent::TouchPoint> &points = event->touchPoints();
if (!points.isEmpty())
Expand All @@ -259,14 +252,6 @@ void QWaylandSurfaceItem::touchEvent(QTouchEvent *event)
}
}

void QWaylandSurfaceItem::mouseUngrabEvent()
{
if (surface()) {
QTouchEvent e(QEvent::TouchCancel);
touchEvent(&e);
}
}

void QWaylandSurfaceItem::takeFocus(QWaylandInputDevice *device)
{
setFocus(true);
Expand Down
1 change: 0 additions & 1 deletion src/compositor/compositor_api/qwaylandsurfaceitem.h
Expand Up @@ -100,7 +100,6 @@ class Q_COMPOSITOR_EXPORT QWaylandSurfaceItem : public QQuickItem, public QWayla
void keyReleaseEvent(QKeyEvent *event);

void touchEvent(QTouchEvent *event);
void mouseUngrabEvent() Q_DECL_OVERRIDE;

public Q_SLOTS:
virtual void takeFocus(QWaylandInputDevice *device = Q_NULLPTR);
Expand Down

0 comments on commit 306c7ac

Please sign in to comment.