diff options
author | Johan Klokkhammer Helsing <johan.helsing@qt.io> | 2018-12-21 14:31:58 +0100 |
---|---|---|
committer | Johan Helsing <johan.helsing@qt.io> | 2019-02-06 15:30:23 +0000 |
commit | 60d6d83ea0c43462d5f8e17aaa654ab6f625dd6e (patch) | |
tree | 643f3860052c5ee50b3f9ab53481a4f552c025c4 /tests/auto/client/shared/coreprotocol.cpp | |
parent | 401bdecabb950001ae3294e864ed397d1b76b3f4 (diff) |
Client xdg-shell: Add test for tooltips on popupsv5.13.0-alpha1
This used to cause protocol errors.
Task-number: QTBUG-71734
Change-Id: Ic937210fc42c93f1d411fb0fb4f269de01f07b5b
Reviewed-by: Paul Olav Tvete <paul.tvete@qt.io>
Diffstat (limited to 'tests/auto/client/shared/coreprotocol.cpp')
-rw-r--r-- | tests/auto/client/shared/coreprotocol.cpp | 14 |
1 files changed, 13 insertions, 1 deletions
diff --git a/tests/auto/client/shared/coreprotocol.cpp b/tests/auto/client/shared/coreprotocol.cpp index 54725e812..6f51a9793 100644 --- a/tests/auto/client/shared/coreprotocol.cpp +++ b/tests/auto/client/shared/coreprotocol.cpp @@ -263,10 +263,22 @@ uint Pointer::sendEnter(Surface *surface, const QPointF &position) wl_client *client = surface->resource()->client(); const auto pointerResources = resourceMap().values(client); for (auto *r : pointerResources) - send_enter(r->handle, m_enterSerial, surface->resource()->handle, x ,y); + wl_pointer::send_enter(r->handle, m_enterSerial, surface->resource()->handle, x ,y); return m_enterSerial; } +uint Pointer::sendLeave(Surface *surface) +{ + m_enterSerial = 0; + uint serial = m_seat->m_compositor->nextSerial(); + + wl_client *client = surface->resource()->client(); + const auto pointerResources = resourceMap().values(client); + for (auto *r : pointerResources) + wl_pointer::send_leave(r->handle, serial, surface->resource()->handle); + return serial; +} + // Make sure you call enter, frame etc. first void Pointer::sendMotion(wl_client *client, const QPointF &position) { |