From aabe59c5330e6ad88af5ad730dae2e789d9099da Mon Sep 17 00:00:00 2001 From: Christoph Oelckers Date: Fri, 22 Apr 2022 14:01:08 +0200 Subject: [PATCH] - made intermissions work as screenjob. --- src/intermission/intermission.cpp | 9 +++++---- src/intermission/intermission.h | 2 +- 2 files changed, 6 insertions(+), 5 deletions(-) diff --git a/src/intermission/intermission.cpp b/src/intermission/intermission.cpp index 2593955073..6bd9d44cea 100644 --- a/src/intermission/intermission.cpp +++ b/src/intermission/intermission.cpp @@ -938,7 +938,7 @@ bool DIntermissionController::Responder (FInputEvent *ev) return false; } -void DIntermissionController::Ticker () +bool DIntermissionController::Ticker () { if (mAdvance) { @@ -953,8 +953,10 @@ void DIntermissionController::Ticker () mAdvance = false; if (!NextPage()) { + return false; } } + return true; } void DIntermissionController::Drawer () @@ -1031,14 +1033,13 @@ DEFINE_ACTION_FUNCTION(DIntermissionController, Responder) DEFINE_ACTION_FUNCTION(DIntermissionController, Ticker) { PARAM_SELF_PROLOGUE(DIntermissionController); - self->Ticker(); - ACTION_RETURN_BOOL(true); + ACTION_RETURN_BOOL(self->Ticker()); } DEFINE_ACTION_FUNCTION(DIntermissionController, Drawer) { PARAM_SELF_PROLOGUE(DIntermissionController); - self->Ticker(); + self->Drawer (); return 0; } diff --git a/src/intermission/intermission.h b/src/intermission/intermission.h index a517166ed2..2d731a359b 100644 --- a/src/intermission/intermission.h +++ b/src/intermission/intermission.h @@ -303,7 +303,7 @@ public: DIntermissionController(FIntermissionDescriptor *mDesc = NULL, bool mDeleteDesc = false); bool Responder (FInputEvent *ev); - void Ticker (); + bool Ticker (); void Drawer (); void OnDestroy() override; bool NextPage();