Add a DISCONNECTING call state.
This indicates to the UI that the hangup command has been received by the Telephony layer and passed down to the RIL, but we have not yet been notified of a successful DISCONNECT. Addresses http://b/issue?id=1659876.
This commit is contained in:
@@ -25,10 +25,10 @@ public abstract class Call {
|
||||
/* Enums */
|
||||
|
||||
public enum State {
|
||||
IDLE, ACTIVE, HOLDING, DIALING, ALERTING, INCOMING, WAITING, DISCONNECTED;
|
||||
IDLE, ACTIVE, HOLDING, DIALING, ALERTING, INCOMING, WAITING, DISCONNECTED, DISCONNECTING;
|
||||
|
||||
public boolean isAlive() {
|
||||
return !(this == IDLE || this == DISCONNECTED);
|
||||
return !(this == IDLE || this == DISCONNECTED || this == DISCONNECTING);
|
||||
}
|
||||
|
||||
public boolean isRinging() {
|
||||
|
||||
@@ -24,6 +24,7 @@ import com.android.internal.telephony.CallStateException;
|
||||
import com.android.internal.telephony.Connection;
|
||||
import com.android.internal.telephony.DriverCall;
|
||||
import com.android.internal.telephony.Phone;
|
||||
import com.android.internal.telephony.Call.State;
|
||||
|
||||
/**
|
||||
* {@hide}
|
||||
@@ -186,6 +187,7 @@ public final class CdmaCall extends Call {
|
||||
|
||||
cn.onHangupLocal();
|
||||
}
|
||||
state = State.DISCONNECTING;
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@@ -761,6 +761,7 @@ public final class CdmaCallTracker extends CallTracker {
|
||||
}
|
||||
|
||||
call.onHangupLocal();
|
||||
phone.notifyPreciseCallStateChanged();
|
||||
}
|
||||
|
||||
/* package */
|
||||
|
||||
@@ -185,6 +185,7 @@ class GsmCall extends Call {
|
||||
|
||||
cn.onHangupLocal();
|
||||
}
|
||||
state = State.DISCONNECTING;
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@@ -738,6 +738,7 @@ public final class GsmCallTracker extends CallTracker {
|
||||
}
|
||||
|
||||
call.onHangupLocal();
|
||||
phone.notifyPreciseCallStateChanged();
|
||||
}
|
||||
|
||||
/* package */
|
||||
|
||||
Reference in New Issue
Block a user