From db4e0fbc4ac317c9ce5c0c0b4ad9397f4a743806 Mon Sep 17 00:00:00 2001 From: Devine Lu Linvega Date: Sun, 11 Feb 2024 12:19:45 -0800 Subject: [PATCH] Abstracted set-layer --- gui/shaviankb/shaviankb.tal | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/gui/shaviankb/shaviankb.tal b/gui/shaviankb/shaviankb.tal index 062025d..9926593 100644 --- a/gui/shaviankb/shaviankb.tal +++ b/gui/shaviankb/shaviankb.tal @@ -51,8 +51,7 @@ @on-control ( -> ) ( | release ) .Controller/button DEI2 ORA ?{ - #00 .layer STZ - + #00 [ LIT2 00 -lock ] STZ BRK } ( | toggle layer ) @@ -99,8 +98,7 @@ DUP [ LIT 80 ] NEQ ?{ #0019 POP BRK } - #02 SFT #01 AND .layer STZ - + #02 SFT #01 AND BRK ( @@ -141,7 +139,11 @@ &bottom #0002 JMP2r @ ( -- ) - .layer LDZ INC #03 DIVk MUL SUB .layer STZ + .layer LDZ INC #03 DIVk MUL SUB + ( >> ) + +@ ( layer -- ) + .layer STZ ! @ ( id* -- )