Summary:
The Qt::KeypadModifier should only accompany a keysym when this specific keysym
originates from the keypad not in general for every keysym while numlock is
engaged.
BUG: 400658
FIXED-IN: 5.18.0
Test Plan: Manually with the Thumbnail Grid task switcher and numlock enabled.
Reviewers: #kwin, davidedmundson
Reviewed By: #kwin, davidedmundson
Subscribers: kwin
Tags: #kwin
Differential Revision: https://phabricator.kde.org/D26283
Summary:
The GLX backend might need a combination of swap and composite timer events for
continous painting.
The reason for that is that if the buffer age extension is not available we
fall back to copies in case not the whole screen is repainted.
The timer logic is adapted to make this possible in a lean way what cleans up
the Compositor class in several ways.
Test Plan: Tested on X11 (with/without swap events, buffer age enabled) and Wayland.
Reviewers: #kwin
Subscribers: hurikhan77, kwin
Tags: #kwin
Differential Revision: https://phabricator.kde.org/D26216
After paint in case we have swap events the buffer swap should be pending.
This is not always the case with the X11 standalone plugin what needs to be
investigated some more. This is for now a quick fix to make sessions work
again without failing on the assert.
Summary:
When the compositor is stopped there might still be a buffer swap ongoing, in
particular when a client blocks compositing on X11.
Depending on the backend the next buffer swap event might be handled in
bufferSwapComplete (Wayland) or not be handled (X11 GLX, since a new
GLX window will be created while the swap event is sent for the old one).
With this patch the buffer swap state is reset on stop such that on later
start no outdated data might create errors and instead a new repaint can be
triggered with updated data.
BUG: 415262
Test Plan: Manually on X11 and Wayland.
Reviewers: #kwin, davidedmundson
Reviewed By: #kwin, davidedmundson
Subscribers: kwin
Tags: #kwin
Differential Revision: https://phabricator.kde.org/D26090
The semantics of a window taking focus on user interaction apply to more roles. See D25851.
Given it is used by KWindowSystem::forceActivateWindow in kwayland-integration,
it makes sense to pass focus to the window once it gets this property set.
Differential Revision: https://phabricator.kde.org/D25968
Summary: It works for the effect
Test Plan:
kcmshell5 kcm_kwin_effects
Change some settings, the "Restore defaults" button is enabled when the state is not the default state.
Open an effect configuration, the "Restore defaults" button is enabled when the settings are not default.
Reviewers: #kwin, crossi, ervin, zzag
Reviewed By: #kwin, zzag
Subscribers: zzag, kwin
Tags: #kwin
Differential Revision: https://phabricator.kde.org/D26040
Summary: Same as on Windows 10, very useful when you use virtual desktops.
Test Plan: Have 2 or more virtual desktops and use the new shortcut.
Reviewers: #kwin, #plasma, #vdg, romangg, ngraham, davidedmundson
Reviewed By: #kwin, #plasma, #vdg, ngraham, davidedmundson
Subscribers: davidedmundson, thiagosueto, ngraham, romangg, zzag, #vdg, #plasma, kwin, #kwin
Tags: #kwin
Maniphest Tasks: T11520
Differential Revision: https://phabricator.kde.org/D24281
Summary:
I could never reproduce the crash, but we know from gdb that it's from
the decorationSettings object
We are setting the same QObject instance as a context property in
multiple contexts at once. This is already slightly odd especially from the POV of
Qt's internal property cache.
Given we want one object to be exposed to all contexts, we can expose it
to the parent context only once and achieve the same result in a simpler
way.
BUG: 411166
Test Plan:
Verified opening and closing system settings still worked for me.
I could never reproduce the original crash.
Reviewers: #kwin, ngraham
Reviewed By: ngraham
Subscribers: ngraham, apol, kwin
Tags: #kwin
Differential Revision: https://phabricator.kde.org/D25913
Summary: Print the Qt::Key value on the debug window
Test Plan: When I press the power button I get Key_PowerOff
Reviewers: #kwin, romangg
Reviewed By: #kwin, romangg
Subscribers: romangg, kwin
Tags: #kwin
Differential Revision: https://phabricator.kde.org/D25896
This reverts commit 1747e497e4.
Unfortunately, this patch causes fall apart effect to override sliding
popups effect, which we really don't want to do.
Summary:
The buffer shape is in buffer-local coordinates and must be mapped to
window coordinates. After that, we are free to map it to the global screen
coordinates.
Reviewers: #kwin, davidedmundson
Reviewed By: #kwin, davidedmundson
Subscribers: kwin
Tags: #kwin
Differential Revision: https://phabricator.kde.org/D25733
Summary:
If the XRender scene has cross-faded a window, then, eventually, KWin/X11 will
crash in the destructor of the XRenderPictureData class during tear down with
the following message in the terminal
```
ASSERT: "qApp" in file /home/vlad/Workspace/KDE/src/kde/workspace/kwin/libkwineffects/kwinxrenderutils.cpp, line 163
```
The crash happens because X11StandalonePlatform attempts to clean up XRender
resources, including XRenderUtils::s_blendPicture, after the application object
has been destroyed.
In order to fix the crash, we have to destroy the platform object before the
destructor of QCoreApplication is executed.
Test Plan:
- Enable maximize effect
- Maximize a window
- Replace the current instance of KWin/X11 with another one
Without this patch, KWin/X11 crashes after the third step.
Reviewers: #kwin, davidedmundson
Reviewed By: #kwin, davidedmundson
Subscribers: kwin
Tags: #kwin
Differential Revision: https://phabricator.kde.org/D25768
Summary:
Activate intel swap events by default if available. They were hidden behind an
environmental variable because of some critical release blocking issue years
ago.
Manual testing indicates that there are no issues anymore with this extension.
Since it allows us to use swap events with MESA drivers for optimized repaints
enable swap events by default again.
For now leave a modified environment variable to switch back to using no swap
events easily.
CCBUG: 342582
Test Plan: i915
Reviewers: #kwin
Subscribers: zzag, broulik, kwin
Tags: #kwin
Maniphest Tasks: T11071
Differential Revision: https://phabricator.kde.org/D25300
Summary:
When swap events are available do not delay the next repaint by one frame
through the composite timer but directly repaint on swap event.
Test Plan: i915
Reviewers: #kwin
Subscribers: davidedmundson, zzag
Maniphest Tasks: T11071
Differential Revision: https://phabricator.kde.org/D25299
Summary:
Add a small getter to query information internally if the backend supports
swap events. Defaults to true as it is the default in the GBM Wayland backend.
Test Plan: i915
Reviewers: #kwin
Subscribers: kwin
Tags: #kwin
Maniphest Tasks: T11071
Differential Revision: https://phabricator.kde.org/D25298
When initializing a property we loop through the drmModeObjectProperties
object and search for the property by its name.
Once found we create the Property object and there should be not another one
with the same name afterwards. In any case we would leak memory. Therefore just
directly return once the property was found.
This gives us the added benefit that we can put out a warning in case the
property was not found in the loop, what should not happen with the properties
we use.
This is just a code cosmetic change to have the same values internally like the
kernel for the type enum. In the logic there should not be a difference since
the enum values are mapped at runtime.
Summary:
This cleans up some of the code, moves and deletes superfluous functions,
improves in-code docs and runtime warnings.
Test Plan: On vt.
Reviewers: #kwin
Subscribers: kwin
Tags: #kwin
Differential Revision: https://phabricator.kde.org/D25867
Summary:
According to Gl 3.2 (page 501) and 4.5 (page 204) specs the initial state of
the default framebuffer is already BACK. Therefore we do not need to set it
explicitly.
When we draw in the future to alternative framebuffers which do not have back
buffers this call is fatal.
Test Plan: No tearing on Wayland, tearing as before on X11.
Reviewers: #kwin, davidedmundson
Reviewed By: #kwin, davidedmundson
Subscribers: kwin
Tags: #kwin
Differential Revision: https://phabricator.kde.org/D25868
Summary: Use a kcfg file to specify virtual desktops settings saved to kwinrc.
Test Plan:
kcmshell5 kcm_kwin_virtualdesktops
Change something, check apply buttons works appropriately
Save the settings and relaunch the kcm, the new settings are taken loaded correctly
Reviewers: #kwin, ervin
Reviewed By: ervin
Subscribers: kwin
Tags: #kwin
Differential Revision: https://phabricator.kde.org/D25871
Summary:
At the moment, the state of wayland of getting such events isn't all
that clear. There's a zwp_tablet protocol that isn't stable yet and more
importantly isn't supported by Qt just yet.
Have it move and click the mouse about for now.
Depends on D25663 and D25763
Reviewers: #kwin, romangg
Reviewed By: #kwin, romangg
Subscribers: romangg, zzag, kwin
Tags: #kwin
Differential Revision: https://phabricator.kde.org/D25764
Summary: This way we can reverse-lookup if we ever want the opposite information.
Reviewers: #kwin, romangg
Reviewed By: #kwin, romangg
Subscribers: zzag, kwin
Tags: #kwin
Differential Revision: https://phabricator.kde.org/D25763
Summary:
This includes support for them on libinput and turns it into fake
pointer actions.
This doesn't implement zwp_tablet, this will have to happen in an
iteration later.
Test Plan:
Been playing around with it, see video.
https://www.youtube.com/watch?v=GF1WbO8FVvU
Reviewers: #plasma, #kwin, romangg
Reviewed By: #plasma, #kwin, romangg
Subscribers: zzag, davidedmundson, romangg, kwin
Tags: #kwin
Differential Revision: https://phabricator.kde.org/D25663
Summary:
startupfeedback is a special case, rather than loading our own config we
load settings from klaunchrc.
In order to reload this means leaking kwin specific calls into the
launch feedback KCM. Using the new KConfigWatcher syntax, we can use a
generic solution for all this code.
Test Plan:
Changed the value in KCM
Opened dolphin
cursor did the right thing
Reviewers: zzag
Reviewed By: zzag
Subscribers: kwin
Tags: #kwin
Differential Revision: https://phabricator.kde.org/D25834
Summary:
This is a small overhaul of the EglGbmBackend. Functions are restructured,
white space added and variables renamed for better readability and style
aligned with Frameworks Coding Style.
Test Plan: Session starts.
Reviewers: #kwin, zzag
Reviewed By: #kwin, zzag
Subscribers: kwin
Tags: #kwin
Differential Revision: https://phabricator.kde.org/D25830
Summary:
Currently the fall apart effect doesn't work in conjuction with window
open/close animation effects, e.g. scale. The reason for that is those
effects grab windows before the fall apart effect.
Test Plan:
* Enable the fall apart effect and the scale effect;
* Close a window.
(without this patch the window doesn't fall apart)
Reviewers: #kwin, davidedmundson
Reviewed By: #kwin, davidedmundson
Subscribers: ngraham, davidedmundson, kwin
Tags: #kwin
Differential Revision: https://phabricator.kde.org/D19723
Summary: The new name better reflects what Toplevel::geom is.
Test Plan: Compiles, tests still pass.
Reviewers: #kwin, davidedmundson
Reviewed By: #kwin, davidedmundson
Subscribers: kwin
Tags: #kwin
Differential Revision: https://phabricator.kde.org/D25738
Summary:
The frame geometry doesn't necessarily correspond to the server-side
geometry of the toplevel window, we need to use the buffer geometry
instead.
Reviewers: #kwin, davidedmundson
Reviewed By: #kwin, davidedmundson
Subscribers: kwin
Tags: #kwin
Differential Revision: https://phabricator.kde.org/D25730
Summary:
This change makes geometry updates in the X11Client class simpler and
also fixes a bug in the move() method.
Test Plan: All tests pass.
Reviewers: #kwin
Subscribers: kwin
Tags: #kwin
Differential Revision: https://phabricator.kde.org/D25710
Summary:
This makes it possible to detect these changes via KConfigWatcher.
This is needed for D25670
Reviewers: #kwin, ngraham, davidedmundson
Reviewed By: #kwin, ngraham, davidedmundson
Subscribers: ngraham, kwin
Tags: #kwin
Differential Revision: https://phabricator.kde.org/D25695