From 3261bbdce6cc0fa494c257849cb69c640f1aeade Mon Sep 17 00:00:00 2001 From: Victor Kareh Date: Tue, 9 Sep 2025 10:34:49 -0400 Subject: theme: Include shadow and resize borders Extend MetaFrameBorders to include shadow and resize borders to calculate invisible border size. Also added border caching to prevent recalculating borders on every frame operation. This is a backport of the following commits from Metacity: - https://gitlab.gnome.org/GNOME/metacity/-/commit/21e664af - https://gitlab.gnome.org/GNOME/metacity/-/commit/3c6e269b - https://gitlab.gnome.org/GNOME/metacity/-/commit/700e87ea --- src/core/frame-private.h | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'src/core/frame-private.h') diff --git a/src/core/frame-private.h b/src/core/frame-private.h index 8c2a2eeb..77216420 100644 --- a/src/core/frame-private.h +++ b/src/core/frame-private.h @@ -48,9 +48,13 @@ struct _MetaFrame int right_width; int bottom_height; + /* valid if borders_cached is set */ + MetaFrameBorders cached_borders; + guint mapped : 1; guint need_reapply_frame_shape : 1; guint is_flashing : 1; /* used by the visual bell flash */ + guint borders_cached : 1; }; void meta_window_ensure_frame (MetaWindow *window); -- cgit v1.2.1