From 2cec38000c225d15a7b895db28541f4be2f2df7b Mon Sep 17 00:00:00 2001 From: roldenburg Date: Wed, 11 Oct 2017 16:26:51 -0700 Subject: Fix for voice screen showing for a short time when making a video call Author: tomoyuki.nishikawa@sony.com This change was inspired by http://aosp/508735 Even though VideoProfile.isVideo(getVideoState() returns true when starting a video call, ImsVideoTech is not ready until call.getVideoCall() returns not null (see https://android.googlesource.com/platform/packages/apps/Dialer/+/master/java/com/android/incallui/videotech/ims/ImsVideoTech.java#66) During the time between VideoProfile.isVideo(getVideoState() being true but call.getVideoCall() returning null, we are incorrectly showing the phone call UI instead of the video call UI. To fix this, we need to trust the VideoProfile check in addition to the VideoTech check. We still need to check VideoTech for other video options aside from just IMS VT. Bug: 67712159 Test: manual PiperOrigin-RevId: 171892356 Change-Id: Ibe1f9de60aaa4adc971401bee0277961cfe037e4 --- java/com/android/incallui/call/DialerCall.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'java/com/android/incallui') diff --git a/java/com/android/incallui/call/DialerCall.java b/java/com/android/incallui/call/DialerCall.java index 621ad21f8..6829203ff 100644 --- a/java/com/android/incallui/call/DialerCall.java +++ b/java/com/android/incallui/call/DialerCall.java @@ -857,7 +857,7 @@ public class DialerCall implements VideoTechListener, StateChangedListener, Capa } public boolean isVideoCall() { - return getVideoTech().isTransmittingOrReceiving(); + return getVideoTech().isTransmittingOrReceiving() || VideoProfile.isVideo(getVideoState()); } public boolean hasReceivedVideoUpgradeRequest() { -- cgit v1.2.3