From 9943c05b4a6a63644313ea7c4cb27926a17b02e9 Mon Sep 17 00:00:00 2001 From: ollie Date: Sun, 17 May 2026 17:43:47 +0200 Subject: [PATCH] docs: mark signature changes and _x11_raw eliminations complete --- ACTION_PLAN.md | 32 ++++++++++++++++---------------- WAYLAND_ROADMAP.md | 12 ++++++++---- 2 files changed, 24 insertions(+), 20 deletions(-) diff --git a/ACTION_PLAN.md b/ACTION_PLAN.md index 82f29a1..894f7cd 100644 --- a/ACTION_PLAN.md +++ b/ACTION_PLAN.md @@ -96,7 +96,7 @@ Key architecture point: wrlib's `convert_image` function pointer (`context->conv ### A5: Alt-Tab Window Cycling -#### A5.1 Change `wSwitchPanelHandleEvent` signature from `XEvent*` to `WMEvent*` +#### A5.1 ~~Change `wSwitchPanelHandleEvent` signature from `XEvent*` to `WMEvent*`~~ ✅ - **Files**: `src/switchpanel.c:684`, `src/switchpanel.h:33` - **Operation**: 1. Change function signature from `WWindow *wSwitchPanelHandleEvent(WSwitchPanel *panel, XEvent *event)` to `WWindow *wSwitchPanelHandleEvent(WSwitchPanel *panel, WMEvent *event)` @@ -105,7 +105,7 @@ Key architecture point: wrlib's `convert_image` function pointer (`context->conv 4. Replace `event->type == MotionNotify` with `event->type == WME_MOTION`, etc. - **Blocked by**: nothing -#### A5.2 Remove XEvent synthesis in `cycling.c` +#### A5.2 ~~Remove XEvent synthesis in `cycling.c`~~ ✅ - **File**: `src/cycling.c:227-259` - **Operation**: After A5.1, the `wSwitchPanelHandleEvent` takes `WMEvent*`. Delete the entire XEvent synthesis block (lines 227-259) and replace with: ```c @@ -134,7 +134,7 @@ Key architecture point: wrlib's `convert_image` function pointer (`context->conv - **Xlib calls eliminated**: 0 (guards only; actual Xlib calls are in `xdnd.c`) - **Blocked by**: nothing -### B.3 Change `wDockReceiveDNDDrop` signature from `XEvent*` to `WMEvent*` +### B.3 ~~Change `wDockReceiveDNDDrop` signature from `XEvent*` to `WMEvent*`~~ ✅ - **Files**: `src/dock.c:2009`, `src/dock.h:97` - **Operation**: Same pattern as A5.1. Change `int wDockReceiveDNDDrop(WScreen *scr, XEvent *event)` to take `WMEvent*`. Update the single call site in `event.c:782` to pass the `WMEvent` instead of casting `_x11_raw`. - **Xlib calls eliminated**: 1 `_x11_raw` access in `event.c` @@ -315,12 +315,12 @@ Key architecture point: wrlib's `convert_image` function pointer (`context->conv - **Xlib calls eliminated**: 16 `_x11_raw` accesses - **Blocked by**: B.3, E.3 -### E.3 Change `wRootMenuPerformShortcut` from `XEvent*` to `WMEvent*` +### E.3 ~~Change `wRootMenuPerformShortcut` from `XEvent*` to `WMEvent*`~~ ✅ - **Files**: `src/rootmenu.c:320`, `src/rootmenu.h:25` - **Operation**: Change signature from `Bool wRootMenuPerformShortcut(XEvent *event)` to `Bool wRootMenuPerformShortcut(WMEvent *event)`. Update internals to use `event->u.key.*` fields instead of `event->xkey.*`. - **Blocked by**: nothing -### E.4 Eliminate X11 types in `client.c` function signatures +### E.4 ~~Eliminate X11 types in `client.c` function signatures~~ ✅ - **Files**: `src/client.c:119,247`, `src/client.h:27,31` - **Operation**: 1. `wClientConfigure(WWindow *wwin, XConfigureRequestEvent *xcre)` → change parameter to `WMEvent *event` and extract fields from `event->u.configureRequest.*` @@ -399,17 +399,17 @@ Key architecture point: wrlib's `convert_image` function pointer (`context->conv ## Remaining `src/` Cleanup (not phase-specific) -### R.1 Eliminate `_x11_raw` in `framewin.c` +### R.1 ~~Eliminate `_x11_raw` in `framewin.c`~~ ✅ - **File**: `src/framewin.c:1165` - **Operation**: The `_x11_raw` access is in a titlebar click handler. Replace with `WMEvent` field access. - **Blocked by**: nothing -### R.2 Eliminate `_x11_raw` in `icon.c` +### R.2 ~~Eliminate `_x11_raw` in `icon.c`~~ ✅ - **File**: `src/icon.c:861` - **Operation**: The `_x11_raw` access is in `miniwindowDblClick`. Replace with `WMEvent` field access. - **Blocked by**: nothing -### R.3 Eliminate `_x11_raw` in `menu.c` +### R.3 ~~Eliminate `_x11_raw` in `menu.c`~~ ✅ - **File**: `src/menu.c:738` - **Operation**: The `_x11_raw` access is in `check_key`. Replace with `WMEvent` field access for key handling. - **Blocked by**: nothing @@ -463,10 +463,10 @@ IMMEDIATE (unblocks everything else): WAVE 1 (independent, no prerequisites): A4.1 workspace.c USE_XINERAMA → backend-neutral - A5.1 switchpanel.c XEvent* → WMEvent* + A5.1 ~~switchpanel.c XEvent* → WMEvent*~~ ✅ B.1 appicon.c XClearArea → vtable B.2 appicon.c USE_DOCK_XDND → backend - B.3 dock.c/h XEvent* → WMEvent* + B.3 ~~dock.c/h XEvent* → WMEvent*~~ ✅ C.1 moveres.c XDrawLine → overlay vtable D.1 widgets.c screen init → backend guard D.3 winputmethod.c → _x11/_wl split @@ -475,11 +475,11 @@ WAVE 1 (independent, no prerequisites): D.10 wpopupbutton.c grabs → viewBackend D.11 wappresource.c props → backend guard D.12 wmisc.c coords → viewBackend - E.3 rootmenu.c XEvent* → WMEvent* - E.4 client.c X11 types → WMEvent* - R.1 framewin.c _x11_raw → WMEvent - R.2 icon.c _x11_raw → WMEvent - R.3 menu.c _x11_raw → WMEvent + E.3 ~~rootmenu.c XEvent* → WMEvent*~~ ✅ + E.4 ~~client.c X11 types → WMEvent*~~ ✅ + R.1 ~~framewin.c _x11_raw → WMEvent~~ ✅ + R.2 ~~icon.c _x11_raw → WMEvent~~ ✅ + R.3 ~~menu.c _x11_raw → WMEvent~~ ✅ R.4 misc.c Xlib → vtable R.5 usermenu.c Xlib → vtable R.6 xmodifier.c → backend guard @@ -489,7 +489,7 @@ WAVE 1 (independent, no prerequisites): I.2 xdnd.c — verify X11-only paths WAVE 2 (depends on Wave 1): - A5.2 cycling.c XEvent synthesis → delete + A5.2 ~~cycling.c XEvent synthesis → delete~~ ✅ D.2 wwindow.c ICCCM → viewBackend D.4 wballoon.c drawing → renderBackend D.7 wcolorpanel.c → renderBackend/viewBackend diff --git a/WAYLAND_ROADMAP.md b/WAYLAND_ROADMAP.md index b48102c..4f8812e 100644 --- a/WAYLAND_ROADMAP.md +++ b/WAYLAND_ROADMAP.md @@ -1,6 +1,6 @@ # WindowMaker Wayland Port — Roadmap -Last updated: 2026-05-16 +Last updated: 2026-05-17 ## Governing Principles @@ -50,7 +50,7 @@ Three major libraries: --- -## Completed (as of 2026-05-14) +## Completed (as of 2026-05-17) - Backend vtable abstraction (150+ slots) - Policy layer fully X11-free (zero direct Xlib calls in WM core) @@ -71,6 +71,10 @@ Three major libraries: - Focus delivery (wlr_seat_keyboard_notify_enter) - WINGs Wayland backend (views, fonts/PangoFT2, events/ring buffer, rendering/pixman, colors) - Smoke test suite (30+ tests in tests/wl-smoke-test.sh) +- Alt-Tab window cycling (switch panel) +- Signature changes: wSwitchPanelHandleEvent, wDockReceiveDNDDrop, wRootMenuPerformShortcut, wClientConfigure, wClientCheckProperty — all XEvent*/X11 types → WMEvent* +- _x11_raw eliminations in framewin.c, icon.c, menu.c, event.c (7 of 16 sites eliminated) +- XEvent synthesis block deleted in cycling.c --- @@ -84,7 +88,7 @@ Priority: HIGH — needed for daily-driver use. | A2 | ~~Window maximize~~ | actions.c, usable area calc | ✅ Done | | A3 | ~~Window shade (titlebar collapse)~~ | actions.c, frame buffer resize | ✅ Done | | A4 | Workspace switching (create/destroy/switch) | workspace.c, scene tree reparenting | Medium | -| A5 | Alt-Tab window cycling + switch panel | cycling.c, switchpanel.c, vtable switchpanel_enter | Medium | +| A5 | ~~Alt-Tab window cycling + switch panel~~ | cycling.c, switchpanel.c, vtable switchpanel_enter | Medium | | A6 | ~~Window iconification (minimize) + miniwindow~~ | icon.c, appicon.c, vtable icon_paint/icon_update_pixmap | Done | | A7 | Window placement algorithms (smart/cascade/random) | placement.c (may already work via vtable) | Low | @@ -218,7 +222,7 @@ NOW (daily-driver basics): A2. ~~Maximize~~ ✅ A3. ~~Shade~~ ✅ A4. Workspace switching - A5. Alt-Tab cycling + ~~A5. Alt-Tab cycling~~ ✅ A6. Icon/minimize A7. Placement (verify)