diff --git a/rom5x/B0_C4EE_del_key.s b/rom5x/B0_C4EE_del_key.s deleted file mode 100644 index 4a336fb..0000000 --- a/rom5x/B0_C4EE_del_key.s +++ /dev/null @@ -1,11 +0,0 @@ -; call RDCHAR, convert DEL to space -; for patching into GETLN1/NXTCHAR (at $FD75) -.code -.include "iic+.defs" - .org $c4ee - jsr $cced - cmp #$ff - bne :+ - lda #$88 -: rts - diff --git a/rom5x/B0_FD10_del_key_part_2.s b/rom5x/B0_FD10_del_key_part_2.s new file mode 100644 index 0000000..58a530c --- /dev/null +++ b/rom5x/B0_FD10_del_key_part_2.s @@ -0,0 +1,10 @@ +; patch RDKEY to skip over NOPs and add in additional code for handling +; delete key. +.code +.PC02 +.include "iic+.defs" + .org $fd10 + bra :+ ; skip over the patch + lda #$88 ; replace with left arrow code + bra $fd7c ; branch back out of the patch +: \ No newline at end of file diff --git a/rom5x/B0_FD75_patch_getln1.s b/rom5x/B0_FD75_patch_getln1.s deleted file mode 100644 index 87f99d4..0000000 --- a/rom5x/B0_FD75_patch_getln1.s +++ /dev/null @@ -1,6 +0,0 @@ -; patch GETLN1 to call delete key handler -.code -.include "iic+.defs" - .org $fd75 - jsr $c4ee - diff --git a/rom5x/B0_FD78_del_key.s b/rom5x/B0_FD78_del_key.s new file mode 100644 index 0000000..a488949 --- /dev/null +++ b/rom5x/B0_FD78_del_key.s @@ -0,0 +1,13 @@ +; patch GETLN1 to call delete key handler +; +; This patch uses the run of NOPs in RDKEY since there wasn't enough space here +; (6 bytes needed, 5 available). +.code +.include "iic+.defs" + .org $fd78 + cmp #$ff ; check for delete + beq $fd12 ; go to part 2 of the patch + cmp #$95 ; check for control-u + bne $fd84 + jsr $cc1d ; lift char +