This commit also drops most of the code around checks for direct rendering. If
direct rendering isn't supported, creating the OpenGL context will now simply fail,
achieving the same effect
In certain cases it can be useful to delay applying a surface commit. As
an example, the compositor may wait until the committed graphics buffer
is ready for reading to avoid stalling its graphics pipeline.
This change introduces basic surface state locking capabilities and
ports some surface extensions to new helpers to manage associated state.
Currently, committed fields are contiguously accumulated. With this, it
will be possible to see what fields have been committed when the
committed() signal is emitted.
It would be nice if xdg-surface and xdg-surface role state are in a
single object so it's easier to stash them. This change refactors
xdg-shell handling to allow that.
xdg-surface state now belongs to xdg-toplevel or xdg-popup state.
It makes no sense to lock that behind an env var. If there's errors those
should always be printed so that we know about them without further investigation
Avoids accidentally triggering an edge when dragging a scroll bar or
text selection all the way to the screen edge.
Special case for moving windows, as you want to be able to drag
a window to an edge to switch virtual desktops.
Compositor::scheduleRepaint() needs some knowledge of the composited
layers, which would be great to get rid of to split wayland and x11
compositing bits.
Display the window caption and class name (safe for the icon) like is done
with the windows themselves.
Eases debugging properties, such as "transientFor".
Otherwise, when using Alt as modifier for moving windows, the tabbox window
cannot be clicked because Alt is held down during Alt+Tab, which would try
to initiate a window move but the window isn't actually movable, so ends up
doing nothing.
It also allows to interact with Plasma popups, which are also immovable,
while the modified key is pressed.
Currently when we move the mouse the one render loop triggers a repaint.
When the cursor layer needs a new update we end up in the compositor
repainting the main content.
Even though painting should mostly no-op it still goes through all
existing items and effects to collect damage, still potentially making
the GL context current which could stall. A waste when we know we
haven't got anything to do. It's enough to cause noticable mouse lag on
some hardware.
Co-authored-by: Vlad Zahorodnii <vlad.zahorodnii@kde.org>