diff --git a/src/textrank.a b/src/textrank.a index 78ad3d089..f33bf2dbd 100644 --- a/src/textrank.a +++ b/src/textrank.a @@ -37,6 +37,20 @@ BestMatchScore BestMatchIndex !byte 0 +;------------------------------------------------------------------------------ +; ResetTextRank +; reset the Match variables to allow re-scanning (e.g. because of backspace) + +; in: nothing +; out: X, MatchCount, BestMatchScore, BestMatchIndex zeroed +;------------------------------------------------------------------------------ +ResetTextRank + ldx #0 + stx MatchCount + stx BestMatchScore + stx BestMatchIndex + rts + ;------------------------------------------------------------------------------ ; TextRankCallback ; callback called by okvs_iter_values on gGamesListStore @@ -132,6 +146,7 @@ TextRankCallback pha ldy #1 lda (zpstring),y + +LOW_ASCII_TO_LOWER sta firstletter pla ldx InputBuffer diff --git a/src/ui.search.mode.a b/src/ui.search.mode.a index fc1e47de6..924d97742 100644 --- a/src/ui.search.mode.a +++ b/src/ui.search.mode.a @@ -39,7 +39,8 @@ InputLoop cmp #$7F ; delete key bne + -- ldx #kInputBackspace +- jsr ResetTextRank + ldx #kInputBackspace bne InputDispatch ; always branches + cmp #$08 ; left arrow = delete diff --git a/winmake.bat b/winmake.bat index c3fffa664..69878efc9 100644 --- a/winmake.bat +++ b/winmake.bat @@ -121,9 +121,9 @@ cscript /nologo bin\rsync.js res\demo\* build\DEMO >>build\log cscript /nologo bin\rsync.js res\fx\* build\FX >>build\log %CADIUS% ADDFOLDER "build\%DISK%" "/%VOLUME%/FX" "build\FX" >>build\log %CADIUS% CREATEFOLDER "build\%DISK%" "/%VOLUME%/X/" >>build\log -cscript /nologo bin\do2po.js res\dsk build\po -cscript /nologo bin\rsync.js res\dsk\*.po build\po -cscript /nologo bin\extract.js build\po >>build\log +rem cscript /nologo bin\do2po.js res\dsk build\po +rem cscript /nologo bin\rsync.js res\dsk\*.po build\po +rem cscript /nologo bin\extract.js build\po >>build\log echo y|1>nul 2>nul del /s build\X\.DS_Store echo y|1>nul 2>nul del /s build\X\PRODOS echo y|1>nul 2>nul del /s build\X\LOADER.SYSTEM