From 7f0c2477679cea555cb9f17f0f309e47587aba2b Mon Sep 17 00:00:00 2001 From: Mitchell Hashimoto Date: Sat, 19 Jul 2025 07:26:58 -0700 Subject: [PATCH] Fully remove the redrawSurface API This is a tiny addon from the recent gtk-ng work. We've moved redraw requests into the apprt action system (the `render` action). I waited until I had my macOS machine to verify that this fix could work. We can now remove this completely. We can probably remove the redraw inspector API too at some point but I'm not there yet with the GTK backend so I'll just wait on it. --- src/App.zig | 8 -------- src/apprt/embedded.zig | 6 ------ 2 files changed, 14 deletions(-) diff --git a/src/App.zig b/src/App.zig index c4c7ad55b..effef0c5f 100644 --- a/src/App.zig +++ b/src/App.zig @@ -293,14 +293,6 @@ fn redrawSurface( ) !void { if (!self.hasRtSurface(surface)) return; - // TODO: Remove this in a separate PR. We should transition to - // the `render` apprt action completely. This is only to make - // our initial gtk-ng work touch less things. - if (@hasDecl(apprt.App, "redrawSurface")) { - rt_app.redrawSurface(surface); - return; - } - _ = try rt_app.performAction( .{ .surface = surface.core() }, .render, diff --git a/src/apprt/embedded.zig b/src/apprt/embedded.zig index 25e344983..c21f57ffb 100644 --- a/src/apprt/embedded.zig +++ b/src/apprt/embedded.zig @@ -249,12 +249,6 @@ pub const App = struct { self.core_app.alloc.destroy(surface); } - pub fn redrawSurface(self: *App, surface: *Surface) void { - _ = self; - _ = surface; - // No-op, we use a threaded interface so we're constantly drawing. - } - pub fn redrawInspector(self: *App, surface: *Surface) void { _ = self; surface.queueInspectorRender();