Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 79b1855e authored by Jinhong Seol's avatar Jinhong Seol
Browse files

change condition isPhoneInVoiceCall for added call



Bug: 223797061
Test: atest FrameworksTelephonyTests:PhoneSwitcherTest

Signed-off-by: default avatarJinhong Seol <jinhong.seol@samsung.com>
Change-Id: I58973a2cf7bfff0bbdde1f3eb2bc9598a1ff9f50
parent 7d40c4ab
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -1643,7 +1643,7 @@ public class PhoneSwitcher extends Handler {
        // in network (DIALING -> ALERTING).
        return (phone.getForegroundCall().getState() == Call.State.ACTIVE
                || phone.getForegroundCall().getState() == Call.State.ALERTING
                || phone.getBackgroundCall().getState() == Call.State.HOLDING);
                || !phone.getBackgroundCall().isIdle());
    }

    private void updateHalCommandToUse() {
+4 −0
Original line number Diff line number Diff line
@@ -150,6 +150,10 @@ public class PhoneSwitcherTest extends TelephonyTest {
        doReturn(Call.State.IDLE).when(mInactiveCall).getState();
        doReturn(Call.State.HOLDING).when(mHoldingCall).getState();

        doReturn(true).when(mInactiveCall).isIdle();
        doReturn(false).when(mActiveCall).isIdle();
        doReturn(false).when(mHoldingCall).isIdle();

        replaceInstance(Phone.class, "mCi", mPhone, mCommandsInterface0);
        replaceInstance(Phone.class, "mCi", mPhone2, mCommandsInterface1);
    }