From fd3af4c5d32a34b27c45b478c74fa1127b6438b9 Mon Sep 17 00:00:00 2001 From: iwubcode Date: Sat, 17 Aug 2019 14:40:58 -0500 Subject: InputCommon: Introducing the "Dynamic Input Texture". Configuration links an emulated input action to an image based on what host key is defined for that emulated input. Specific regions are called out in configuration that mark where to replace an input button with a host key image. --- Source/Core/InputCommon/InputConfig.h | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'Source/Core/InputCommon/InputConfig.h') diff --git a/Source/Core/InputCommon/InputConfig.h b/Source/Core/InputCommon/InputConfig.h index 37d6e06b96..3d0a60dd73 100644 --- a/Source/Core/InputCommon/InputConfig.h +++ b/Source/Core/InputCommon/InputConfig.h @@ -10,6 +10,7 @@ #include #include "InputCommon/ControllerInterface/ControllerInterface.h" +#include "InputCommon/DynamicInputTextureManager.h" namespace ControllerEmu { @@ -30,7 +31,8 @@ public: template void CreateController(Args&&... args) { - m_controllers.emplace_back(std::make_unique(std::forward(args)...)); + OnControllerCreated( + *m_controllers.emplace_back(std::make_unique(std::forward(args)...))); } ControllerEmu::EmulatedController* GetController(int index); @@ -47,9 +49,11 @@ public: void UnregisterHotplugCallback(); private: + void OnControllerCreated(ControllerEmu::EmulatedController& controller); ControllerInterface::HotplugCallbackHandle m_hotplug_callback_handle; std::vector> m_controllers; const std::string m_ini_name; const std::string m_gui_name; const std::string m_profile_name; + InputCommon::DynamicInputTextureManager m_dynamic_input_tex_config_manager; }; -- cgit v1.2.3