Merge pull request #103857 from bruvzg/macos_trans_b

[macOS] Enable transparency for windows with decorations.
This commit is contained in:
Thaddeus Crews
2025-03-18 14:42:54 -05:00
2 changed files with 22 additions and 12 deletions
+3 -1
View File
@@ -184,10 +184,12 @@
}
// Restore borderless, transparent and resizability state.
if (wd.borderless || wd.layered_window) {
if (wd.borderless) {
[wd.window_object setStyleMask:NSWindowStyleMaskBorderless];
[wd.window_object setHasShadow:NO];
} else {
[wd.window_object setStyleMask:NSWindowStyleMaskTitled | NSWindowStyleMaskClosable | NSWindowStyleMaskMiniaturizable | (wd.extend_to_title ? NSWindowStyleMaskFullSizeContentView : 0) | (wd.resize_disabled ? 0 : NSWindowStyleMaskResizable)];
[wd.window_object setHasShadow:YES];
}
if (wd.layered_window) {
ds->set_window_per_pixel_transparency_enabled(true, window_id);