diff --git a/src/input/emulated/EmulatedController.cpp b/src/input/emulated/EmulatedController.cpp index b7a4743c..8712bcf0 100644 --- a/src/input/emulated/EmulatedController.cpp +++ b/src/input/emulated/EmulatedController.cpp @@ -207,16 +207,6 @@ glm::vec2 EmulatedController::get_prev_position() const return {}; } -std::shared_ptr EmulatedController::find_controller(std::string_view uuid, InputAPI::Type type) const -{ - std::scoped_lock lock(m_mutex); - const auto it = std::find_if(m_controllers.cbegin(), m_controllers.cend(), [uuid, type](const auto& c) { return c->api() == type && c->uuid() == uuid; }); - if (it != m_controllers.cend()) - return *it; - - return {}; -} - void EmulatedController::add_controller(std::shared_ptr controller) { controller->connect(); diff --git a/src/input/emulated/EmulatedController.h b/src/input/emulated/EmulatedController.h index bcc5c165..b7bd8c6d 100644 --- a/src/input/emulated/EmulatedController.h +++ b/src/input/emulated/EmulatedController.h @@ -67,8 +67,7 @@ public: bool has_position() const; glm::vec2 get_position() const; glm::vec2 get_prev_position() const; - - std::shared_ptr find_controller(std::string_view uuid, InputAPI::Type type) const; + void add_controller(std::shared_ptr controller); void remove_controller(const std::shared_ptr& controller); void clear_controllers();