clay/examples
Seintian 8643a5d2d9 Fix Ncurses click handling and restore ncursesw build
This commit addresses issues with mouse interaction reliability and build configuration in the Ncurses renderer and example.

Renderer Changes:
- Enable explicit xterm 1003 mouse tracking (Any Event) via escape sequences to ensure reliable hover sensing from the first frame (though not so portable).
- Refactor `Clay_Ncurses_ProcessInput` to:
  - Correctly order `Clay_SetPointerState` calls to ensure the "Pressed" state is registered before the function returns.
  - Detect and return a new `CLAY_NCURSES_KEY_MOUSE_CLICK` event code for single, double, and triple clicks.
- Make `Clay_Ncurses_OnClick` as a semantic wrapper around `Clay_OnHover`.
- Add empty switch cases for `CLAY_RENDER_COMMAND_TYPE_IMAGE` and `CLAY_RENDER_COMMAND_TYPE_CUSTOM` to prevent unhandled enumeration warnings.

Example Application Changes:
- Update `main.c` to break the input processing loop immediately upon receiving `CLAY_NCURSES_KEY_MOUSE_CLICK`, ensuring the "Pressed" state is processed by the layout engine for that frame.

Build System:
- Update `CMakeLists.txt` to replace `FindCurses` with `find_library` and `find_path` for `ncursesw`.
2025-12-29 21:57:50 +01:00
..
cairo-pdf-rendering [Core] Remove ID from element declaration struct and split clay macro into CLAY and CLAY_WITHID (#492) 2025-09-16 11:39:07 +10:00
clay-official-website [Core] Update Clay_OnHover to take void* instead of uintptr_t (#334) 2025-11-26 15:11:34 +11:00
cpp-project-example [Core] Remove ID from element declaration struct and split clay macro into CLAY and CLAY_WITHID (#492) 2025-09-16 11:39:07 +10:00
introducing-clay-video-demo [Renderers/Raylib] Pin raylib version to 5.5 2025-04-29 12:43:44 +12:00
ncurses-example Fix Ncurses click handling and restore ncursesw build 2025-12-29 21:57:50 +01:00
playdate-project-example [Core] Remove ID from element declaration struct and split clay macro into CLAY and CLAY_WITHID (#492) 2025-09-16 11:39:07 +10:00
raylib-multi-context [Renderers/Raylib] Pin raylib version to 5.5 2025-04-29 12:43:44 +12:00
raylib-sidebar-scrolling-container [Core] Remove ID from element declaration struct and split clay macro into CLAY and CLAY_WITHID (#492) 2025-09-16 11:39:07 +10:00
SDL2-video-demo [Renderers/SDL2] Indent SDL2's CMakeLists.txt consistently (#424) 2025-05-28 09:50:00 +10:00
SDL3-simple-demo [Core] Remove ID from element declaration struct and split clay macro into CLAY and CLAY_WITHID (#492) 2025-09-16 11:39:07 +10:00
shared-layouts [Core] Update Clay_OnHover to take void* instead of uintptr_t (#334) 2025-11-26 15:11:34 +11:00
sokol-corner-radius [Core] Remove ID from element declaration struct and split clay macro into CLAY and CLAY_WITHID (#492) 2025-09-16 11:39:07 +10:00
sokol-video-demo [Core] Fix a string hash bug with single characters (#384) 2025-04-16 20:16:05 +12:00
termbox2-demo Fixed termbox2 demo build, added scroll functionality (#523) 2025-10-23 12:57:11 +11:00
termbox2-image-demo [Renderers/termbox] Fixing termbox2-image-demo build error (#524) 2025-10-02 11:21:11 +10:00
terminal-example [Renderers/Terminal] Add initial implementation of terminal renderer (#91) 2025-05-22 12:45:52 +12:00
win32_gdi [Renderers/WinGDI] Working on Win32 GDI renderer and example (#344) 2025-04-09 11:31:33 +12:00