diff --git a/platform/osx/os_osx.mm b/platform/osx/os_osx.mm index 53fe11b3bb5..df3e57e2829 100644 --- a/platform/osx/os_osx.mm +++ b/platform/osx/os_osx.mm @@ -2661,7 +2661,6 @@ void OS_OSX::set_window_per_pixel_transparency_enabled(bool p_enabled) { if (!is_layered_allowed()) return; if (layered_window != p_enabled) { if (p_enabled) { - set_borderless_window(true); GLint opacity = 0; [window_object setBackgroundColor:[NSColor clearColor]]; [window_object setOpaque:NO]; @@ -2691,9 +2690,6 @@ void OS_OSX::set_borderless_window(bool p_borderless) { if (p_borderless) { [window_object setStyleMask:NSWindowStyleMaskBorderless]; } else { - if (layered_window) - set_window_per_pixel_transparency_enabled(false); - [window_object setStyleMask:NSWindowStyleMaskTitled | NSWindowStyleMaskClosable | NSWindowStyleMaskMiniaturizable | (resizable ? NSWindowStyleMaskResizable : 0)]; // Force update of the window styles diff --git a/platform/windows/os_windows.cpp b/platform/windows/os_windows.cpp index 40cee5d15f6..a8c3551671c 100755 --- a/platform/windows/os_windows.cpp +++ b/platform/windows/os_windows.cpp @@ -2210,7 +2210,6 @@ void OS_Windows::set_window_per_pixel_transparency_enabled(bool p_enabled) { if (!is_layered_allowed()) return; if (layered_window != p_enabled) { if (p_enabled) { - set_borderless_window(true); //enable per-pixel alpha DWM_BLURBEHIND bb = { 0 }; @@ -2239,9 +2238,6 @@ void OS_Windows::set_borderless_window(bool p_borderless) { if (video_mode.borderless_window == p_borderless) return; - if (!p_borderless && layered_window) - set_window_per_pixel_transparency_enabled(false); - video_mode.borderless_window = p_borderless; preserve_window_size = true; diff --git a/platform/x11/os_x11.cpp b/platform/x11/os_x11.cpp index 2a1bdb6b819..9b9d141f7ad 100644 --- a/platform/x11/os_x11.cpp +++ b/platform/x11/os_x11.cpp @@ -964,7 +964,6 @@ void OS_X11::set_window_per_pixel_transparency_enabled(bool p_enabled) { if (!is_layered_allowed()) return; if (layered_window != p_enabled) { if (p_enabled) { - set_borderless_window(true); layered_window = true; } else { layered_window = false; @@ -1683,9 +1682,6 @@ void OS_X11::set_borderless_window(bool p_borderless) { if (get_borderless_window() == p_borderless) return; - if (!p_borderless && layered_window) - set_window_per_pixel_transparency_enabled(false); - current_videomode.borderless_window = p_borderless; Hints hints;