Revert "window: alternative shadow/ghost/macos fix"

This reverts commit f2b504ee1f9a607fe8965e96b659bca282147672;
we prefer the overall snappier perf from not having a shadow.

refs: #310
This commit is contained in:
Wez Furlong committed 2020-10-28 17:55:15 -07:00
1 parent f2b504ee1f
commit 92bdc4a3b0
1 file changed
+4 -4
+4 -4
View File
@@ -405,6 +405,10 @@ impl Window {
window.setReleasedWhenClosed_(NO);
window.setOpaque_(NO);
// Turn off the window shadow, because when the background is transparent
// having the shadow enabled seems to correlate with ghostly remnants
// see: https://github.com/wez/wezterm/issues/310
window.setHasShadow_(NO);
let ns_color: id = msg_send![Class::get("NSColor").unwrap(), alloc];
window.setBackgroundColor_(cocoa::appkit::NSColor::clearColor(ns_color));
@@ -663,10 +667,6 @@ impl WindowOpsMut for WindowInner {
fn invalidate(&mut self) {
unsafe {
let () = msg_send![*self.view, setNeedsDisplay: YES];
// Explicitly invalidate the window shadow to avoid
// leaving behind ghost remnants!
// see: https://github.com/wez/wezterm/issues/310
NSWindow::invalidateShadow(*self.window);
}
}
fn set_title(&mut self, title: &str) {