Bilal Elmoussaoui
dc0a4c554a
transition: Use macros for subclassing boilerplate
...
Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/3387 >
2024-01-10 09:15:47 +01:00
Bilal Elmoussaoui
e9c1f1c642
timeline: Use macros for subclassing boilerplate
...
Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/3387 >
2024-01-10 09:11:56 +01:00
Bilal Elmoussaoui
5fb78dfbad
zoom-action: Use macros for subclassing boilerplate
...
Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/3387 >
2024-01-10 09:11:52 +01:00
Bilal Elmoussaoui
09b7cd9f4a
x11/display: Don't try to retrieve xwindow of wayland windows
...
Trying to get the xwindow of a wayland only window would fail when
casting to a x11 window. Which happens as
meta_x11_display_set_input_focus is called whenever the focused
window changes, whether it is a wayland or x11 one
Fixes: bc9cd123e
("window: Move xwindow to WindowX11")
Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/3506 >
2024-01-09 23:51:37 +01:00
Bilal Elmoussaoui
5ad8a79823
display: Add a helper to retrieve associated xwindow
...
As we moved the xwindow property from Window to WindowX11 which is
not exposed as public API. So instead of exposing WindowX11,
the API is added to MetaX11Display which is already exposed.
This is only needed by gnome-shell for it tray icons support
https://gitlab.gnome.org/GNOME/gnome-shell/-/blob/81f18d7d/src/shell-tray-icon.c#L67
Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/3211 >
2024-01-09 18:59:36 +00:00
Bilal Elmoussaoui
0236506cff
window: Move has_pointer_x11 to WindowX11
...
Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/3211 >
2024-01-09 18:59:36 +00:00
Bilal Elmoussaoui
19a36b8879
window: Stop storing xtransient_for field
...
Instead retrieve the associated Window from the xwindow property.
Avoids having a vfunc to handle the get_transient_for differences
between Wayland and x11
Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/3211 >
2024-01-09 18:59:36 +00:00
Bilal Elmoussaoui
5e098eadce
window: Move user_time_window to WindowX11
...
Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/3211 >
2024-01-09 18:59:36 +00:00
Bilal Elmoussaoui
9e150fda42
window: Move xgroup_leader to WindowX11
...
Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/3211 >
2024-01-09 18:59:36 +00:00
Bilal Elmoussaoui
7d6e7773bf
window: Make Window.set_transient_for a vfunc
...
So we can move the xgroup_leader to WindowX11. See next commit
Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/3211 >
2024-01-09 18:59:36 +00:00
Bilal Elmoussaoui
c0685fe29b
window: Move xclient_leader to WindowX11
...
Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/3211 >
2024-01-09 18:59:36 +00:00
Bilal Elmoussaoui
bc9cd123e9
window: Move xwindow to WindowX11
...
Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/3211 >
2024-01-09 18:59:36 +00:00
Bilal Elmoussaoui
d98b0eb71e
window: Move xvisual to WindowX11
...
Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/3211 >
2024-01-09 18:59:36 +00:00
Bilal Elmoussaoui
2a75661883
region: Move RegionBuilder to Mtk
...
Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/3501 >
2024-01-09 18:47:34 +00:00
Bilal Elmoussaoui
fced59b33d
region: Make Region.transform private
...
It is only used once in MetaWaylandSurface
Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/3501 >
2024-01-09 18:47:34 +00:00
Bilal Elmoussaoui
9953704ceb
region: Move RegionIterator to Mtk
...
Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/3501 >
2024-01-09 18:47:34 +00:00
Bilal Elmoussaoui
cf8eb4944a
region: Make make_region_border private
...
It is only used by the shadow factory and doesn't make sense to
have as part of mtk
Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/3501 >
2024-01-09 18:47:34 +00:00
Bilal Elmoussaoui
39aeb81a8b
region: Move Region.apply_matrix_transform_expand to Mtk
...
Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/3501 >
2024-01-09 18:47:34 +00:00
Bilal Elmoussaoui
4d53e4d156
region: Move Region.crop_and_scale to Mtk
...
Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/3501 >
2024-01-09 18:47:34 +00:00
Bilal Elmoussaoui
6e7d314e75
region: Move Region.scale to Mtk
...
Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/3501 >
2024-01-09 18:47:34 +00:00
Bilal Elmoussaoui
4513abd584
region: Move rectangle helper macro to Mtk
...
Rename it to Rectangle prefix to avoid confusion with MtkRegion
Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/3501 >
2024-01-09 18:47:34 +00:00
Bilal Elmoussaoui
6f9e75b6f2
boxes: Move Rectangle.is_adjacent_to to Mtk
...
Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/3501 >
2024-01-09 18:47:34 +00:00
Bilal Elmoussaoui
fcc8cfff11
boxes: Move Rectangle.scale_double to Mtk
...
Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/3501 >
2024-01-09 18:47:34 +00:00
Bilal Elmoussaoui
59457dff81
boxes: Move Rectangle.crop_and_scale to Mtk
...
Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/3501 >
2024-01-09 18:47:34 +00:00
Sebastian Wick
abe47769b7
docs: Move kms abstractions documentation out of references
...
Eventually we want to have all the high-level code documentation in the
component API reference documentation. However, gi-docgen is currently
missing support for mermaid so we just keep the files in `doc/` and link
to them from `code-overview.md`.
Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/3505 >
2024-01-09 17:59:15 +00:00
Peter Hutterer
b5e9279ea0
backends/x11: Fetch the tablet serial prop on device add
...
For tablet device, the tool was created when the "Wacom Serial IDs" prop
changed values. This property does not exist on the xf86-input-libinput
driver but v1.5.0 of that driver has a different property for the serial.
The serial is constant (the driver creates one X device per serial), so
we can fetch it after device creation and set it then. For earlier
versions of the driver we assign the random serial 0xffffffaa - good
enough to have at least a tool.
This fixes the crash in #3120 - clutter_event_motion_new()
overrides event->device to the tool's device (if any). Without a tool
motion events use the Virtual Core Pointer instead and our source device
is never added to the stage's priv->pointer_devices.
When we generate an crossing event (which uses the source device) we
fall afoul of an assert in clutter_stage_update_device() that expects
our source device to be in priv->pointer_devices.
Fixes https://gitlab.gnome.org/GNOME/mutter/-/issues/3120
Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/3383 >
2024-01-09 17:33:33 +00:00
Zander Brown
b1dd6973df
workspace-manager: Accessors for layout-{columns,rows}
...
This will allow C code in shell to avoid going though `g_object_get`,
and in future GJS will also be able to take advantage giving a slender
yet not unwelcome boost to perf in some animations
(Semi relates to https://gitlab.gnome.org/GNOME/mutter/-/issues/3083 )
Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/3351 >
2024-01-09 16:38:25 +00:00
Robert Mader
5ffeb34251
build: Enable no-omit-frame-pointer for all non-plain builds
...
This is useful for local installations with e.g. the `release`
buildtype.
Further more, Fedora has been doing the same system wide and it
apparently was helpful in various ways, see also
Also add -mno-omit-leaf-frame-pointer, like Fedora.
https://blogs.gnome.org/chergert/2023/10/03/what-have-frame-pointers-given-us-anyway/
Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/3333 >
2024-01-09 16:26:57 +00:00
Robert Mader
ee65ca791b
build: Harmonize c_args handling
...
The slightly different styles in the different build files make it
harder to reason about or share c_args.
This notably ensures we never set any extra c_args for plain builds and
fixes the cc.get_supported_arguments() check in Cogl, Clutter and Mtk.
Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/3333 >
2024-01-09 16:26:57 +00:00
Bilal Elmoussaoui
aaa63c1e08
clutter: Remove no longer useful since tags
...
As they represent the pre-merge version of Clutter
Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/3489 >
2024-01-09 15:23:04 +00:00
Bilal Elmoussaoui
346e9a7f2c
docs: Remove remaining SECTIONs
...
Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/3489 >
2024-01-09 15:23:04 +00:00
Bilal Elmoussaoui
52c64d44fc
docs: Move kms abstractions to a separate file
...
Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/3489 >
2024-01-09 15:23:04 +00:00
Bilal Elmoussaoui
00b4d4c4bc
docs: Update more links to gi-docgen
...
Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/3489 >
2024-01-09 15:23:04 +00:00
Bilal Elmoussaoui
e7a920f94d
docs: Migrate remaining content to markdown
...
By stopping using gtk-doc annotations
Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/3489 >
2024-01-09 15:23:04 +00:00
Sebastian Wick
a0a1d102a0
cogl/bitmap-conversion: Don't break strict-aliasing for flt_pack/unpack
...
Simply reinterpreting the bytes differently is a strict-aliasing
violation if the type of the object isn't char or the target type of the
reinterpretation. None of that is the case here, so we have to resort to
a memcpy.
Fixes: 60c082caa
("cogl/bitmap-conversion: Support packing fp16 formats")
Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/3499 >
2024-01-09 14:43:16 +00:00
Sebastian Wick
0cd85e4adf
cogl/half-float: Include SSE intrinsics
...
The intel intrinsics (including SSE) are only included in the header if
the arch is x86_64 which made the i686 build fail.
Closes: https://gitlab.gnome.org/GNOME/mutter/-/issues/3234
Fixes: 568506ecb
("cogl: Add half float implementation")
Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/3499 >
2024-01-09 14:43:16 +00:00
Bilal Elmoussaoui
84739c0e96
docs: Remove extra slash from the git show command
...
It adds extra slashes in the end result
Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/3504 >
2024-01-09 14:02:59 +00:00
Albert Esteve
1a0d00467d
backends/native: Fix atomic cursor plane assign
...
Make atomic cursor plane assignment not depending on
cursor hotspot support.
Fixes: 4b9d1271a
("backends/native: Add PLANE_PROP_HOTSPOT_[X,Y]")
Closes: https://gitlab.gnome.org/GNOME/mutter/-/issues/3238
Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/3503 >
2024-01-09 13:52:37 +00:00
Bilal Elmoussaoui
133adc6fb4
docs: Add a logo
...
Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/3484 >
2024-01-09 13:38:54 +00:00
Bilal Elmoussaoui
fded7d29df
data: Remove no longer used icon
...
It is also very ugly and doesn't represent the current state of Mutter
Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/3484 >
2024-01-09 13:38:54 +00:00
Bilal Elmoussaoui
39a8b153d5
backends: Drop unused private functions
...
Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/3492 >
2024-01-09 13:14:35 +00:00
Bilal Elmoussaoui
57b59f95a6
x11: Drop unused private functions
...
Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/3492 >
2024-01-09 13:14:35 +00:00
Bilal Elmoussaoui
74cab06b72
core: Drop unused private functions
...
Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/3492 >
2024-01-09 13:14:35 +00:00
Bilal Elmoussaoui
ad49ecccf7
compositor: Drop unused private functions
...
Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/3492 >
2024-01-09 13:14:35 +00:00
Bilal Elmoussaoui
77d71b5530
misc: Add common noisy dirs to gitignore
...
Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/3500 >
2024-01-08 19:53:57 +01:00
Bilal Elmoussaoui
fb959f3a5d
clutter: Remove no longer useful gitignore
...
Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/3500 >
2024-01-08 19:50:50 +01:00
Zack Rusin
27f798b6d0
kms/impl-device/atomic: Implement mouse cursor hotspots
...
DRM's kms atomic code was updated to include an API to set the mouse
cursor hotspot. This has historically been missing in the atomic kms
which meant that the virtualized drivers which require mouse cursor
hotspot info to properly render had to be put on a deny list and
had to fallback to the legacy DRM kms code.
Implement the new hotspot API by checking whether the device supports
hotspot properties and if it does set them on the cursor plane. This
enables atomic kms on all virtualized drivers for kernels where
mouse cursor hotspots are in drm core.
Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/3337 >
2024-01-08 15:54:15 +01:00
Albert Esteve
3885d2b3f6
backends/native: Set hotspot property on updates
...
Add a `has_update` flag to the cursor hotspot struct
to allow selective update of the hotsport property
only when it will take an effect.
Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/3337 >
2024-01-08 15:54:01 +01:00
Albert Esteve
4b9d1271a0
backends/native: Add PLANE_PROP_HOTSPOT_[X,Y]
...
Add META_KMS_PLANE_PROP_HOTSPOT_[X,Y] properties
to the MetaKmsPlaneProp enumeration, and
properly initialise them.
Also, add a convenience method in meta-kms-plane
(i.e., `meta_kms_plane_supports_cursor_hotspot`)
to check whether a plane supports hotspot
property setting.
Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/3337 >
2024-01-08 15:15:25 +01:00
Daniel van Vugt
8252f71447
onscreen/native: Replace an old strerror with g_strerror
...
For consistency with the previous commit.
Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/3418 >
2024-01-08 13:05:17 +00:00