aboutsummaryrefslogtreecommitdiff
path: root/src/interfaces/cursor.hpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/interfaces/cursor.hpp')
-rw-r--r--src/interfaces/cursor.hpp16
1 files changed, 3 insertions, 13 deletions
diff --git a/src/interfaces/cursor.hpp b/src/interfaces/cursor.hpp
index 053ff40..63aae41 100644
--- a/src/interfaces/cursor.hpp
+++ b/src/interfaces/cursor.hpp
@@ -1,8 +1,5 @@
#pragma once
-#include "interfaces/publisher.hpp"
-#include "interfaces/subscriber.hpp"
-
#include "engine/data/vector2.hpp"
#include <memory>
@@ -13,19 +10,18 @@ enum CursorEvent
};
// NOLINTNEXTLINE(cppcoreguidelines-special-member-functions)
-class ICursorController : public IPublisher<CursorEvent, Vector2>
+class ICursorController
{
public:
using Event = CursorEvent;
using Context = Vector2;
- using Subscriber = std::shared_ptr<ISubscriber<Context>>;
- ~ICursorController() noexcept override = default;
+ virtual ~ICursorController() noexcept = default;
virtual void move(const Vector2 &direction, const uint32_t &amount) noexcept = 0;
// NOLINTNEXTLINE(google-default-arguments)
- virtual void move_to(const Vector2 &position, bool silent = false) noexcept = 0;
+ virtual void move_to(const Vector2 &position) noexcept = 0;
[[nodiscard]] virtual auto where() const noexcept -> Vector2 = 0;
@@ -34,10 +30,4 @@ public:
virtual void hide() noexcept = 0;
virtual void show() noexcept = 0;
-
- void
- subscribe(const Event &event, const Subscriber &subscriber) noexcept override = 0;
-
- void notify_subscribers(const Event &event, const Context &context)
- const noexcept override = 0;
};