Dependency injection for apu/gpu/hid.
This commit is contained in:
@@ -15,8 +15,8 @@ namespace xe {
|
||||
namespace hid {
|
||||
namespace xinput {
|
||||
|
||||
std::unique_ptr<InputDriver> Create(InputSystem* input_system) {
|
||||
return std::make_unique<XInputInputDriver>(input_system);
|
||||
std::unique_ptr<InputDriver> Create(xe::ui::Window* window) {
|
||||
return std::make_unique<XInputInputDriver>(window);
|
||||
}
|
||||
|
||||
} // namespace xinput
|
||||
|
||||
@@ -18,7 +18,7 @@ namespace xe {
|
||||
namespace hid {
|
||||
namespace xinput {
|
||||
|
||||
std::unique_ptr<InputDriver> Create(InputSystem* input_system);
|
||||
std::unique_ptr<InputDriver> Create(xe::ui::Window* window);
|
||||
|
||||
} // namespace xinput
|
||||
} // namespace hid
|
||||
|
||||
@@ -19,8 +19,8 @@ namespace xe {
|
||||
namespace hid {
|
||||
namespace xinput {
|
||||
|
||||
XInputInputDriver::XInputInputDriver(InputSystem* input_system)
|
||||
: InputDriver(input_system) {
|
||||
XInputInputDriver::XInputInputDriver(xe::ui::Window* window)
|
||||
: InputDriver(window) {
|
||||
XInputEnable(TRUE);
|
||||
}
|
||||
|
||||
|
||||
@@ -18,7 +18,7 @@ namespace xinput {
|
||||
|
||||
class XInputInputDriver : public InputDriver {
|
||||
public:
|
||||
explicit XInputInputDriver(InputSystem* input_system);
|
||||
explicit XInputInputDriver(xe::ui::Window* window);
|
||||
~XInputInputDriver() override;
|
||||
|
||||
X_STATUS Setup() override;
|
||||
|
||||
Reference in New Issue
Block a user