mod: replace Layout.content with Layout.render
Some checks failed
Zig Project Action / Lint, Spell-check and test zig project (push) Failing after 30s

The App.Renderer is used for the new `Layout.render` method. Each layout
renders itself now with corresponding renderers which might only update
parts of the screen, etc.
This commit is contained in:
2024-11-10 14:34:28 +01:00
parent b32556720e
commit b314ff7813
12 changed files with 112 additions and 92 deletions

View File

@@ -45,9 +45,9 @@ pub fn App(comptime E: type, comptime R: fn (comptime bool) type, comptime fulls
}
return struct {
pub const Event = mergeTaggedUnions(event.SystemEvent, E);
pub const Layout = @import("layout.zig").Layout(Event);
pub const Widget = @import("widget.zig").Widget(Event);
pub const Renderer = R(fullscreen);
pub const Layout = @import("layout.zig").Layout(Event, Renderer);
pub const Widget = @import("widget.zig").Widget(Event);
queue: Queue(Event, 256) = .{},
thread: ?std.Thread = null,