mirror of
https://github.com/Swiftgram/Telegram-iOS.git
synced 2025-06-16 05:55:20 +00:00
fix for mac
This commit is contained in:
parent
b28b67eef2
commit
f440eccbf6
@ -601,44 +601,13 @@ public final class OngoingGroupCallContext {
|
||||
mainView?.setOnIsMirroredUpdated { value in
|
||||
f?(value)
|
||||
}
|
||||
}, setIsPaused: { [weak mainView] paused in
|
||||
mainView?.setIsPaused(paused)
|
||||
}, renderToSize: { [weak mainView] size, animated in
|
||||
mainView?.render(to: size, animated: animated)
|
||||
}
|
||||
)
|
||||
var cloneVideoView: OngoingCallContextPresentationCallVideoView?
|
||||
if let cloneView = cloneView {
|
||||
cloneVideoView = OngoingCallContextPresentationCallVideoView(
|
||||
view: cloneView,
|
||||
setOnFirstFrameReceived: { [weak cloneView] f in
|
||||
cloneView?.setOnFirstFrameReceived(f)
|
||||
},
|
||||
getOrientation: { [weak cloneView] in
|
||||
if let cloneView = cloneView {
|
||||
return OngoingCallVideoOrientation(cloneView.orientation)
|
||||
} else {
|
||||
return .rotation0
|
||||
}
|
||||
},
|
||||
getAspect: { [weak cloneView] in
|
||||
if let cloneView = cloneView {
|
||||
return cloneView.aspect
|
||||
} else {
|
||||
return 0.0
|
||||
}
|
||||
},
|
||||
setOnOrientationUpdated: { [weak cloneView] f in
|
||||
cloneView?.setOnOrientationUpdated { value, aspect in
|
||||
f?(OngoingCallVideoOrientation(value), aspect)
|
||||
}
|
||||
}, setVideoContentMode: { [weak cloneView] mode in
|
||||
cloneView?.setVideoContentMode(mode)
|
||||
},
|
||||
setOnIsMirroredUpdated: { [weak cloneView] f in
|
||||
cloneView?.setOnIsMirroredUpdated { value in
|
||||
f?(value)
|
||||
}
|
||||
}
|
||||
)
|
||||
}
|
||||
completion(mainVideoView, cloneVideoView)
|
||||
completion(mainVideoView, nil)
|
||||
#endif
|
||||
} else {
|
||||
completion(nil, nil)
|
||||
|
Loading…
x
Reference in New Issue
Block a user