aboutsummaryrefslogtreecommitdiff
path: root/src/crepe/manager/Mediator.h
diff options
context:
space:
mode:
authorJAROWMR <jarorutjes07@gmail.com>2024-12-12 15:05:33 +0100
committerJAROWMR <jarorutjes07@gmail.com>2024-12-12 15:05:33 +0100
commit641e202607b0f694df6662532f0165022c0f8621 (patch)
tree0701bbfe705a95b670c8dfcb5eaabf6007556831 /src/crepe/manager/Mediator.h
parentdd7d5cf6b01b8a6a4238b66c27861ee76522067e (diff)
parent05a33d4793520fa84a93bc79882ef29d39cd08e5 (diff)
merge master
Diffstat (limited to 'src/crepe/manager/Mediator.h')
-rw-r--r--src/crepe/manager/Mediator.h20
1 files changed, 10 insertions, 10 deletions
diff --git a/src/crepe/manager/Mediator.h b/src/crepe/manager/Mediator.h
index 8094d80..a336410 100644
--- a/src/crepe/manager/Mediator.h
+++ b/src/crepe/manager/Mediator.h
@@ -2,16 +2,15 @@
#include "../util/OptionalRef.h"
-// TODO: remove these singletons:
-#include "../facade/SDLContext.h"
-#include "EventManager.h"
-#include "SaveManager.h"
-#include "api/LoopTimer.h"
-
namespace crepe {
class ComponentManager;
class SceneManager;
+class EventManager;
+class LoopTimerManager;
+class SaveManager;
+class ResourceManager;
+class SDLContext;
/**
* Struct to pass references to classes that would otherwise need to be singletons down to
@@ -26,12 +25,13 @@ class SceneManager;
* \warning This class should never be directly accessible from the API
*/
struct Mediator {
+ OptionalRef<SDLContext> sdl_context;
OptionalRef<ComponentManager> component_manager;
OptionalRef<SceneManager> scene_manager;
- OptionalRef<SaveManager> save_manager = SaveManager::get_instance();
- OptionalRef<EventManager> event_manager = EventManager::get_instance();
- OptionalRef<SDLContext> sdl_context = SDLContext::get_instance();
- OptionalRef<LoopTimer> timer = LoopTimer::get_instance();
+ OptionalRef<EventManager> event_manager;
+ OptionalRef<LoopTimerManager> loop_timer;
+ OptionalRef<SaveManager> save_manager;
+ OptionalRef<ResourceManager> resource_manager;
};
} // namespace crepe