aboutsummaryrefslogtreecommitdiff
path: root/src/bootstrap.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/bootstrap.cpp')
-rw-r--r--src/bootstrap.cpp29
1 files changed, 1 insertions, 28 deletions
diff --git a/src/bootstrap.cpp b/src/bootstrap.cpp
index 6d42263..ef54940 100644
--- a/src/bootstrap.cpp
+++ b/src/bootstrap.cpp
@@ -12,7 +12,6 @@
#include "interfaces/scene.hpp"
#include "interfaces/status_manager.hpp"
#include "interfaces/statusline.hpp"
-#include "interfaces/statusline_subscriber_adapter.hpp"
// Implementations
#include "argument_parser.hpp"
@@ -27,7 +26,6 @@
#include "game/game.hpp"
#include "game/generation_tracker.hpp"
#include "game/status_manager.hpp"
-#include "game/statusline_subscriber_adapter.hpp"
#include "randomization/generator.hpp"
#include "randomization/seed_generator.hpp"
@@ -64,16 +62,12 @@ auto bootstrap() noexcept -> yacppdic::Container
std::shared_ptr<IGenerationTracker> generation_tracker =
container.get<IGenerationTrackerFactory>()(true);
- auto vector2_statusline_subscriber_adapter_factory =
- container.get<IStatusLineSubscriberAdapterFactory<Vector2>>();
-
return std::make_unique<Game>(
scene,
cursor_controller,
generation_tracker,
status_manager,
- user_input_observer,
- vector2_statusline_subscriber_adapter_factory);
+ user_input_observer);
});
container.bind<IRandomNumberGeneratorFactory>().to_factory(
@@ -109,27 +103,6 @@ auto bootstrap() noexcept -> yacppdic::Container
return std::make_unique<StatusManager>(statusline);
});
- container.bind<IStatusLineSubscriberAdapterFactory<Vector2>>().to_factory(
- [](const std::shared_ptr<IStatusManager> &status_manager,
- std::vector<StatusLineSection> sections)
- {
- return std::make_unique<StatusLineSubscriberAdapter<Vector2>>(
- status_manager,
- [](std::size_t section_index, const Vector2 &position)
- {
- switch (section_index)
- {
- case 0:
- return fmt::format("{}", position.get_x());
- case 1:
- return fmt::format("{}", position.get_y());
- default:
- return std::string("");
- }
- },
- sections);
- });
-
container.bind<IGenerationTrackerFactory>().to_factory(
[](bool is_paused)
{