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:
jsh
2009-08-04 11:26:58 -07:00
parent f2beab58f3
commit e7a9201edb
5 changed files with 7 additions and 2 deletions

View File

@@ -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() {

View File

@@ -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;
}
/**

View File

@@ -761,6 +761,7 @@ public final class CdmaCallTracker extends CallTracker {
}
call.onHangupLocal();
phone.notifyPreciseCallStateChanged();
}
/* package */

View File

@@ -185,6 +185,7 @@ class GsmCall extends Call {
cn.onHangupLocal();
}
state = State.DISCONNECTING;
}
/**

View File

@@ -738,6 +738,7 @@ public final class GsmCallTracker extends CallTracker {
}
call.onHangupLocal();
phone.notifyPreciseCallStateChanged();
}
/* package */