Add DTMF dial tone commands to CallCommandsService.
Moved over much of the code from DTMFTwelveKeyDialer except for UI code
and short-Tone. When we copy over short tone, we should be able to
delete DTMFTwelveKeyDialer.
Change-Id: Ibb954cdeb30bec99d717569f9254892661533699
diff --git a/src/com/android/phone/CallModeler.java b/src/com/android/phone/CallModeler.java
index 01f571f..8aed6e5 100644
--- a/src/com/android/phone/CallModeler.java
+++ b/src/com/android/phone/CallModeler.java
@@ -127,6 +127,19 @@
return null;
}
+ public boolean hasOutstandingActiveCall() {
+ for (Call call : mCallMap.values()) {
+ int state = call.getState();
+ if (Call.State.INVALID != state &&
+ Call.State.IDLE != state &&
+ Call.State.INCOMING != state) {
+ return true;
+ }
+ }
+
+ return false;
+ }
+
private void onNewRingingConnection(AsyncResult r) {
final Connection conn = (Connection) r.result;
final Call call = getCallFromConnection(conn, true);