diff options
author | Kartik K. Agaram <vc@akkartik.com> | 2021-08-14 15:39:14 -0700 |
---|---|---|
committer | Kartik K. Agaram <vc@akkartik.com> | 2021-08-14 15:39:14 -0700 |
commit | 55cac9e7a9943f53e17a1d02eb8e39eafb59ce24 (patch) | |
tree | 282f3148858241d9c8bfe3090883102352755aba /browse-slack | |
parent | 6706c69407c98fae906956821bb3b6fb69b58fd6 (diff) | |
download | mu-55cac9e7a9943f53e17a1d02eb8e39eafb59ce24.tar.gz |
slack: start building a cursor for the main pane
First step: switch to arrow keys for navigating by item.
Diffstat (limited to 'browse-slack')
-rw-r--r-- | browse-slack/environment.mu | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/browse-slack/environment.mu b/browse-slack/environment.mu index 05967c59..6479d5ff 100644 --- a/browse-slack/environment.mu +++ b/browse-slack/environment.mu @@ -335,10 +335,6 @@ fn render-main-menu screen: (addr screen), _env: (addr environment) { draw-text-rightward-from-cursor screen, " go to channels ", width, 0xf/fg, 0/bg draw-text-rightward-from-cursor screen, " ^b ", width, 0/fg 0xf/bg draw-text-rightward-from-cursor screen, " << page ", width, 0xf/fg, 0/bg - draw-text-rightward-from-cursor screen, " ^p ", width, 0/fg 0xf/bg - draw-text-rightward-from-cursor screen, " < item ", width, 0xf/fg, 0/bg - draw-text-rightward-from-cursor screen, " ^n ", width, 0/fg 0xf/bg - draw-text-rightward-from-cursor screen, " item > ", width, 0xf/fg, 0/bg draw-text-rightward-from-cursor screen, " ^f ", width, 0/fg 0xf/bg draw-text-rightward-from-cursor screen, " page >> ", width, 0xf/fg, 0/bg } @@ -716,13 +712,13 @@ fn update-environment _env: (addr environment), key: byte, users: (addr array us fn update-main-panel env: (addr environment), key: byte, users: (addr array user), channels: (addr array channel), items: (addr item-list) { { - compare key, 0xe/ctrl-n + compare key, 0x81/down-arrow break-if-!= next-item env, users, channels, items return } { - compare key, 0x10/ctrl-p + compare key, 0x82/up-arrow break-if-!= previous-item env, users, channels, items return |