diff options
author | Tyler Gunn <tgunn@google.com> | 2016-02-29 10:12:46 -0800 |
---|---|---|
committer | Tyler Gunn <tgunn@google.com> | 2016-03-01 09:35:32 -0800 |
commit | 0e5105aee781620518550689803bff1e4e558f55 (patch) | |
tree | 6c48dd8e76a61dec9381e1d734cbaf6ef622ebc1 | |
parent | 9172c905b311816eba1d24659f02facfab95b0b3 (diff) |
Fix issue where video does not un-pause after call waiting dismissed.
When an incoming call waiting call is received, the VideoPauseController
sends a "pause" command to the video provider.
However, upon dismissing the call waiting call, the foreground call
was not being unpaused.
Bug: 21815566
Change-Id: I637ab70d1b2adf4510dd87e5d56e233b1a3e065d
-rw-r--r-- | InCallUI/src/com/android/incallui/VideoPauseController.java | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/InCallUI/src/com/android/incallui/VideoPauseController.java b/InCallUI/src/com/android/incallui/VideoPauseController.java index 070448ee9..54b36fe76 100644 --- a/InCallUI/src/com/android/incallui/VideoPauseController.java +++ b/InCallUI/src/com/android/incallui/VideoPauseController.java @@ -23,6 +23,8 @@ import com.android.incallui.InCallPresenter.IncomingCallListener; import com.android.incallui.InCallVideoCallCallbackNotifier.SessionModificationListener; import com.google.common.base.Preconditions; +import android.telecom.VideoProfile; + /** * This class is responsible for generating video pause/resume requests when the InCall UI is sent * to the background and subsequently brought back to the foreground. @@ -195,10 +197,11 @@ class VideoPauseController implements InCallStateListener, IncomingCallListener, Preconditions.checkState(!areSame(call, mPrimaryCallContext)); final boolean canVideoPause = VideoUtils.canVideoPause(call); - if ((isIncomingCall(mPrimaryCallContext) || isDialing(mPrimaryCallContext)) + if ((isIncomingCall(mPrimaryCallContext) || isDialing(mPrimaryCallContext) || + (call != null && VideoProfile.isPaused(call.getVideoState()))) && canVideoPause && !mIsInBackground) { - // Send resume request for the active call, if user rejects incoming call or ends - // dialing call and UI is in the foreground. + // Send resume request for the active call, if user rejects incoming call, ends dialing + // call, or the call was previously in a paused state and UI is in the foreground. sendRequest(call, true); } else if (isIncomingCall(call) && canVideoPause(mPrimaryCallContext)) { // Send pause request if there is an active video call, and we just received a new |