summaryrefslogtreecommitdiff
path: root/src/Compositor.cpp
diff options
context:
space:
mode:
authorVaxry <vaxry@vaxry.net>2023-11-17 15:29:51 +0000
committerVaxry <vaxry@vaxry.net>2023-11-17 15:30:04 +0000
commit84bc0a73f6aad2bdbba9a36f7a751261abf606d9 (patch)
treea0a1e8b52ed3f05f2e8aabea0e36c36a90e9da6c /src/Compositor.cpp
parent1d9bfa60a19975274afb5fd9a3492f8cb6742c2e (diff)
compositor: drop unused vectorToWindow func
Diffstat (limited to 'src/Compositor.cpp')
-rw-r--r--src/Compositor.cpp40
1 files changed, 0 insertions, 40 deletions
diff --git a/src/Compositor.cpp b/src/Compositor.cpp
index 70a19cb5..79e9360c 100644
--- a/src/Compositor.cpp
+++ b/src/Compositor.cpp
@@ -630,46 +630,6 @@ bool CCompositor::windowExists(CWindow* pWindow) {
return false;
}
-CWindow* CCompositor::vectorToWindow(const Vector2D& pos) {
- const auto PMONITOR = getMonitorFromVector(pos);
-
- if (PMONITOR->specialWorkspaceID) {
- for (auto& w : m_vWindows | std::views::reverse) {
- auto box = w->getWindowMainSurfaceBox();
- if (w->m_bIsFloating && w->m_iWorkspaceID == PMONITOR->specialWorkspaceID && w->m_bIsMapped && box.containsPoint(pos) && !w->isHidden() && !w->m_bNoFocus)
- return w.get();
- }
-
- for (auto& w : m_vWindows) {
- auto box = w->getWindowMainSurfaceBox();
- if (w->m_iWorkspaceID == PMONITOR->specialWorkspaceID && box.containsPoint(pos) && w->m_bIsMapped && !w->m_bIsFloating && !w->isHidden() && !w->m_bNoFocus)
- return w.get();
- }
- }
-
- // pinned
- for (auto& w : m_vWindows | std::views::reverse) {
- auto box = w->getWindowMainSurfaceBox();
- if (box.containsPoint(pos) && w->m_bIsMapped && w->m_bIsFloating && !w->isHidden() && w->m_bPinned && !w->m_bNoFocus)
- return w.get();
- }
-
- // first loop over floating cuz they're above, m_vWindows should be sorted bottom->top, for tiled it doesn't matter.
- for (auto& w : m_vWindows | std::views::reverse) {
- auto box = w->getWindowMainSurfaceBox();
- if (box.containsPoint(pos) && w->m_bIsMapped && w->m_bIsFloating && isWorkspaceVisible(w->m_iWorkspaceID) && !w->isHidden() && !w->m_bPinned && !w->m_bNoFocus)
- return w.get();
- }
-
- for (auto& w : m_vWindows) {
- auto box = w->getWindowMainSurfaceBox();
- if (box.containsPoint(pos) && w->m_bIsMapped && !w->m_bIsFloating && PMONITOR->activeWorkspace == w->m_iWorkspaceID && !w->isHidden() && !w->m_bNoFocus)
- return w.get();
- }
-
- return nullptr;
-}
-
CWindow* CCompositor::vectorToWindowTiled(const Vector2D& pos) {
const auto PMONITOR = getMonitorFromVector(pos);