|  |  | @ -458,6 +458,7 @@ class CallViewController: UIViewController, CallObserver, CallServiceObserver, R | 
			
		
	
		
		
			
				
					
					|  |  |  |         } |  |  |  |         } | 
			
		
	
		
		
			
				
					
					|  |  |  | 
 |  |  |  | 
 | 
			
		
	
		
		
			
				
					
					|  |  |  |         self.localVideoConstraints = constraints |  |  |  |         self.localVideoConstraints = constraints | 
			
		
	
		
		
			
				
					
					|  |  |  |  |  |  |  |         updateCallUI(callState: call.state) | 
			
		
	
		
		
			
				
					
					|  |  |  |     } |  |  |  |     } | 
			
		
	
		
		
			
				
					
					|  |  |  | 
 |  |  |  | 
 | 
			
		
	
		
		
			
				
					
					|  |  |  |     // MARK: - Methods |  |  |  |     // MARK: - Methods | 
			
		
	
	
		
		
			
				
					|  |  | @ -546,12 +547,17 @@ class CallViewController: UIViewController, CallObserver, CallServiceObserver, R | 
			
		
	
		
		
			
				
					
					|  |  |  |         ongoingCallView.isUserInteractionEnabled = !isRinging |  |  |  |         ongoingCallView.isUserInteractionEnabled = !isRinging | 
			
		
	
		
		
			
				
					
					|  |  |  | 
 |  |  |  | 
 | 
			
		
	
		
		
			
				
					
					|  |  |  |         // Rework control state if remote video is available. |  |  |  |         // Rework control state if remote video is available. | 
			
		
	
		
		
			
				
					
					|  |  |  |         contactAvatarView.isHidden = !remoteVideoView.isHidden |  |  |  |         let hasRemoteVideo = !remoteVideoView.isHidden | 
			
				
				
			
		
	
		
		
			
				
					
					|  |  |  |         speakerPhoneButton.isHidden = !remoteVideoView.isHidden |  |  |  |         contactAvatarView.isHidden = hasRemoteVideo | 
			
				
				
			
		
	
		
		
			
				
					
					|  |  |  |         audioModeMuteButton.isHidden = !remoteVideoView.isHidden |  |  |  | 
 | 
			
				
				
			
		
	
		
		
			
				
					
					|  |  |  |         videoModeMuteButton.isHidden = remoteVideoView.isHidden |  |  |  |         // Rework control state if local video is available. | 
			
				
				
			
		
	
		
		
			
				
					
					|  |  |  |         audioModeVideoButton.isHidden = !remoteVideoView.isHidden |  |  |  |         let hasLocalVideo = !localVideoView.isHidden | 
			
				
				
			
		
	
		
		
			
				
					
					|  |  |  |         videoModeVideoButton.isHidden = remoteVideoView.isHidden |  |  |  |         for subview in [speakerPhoneButton, audioModeMuteButton, audioModeVideoButton] { | 
			
				
				
			
		
	
		
		
	
		
		
	
		
		
	
		
		
	
		
		
	
		
		
	
		
		
			
				
					
					|  |  |  |  |  |  |  |             subview?.isHidden = hasLocalVideo | 
			
		
	
		
		
			
				
					
					|  |  |  |  |  |  |  |         } | 
			
		
	
		
		
			
				
					
					|  |  |  |  |  |  |  |         for subview in [videoModeMuteButton, videoModeVideoButton] { | 
			
		
	
		
		
			
				
					
					|  |  |  |  |  |  |  |             subview?.isHidden = !hasLocalVideo | 
			
		
	
		
		
			
				
					
					|  |  |  |  |  |  |  |         } | 
			
		
	
		
		
			
				
					
					|  |  |  | 
 |  |  |  | 
 | 
			
		
	
		
		
			
				
					
					|  |  |  |         // Also hide other controls if user has tapped to hide them. |  |  |  |         // Also hide other controls if user has tapped to hide them. | 
			
		
	
		
		
			
				
					
					|  |  |  |         if areRemoteVideoControlsHidden && !remoteVideoView.isHidden { |  |  |  |         if areRemoteVideoControlsHidden && !remoteVideoView.isHidden { | 
			
		
	
	
		
		
			
				
					|  |  | 
 |