From 40d02748924aa7c48b04cf948204d8dacdfbbc74 Mon Sep 17 00:00:00 2001 From: HampusM Date: Sat, 30 Apr 2022 16:28:13 +0200 Subject: refactor: replace DI files with the yacppdic library --- src/engine/engine.hpp | 5 +++-- src/engine/graphics/window.hpp | 5 +++-- src/engine/user/cursor.hpp | 5 +++-- src/engine/user/input.hpp | 6 ++++-- 4 files changed, 13 insertions(+), 8 deletions(-) (limited to 'src/engine') diff --git a/src/engine/engine.hpp b/src/engine/engine.hpp index c13245f..cf162d9 100644 --- a/src/engine/engine.hpp +++ b/src/engine/engine.hpp @@ -1,6 +1,5 @@ #pragma once -#include "DI/auto_wirable.hpp" #include "interfaces/command.hpp" #include "interfaces/cursor.hpp" #include "interfaces/engine.hpp" @@ -9,11 +8,13 @@ #include "interfaces/scene.hpp" #include "interfaces/window.hpp" +#include + #include #include class CLIGameEngine : public ICLIGameEngine, - public AutoWirable< + public yacppdic::AutoWirable< ICLIGameEngine, CLIGameEngine, IGameFactory, diff --git a/src/engine/graphics/window.hpp b/src/engine/graphics/window.hpp index 69c04c3..9284e5e 100644 --- a/src/engine/graphics/window.hpp +++ b/src/engine/graphics/window.hpp @@ -1,11 +1,12 @@ #pragma once -#include "DI/auto_wirable.hpp" #include "interfaces/window.hpp" #include "engine/data/bounds.hpp" -class Window : public IWindow, public AutoWirable +#include + +class Window : public IWindow, public yacppdic::AutoWirable { public: Window() noexcept = default; diff --git a/src/engine/user/cursor.hpp b/src/engine/user/cursor.hpp index 9d614f1..080321e 100644 --- a/src/engine/user/cursor.hpp +++ b/src/engine/user/cursor.hpp @@ -1,11 +1,12 @@ #pragma once -#include "DI/auto_wirable.hpp" #include "interfaces/cursor.hpp" #include "engine/data/vector2.hpp" #include +#include + #include #include #include @@ -30,7 +31,7 @@ const std::unordered_map { Vector2::right(), MOVE_CURSOR_RIGHT } }; class CursorController : public ICursorController, - public AutoWirable + public yacppdic::AutoWirable { public: CursorController() noexcept; diff --git a/src/engine/user/input.hpp b/src/engine/user/input.hpp index 6a7bf26..c88809d 100644 --- a/src/engine/user/input.hpp +++ b/src/engine/user/input.hpp @@ -1,16 +1,18 @@ #pragma once -#include "DI/auto_wirable.hpp" #include "interfaces/input.hpp" #include "interfaces/subscriber.hpp" +#include + #include #include #include #include #include -class InputHandler : public IInputHandler, public AutoWirable +class InputHandler : public IInputHandler, + public yacppdic::AutoWirable { public: InputHandler() noexcept = default; -- cgit v1.2.3-18-g5258