aboutsummaryrefslogtreecommitdiffstats
path: root/src/osk.asm
diff options
context:
space:
mode:
Diffstat (limited to 'src/osk.asm')
-rw-r--r--src/osk.asm5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/osk.asm b/src/osk.asm
index c761aed..a34a863 100644
--- a/src/osk.asm
+++ b/src/osk.asm
@@ -236,6 +236,9 @@ osk_toggle::
ld [wOskVisible], a
or a
jr z, .hide
+ ; show: shrink the terminal to the rows above the keyboard, then enable window
+ ld a, 18 - OSK_ROWS
+ call term_set_rows
ld a, [rLCDC]
or %00100000
ld [rLCDC], a
@@ -244,6 +247,8 @@ osk_toggle::
ld a, [rLCDC]
and %11011111
ld [rLCDC], a
+ ld a, 18 ; restore full-height terminal
+ call term_set_rows
ret
; movement with wrap-around; each moves the highlight