diff options
Diffstat (limited to 'packages/kernel/kernel.md')
| -rw-r--r-- | packages/kernel/kernel.md | 21 |
1 files changed, 18 insertions, 3 deletions
diff --git a/packages/kernel/kernel.md b/packages/kernel/kernel.md index e2ee684..18d7c85 100644 --- a/packages/kernel/kernel.md +++ b/packages/kernel/kernel.md @@ -1,8 +1,11 @@ # kernel — package notes -Slice-1 state: a probe surface (`kernel.hpp`) proving C++ ↔ wlroots ↔ RMLUi -compile/link. Real contracts (extension host, bus, scene/seat glue, ui -substrate) land from slice 2. +Slice-2 state: a working tinywl port (+ touch, which tinywl lacks) wholly +inside the kernel: backend/output/scene glue, xdg-shell toplevels + popups, +click/tap-to-focus, Alt-drag-free interactive move/resize (client-requested +only), keyboard/pointer/touch via one wlr_cursor path. Slice-2 keybindings: +Alt+Escape = terminate, Alt+F1 = cycle. Slice 4 splits shell policy out +into extensions. Gotchas the headers can't express: @@ -16,4 +19,16 @@ Gotchas the headers can't express: `kernel_dep` propagation (see meson.build): extensions contribute RML documents + data bindings via the ui substrate, never RMLUi API calls. Do not "fix" a missing-RMLUi-header error downstream by propagating it. +- **Shutdown order is load-bearing** (`Impl::shutdown()`): destroy clients + → disconnect ALL server-level Listeners → scene/cursor/allocator/ + renderer/backend/display. A Listener outliving the wlr object owning its + signal is a use-after-free (`wl_list_remove` touches neighbor links). + Entity-level Listeners are exempt: their destroy events fire (and erase + the entities) during `wl_display_destroy_clients` / backend destroy. +- **A Listener handler may destroy its own Listener** (the destroy-event + pattern) but the erase/delete must be the handler's LAST action — see + listener.hpp. The slice-4 bus formalizes this. +- **Touch points record their down-surface's layout origin** to derive + surface-local motion coords; a surface moving mid-touch (interactive + grab) skews them. Acceptable until slice 5's input routing. - Everything runs on the single `wl_event_loop` thread. |
