Handle when a xdg-toplevel changes its min or max size
We previously never emitted maximiziableChanged() meaning we never synced the state to the decoration. BUG:439578
This commit is contained in:
parent
e35ed5088a
commit
5fe6de699c
2 changed files with 16 additions and 0 deletions
|
@ -393,6 +393,10 @@ XdgToplevelClient::XdgToplevelClient(XdgToplevelInterface *shellSurface)
|
|||
this, &XdgToplevelClient::initialize);
|
||||
connect(shellSurface, &XdgToplevelInterface::destroyed,
|
||||
this, &XdgToplevelClient::destroyClient);
|
||||
connect(shellSurface, &XdgToplevelInterface::maximumSizeChanged,
|
||||
this, &XdgToplevelClient::handleMaximumSizeChanged);
|
||||
connect(shellSurface, &XdgToplevelInterface::minimumSizeChanged,
|
||||
this, &XdgToplevelClient::handleMinimumSizeChanged);
|
||||
connect(shellSurface->shell(), &XdgShellInterface::pingTimeout,
|
||||
this, &XdgToplevelClient::handlePingTimeout);
|
||||
connect(shellSurface->shell(), &XdgShellInterface::pingDelayed,
|
||||
|
@ -1148,6 +1152,16 @@ void XdgToplevelClient::handlePongReceived(quint32 serial)
|
|||
setUnresponsive(false);
|
||||
}
|
||||
|
||||
void XdgToplevelClient::handleMaximumSizeChanged()
|
||||
{
|
||||
Q_EMIT maximizeableChanged(isMaximizable());
|
||||
}
|
||||
|
||||
void XdgToplevelClient::handleMinimumSizeChanged()
|
||||
{
|
||||
Q_EMIT maximizeableChanged(isMaximizable());
|
||||
}
|
||||
|
||||
void XdgToplevelClient::sendPing(PingReason reason)
|
||||
{
|
||||
XdgShellInterface *shell = m_shellSurface->shell();
|
||||
|
|
|
@ -185,6 +185,8 @@ private:
|
|||
void handlePingTimeout(quint32 serial);
|
||||
void handlePingDelayed(quint32 serial);
|
||||
void handlePongReceived(quint32 serial);
|
||||
void handleMaximumSizeChanged();
|
||||
void handleMinimumSizeChanged();
|
||||
void initialize();
|
||||
void updateMaximizeMode(MaximizeMode maximizeMode);
|
||||
void updateFullScreenMode(bool set);
|
||||
|
|
Loading…
Reference in a new issue