Commit 33cf87f0 authored by Vlad Zahorodnii's avatar Vlad Zahorodnii
Browse files

x11: Update decoration input shape

We need to update the input shape; otherwise it won't be possible to
resize X11 windows without bottom and side borders.
parent 66daa862
......@@ -1045,6 +1045,10 @@ void X11Client::createDecoration(const QRect& oldgeom)
if (decoration) {
QMetaObject::invokeMethod(decoration, "update", Qt::QueuedConnection);
connect(decoration, &KDecoration2::Decoration::shadowChanged, this, &Toplevel::updateShadow);
connect(decoration, &KDecoration2::Decoration::bordersChanged,
this, &X11Client::updateDecorationInputShape);
connect(decoration, &KDecoration2::Decoration::resizeOnlyBordersChanged,
this, &X11Client::updateDecorationInputShape);
connect(decoration, &KDecoration2::Decoration::resizeOnlyBordersChanged, this, &X11Client::updateInputWindow);
connect(decoration, &KDecoration2::Decoration::bordersChanged, this,
[this]() {
......@@ -1063,11 +1067,14 @@ void X11Client::createDecoration(const QRect& oldgeom)
);
connect(decoratedClient()->decoratedClient(), &KDecoration2::DecoratedClient::widthChanged, this, &X11Client::updateInputWindow);
connect(decoratedClient()->decoratedClient(), &KDecoration2::DecoratedClient::heightChanged, this, &X11Client::updateInputWindow);
connect(decoratedClient()->decoratedClient(), &KDecoration2::DecoratedClient::sizeChanged,
this, &X11Client::updateDecorationInputShape);
}
setDecoration(decoration);
move(calculateGravitation(false));
plainResize(adjustedSize(), ForceGeometrySet);
updateDecorationInputShape();
if (Compositor::compositing()) {
discardWindowPixmap();
}
......
Supports Markdown
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