╭──────────╮ │← previous│ ╰──────────╯ ╭ changed ──────╮ │src/ui/Quit.zig│ ╰───────────────╯ ╭─────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╮ │27 button_id: usize, │ │28 │ │29 pub fn init(allocator: std.mem.Allocator, data: *const Self, session: *ui.Session) !View { │ │30 - var box = wgt.Box(ui.Widget).init(.{ .border_style = null, .rounded_corners = true, .direction = .vert }); │ │30 + var box = try wgt.Box(ui.Widget).init(allocator, .{ .border_style = null, .rounded_corners = true, .direction = .vert });│ │31 errdefer box.deinit(allocator); │ │32 │ │33 { │ ╰─────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯ ╭──────────────────────────────────────────────────────────────────────────────────────╮ │34 - var prompt = wgt.Text(ui.Widget).init("are you sure?"); │ │34 + var prompt = try wgt.Text(ui.Widget).init(allocator, "are you sure?");│ │35 errdefer prompt.deinit(allocator); │ │36 try box.children.put(allocator, prompt.getFocus().id, .{ │ │37 .widget = .{ .text = prompt }, │ ╰──────────────────────────────────────────────────────────────────────────────────────╯ ╭ changed ──────╮ │src/ui/Repo.zig│ ╰───────────────╯ ╭──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╮ │ 95 const stack_index: usize = 1; │ │ 96 │ │ 97 pub fn init(allocator: std.mem.Allocator, data: *const Self, session: *ui.Session) !View { │ │ 98 - var box = wgt.Box(ui.Widget).init(.{ .border_style = null, .rounded_corners = true, .direction = .vert }); │ │ 98 + var box = try wgt.Box(ui.Widget).init(allocator, .{ .border_style = null, .rounded_corners = true, .direction = .vert });│ │ 99 errdefer box.deinit(allocator); │ │100 │ │101 // build the header first so we can grab the files-tab id for the auth │ ╰──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯ ╭─────────────────────────────────────────────────────────────────────────────╮ │109 } │ │110 │ │111 { │ │112 - var stack = wgt.Stack(ui.Widget).init(); │ │112 + var stack = try wgt.Stack(ui.Widget).init(allocator); │ │113 errdefer stack.deinit(allocator); │ │114 │ │115 // files — the default tab: the current directory's listing.│ ╰─────────────────────────────────────────────────────────────────────────────╯ ╭ changed ──────────────╮ │src/ui/Repo/Commits.zig│ ╰───────────────────────╯ ╭─────────────────────────────────────────────────────────────────────────────────────────────────────────────╮ │120 data: *const Self, │ │121 │ │122 pub fn init(allocator: std.mem.Allocator, data: *const Self, session: *ui.Session) !View { │ │123 - var box = wgt.Box(ui.Widget).init(.{ .border_style = null, .direction = .vert }); │ │123 + var box = try wgt.Box(ui.Widget).init(allocator, .{ .border_style = null, .direction = .vert });│ │124 errdefer box.deinit(allocator); │ │125 │ │126 // labels and link kinds are borrowed by the rows, so they live in the │ ╰─────────────────────────────────────────────────────────────────────────────────────────────────────────────╯ ╭──────────────────────────────────────────────────────────────────────────────────────────────────────────────╮ │135 } │ │136 if (box.children.count() > 0) box.getFocus().child_id = box.children.keys()[0]; │ │137 │ │138 - var scroll = try wgt.Scroll(ui.Widget).init(allocator, .{ .box = box }, .vert); │ │138 + var scroll = try wgt.Scroll(ui.Widget).init(allocator, .{ .box = box }, .{ .direction = .vert });│ │139 errdefer scroll.deinit(allocator); │ │140 return .{ .scroll = scroll, .data = data }; │ │141 } │ ╰──────────────────────────────────────────────────────────────────────────────────────────────────────────────╯ ╭ changed ────────────╮ │src/ui/Repo/Files.zig│ ╰─────────────────────╯ ╭─────────────────────────────────────────────────────────────────────────────────────────────────────────────╮ │ 97 data: *const Self, │ │ 98 │ │ 99 pub fn init(allocator: std.mem.Allocator, data: *const Self, session: *ui.Session) !View { │ │100 - var box = wgt.Box(ui.Widget).init(.{ .border_style = null, .direction = .vert }); │ │100 + var box = try wgt.Box(ui.Widget).init(allocator, .{ .border_style = null, .direction = .vert });│ │101 errdefer box.deinit(allocator); │ │102 │ │103 // labels and link kinds are borrowed by the rows, so they live in the │ ╰─────────────────────────────────────────────────────────────────────────────────────────────────────────────╯ ╭──────────────────────────────────────────────────────────────────────────────────────────────────────────────╮ │113 } │ │114 if (box.children.count() > 0) box.getFocus().child_id = box.children.keys()[0]; │ │115 │ │116 - var scroll = try wgt.Scroll(ui.Widget).init(allocator, .{ .box = box }, .vert); │ │116 + var scroll = try wgt.Scroll(ui.Widget).init(allocator, .{ .box = box }, .{ .direction = .vert });│ │117 errdefer scroll.deinit(allocator); │ │118 return .{ .scroll = scroll, .data = data }; │ │119 } │ ╰──────────────────────────────────────────────────────────────────────────────────────────────────────────────╯ ╭ changed ─────────────╮ │src/ui/Repo/Header.zig│ ╰──────────────────────╯ ╭─────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╮ │32 tab_ids: std.AutoArrayHashMapUnmanaged(usize, void), │ │33 │ │34 pub fn init(allocator: std.mem.Allocator, data: *const Self, session: *ui.Session) !View { │ │35 - var box = wgt.Box(ui.Widget).init(.{ .border_style = .hidden, .rounded_corners = true, .direction = .horiz }); │ │35 + var box = try wgt.Box(ui.Widget).init(allocator, .{ .border_style = .hidden, .rounded_corners = true, .direction = .horiz });│ │36 errdefer box.deinit(allocator); │ │37 │ │38 var tab_ids: std.AutoArrayHashMapUnmanaged(usize, void) = .empty; │ ╰─────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯ ╭────────────────────────────────────────────────────────────────────────╮ │74 │ │75 // spacer │ │76 { │ │77 - var text = wgt.Text(ui.Widget).init(" "); │ │77 + var text = try wgt.Text(ui.Widget).init(allocator, " ");│ │78 errdefer text.deinit(allocator); │ │79 try box.children.put(allocator, text.getFocus().id, .{ │ │80 .widget = .{ .text = text }, │ ╰────────────────────────────────────────────────────────────────────────╯ ╭──────╮ │next →│ ╰──────╯