From 89169ec2b4c2cb50b14be3b02cff2330da400c86 Mon Sep 17 00:00:00 2001 From: Max Kellermann Date: Tue, 10 Sep 2024 17:35:42 +0200 Subject: [PATCH] Main: remove empty function begin_input_event() This has been an empty placeholder for a long time, but it turns out we never needed it, so let's remove it for good. --- src/AsyncUserInput.cxx | 5 ----- src/Main.cxx | 5 ----- src/lirc.cxx | 2 -- src/ncmpc.hxx | 3 --- 4 files changed, 15 deletions(-) diff --git a/src/AsyncUserInput.cxx b/src/AsyncUserInput.cxx index dc45287c..3fdb0e96 100644 --- a/src/AsyncUserInput.cxx +++ b/src/AsyncUserInput.cxx @@ -52,8 +52,6 @@ AsyncUserInput::OnSocketReady(unsigned) noexcept getmouse(&event); #endif - begin_input_event(); - if (!handler.OnMouse({event.x, event.y}, event.bstate)) return; @@ -64,7 +62,6 @@ AsyncUserInput::OnSocketReady(unsigned) noexcept #endif if (handler.OnRawKey(key)) { - // TODO: begin_input_event() ? end_input_event(); return; } @@ -73,8 +70,6 @@ AsyncUserInput::OnSocketReady(unsigned) noexcept if (cmd == Command::NONE) return; - begin_input_event(); - if (!handler.OnCommand(cmd)) return; diff --git a/src/Main.cxx b/src/Main.cxx index 2d56fc77..5ce59aeb 100644 --- a/src/Main.cxx +++ b/src/Main.cxx @@ -179,11 +179,6 @@ Instance::OnUpdateTimer() noexcept ScheduleUpdateTimer(); } -void -begin_input_event() noexcept -{ -} - void end_input_event() noexcept { auto &client = global_instance->GetClient(); diff --git a/src/lirc.cxx b/src/lirc.cxx index 6665d541..33fafa03 100644 --- a/src/lirc.cxx +++ b/src/lirc.cxx @@ -14,8 +14,6 @@ LircInput::OnSocketReady(unsigned) noexcept { char *code, *txt; - begin_input_event(); - if (lirc_nextcode(&code) == 0) { while (lirc_code2char(lc, code, &txt) == 0 && txt != nullptr) { const auto cmd = get_key_command_from_name(txt); diff --git a/src/ncmpc.hxx b/src/ncmpc.hxx index 47b04138..53a4edda 100644 --- a/src/ncmpc.hxx +++ b/src/ncmpc.hxx @@ -6,8 +6,5 @@ class ScreenManager; extern ScreenManager *screen; -void -begin_input_event() noexcept; - void end_input_event() noexcept;