class
VideoPlayerProxy
UI(context)高层代理
1
2
3
4
5
6
7
8
9
10
private func withContext(_ f: @escaping (VideoPlayerProxyContext?) -> Void) {
self.contextQueue.async {
if let contextRef = self.contextRef {
let context = contextRef.takeUnretainedValue()
f(context)
} else {
f(nil)
}
}
}