only show remote video when connected
This commit is contained in:
		
							parent
							
								
									0c4f0c074d
								
							
						
					
					
						commit
						21e412ef6f
					
				@ -531,12 +531,17 @@ public class RtpSessionActivity extends XmppActivity implements XmppConnectionSe
 | 
			
		||||
        if (remoteVideoTrack.isPresent()) {
 | 
			
		||||
            ensureSurfaceViewRendererIsSetup(binding.remoteVideo);
 | 
			
		||||
            remoteVideoTrack.get().addSink(binding.remoteVideo);
 | 
			
		||||
            if (state == RtpEndUserState.CONNECTED) {
 | 
			
		||||
                binding.appBarLayout.setVisibility(View.GONE);
 | 
			
		||||
                getWindow().addFlags(WindowManager.LayoutParams.FLAG_FULLSCREEN);
 | 
			
		||||
            } else {
 | 
			
		||||
                getWindow().clearFlags(WindowManager.LayoutParams.FLAG_FULLSCREEN);
 | 
			
		||||
                binding.remoteVideo.setVisibility(View.GONE);
 | 
			
		||||
            }
 | 
			
		||||
        } else {
 | 
			
		||||
            getWindow().clearFlags(WindowManager.LayoutParams.FLAG_FULLSCREEN);
 | 
			
		||||
            binding.remoteVideo.setVisibility(View.GONE);
 | 
			
		||||
        }
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    private void disableMicrophone(View view) {
 | 
			
		||||
 | 
			
		||||
@ -196,7 +196,7 @@ public class JingleConnectionManager extends AbstractConnectionManager {
 | 
			
		||||
                    Log.d(Config.LOGTAG, account.getJid().asBareJid() + ": encountered unknown media in session proposal. " + propose);
 | 
			
		||||
                    return;
 | 
			
		||||
                }
 | 
			
		||||
                if (isBusy()) { //TODO only if no other devices are active
 | 
			
		||||
                if (isBusy()) {
 | 
			
		||||
                    writeLogMissedIncoming(account, id.with.asBareJid(), id.sessionId, serverMsgId, timestamp);
 | 
			
		||||
                    final int activeDevices = account.countPresences();
 | 
			
		||||
                    Log.d(Config.LOGTAG, "active devices: " + activeDevices);
 | 
			
		||||
 | 
			
		||||
		Loading…
	
		Reference in New Issue
	
	Block a user