|
@@ -468,6 +468,20 @@ class QmeraVideoViewController: UIViewController {
|
|
|
}
|
|
|
|
|
|
@objc func didTapAcceptCallButton(){
|
|
|
+ let goAudioCall = Nexilis.checkMicPermission()
|
|
|
+ let goVideoCall = Nexilis.checkCameraPermission()
|
|
|
+ if goVideoCall == 0 {
|
|
|
+ let alert = UIAlertController(title: "Attention!".localized(), message: !goAudioCall && goVideoCall == 0 ? "Please allow microphone & camera permission in your settings".localized() : !goAudioCall ? "Please allow microphone permission in your settings".localized() : "Please allow camera permission in your settings", preferredStyle: .alert)
|
|
|
+ alert.addAction(UIAlertAction(title: "OK".localized(), style: UIAlertAction.Style.default, handler: {_ in
|
|
|
+ if let url = URL(string: UIApplication.openSettingsURLString), UIApplication.shared.canOpenURL(url) {
|
|
|
+ UIApplication.shared.open(url, options: [:], completionHandler: nil)
|
|
|
+ }
|
|
|
+ }))
|
|
|
+ self.navigationController?.present(alert, animated: true, completion: nil)
|
|
|
+ return
|
|
|
+ } else if goVideoCall == -1 {
|
|
|
+ return
|
|
|
+ }
|
|
|
Nexilis.startAudio(nMode: 2, bSpeakerOn: true)
|
|
|
API.receiveCCall(sParty: dataPerson[0]["f_pin"]!, nCamIdx: 1, nResIdx: 2, nVQuality: 4, ivRemoteView: listRemoteViewFix, ivLocalView: cameraView,ivRemoteZ: zoomView)
|
|
|
DispatchQueue.main.async {
|
|
@@ -918,6 +932,8 @@ class QmeraVideoViewController: UIViewController {
|
|
|
} else if self.dataPerson.count > 1 {
|
|
|
DispatchQueue.main.async {
|
|
|
for i in 0..<self.dataPerson.count {
|
|
|
+// self.listRemoteViewFix[i].image = self.listRemoteViewFix[i].image?.rotate(radians: (CGFloat.pi * 3 )/2)
|
|
|
+ self.listRemoteViewFix[i].image = nil
|
|
|
if self.dataPerson[i]["user_type"] == "2" || arrayMessage[5] == "2" {
|
|
|
self.listRemoteViewFix[i].transform = CGAffineTransform.init(scaleX: 1.4, y: 1.3).rotated(by: (CGFloat.pi)/2)
|
|
|
} else {
|