cursor-sprite: Register all cursor sprites with the cursor tracker

This will later be used to invalidate GPU state when closing device
nodes.

Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/2147>
This commit is contained in:
Jonas Ådahl
2021-11-15 14:24:53 +01:00
committed by Marge Bot
parent c498ae337f
commit 25ed64b61d
13 changed files with 141 additions and 14 deletions

View File

@ -64,11 +64,14 @@ meta_cursor_sprite_wayland_invalidate (MetaCursorSprite *sprite)
}
MetaCursorSpriteWayland *
meta_cursor_sprite_wayland_new (MetaWaylandSurface *surface)
meta_cursor_sprite_wayland_new (MetaWaylandSurface *surface,
MetaCursorTracker *cursor_tracker)
{
MetaCursorSpriteWayland *sprite_wayland;
sprite_wayland = g_object_new (META_TYPE_CURSOR_SPRITE_WAYLAND, NULL);
sprite_wayland = g_object_new (META_TYPE_CURSOR_SPRITE_WAYLAND,
"cursor-tracker", cursor_tracker,
NULL);
sprite_wayland->surface = surface;
return sprite_wayland;