From 642c7c8cab9dc4efe056a7774b42832646a43ba3 Mon Sep 17 00:00:00 2001 From: Kartik Agaram Date: Sun, 6 Dec 2020 21:57:27 -0800 Subject: 7342 - tile: hotkeys for ending function edit --- apps/tile/environment.mu | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) (limited to 'apps') diff --git a/apps/tile/environment.mu b/apps/tile/environment.mu index 3103dd6e..1795b32b 100644 --- a/apps/tile/environment.mu +++ b/apps/tile/environment.mu @@ -267,6 +267,26 @@ fn process-function-edit _self: (addr environment), _function: (addr function), cursor-to-end cursor-word return } + # bounce to another function + compare key, 7 # ctrl-g + $process-function-edit:goto-function: { + break-if-!= + # initialize dialog to name function to jump to + var partial-function-name-ah/eax: (addr handle word) <- get self, partial-function-name + allocate partial-function-name-ah + var partial-function-name/eax: (addr word) <- lookup *partial-function-name-ah + initialize-word partial-function-name + return + } + # bounce to sandbox + compare key, 9 # tab + $process-function-edit:goto-sandbox: { + break-if-!= + var function-ah/eax: (addr handle function) <- get self, cursor-function + clear-object function-ah + return + } + # editing the current function compare key, 0x7f # del (backspace on Macs) $process-function-edit:backspace: { break-if-!= -- cgit 1.4.1-2-gfad0