491a370...
by
Michael Catanzaro <email address hidden>
Fix crashes on idle
Currently whenever GNOME reaches its idle timeout and attempts to lock
the screen, it crashes. The problem occurs in
meta_onscreen_native_invalidate(), which calls
meta_output_is_privacy_screen_supported(),
meta_output_is_color_space_supported(), and
meta_output_is_hdr_metadata_supported(). For the KMS backend, all three
functions assume that meta_kms_connector_get_current_state() returns a
non-NULL pointer. This assumption is wrong.
This fixes the problem just enough to avoid the crashes that users are
encountering in practice. The problem is not comprehensively fixed. E.g.
even MetaKmsConnector itself often assumes that the current_state is
non-NULL without any evidence or assertions that it's true. Further
investigation is required; either it should be NULL-checked everywhere,
or it should be prevented from ever becoming NULL, or some more precise
invariant should be enforced.
x11/events: Don't define an unused function when tracing is disabled
This fixes a compiler warning:
```
src/x11/events.c:523:1: warning: ‘get_event_name’ defined but not used [-Wunused-function]
523 | get_event_name (MetaX11Display *x11_display,
| ^~~~~~~~~~~~~~
```
backends: Make base MetaCursorRenderer implementation want an overlay
This used to be the behavior, until commit 5d35138df02 changed the meaning
of the return value of MetaCursorRendererClass::update_cursor(). This
made the user of pure-overlay cursors (singular, MetaWaylandTabletTool)
miss their overlays.
Change the return value, so that it matches the desired behavior of
a backend-less overlay-only cursor renderer.
backends/native: Fix accounting of cursor overlay inhibition
We react on changes to has_hw_cursor, but always try to inhibit if
there is no cursor sprite. While this looks like a reasonable optimization
with the typical situation of one cursor renderer, it may fall into
inhibiting twice without knowing to unwind, e.g.:
And this may also result in the CLUTTER_PAINT_FLAG_NO_CURSORS flag
staying on for Tablet cursors, that (so far) always use overlay paths.
This results in invisible tablet cursors after using the mouse at
least once.
Under strange timings, the GTK frames client may implicitly queue
relayouts that end up disagreeing with the latest frame size as
given by Mutter, this results in GTK calling XResizeWindow, and
Mutter plain out ignoring the resulting XConfigureRequestEvent
received.
This however makes GTK think there's pending resize operations,
so at the next resize it will freeze the window, until enough
resizes happened to thaw it again. This is seen as temporary
loss of frame-sync ness (e.g. frozen frame, and other weird
behavior).
In order to make GTK happy and balanced, reply to this
XConfigureRequest, even if just to ignore it in a more polite
way (we simply re-apply the size Mutter thinks the frame should
have, not GTK), this results in the right amount of
ConfigureNotify received on the frames client side, and the
surface to be thawed more timely, while enforcing the size as
managed by Mutter.
788caf7...
by
Bilal Elmoussaoui <email address hidden>
boxes: Add an alias for MetaRectangle
This is meant for compatibility purposes with the shell extensions
avoiding to break a bunch of them in the last minute and we would
drop it in the GNOME 46 release.