summaryrefslogtreecommitdiff
path: root/src/Compositor.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/Compositor.cpp')
-rw-r--r--src/Compositor.cpp12
1 files changed, 12 insertions, 0 deletions
diff --git a/src/Compositor.cpp b/src/Compositor.cpp
index 9c6df787..5cf43334 100644
--- a/src/Compositor.cpp
+++ b/src/Compositor.cpp
@@ -326,6 +326,9 @@ void CCompositor::startCompositor() {
Debug::log(LOG, "Creating the XWaylandManager!");
g_pXWaylandManager = std::make_unique<CHyprXWaylandManager>();
+ Debug::log(LOG, "Creating the ProtocolManager!");
+ g_pProtocolManager = std::make_unique<CProtocolManager>();
+
Debug::log(LOG, "Creating the EventManager!");
g_pEventManager = std::make_unique<CEventManager>();
g_pEventManager->startThread();
@@ -909,6 +912,15 @@ CWindow* CCompositor::getWindowFromSurface(wlr_surface* pSurface) {
return nullptr;
}
+CWindow* CCompositor::getWindowFromHandle(uint32_t handle) {
+ for (auto& w : m_vWindows) {
+ if ((uintptr_t)w.get() == (uintptr_t)handle)
+ return w.get();
+ }
+
+ return nullptr;
+}
+
CWindow* CCompositor::getFullscreenWindowOnWorkspace(const int& ID) {
for (auto& w : m_vWindows) {
if (w->m_iWorkspaceID == ID && w->m_bIsFullscreen)