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

Commit 6cb805f8 authored by Santos Cordon's avatar Santos Cordon
Browse files

Telephony Capability-Distinguish dialing & connect

New capability returns true if the device can distinguish between
dialing/active and connected reliably. Currently returns true only for
GSM phones.

Change-Id: I50751abaf74b31fdc747f4d04ca9a2ac4d73a1ff
parent b25f48f2
Loading
Loading
Loading
Loading
+11 −0
Original line number Diff line number Diff line
@@ -177,4 +177,15 @@ public class TelephonyCapabilities {
    public static boolean supportsAdn(int phoneType) {
        return phoneType == Phone.PHONE_TYPE_GSM;
    }

    /**
     * Returns true if the device can distinguish the phone's dialing state
     * (Call.State.DIALING/ACTIVE) and connected state (Call.State.CONNECTED).
     *
     * Currently this returns true for GSM phones as we cannot know when a CDMA
     * phone has transitioned from dialing/active to connected.
     */
    public static boolean canDistinguishDialingAndConnected(int phoneType) {
        return phoneType == Phone.PHONE_TYPE_GSM;
    }
}