Summary:
So far the ThumbnailItem in TabBox mode used the window id for finding
the window it should render a thumbnail on. In the Wayland world this is
not unique. The window id could be either an X11 window or a wayland
window. We don't guarantee that there are no conflicting ids.
With the internal id we have a way to properly identify the windows, so
this element should use them.
To support this the property changed the type to QUuid and the
clientmodel also provides the QUuid. As in TabBox the way to get the
window is through the model this should be compatible for all themes.
It's tested and verified with the Breeze switcher.
For declarative KWin scripts the ThumbnailItem also provides the
AbstractClient as a property, so there should not be any script which
uses wid. If it does, this could break, but well the script should use
the intended API.
Test Plan: ctest passes, manual testing of Breeze alt-tab switcher
Reviewers: #kwin
Differential Revision: https://phabricator.kde.org/D18405
Summary:
KWindowSystem provides a plugin interface to have platform specific
implementations. So far KWin relied on the implementation in
KWayland-integration repository.
This is something I find unsuited, for the following reasons:
* any test in KWin for functionality set through the plugin would fail
* it's not clear what's going on where
* in worst case some code could deadlock
* KWin shouldn't use KWindowSystem and only a small subset is allowed
to be used
The last point needs some further explanation. KWin internally does not
and cannot use KWindowSystem. KWindowSystem (especially KWindowInfo) is
exposing information which KWin sets. It's more than weird if KWin asks
KWindowSystem for the state of a window it set itself. On X11 it's just
slow, on Wayland it can result in roundtrips to KWin itself which is
dangerous.
But due to using Plasma components we have a few areas where we use
KWindowSystem. E.g. a Plasma::Dialog sets a window type, the slide in
direction, blur and background contrast. This we want to support and
need to support. Other API elements we do not want, like for examples
the available windows. KWin internal windows either have direct access
to KWin or a scripting interface exposed providing (limited) access -
there is just no need to have this in KWindowSystem.
To make it more clear what KWin supports as API of KWindowSystem for
internal windows this change implements a stripped down version of the
kwayland-integration plugin. The main difference is that it does not use
KWayland at all, but a QWindow internal side channel.
To support this EffectWindow provides an accessor for internalWindow and
the three already mentioned effects are adjusted to read from the
internal QWindow and it's dynamic properties.
This change is a first step for a further refactoring. I plan to split
the internal window out of ShellClient into a dedicated class. I think
there are nowadays too many special cases. If it moves out there is the
question whether we really want to use Wayland for the internal windows
or whether this is just historic ballast (after all we used to use
qwayland for that in the beginning).
As the change could introduce regressions I'm targetting 5.16.
Test Plan:
new test case for window type, manual testing using Alt+Tab
for the effects integration. Sliding popups, blur and contrast worked fine.
Reviewers: #kwin
Subscribers: kwin
Tags: #kwin
Differential Revision: https://phabricator.kde.org/D18228
Summary:
For some reason this lines are duplicated twice, (possibly due to merge
conflict resolution?), clean it up.
Reviewers: #kwin, davidedmundson
Reviewed By: #kwin, davidedmundson
Subscribers: kwin
Tags: #kwin
Differential Revision: https://phabricator.kde.org/D18348
Summary:
The new connect syntax has several advantages over the old syntax:
(a) Connecting with the new syntax is faster;
(b) It is compile time checked.
There are still a few places where the old connect syntax is used, e.g.
connecting to QML buttons in the Desktop Grid effect.
Test Plan:
Have been testing this patch for ~2 weeks, haven't noticed any
regressions.
Reviewers: #kwin, davidedmundson
Reviewed By: #kwin, davidedmundson
Subscribers: davidedmundson, broulik, graesslin, kwin
Tags: #kwin
Differential Revision: https://phabricator.kde.org/D18368
Summary:
Wayland provides functionality for servers to acquire an unused socket name
automatically. Do this through the recently added functionality in KWayland
in case no socket name was specified as an argument to KWin.
Test Plan: Manually, autotests pass.
Reviewers: #kwin, fvogt
Reviewed By: fvogt
Subscribers: kwin
Tags: #kwin
Differential Revision: https://phabricator.kde.org/D18522
Summary:
The plasma virtual desktop protocol states the following about
the done event
> This event is sent after all other properties has been sent after
> binding to the desktop manager object and after any other property
> changes done after that.
Thus we have to send that event when the number of rows has been changed.
Reviewers: #kwin, davidedmundson
Reviewed By: #kwin, davidedmundson
Subscribers: kwin
Tags: #kwin
Differential Revision: https://phabricator.kde.org/D18518
Summary:
The protocol is double buffered, after changing the name done should be
sent so that clients update.
Test Plan:
Changed a VD name on wayland
Pager tooltip updated
Reviewers: #kwin, zzag
Reviewed By: #kwin, zzag
Subscribers: zzag, kwin
Tags: #kwin
Differential Revision: https://phabricator.kde.org/D18513
Summary: New icons were added in D18483 and D18490, so this is 5.16 only.
Test Plan: {F6565234, size=full}
Reviewers: #vdg, #plasma, ndavis
Reviewed By: #vdg, ndavis
Subscribers: kwin
Tags: #kwin
Differential Revision: https://phabricator.kde.org/D18492
Summary:
We have to connect to nameChanged even if m_rootInfo is not set yet,
otherwise names in _NET_DESKTOP_NAMES won't be kept in sync if
a virtual desktop is renamed.
CCBUG: 403307
Reviewers: #kwin, davidedmundson
Reviewed By: #kwin, davidedmundson
Subscribers: kwin
Tags: #kwin
Differential Revision: https://phabricator.kde.org/D18503
Summary:
Default CXX flags are out of our control. Whether they're set by the
compiler or the user or ECM.
We currently disable for clang. This patch also disables this warning
for other compilers.
This might not be anyone's first preference, but we're at an impasse
there.
Test Plan: Compiled
Reviewers: #kwin, graesslin
Reviewed By: #kwin, graesslin
Subscribers: zzag, kwin
Tags: #kwin
Differential Revision: https://phabricator.kde.org/D18488
Summary: Uses D17691 and sets the info on the protocol
Test Plan: correct data sent
Reviewers: #plasma, #kwin, zzag
Reviewed By: #plasma, #kwin, zzag
Subscribers: zzag, graesslin, kwin
Tags: #kwin
Differential Revision: https://phabricator.kde.org/D18293
Summary: We depend on Qt 5.11, thus we can address the TODO item.
Reviewers: #kwin, davidedmundson
Reviewed By: #kwin, davidedmundson
Subscribers: kwin
Tags: #kwin
Differential Revision: https://phabricator.kde.org/D18355
Summary:
We need to connect to PlasmaVirtualDesktopInterface::activateRequested
when a virtual desktop is created, otherwise one won't be able to
activate the desktop by using the pager.
Reviewers: #kwin, davidedmundson
Reviewed By: #kwin, davidedmundson
Subscribers: kwin
Tags: #kwin
Differential Revision: https://phabricator.kde.org/D18342
Summary:
Currently, there are several issues with
VirtualDesktopManager::createVirtualDesktop:
(a) The method expects the number parameter to be in range [1, count + 1],
but we pass [0, count];
(b) It doesn't correctly update X11 desktop numbers.
This change tries to address all previously mentioned issues.
BUG: 403312
FIXED-IN: 5.15.0
Test Plan: No longer able to reproduce bug 403312.
Reviewers: #kwin, davidedmundson
Reviewed By: #kwin, davidedmundson
Subscribers: davidedmundson, hein, kwin
Tags: #kwin
Differential Revision: https://phabricator.kde.org/D18328
Summary: Connecting with the new syntax is faster and also type checked.
Test Plan: Scripted effects still work as expected.
Reviewers: #kwin, graesslin
Reviewed By: #kwin, graesslin
Subscribers: kwin
Tags: #kwin
Differential Revision: https://phabricator.kde.org/D18393
Summary:
Currently, when the lanczos filter attempts to release acquired resources,
the backend is already gone. To fix that we have to destroy the filter
together with SceneOpenGL2. At that moment the backend is still alive.
BUG: 403370
FIXED-IN: 5.15.0
Reviewers: #kwin, davidedmundson
Reviewed By: #kwin, davidedmundson
Subscribers: kwin
Tags: #kwin
Differential Revision: https://phabricator.kde.org/D18367
Summary:
EffectsAPI explicitly says:
"On X11, the window will end up on the last window in the list" and
DesktopGrid reliaed on that.
Using the last makes sense as it means the
enterDesktop method will work for both.
Somehow in the refactors AbstractClient ended up doing the opposite.
Reviewers: #kwin, zzag
Reviewed By: #kwin, zzag
Subscribers: zzag, kwin
Tags: #kwin
Differential Revision: https://phabricator.kde.org/D18339
Summary:
ColumnLayout only contains one item so is rather pointless, but more
importantly prevents size hints from the formLayout propogating up to
the ScrollViewKCM.
Test Plan: Opened KCM
Reviewers: #kwin, broulik
Reviewed By: broulik
Subscribers: kwin
Tags: #kwin
Differential Revision: https://phabricator.kde.org/D18297
Summary:
the Lookand Feel kcm already applies decorations to kwin, allow to
read them as defaults for the case of distribution customization
where a different lnf with a different deco is wanted
Test Plan: tested to start kwin with a different lnf which loads an aurorae decoration
Reviewers: #plasma, #kwin, davidedmundson
Reviewed By: #plasma, #kwin, davidedmundson
Subscribers: davidedmundson, kwin
Tags: #kwin
Differential Revision: https://phabricator.kde.org/D18261
Summary:
kcm.osdTextOnly is the inverse of "show desktop layout indicators"
The save was inversed, the load was not.
Also port from onCheckedChanged to onToggled as that's emitted only on
user changes and not on binding re-evaluation.
BUG: 403150
Test Plan:
Toggled it
Reopened KCM
Checked kwinrc
Reviewers: #kwin, ngraham
Reviewed By: ngraham
Subscribers: ngraham, kwin
Tags: #kwin
Differential Revision: https://phabricator.kde.org/D18272
Summary:
We need to return the absolute path instead of base name so decoColorToCombo
can return the correct index.
Test Plan:
* Go to System Settings > Window Management > Window Rules;
* Create a new rule for Konsole to force the Oxygen color scheme,
close the dialog, and click the Apply button;
* Open the rules dialog (you don't have to modify anything), click OK button, then Apply button.
Without this patch, Breeze color scheme will be forced after the
last step.
Reviewers: #kwin, davidedmundson
Reviewed By: #kwin, davidedmundson
Subscribers: graesslin, broulik, kwin
Tags: #kwin
Differential Revision: https://phabricator.kde.org/D17655