From a16d18d83c921317f643219b9e8737ff483cf23c Mon Sep 17 00:00:00 2001 From: Megamouse Date: Fri, 21 Oct 2022 22:48:38 +0200 Subject: [PATCH] Input: rename misleading ThreadProc to process --- rpcs3/Emu/Io/Null/NullPadHandler.h | 2 +- rpcs3/Emu/Io/PadHandler.cpp | 2 +- rpcs3/Emu/Io/PadHandler.h | 2 +- rpcs3/Input/hid_pad_handler.cpp | 4 ++-- rpcs3/Input/hid_pad_handler.h | 2 +- rpcs3/Input/keyboard_pad_handler.cpp | 2 +- rpcs3/Input/keyboard_pad_handler.h | 2 +- rpcs3/Input/pad_thread.cpp | 4 ++-- 8 files changed, 10 insertions(+), 10 deletions(-) diff --git a/rpcs3/Emu/Io/Null/NullPadHandler.h b/rpcs3/Emu/Io/Null/NullPadHandler.h index 22e5fdfc93..96616b450a 100644 --- a/rpcs3/Emu/Io/Null/NullPadHandler.h +++ b/rpcs3/Emu/Io/Null/NullPadHandler.h @@ -64,7 +64,7 @@ public: return true; } - void ThreadProc() override + void process() override { } }; diff --git a/rpcs3/Emu/Io/PadHandler.cpp b/rpcs3/Emu/Io/PadHandler.cpp index 390076ccc2..0d7ab2cf71 100644 --- a/rpcs3/Emu/Io/PadHandler.cpp +++ b/rpcs3/Emu/Io/PadHandler.cpp @@ -708,7 +708,7 @@ void PadHandlerBase::get_mapping(const pad_ensemble& binding) } } -void PadHandlerBase::ThreadProc() +void PadHandlerBase::process() { for (usz i = 0; i < m_bindings.size(); ++i) { diff --git a/rpcs3/Emu/Io/PadHandler.h b/rpcs3/Emu/Io/PadHandler.h index 30f4c8d46f..1816b63b08 100644 --- a/rpcs3/Emu/Io/PadHandler.h +++ b/rpcs3/Emu/Io/PadHandler.h @@ -203,7 +203,7 @@ public: // Return list of devices for that handler virtual std::vector list_devices() = 0; // Callback called during pad_thread::ThreadFunc - virtual void ThreadProc(); + virtual void process(); // Binds a Pad to a device virtual bool bindPadToDevice(std::shared_ptr pad, u8 player_id); virtual void init_config(cfg_pad* cfg) = 0; diff --git a/rpcs3/Input/hid_pad_handler.cpp b/rpcs3/Input/hid_pad_handler.cpp index c46332b30a..3798495308 100644 --- a/rpcs3/Input/hid_pad_handler.cpp +++ b/rpcs3/Input/hid_pad_handler.cpp @@ -98,11 +98,11 @@ bool hid_pad_handler::Init() } template -void hid_pad_handler::ThreadProc() +void hid_pad_handler::process() { update_devices(); - PadHandlerBase::ThreadProc(); + PadHandlerBase::process(); } template diff --git a/rpcs3/Input/hid_pad_handler.h b/rpcs3/Input/hid_pad_handler.h index 1259b530d5..4ce4e79ca7 100644 --- a/rpcs3/Input/hid_pad_handler.h +++ b/rpcs3/Input/hid_pad_handler.h @@ -58,7 +58,7 @@ public: ~hid_pad_handler(); bool Init() override; - void ThreadProc() override; + void process() override; std::vector list_devices() override; protected: diff --git a/rpcs3/Input/keyboard_pad_handler.cpp b/rpcs3/Input/keyboard_pad_handler.cpp index f47a6560ce..dfd6ffdb8b 100644 --- a/rpcs3/Input/keyboard_pad_handler.cpp +++ b/rpcs3/Input/keyboard_pad_handler.cpp @@ -889,7 +889,7 @@ bool keyboard_pad_handler::bindPadToDevice(std::shared_ptr pad, u8 player_i return true; } -void keyboard_pad_handler::ThreadProc() +void keyboard_pad_handler::process() { static const double stick_interval = 10.0; static const double button_interval = 10.0; diff --git a/rpcs3/Input/keyboard_pad_handler.h b/rpcs3/Input/keyboard_pad_handler.h index cf3ae5fcb5..eb2530b7e8 100644 --- a/rpcs3/Input/keyboard_pad_handler.h +++ b/rpcs3/Input/keyboard_pad_handler.h @@ -86,7 +86,7 @@ public: std::vector list_devices() override; void get_next_button_press(const std::string& /*padId*/, const pad_callback& /*callback*/, const pad_fail_callback& /*fail_callback*/, bool /*get_blacklist*/ = false, const std::vector& /*buttons*/ = {}) override {} bool bindPadToDevice(std::shared_ptr pad, u8 player_id) override; - void ThreadProc() override; + void process() override; std::string GetMouseName(const QMouseEvent* event) const; std::string GetMouseName(u32 button) const; diff --git a/rpcs3/Input/pad_thread.cpp b/rpcs3/Input/pad_thread.cpp index 97605ea8e5..e1b2f53eaf 100644 --- a/rpcs3/Input/pad_thread.cpp +++ b/rpcs3/Input/pad_thread.cpp @@ -278,7 +278,7 @@ void pad_thread::operator()() continue; } - handler->ThreadProc(); + handler->process(); thread_ctrl::wait_for(g_cfg.io.pad_sleep); } @@ -325,7 +325,7 @@ void pad_thread::operator()() { for (auto& handler : handlers) { - handler.second->ThreadProc(); + handler.second->process(); connected_devices += handler.second->connected_devices; } }