diff options
author | Kartik K. Agaram <vc@akkartik.com> | 2021-03-26 22:47:44 -0700 |
---|---|---|
committer | Kartik K. Agaram <vc@akkartik.com> | 2021-03-26 23:07:35 -0700 |
commit | 1a43d12b15c11c1fb1686369665f48d87f350f37 (patch) | |
tree | 73902bccd19f3b6358b9b3ed1c9a0c33956a7e0b /shell | |
parent | 9f71d7248c908900e987c08b2ab4642dfd88eacb (diff) | |
download | mu-1a43d12b15c11c1fb1686369665f48d87f350f37.tar.gz |
explicitly pass screen and keyboard to main
Diffstat (limited to 'shell')
-rw-r--r-- | shell/main.mu | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/shell/main.mu b/shell/main.mu index 07ba00c6..87ad0893 100644 --- a/shell/main.mu +++ b/shell/main.mu @@ -1,18 +1,18 @@ # Experimental Mu shell # A Lisp with indent-sensitivity and infix, no macros. Commas are ignored. -fn main { +fn main screen: (addr screen), keyboard: (addr keyboard) { var sandbox-storage: sandbox var sandbox/esi: (addr sandbox) <- address sandbox-storage initialize-sandbox sandbox load-sandbox-from-secondary-disk sandbox var width/eax: int <- copy 0 var height/ecx: int <- copy 0 - width, height <- screen-size 0/screen + width, height <- screen-size screen { - render-sandbox 0/screen, sandbox, 2/x, 2/y, width, height + render-sandbox screen, sandbox, 2/x, 2/y, width, height { - var key/eax: byte <- read-key 0/keyboard + var key/eax: byte <- read-key keyboard compare key, 0 loop-if-= # no way to quit right now; just reboot |