From 5df22c3912dcb276fe9f577a6e6b7f4afe513813 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Juhani=20Krekel=C3=A4?= Date: Wed, 22 Mar 2023 21:17:02 +0200 Subject: [PATCH] Properly pass window size to print_ls --- shell.asm | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/shell.asm b/shell.asm index 027adb5..19b229a 100644 --- a/shell.asm +++ b/shell.asm @@ -251,13 +251,16 @@ show_file_window: add ax, 0x001 xchg [es:GLOBAL_WINDOW_CHAIN_HEAD], ax mov [windows + 1*window.size + window.next], ax - mov ax, cs ; Populate file window contents + mov ax, cs mov es, ax - mov di, file_window + 80 - mov cx, 3 - mov dx, 40 + mov di, file_window + add di, [windows + 1*window.size + window.width] + add di, [windows + 1*window.size + window.width] + mov cx, [windows + 1*window.size + window.height] + dec cx + mov dx, [windows + 1*window.size + window.width] call print_ls pop ax