summaryrefslogtreecommitdiff
path: root/src/input_common/input_poller.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/input_common/input_poller.h')
-rw-r--r--src/input_common/input_poller.h32
1 files changed, 20 insertions, 12 deletions
diff --git a/src/input_common/input_poller.h b/src/input_common/input_poller.h
index 1357e104b..573f09fde 100644
--- a/src/input_common/input_poller.h
+++ b/src/input_common/input_poller.h
@@ -17,7 +17,7 @@ class InputEngine;
17 * An Input factory. It receives input events and forward them to all input devices it created. 17 * An Input factory. It receives input events and forward them to all input devices it created.
18 */ 18 */
19 19
20class OutputFactory final : public Input::Factory<Input::OutputDevice> { 20class OutputFactory final : public Common::Input::Factory<Common::Input::OutputDevice> {
21public: 21public:
22 explicit OutputFactory(std::shared_ptr<InputEngine> input_engine_); 22 explicit OutputFactory(std::shared_ptr<InputEngine> input_engine_);
23 23
@@ -29,13 +29,14 @@ public:
29 * @param - "pad": slot of the connected controller 29 * @param - "pad": slot of the connected controller
30 * @return an unique ouput device with the parameters specified 30 * @return an unique ouput device with the parameters specified
31 */ 31 */
32 std::unique_ptr<Input::OutputDevice> Create(const Common::ParamPackage& params) override; 32 std::unique_ptr<Common::Input::OutputDevice> Create(
33 const Common::ParamPackage& params) override;
33 34
34private: 35private:
35 std::shared_ptr<InputEngine> input_engine; 36 std::shared_ptr<InputEngine> input_engine;
36}; 37};
37 38
38class InputFactory final : public Input::Factory<Input::InputDevice> { 39class InputFactory final : public Common::Input::Factory<Common::Input::InputDevice> {
39public: 40public:
40 explicit InputFactory(std::shared_ptr<InputEngine> input_engine_); 41 explicit InputFactory(std::shared_ptr<InputEngine> input_engine_);
41 42
@@ -64,7 +65,7 @@ public:
64 * @param - "battery": Only used as a placeholder to set the input type 65 * @param - "battery": Only used as a placeholder to set the input type
65 * @return an unique input device with the parameters specified 66 * @return an unique input device with the parameters specified
66 */ 67 */
67 std::unique_ptr<Input::InputDevice> Create(const Common::ParamPackage& params) override; 68 std::unique_ptr<Common::Input::InputDevice> Create(const Common::ParamPackage& params) override;
68 69
69private: 70private:
70 /** 71 /**
@@ -79,7 +80,8 @@ private:
79 * @param - "pad": slot of the connected controller 80 * @param - "pad": slot of the connected controller
80 * @return an unique input device with the parameters specified 81 * @return an unique input device with the parameters specified
81 */ 82 */
82 std::unique_ptr<Input::InputDevice> CreateButtonDevice(const Common::ParamPackage& params); 83 std::unique_ptr<Common::Input::InputDevice> CreateButtonDevice(
84 const Common::ParamPackage& params);
83 85
84 /** 86 /**
85 * Creates a hat button device from the parameters given. 87 * Creates a hat button device from the parameters given.
@@ -93,7 +95,8 @@ private:
93 * @param - "pad": slot of the connected controller 95 * @param - "pad": slot of the connected controller
94 * @return an unique input device with the parameters specified 96 * @return an unique input device with the parameters specified
95 */ 97 */
96 std::unique_ptr<Input::InputDevice> CreateHatButtonDevice(const Common::ParamPackage& params); 98 std::unique_ptr<Common::Input::InputDevice> CreateHatButtonDevice(
99 const Common::ParamPackage& params);
97 100
98 /** 101 /**
99 * Creates a stick device from the parameters given. 102 * Creates a stick device from the parameters given.
@@ -112,7 +115,8 @@ private:
112 * @param - "pad": slot of the connected controller 115 * @param - "pad": slot of the connected controller
113 * @return an unique input device with the parameters specified 116 * @return an unique input device with the parameters specified
114 */ 117 */
115 std::unique_ptr<Input::InputDevice> CreateStickDevice(const Common::ParamPackage& params); 118 std::unique_ptr<Common::Input::InputDevice> CreateStickDevice(
119 const Common::ParamPackage& params);
116 120
117 /** 121 /**
118 * Creates an analog device from the parameters given. 122 * Creates an analog device from the parameters given.
@@ -128,7 +132,8 @@ private:
128 * @param - "pad": slot of the connected controller 132 * @param - "pad": slot of the connected controller
129 * @return an unique input device with the parameters specified 133 * @return an unique input device with the parameters specified
130 */ 134 */
131 std::unique_ptr<Input::InputDevice> CreateAnalogDevice(const Common::ParamPackage& params); 135 std::unique_ptr<Common::Input::InputDevice> CreateAnalogDevice(
136 const Common::ParamPackage& params);
132 137
133 /** 138 /**
134 * Creates a trigger device from the parameters given. 139 * Creates a trigger device from the parameters given.
@@ -148,7 +153,8 @@ private:
148 * @param - "pad": slot of the connected controller 153 * @param - "pad": slot of the connected controller
149 * @return an unique input device with the parameters specified 154 * @return an unique input device with the parameters specified
150 */ 155 */
151 std::unique_ptr<Input::InputDevice> CreateTriggerDevice(const Common::ParamPackage& params); 156 std::unique_ptr<Common::Input::InputDevice> CreateTriggerDevice(
157 const Common::ParamPackage& params);
152 158
153 /** 159 /**
154 * Creates a touch device from the parameters given. 160 * Creates a touch device from the parameters given.
@@ -171,7 +177,8 @@ private:
171 * @param - "pad": slot of the connected controller 177 * @param - "pad": slot of the connected controller
172 * @return an unique input device with the parameters specified 178 * @return an unique input device with the parameters specified
173 */ 179 */
174 std::unique_ptr<Input::InputDevice> CreateTouchDevice(const Common::ParamPackage& params); 180 std::unique_ptr<Common::Input::InputDevice> CreateTouchDevice(
181 const Common::ParamPackage& params);
175 182
176 /** 183 /**
177 * Creates a battery device from the parameters given. 184 * Creates a battery device from the parameters given.
@@ -181,7 +188,8 @@ private:
181 * @param - "pad": slot of the connected controller 188 * @param - "pad": slot of the connected controller
182 * @return an unique input device with the parameters specified 189 * @return an unique input device with the parameters specified
183 */ 190 */
184 std::unique_ptr<Input::InputDevice> CreateBatteryDevice(const Common::ParamPackage& params); 191 std::unique_ptr<Common::Input::InputDevice> CreateBatteryDevice(
192 const Common::ParamPackage& params);
185 193
186 /** 194 /**
187 * Creates a motion device from the parameters given. 195 * Creates a motion device from the parameters given.
@@ -202,7 +210,7 @@ private:
202 * @param - "pad": slot of the connected controller 210 * @param - "pad": slot of the connected controller
203 * @return an unique input device with the parameters specified 211 * @return an unique input device with the parameters specified
204 */ 212 */
205 std::unique_ptr<Input::InputDevice> CreateMotionDevice(Common::ParamPackage params); 213 std::unique_ptr<Common::Input::InputDevice> CreateMotionDevice(Common::ParamPackage params);
206 214
207 std::shared_ptr<InputEngine> input_engine; 215 std::shared_ptr<InputEngine> input_engine;
208}; 216};