diff options
author | Tyler Gunn <tgunn@google.com> | 2017-09-19 14:43:27 -0700 |
---|---|---|
committer | Tyler Gunn <tgunn@google.com> | 2017-09-19 14:43:27 -0700 |
commit | 64f3d6bc6909237bfc1afe8907bac8e5e47d6cc3 (patch) | |
tree | c25f0a7479f152636d0c32643a90dbaecb9e4317 | |
parent | ca9cdf0f2b4b01e9364c3f599bfae928ccc5bd0e (diff) | |
download | telephony-64f3d6bc6909237bfc1afe8907bac8e5e47d6cc3.tar.gz |
Fix issue where video call continues on LTE when wifi lost and data off.
Due to changes in b/36900451 to decouple VT from the data enabled state
of the device, there was a regression in the case where WIFI is lost during
a WIFI video call and mobile data is off.
Changed code to properly handle this case by triggering a disconnect when
video pause signalling is in use.
Test: Manual - turn off wifi when on WIFI video call and mobile data is
disabled. Regression tested mobile data off auto-pausing.
Bug: 64531514
Change-Id: I6561f653cd446b74f127951e02d482f7c9267c9d
-rw-r--r-- | src/java/com/android/internal/telephony/imsphone/ImsPhoneCallTracker.java | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/src/java/com/android/internal/telephony/imsphone/ImsPhoneCallTracker.java b/src/java/com/android/internal/telephony/imsphone/ImsPhoneCallTracker.java index 11350e03e6..072da68ed9 100644 --- a/src/java/com/android/internal/telephony/imsphone/ImsPhoneCallTracker.java +++ b/src/java/com/android/internal/telephony/imsphone/ImsPhoneCallTracker.java @@ -2551,7 +2551,7 @@ public class ImsPhoneCallTracker extends CallTracker implements ImsPullCall { && targetAccessTech != ServiceState.RIL_RADIO_TECHNOLOGY_UNKNOWN && targetAccessTech != ServiceState.RIL_RADIO_TECHNOLOGY_IWLAN; if (isHandoverFromWifi && imsCall.isVideoCall()) { - if (mNotifyHandoverVideoFromWifiToLTE) { + if (mNotifyHandoverVideoFromWifiToLTE && mIsDataEnabled) { log("onCallHandover :: notifying of WIFI to LTE handover."); conn.onConnectionEvent( TelephonyManager.EVENT_HANDOVER_VIDEO_FROM_WIFI_TO_LTE, null); @@ -2560,7 +2560,7 @@ public class ImsPhoneCallTracker extends CallTracker implements ImsPullCall { if (!mIsDataEnabled && mIsViLteDataMetered) { // Call was downgraded from WIFI to LTE and data is metered; downgrade the // call now. - downgradeVideoCall(ImsReasonInfo.CODE_DATA_DISABLED, conn); + downgradeVideoCall(ImsReasonInfo.CODE_WIFI_LOST, conn); } } } else { @@ -3520,8 +3520,9 @@ public class ImsPhoneCallTracker extends CallTracker implements ImsPullCall { // If the carrier supports downgrading to voice, then we can simply issue a // downgrade to voice instead of terminating the call. modifyVideoCall(imsCall, VideoProfile.STATE_AUDIO_ONLY); - } else if (mSupportPauseVideo) { - // The carrier supports video pause signalling, so pause the video. + } else if (mSupportPauseVideo && reasonCode != ImsReasonInfo.CODE_WIFI_LOST) { + // The carrier supports video pause signalling, so pause the video if we didn't just + // lose wifi; in that case just disconnect. mShouldUpdateImsConfigOnDisconnect = true; conn.pauseVideo(VideoPauseTracker.SOURCE_DATA_ENABLED); } else { |