Преглед изворни кода

Fix window corner background bleed.

Paint the window content view background to match the app background so rounded corners don't show light gaps.

Made-with: Cursor
huzaifahayat12 пре 5 дана
родитељ
комит
de6d24cbec
1 измењених фајлова са 5 додато и 0 уклоњено
  1. 5 0
      zoom_app/ViewController.swift

+ 5 - 0
zoom_app/ViewController.swift

@@ -384,6 +384,11 @@ class ViewController: NSViewController {
384 384
             // Match the outer window background to the app background so rounded shell corners
385 385
             // don't reveal a lighter window color in Dark Mode.
386 386
             window.backgroundColor = appBackground
387
+            window.isOpaque = true
388
+            if let contentView = window.contentView {
389
+                contentView.wantsLayer = true
390
+                contentView.layer?.backgroundColor = appBackground.cgColor
391
+            }
387 392
             // Use full-size content view so custom top chrome sits in the titlebar region.
388 393
             window.titleVisibility = .hidden
389 394
             window.titlebarAppearsTransparent = true