mirror of
https://github.com/hyprwm/Hyprland
synced 2024-11-02 07:26:00 +01:00
parent
50fecf084d
commit
b814ba98a7
2 changed files with 42 additions and 36 deletions
|
@ -123,6 +123,7 @@ void CConfigManager::setDefaultVars() {
|
|||
configValues["misc:close_special_on_empty"].intValue = 1;
|
||||
configValues["misc:groupbar_text_color"].intValue = 0xffffffff;
|
||||
configValues["misc:background_color"].intValue = 0xff111111;
|
||||
configValues["misc:new_window_takes_over_fullscreen"].intValue = 0;
|
||||
|
||||
configValues["debug:int"].intValue = 0;
|
||||
configValues["debug:log_damage"].intValue = 0;
|
||||
|
|
|
@ -46,6 +46,7 @@ void Events::listener_mapWindow(void* owner, void* data) {
|
|||
static auto* const PSWALLOW = &g_pConfigManager->getConfigValuePtr("misc:enable_swallow")->intValue;
|
||||
static auto* const PSWALLOWREGEX = &g_pConfigManager->getConfigValuePtr("misc:swallow_regex")->strValue;
|
||||
static auto* const PSWALLOWEXREGEX = &g_pConfigManager->getConfigValuePtr("misc:swallow_exception_regex")->strValue;
|
||||
static auto* const PNEWTAKESOVERFS = &g_pConfigManager->getConfigValuePtr("misc:new_window_takes_over_fullscreen")->intValue;
|
||||
|
||||
auto PMONITOR = g_pCompositor->m_pLastMonitor;
|
||||
const auto PWORKSPACE =
|
||||
|
@ -467,8 +468,12 @@ void Events::listener_mapWindow(void* owner, void* data) {
|
|||
const auto PLSFROMFOCUS = g_pCompositor->getLayerSurfaceFromSurface(g_pCompositor->m_pLastFocus);
|
||||
if (PLSFROMFOCUS && PLSFROMFOCUS->layerSurface->current.keyboard_interactive)
|
||||
PWINDOW->m_bNoInitialFocus = true;
|
||||
if (PWORKSPACE->m_bHasFullscreenWindow && !requestsFullscreen)
|
||||
if (PWORKSPACE->m_bHasFullscreenWindow && !requestsFullscreen) {
|
||||
if (*PNEWTAKESOVERFS == 0)
|
||||
PWINDOW->m_bNoInitialFocus = true;
|
||||
else
|
||||
requestsFullscreen = true;
|
||||
}
|
||||
|
||||
if (!PWINDOW->m_bNoFocus && !PWINDOW->m_bNoInitialFocus &&
|
||||
(PWINDOW->m_iX11Type != 2 || (PWINDOW->m_bIsX11 && wlr_xwayland_or_surface_wants_focus(PWINDOW->m_uSurface.xwayland))) && !workspaceSilent &&
|
||||
|
|
Loading…
Reference in a new issue