From d0c237bcd85c237248fcabd6331713665a3a8a2a Mon Sep 17 00:00:00 2001 From: cuz Date: Sat, 21 Dec 2002 00:06:28 +0000 Subject: [PATCH] Allow longer file names, use BASIC input buffer git-svn-id: svn://svn.cc65.org/cc65/trunk@1813 b7a2c559-68d2-44c3-8de9-860c34a00d81 --- libsrc/plus4/ksetnam.s | 15 ++++++--------- libsrc/plus4/plus4.inc | 3 +-- 2 files changed, 7 insertions(+), 11 deletions(-) diff --git a/libsrc/plus4/ksetnam.s b/libsrc/plus4/ksetnam.s index 1d1297cdf..283fbea18 100644 --- a/libsrc/plus4/ksetnam.s +++ b/libsrc/plus4/ksetnam.s @@ -15,12 +15,9 @@ .proc SETNAM -; Limit the length of the name and store it into the zero page +; Store the length of the name into the zero page - cmp #16+1 - bcc @L1 - lda #16 ; Use a maximum of 16 chars -@L1: sta FNAM_LEN + sta FNAM_LEN ; Check if we have to copy the name to low memory @@ -34,19 +31,19 @@ stx TMPPTR sty TMPPTR+1 ; Store pointer to name in TMPPTR -; Copy the given name into DOS_FN1 +; Copy the given name into INBUF. ldy #$00 @L2: lda (TMPPTR),y - sta DOS_FN1,y + sta INBUF,y iny cpy FNAM_LEN bne @L2 ; Load the new parameters for the low memory buffer - ldx #DOS_FN1 + ldx #INBUF ; Instead of banking in the ROM, store the values directly into the zeropage diff --git a/libsrc/plus4/plus4.inc b/libsrc/plus4/plus4.inc index 01d02a641..e4f53a76c 100644 --- a/libsrc/plus4/plus4.inc +++ b/libsrc/plus4/plus4.inc @@ -21,8 +21,7 @@ CURS_Y = $CD ; Cursor row SCREEN_PTR = $C8 ; Pointer to current char in text screen CRAM_PTR = $EA ; Pointer to current char in color RAM -DOS_FN1 = $25E ; DOS filename buffer #1 -DOS_FN1LEN = $26E ; DOS filename length #1 +INBUF = $25E ; BASIC Input buffer CHARCOLOR = $53B FKEY_COUNT = $55D ; Characters for function key FKEY_SPACE = $55F ; Function key definitions -- 2.39.5