summaryrefslogtreecommitdiff
path: root/src/managers/XWaylandManager.cpp
diff options
context:
space:
mode:
authorvaxerski <43317083+vaxerski@users.noreply.github.com>2022-03-30 17:39:04 +0200
committervaxerski <43317083+vaxerski@users.noreply.github.com>2022-03-30 17:39:04 +0200
commit7439246efbe8e0c14bd6f8391022499a90554550 (patch)
treeba2a61368f54dbcb85b8d6259d0403e487ef1e60 /src/managers/XWaylandManager.cpp
parentd01c7c07d8d8684bd9aa41298a5122212c01f6ce (diff)
tell windows to fullscreen on keybind
Diffstat (limited to 'src/managers/XWaylandManager.cpp')
-rw-r--r--src/managers/XWaylandManager.cpp8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/managers/XWaylandManager.cpp b/src/managers/XWaylandManager.cpp
index 9bdd992b..6fd37f94 100644
--- a/src/managers/XWaylandManager.cpp
+++ b/src/managers/XWaylandManager.cpp
@@ -174,4 +174,12 @@ void CHyprXWaylandManager::checkBorders(CWindow* pWindow) {
if (pWindow->m_uSurface.xwayland->parent) {
pWindow->m_bX11DoesntWantBorders = true;
}
+}
+
+void CHyprXWaylandManager::setWindowFullscreen(CWindow* pWindow, bool fullscreen) {
+ if (pWindow->m_bIsX11) {
+ wlr_xwayland_surface_set_fullscreen(pWindow->m_uSurface.xwayland, fullscreen);
+ } else {
+ wlr_xdg_toplevel_set_fullscreen(pWindow->m_uSurface.xdg->toplevel, fullscreen);
+ }
} \ No newline at end of file