cocoa-cb: wakeup vo when new events are available

new events were added but not fetched by the vo, because we didn't
signal the vo that new events were available.

actually wakeup the vo when new events are available.
This commit is contained in:
Akemi 2019-01-27 18:38:22 +01:00 committed by Jan Ekström
parent 61005e10ea
commit 48a463d641
2 changed files with 3 additions and 0 deletions

View File

@ -34,6 +34,7 @@ class MPVHelper: NSObject {
var mpvLog: OpaquePointer?
var inputContext: OpaquePointer?
var mpctx: UnsafeMutablePointer<MPContext>?
var vo: UnsafeMutablePointer<vo>?
var macOpts: macos_opts?
var fbo: GLint = 1
let deinitLock = NSLock()

View File

@ -88,6 +88,7 @@ class CocoaCB: NSObject {
func initBackend(_ vo: UnsafeMutablePointer<vo>) {
let opts: mp_vo_opts = vo.pointee.opts.pointee
mpv.vo = vo
NSApp.setActivationPolicy(.regular)
setAppIcon()
@ -363,6 +364,7 @@ class CocoaCB: NSObject {
eventsLock.lock()
events |= ev
eventsLock.unlock()
vo_wakeup(mpv.vo)
}
func checkEvents() -> Int {