mirror of
https://github.com/hyprwm/Hyprland
synced 2024-11-22 10:45:58 +01:00
added fakefullscreen
This commit is contained in:
parent
7525818097
commit
cb4f748226
4 changed files with 15 additions and 2 deletions
|
@ -157,6 +157,9 @@ class CWindow {
|
|||
// For pinned (sticky) windows
|
||||
bool m_bPinned = false;
|
||||
|
||||
// fakefullscreen
|
||||
bool m_bInFullscreenReported = false;
|
||||
|
||||
// for proper cycling. While cycling we can't just move the pointers, so we need to keep track of the last cycled window.
|
||||
CWindow* m_pLastCycledWindow = nullptr;
|
||||
|
||||
|
|
|
@ -11,6 +11,7 @@ CKeybindManager::CKeybindManager() {
|
|||
m_mDispatchers["togglefloating"] = toggleActiveFloating;
|
||||
m_mDispatchers["workspace"] = changeworkspace;
|
||||
m_mDispatchers["fullscreen"] = fullscreenActive;
|
||||
m_mDispatchers["fakefullscreen"] = fakeFullscreenActive;
|
||||
m_mDispatchers["movetoworkspace"] = moveActiveToWorkspace;
|
||||
m_mDispatchers["movetoworkspacesilent"] = moveActiveToWorkspaceSilent;
|
||||
m_mDispatchers["pseudo"] = toggleActivePseudo;
|
||||
|
@ -1818,3 +1819,10 @@ void CKeybindManager::bringActiveToTop(std::string args) {
|
|||
if (g_pCompositor->m_pLastWindow && g_pCompositor->m_pLastWindow->m_bIsFloating)
|
||||
g_pCompositor->moveWindowToTop(g_pCompositor->m_pLastWindow);
|
||||
}
|
||||
|
||||
void CKeybindManager::fakeFullscreenActive(std::string args) {
|
||||
if (g_pCompositor->m_pLastWindow) {
|
||||
// will also set the flag
|
||||
g_pXWaylandManager->setWindowFullscreen(g_pCompositor->m_pLastWindow, !g_pCompositor->m_pLastWindow->m_bInFullscreenReported);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -25,8 +25,7 @@ struct SKeybind {
|
|||
bool shadowed = false;
|
||||
};
|
||||
|
||||
enum eFocusWindowMode
|
||||
{
|
||||
enum eFocusWindowMode {
|
||||
MODE_CLASS_REGEX = 0,
|
||||
MODE_TITLE_REGEX,
|
||||
MODE_ADDRESS,
|
||||
|
@ -91,6 +90,7 @@ class CKeybindManager {
|
|||
static void toggleActivePseudo(std::string);
|
||||
static void changeworkspace(std::string);
|
||||
static void fullscreenActive(std::string);
|
||||
static void fakeFullscreenActive(std::string);
|
||||
static void moveActiveToWorkspace(std::string);
|
||||
static void moveActiveToWorkspaceSilent(std::string);
|
||||
static void moveFocusTo(std::string);
|
||||
|
|
|
@ -257,6 +257,8 @@ void CHyprXWaylandManager::setWindowFullscreen(CWindow* pWindow, bool fullscreen
|
|||
|
||||
if (pWindow->m_phForeignToplevel)
|
||||
wlr_foreign_toplevel_handle_v1_set_fullscreen(pWindow->m_phForeignToplevel, fullscreen);
|
||||
|
||||
pWindow->m_bInFullscreenReported = fullscreen;
|
||||
}
|
||||
|
||||
Vector2D CHyprXWaylandManager::getMaxSizeForWindow(CWindow* pWindow) {
|
||||
|
|
Loading…
Reference in a new issue