From 91646cbafee3ff67baff52499529ac9077675239 Mon Sep 17 00:00:00 2001 From: Mitya Selivanov Date: Tue, 7 Jan 2025 00:16:22 +0100 Subject: Fix clipboard; TODO keys --- examples/ui.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) (limited to 'examples/ui.c') diff --git a/examples/ui.c b/examples/ui.c index 1301a6c..d595617 100755 --- a/examples/ui.c +++ b/examples/ui.c @@ -172,7 +172,7 @@ void update_and_render_frame(void) { ++cursor; break; - case '\b': + case KEY_BACKSPACE: if (selection != 0) { i64 i0 = selection < 0 ? cursor + selection : cursor; i64 i1 = selection < 0 ? cursor : cursor + selection; @@ -205,9 +205,8 @@ void update_and_render_frame(void) { } break; - case '\n': - case '\r': - case '\t': + case KEY_ENTER: + case KEY_TAB: platform.input[i].c = platform.input[i].key; // fallthrough -- cgit v1.2.3