From b74611d2b20fc071b8a699f2ce25e61f60118d6e Mon Sep 17 00:00:00 2001 From: HampusM Date: Sun, 22 May 2022 23:13:29 +0200 Subject: refactor: improve input handling & remove commands --- src/commands/toggle_pause.cpp | 21 --------------------- 1 file changed, 21 deletions(-) delete mode 100644 src/commands/toggle_pause.cpp (limited to 'src/commands/toggle_pause.cpp') diff --git a/src/commands/toggle_pause.cpp b/src/commands/toggle_pause.cpp deleted file mode 100644 index 852e093..0000000 --- a/src/commands/toggle_pause.cpp +++ /dev/null @@ -1,21 +0,0 @@ -#include "toggle_pause.hpp" - -#include -#include - -TogglePauseCommand::TogglePauseCommand( - std::shared_ptr generation_tracker, - std::shared_ptr status_manager) noexcept - : _generation_tracker(std::move(generation_tracker)), - _status_manager(std::move(status_manager)) -{ -} - -void TogglePauseCommand::execute() noexcept -{ - auto onoff = !_generation_tracker->get_is_paused(); - - _generation_tracker->set_is_paused(onoff); - - _status_manager->set_section_body(StatusLineSection::D, onoff ? "yes" : "no"); -} -- cgit v1.2.3-18-g5258