diff options
author | der richter <der.richter@gmx.de> | 2019-12-24 20:08:00 +0100 |
---|---|---|
committer | der richter <der.richter@gmx.de> | 2019-12-24 21:51:24 +0100 |
commit | 1caa653f2d8a76f97a009cf329b9f37f2af69abb (patch) | |
tree | d48b54bf0437849b52fdd09f262f214c51f28af0 /video/out/cocoa-cb/window.swift | |
parent | d9e13f42b8d2490bf89b0af4dd1d6a92d280a9af (diff) | |
download | mpv-1caa653f2d8a76f97a009cf329b9f37f2af69abb.tar.bz2 mpv-1caa653f2d8a76f97a009cf329b9f37f2af69abb.tar.xz |
cocoa-cb: force redraw when screen or size changes
in certain circumstances the video was not redrawn even when the size
or the backing scale factor changed. this could lead to a lower
resolution output than intended.
now it redraws the video when screen properties or the window size
changes.
Diffstat (limited to 'video/out/cocoa-cb/window.swift')
-rw-r--r-- | video/out/cocoa-cb/window.swift | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/video/out/cocoa-cb/window.swift b/video/out/cocoa-cb/window.swift index 55c0fa1688..25f144a38e 100644 --- a/video/out/cocoa-cb/window.swift +++ b/video/out/cocoa-cb/window.swift @@ -301,6 +301,7 @@ class Window: NSWindow, NSWindowDelegate { let cRect = frameRect(forContentRect: rect) unfsContentFrame = rect setFrame(cRect, display: true) + cocoaCB.layer?.update(force: true) } } @@ -464,6 +465,7 @@ class Window: NSWindow, NSWindowDelegate { } if currentScreen != screen { cocoaCB.updateDisplaylink() + cocoaCB.layer?.update(force: true) } currentScreen = screen } |