Commit ebdab57f authored by Vlad Zahorodnii's avatar Vlad Zahorodnii
Browse files

Send current primary selection after introducing focused surface

Toolkits such as GTK don't like that kwin sends the current primary
selection before the wl_keyboard.enter event.


(cherry picked from commit f034ef5d)
parent 1c9e21b2
Pipeline #55968 passed with stage
in 7 minutes and 7 seconds
......@@ -1123,6 +1123,9 @@ void SeatInterface::setFocusedKeyboardSurface(SurfaceInterface *surface)
}
d->globalKeyboard.focus = Private::Keyboard::Focus();
d->globalKeyboard.focus.surface = surface;
d->keyboard->setFocusedSurface(surface, serial);
if (d->globalKeyboard.focus.surface) {
d->globalKeyboard.focus.destroyConnection = connect(surface, &QObject::destroyed, this,
[this] {
......@@ -1159,8 +1162,6 @@ void SeatInterface::setFocusedKeyboardSurface(SurfaceInterface *surface)
}
}
d->keyboard->setFocusedSurface(surface, serial);
// focused text input surface follows keyboard
if (hasKeyboard()) {
setFocusedTextInputSurface(surface);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment