From ea1ac518cfa502e41c036aaf35c97231387c8067 Mon Sep 17 00:00:00 2001 From: Holger Schemel Date: Sat, 28 Jan 2023 13:41:35 +0100 Subject: [PATCH] added pausing tape after replaying not only for warp mode (again) This adds the previously reverted change of commit 31df2f98 again, but should fix the problems that it caused when unpausing the tape after replaying until the end of the tape and entering pause mode. --- src/tape.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/tape.c b/src/tape.c index 55991ce9..f16e7ec9 100644 --- a/src/tape.c +++ b/src/tape.c @@ -936,6 +936,10 @@ void TapeTogglePause(boolean toggle_mode) ModifyPauseButtons(); } + + // stop tape when leaving auto-pause after completely replaying tape + if (tape.playing && !tape.pausing && tape.counter >= tape.length) + TapeStop(); } void TapeStartPlaying(void) @@ -1007,7 +1011,7 @@ byte *TapePlayAction(void) if (tape.counter >= tape.length) // end of tape reached { - if (tape.warp_forward && !tape.auto_play) + if (!tape.auto_play) { TapeStopWarpForward(); TapeTogglePause(TAPE_TOGGLE_MANUAL); -- 2.34.1