From 2147d919d6bc20700b282fb3d47ea5d1e08012bc Mon Sep 17 00:00:00 2001 From: foxnne Date: Sun, 18 Oct 2026 18:34:06 -0500 Subject: [PATCH] ci: the example repos are checked at main again Their Zig 0.17 PRs have landed, so check-examples.sh clones each example's default branch, as before the move. The dvui-dev pin's tag, fizzy-sdk-0.2.30-7, is recorded. win32_titlebar.zig takes zig fmt's 0.17 upgrades, which #463 brought in 0.16 form. Co-Authored-By: Claude Opus 5.5 --- backend/src/platform/win32_titlebar.zig | 6 +++--- docs/DEPENDENCIES.md | 14 ++++++-------- scripts/check-examples.sh | 4 +--- sdk/build.zig.zon | 2 +- 4 files changed, 11 insertions(+), 15 deletions(-) diff --git a/backend/src/platform/win32_titlebar.zig b/backend/src/platform/win32_titlebar.zig index 408336540..dca4597ca 100644 --- a/backend/src/platform/win32_titlebar.zig +++ b/backend/src/platform/win32_titlebar.zig @@ -554,11 +554,11 @@ pub fn viewportCarryChrome(hwnd: *anyopaque) void { const dwm = win32.graphics.dwm; const wm = win32.ui.windows_and_messaging; const corner: u32 = DWMWCP_DONOTROUND; - _ = dwm.DwmSetWindowAttribute(h, @enumFromInt(DWMWA_WINDOW_CORNER_PREFERENCE), &corner, @sizeOf(u32)); + _ = dwm.DwmSetWindowAttribute(h, @fromBackingInt(@intCast(DWMWA_WINDOW_CORNER_PREFERENCE)), &corner, @sizeOf(u32)); const none: u32 = dwm.DWMWA_COLOR_NONE; _ = dwm.DwmSetWindowAttribute(h, dwm.DWMWA_BORDER_COLOR, &none, @sizeOf(u32)); const no_transitions: u32 = 1; - _ = dwm.DwmSetWindowAttribute(h, @enumFromInt(DWMWA_TRANSITIONS_FORCEDISABLED), &no_transitions, @sizeOf(u32)); + _ = dwm.DwmSetWindowAttribute(h, @fromBackingInt(@intCast(DWMWA_TRANSITIONS_FORCEDISABLED)), &no_transitions, @sizeOf(u32)); _ = win32.ui.shell.SetWindowSubclass(h, carrySubclassProc, carry_subclass_id, 0); const style = wm.GetWindowLongPtrW(h, wm.GWL_STYLE); _ = wm.SetWindowLongPtrW(h, wm.GWL_STYLE, style & ~carry_ws_frame); @@ -595,7 +595,7 @@ fn carrySubclassProc( if (uMsg == WM_NCHITTEST) return HTTRANSPARENT; if (uMsg == wm.WM_MOUSEACTIVATE) return MA_NOACTIVATE; // SDL sets the window's style again as it likes: never a frame. - if (uMsg == wm.WM_STYLECHANGING and @as(isize, @bitCast(wParam)) == @intFromEnum(wm.GWL_STYLE)) { + if (uMsg == wm.WM_STYLECHANGING and @as(isize, @bitCast(wParam)) == @backingInt(wm.GWL_STYLE)) { const ss: *wm.STYLESTRUCT = @ptrFromInt(@as(usize, @bitCast(lParam))); ss.styleNew &= ~@as(u32, @intCast(carry_ws_frame)); } diff --git a/docs/DEPENDENCIES.md b/docs/DEPENDENCIES.md index 5db963bff..6316a3cc2 100644 --- a/docs/DEPENDENCIES.md +++ b/docs/DEPENDENCIES.md @@ -7,7 +7,7 @@ bump it; keep it current whenever a pin or a patch moves. | Dependency | Upstream | Fizzy's changes | Pinned in | Carries | |---|---|---|---|---| -| [`foxnne/dvui-dev`](https://github.com/foxnne/dvui-dev) | [`david-vanderson/dvui`](https://github.com/david-vanderson/dvui) | branch `fizzy-dev` | `sdk/build.zig.zon` | dvui changes fizzy needs | +| [`foxnne/dvui-dev`](https://github.com/foxnne/dvui-dev) | [`david-vanderson/dvui`](https://github.com/david-vanderson/dvui) | branch `zig-0.17` (on 0.16, `fizzy-dev`) | `sdk/build.zig.zon` | dvui changes fizzy needs | | SDL | [`libsdl-org/SDL`](https://github.com/libsdl-org/SDL) `release-3.4.16` | `backend/patches/sdl` | `backend/build.zig.zon` (`.sdl_source`) | SDL C patches, applied by [zig-patch](https://github.com/marler8997/zig-patch) (below) | | [`fizzyedit/sdl_zig`](https://github.com/fizzyedit/sdl_zig) | [`Games-By-Mason/sdl_zig`](https://github.com/Games-By-Mason/sdl_zig) | branch `fizzy` | `backend/build.zig.zon` (`.sdl`) | the Zig build of SDL, taking the patched tree | @@ -133,9 +133,8 @@ backend and never link SDL, so an SDL bump is never an SDK release and never mov Each of 5 and 6 is also a branch of its own on upstream `main` (`window-draw-retained`, `screens-set`), from which the upstream PR is opened. -**On fizzy's `zig/0.17` branch** the pin is `foxnne/dvui-dev` branch `zig-0.17`, by commit and -as `git+https` (Zig 0.17 hashes this repo's GitHub archive wrongly; `docs/PITFALLS.md`): the eight -above rebased onto upstream `main` (`41f6703`), then: +**Since fizzy moved to Zig 0.17 (#575)** the pin is `foxnne/dvui-dev` branch `zig-0.17`, by tag and +as `git+https`: the eight above rebased onto upstream `main` (`41f6703`), then: 9. **floatingWindow: a backend may show one in an OS window of its own** (`bd7736d`). Patch 8's `osWindowFloating` became `Backend.floatingWindowOs(id, open_flag, min, max)`, asked as @@ -155,8 +154,6 @@ above rebased onto upstream `main` (`41f6703`), then: kind and a lifted finger hovers nothing; `cursorSet` takes a priority, so a resize handle's cursor wins, and a floating window's edges ask at normal priority. -Tagged `fizzy-sdk-*` when `zig/0.17` merges to `main`, as rule 2 says. - Tags: `fizzy-sdk-0.2.13` → `712f7f7` (the stack before this rebase, still what SDK ≤ 0.2.15 builds); `fizzy-sdk-0.2.16` → `4428108` (SDK 0.2.16 to 0.2.18); `fizzy-sdk-0.2.19` → `f8b32db`; `fizzy-sdk-0.2.19-2` → `a90bc70` (0.2.19 was not released yet, and a tag never @@ -166,8 +163,9 @@ moves, so the second pin of one version takes a suffix, as the SDL fork's tags d `e2c9a85` (item 9 alone, never pinned); `fizzy-sdk-0.2.30-2` → `fdc03d4` (pinned by #540); `fizzy-sdk-0.2.30-3` → `cc60612` (never pinned); `fizzy-sdk-0.2.30-4` → `44010a3`; `fizzy-sdk-0.2.30-5` → -`20e56f1` (never pinned on `main`); `fizzy-sdk-0.2.30-6` → `40e664c`, what `sdk/build.zig.zon` -pins now. +`20e56f1` (never pinned on `main`); `fizzy-sdk-0.2.30-6` → `40e664c`, the last pin on Zig 0.16; +`fizzy-sdk-0.2.30-7` → `1b29a16` on `zig-0.17`, what `sdk/build.zig.zon` pins now (SDK 0.2.30, the +first on Zig 0.17). Fizzy builds dvui in its `custom` backend mode on every target and links its own backends (`backend/`, `src/backend/WebBackend.zig` + `web/web.js`), so dvui's `sdl3` and `web` diff --git a/scripts/check-examples.sh b/scripts/check-examples.sh index a90d487f5..7295127e6 100755 --- a/scripts/check-examples.sh +++ b/scripts/check-examples.sh @@ -50,9 +50,7 @@ for repo in example-app example-plugin; do mkdir -p "$work/$repo" pack "$EXAMPLES_DIR/$repo" | tar -x -C "$work/$repo" else - # ZIG017: the examples' zig-0.17 branches until their 0.17 PRs land (just after fizzy's - # switch to 0.17), then `main` again in a PR of its own. - git clone --quiet --depth 1 --branch "${EXAMPLES_REF:-zig-0.17}" "https://github.com/fizzyedit/$repo" "$work/$repo" + git clone --quiet --depth 1 "https://github.com/fizzyedit/$repo" "$work/$repo" fi done diff --git a/sdk/build.zig.zon b/sdk/build.zig.zon index 26e235959..75b16341c 100644 --- a/sdk/build.zig.zon +++ b/sdk/build.zig.zon @@ -40,7 +40,7 @@ // `fizzy-sdk-` tag in the fork before the pin lands. `fizzy-dev` itself stays a // working branch and can be rebased freely — the tag, never. .dvui = .{ - // zig-0.17 branch (zig/0.17 pins a commit; tagged when it merges to main) + // fizzy-sdk-0.2.30-7, on the zig-0.17 branch (docs/DEPENDENCIES.md) .url = "git+https://github.com/foxnne/dvui-dev#1b29a16d0340005c0d5ed2b689a7ffab797b1c37", .hash = "dvui-0.6.0-dev-AQFJmXGtBAE8dNSt4nGJ7ToMZ9HR7rdMVubvTlhzO-mk", //.path = "../../dvui-dev",