client: Port QWaylandInputDevice to support QT_NO_CONTEXTLESS_CONNECT
There were two existing usages of the 3-arg connect, but the timer is always scoped to be shorter than the receiver so it was previously safe. Change-Id: I0bb5a38fed997cbb68e49defc51972894f5239ee Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io> Reviewed-by: Ahmad Samir <a.samirh78@gmail.com>
This commit is contained in:
parent
ea30d389f8
commit
3783016b72
@ -64,7 +64,7 @@ QWaylandInputDevice::Keyboard::Keyboard(QWaylandInputDevice *p)
|
|||||||
: mParent(p)
|
: mParent(p)
|
||||||
{
|
{
|
||||||
init(p->get_keyboard());
|
init(p->get_keyboard());
|
||||||
mRepeatTimer.callOnTimeout([&]() {
|
mRepeatTimer.callOnTimeout(this, [&]() {
|
||||||
if (!focusWindow()) {
|
if (!focusWindow()) {
|
||||||
// We destroyed the keyboard focus surface, but the server didn't get the message yet...
|
// We destroyed the keyboard focus surface, but the server didn't get the message yet...
|
||||||
// or the server didn't send an enter event first.
|
// or the server didn't send an enter event first.
|
||||||
@ -132,7 +132,7 @@ QWaylandInputDevice::Pointer::Pointer(QWaylandInputDevice *seat)
|
|||||||
}
|
}
|
||||||
|
|
||||||
mCursor.frameTimer.setSingleShot(true);
|
mCursor.frameTimer.setSingleShot(true);
|
||||||
mCursor.frameTimer.callOnTimeout([&]() {
|
mCursor.frameTimer.callOnTimeout(this, [&]() {
|
||||||
cursorTimerCallback();
|
cursorTimerCallback();
|
||||||
});
|
});
|
||||||
#endif
|
#endif
|
||||||
|
Loading…
x
Reference in New Issue
Block a user