diff options
| author | Gabriel Schneider <[email protected]> | 2026-11-19 23:51:23 -0300 |
|---|---|---|
| committer | Gabriel Schneider <[email protected]> | 2026-11-20 00:00:00 -0300 |
| commit | 8a1f65a2d374796b9b5559c4aab87c8d1e8f6e68 (patch) | |
| tree | 24c4d770b8ac5a11e1f0169f9e0707fda8cde678 /runtime/macos.zig | |
| parent | d236dff22567c2f563756695598678afb84fbef4 (diff) | |
| parent | a310585195484b8420f14cff3e736c604f47c11e (diff) | |
| download | pardes-8a1f65a2d374796b9b5559c4aab87c8d1e8f6e68.tar.gz pardes-8a1f65a2d374796b9b5559c4aab87c8d1e8f6e68.zip | |
integration: the ruled renames on the documents and the load-independent tests: pardes-renames (config.Settings, macos.Callbacks, core/ninep/harness.zig, Pane.docked_to and the word Undock) and pardes-merge23; one conflict, in core/CHANGELOG.md, where both sides added Unreleased entries: both kept; no old name left in the tree; tui core-test 848/991 (143 skipped), shell-test 1027/1030, the window builds
Co-Authored-By: Claude Fable 5.2 <[email protected]>
Claude-Session: https://claude.ai/code/session_016Y9MNBECMWcJD5pdS4SR6T
Diffstat (limited to 'runtime/macos.zig')
| -rw-r--r-- | runtime/macos.zig | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/runtime/macos.zig b/runtime/macos.zig index 408915da..a5869753 100644 --- a/runtime/macos.zig +++ b/runtime/macos.zig @@ -103,7 +103,7 @@ pub const Image = extern struct { paper_bg: u32, }; -pub const Runtime = extern struct { +pub const Callbacks = extern struct { userdata: ?*anyopaque = null, wakeup: ?*const fn (?*anyopaque) callconv(.c) void = null, set_clipboard: ?*const fn (?*anyopaque, [*]const u8, usize) callconv(.c) void = null, @@ -250,7 +250,7 @@ const State = struct { io: std.Io, core: *pardes.Pardes, started: bool = false, - runtime: Runtime, + runtime: Callbacks, tag_cells: [pardes.MAX_TAG_LAYERS][]Cell = @splat(&.{}), layer_cells: [pardes.MAX_PANES][]Cell = @splat(&.{}), cells: []Cell = &.{}, @@ -290,7 +290,7 @@ const State = struct { var state: ?State = null; -export fn pardes_init(runtime: ?*const Runtime, cols_arg: u16, rows_arg: u16) c_int { +export fn pardes_init(runtime: ?*const Callbacks, cols_arg: u16, rows_arg: u16) c_int { if (state != null) return 1; // already up; deinit first initCore(runtime, cols_arg, rows_arg) catch |err| { log.err("init failed: {t}", .{err}); @@ -302,7 +302,7 @@ export fn pardes_init(runtime: ?*const Runtime, cols_arg: u16, rows_arg: u16) c_ /// The shell's gpa in a Debug build, as std.start's is for the others. var debug_gpa: std.heap.DebugAllocator(.{}) = .init; -fn initCore(runtime: ?*const Runtime, cols_arg: u16, rows_arg: u16) !void { +fn initCore(runtime: ?*const Callbacks, cols_arg: u16, rows_arg: u16) !void { // The allocator every other shell gets from std.start: a DebugAllocator // in Debug, libc's malloc otherwise. libc's measured at least as fast as // std.heap.smp_allocator everywhere and faster on MuPDF's page-sized @@ -2461,7 +2461,7 @@ test "pardes.h matches the Zig boundary" { try expectEqual(@sizeOf(c.pardes_image_s), @sizeOf(Image)); inline for (@typeInfo(Image).@"struct".field_names) |name| try expectEqual(@offsetOf(c.pardes_image_s, name), @offsetOf(Image, name)); - try expectEqual(@sizeOf(c.pardes_runtime_s), @sizeOf(Runtime)); + try expectEqual(@sizeOf(c.pardes_callbacks_s), @sizeOf(Callbacks)); try expectEqual(@as(u32, c.PARDES_COLOR_DEFAULT), color_default); try expectEqual(@as(u32, c.PARDES_COLOR_INDEXED), color_indexed); |
