From 6b1dd3e4419df5fcf0ea5493e1f4468e07aed6d4 Mon Sep 17 00:00:00 2001 From: Mitchell Hashimoto Date: Thu, 14 Aug 2025 15:01:00 -0700 Subject: [PATCH] apprt/gtk-ng: implement `maximize` and `fullscreen` These fell through the cracks. --- src/apprt/gtk-ng/class/window.zig | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/src/apprt/gtk-ng/class/window.zig b/src/apprt/gtk-ng/class/window.zig index acba271c1..18e9178ac 100644 --- a/src/apprt/gtk-ng/class/window.zig +++ b/src/apprt/gtk-ng/class/window.zig @@ -319,8 +319,15 @@ pub const Window = extern struct { ); } + // Start states based on config. + if (priv.config) |config_obj| { + const config = config_obj.get(); + if (config.maximize) self.as(gtk.Window).maximize(); + if (config.fullscreen) self.as(gtk.Window).fullscreen(); + } + // We always sync our appearance at the end because loading our - // config and such can affect our bindings which ar setup initially + // config and such can affect our bindings which are setup initially // in initTemplate. self.syncAppearance();