aboutsummaryrefslogtreecommitdiff
path: root/include/RoomContainer.hpp
diff options
context:
space:
mode:
authordec05eba <dec05eba@protonmail.com>2019-04-08 21:04:12 +0200
committerdec05eba <dec05eba@protonmail.com>2019-04-08 21:04:17 +0200
commit725ea566a2b6a12e0a02e4f570b6e99102e2d21b (patch)
treed35a338392e15f50402c2055d520e7b1c3ea36a2 /include/RoomContainer.hpp
parent4aac8df198e3a5bd9c6efc95cdf4c520c2e05401 (diff)
Refactor, remove a lot of code and use dchat core instead
Diffstat (limited to 'include/RoomContainer.hpp')
-rw-r--r--include/RoomContainer.hpp26
1 files changed, 26 insertions, 0 deletions
diff --git a/include/RoomContainer.hpp b/include/RoomContainer.hpp
new file mode 100644
index 0000000..fc3e8ae
--- /dev/null
+++ b/include/RoomContainer.hpp
@@ -0,0 +1,26 @@
+#pragma once
+
+#include "MessageBoard.hpp"
+#include "Chatbar.hpp"
+#include <SFML/Graphics/RenderWindow.hpp>
+#include <memory>
+
+namespace dchat
+{
+ class Room;
+ class Cache;
+
+ class RoomContainer
+ {
+ public:
+ RoomContainer(std::shared_ptr<Room> room);
+
+ void processEvent(const sf::Event &event, Cache *cache);
+ void draw(sf::RenderWindow &window, Cache *cache);
+
+ std::shared_ptr<Room> room;
+ MessageBoard messageBoard;
+ Chatbar chatbar;
+ bool offlineRoom;
+ };
+} \ No newline at end of file