Loading telecomm/java/android/telecomm/CallService.java +23 −0 Original line number Diff line number Diff line Loading @@ -63,6 +63,7 @@ public abstract class CallService extends Service { private static final int MSG_STOP_DTMF_TONE = 13; private static final int MSG_ADD_TO_CONFERENCE = 14; private static final int MSG_SPLIT_FROM_CONFERENCE = 15; private static final int MSG_ON_POST_DIAL_CONTINUE = 16; /** * Default Handler used to consolidate binder method calls onto a single thread. Loading Loading @@ -150,6 +151,17 @@ public abstract class CallService extends Service { } break; } case MSG_ON_POST_DIAL_CONTINUE: { SomeArgs args = (SomeArgs) msg.obj; try { String callId = (String) args.arg1; boolean proceed = (args.argi1 == 1); onPostDialContinue(callId, proceed); } finally { args.recycle(); } break; } default: break; } Loading Loading @@ -247,6 +259,14 @@ public abstract class CallService extends Service { args.arg2 = callId; mMessageHandler.obtainMessage(MSG_SPLIT_FROM_CONFERENCE, args).sendToTarget(); } @Override public void onPostDialContinue(String callId, boolean proceed) { SomeArgs args = SomeArgs.obtain(); args.arg1 = callId; args.argi1 = proceed ? 1 : 0; mMessageHandler.obtainMessage(MSG_ON_POST_DIAL_CONTINUE, args).sendToTarget(); } } /** Loading Loading @@ -422,4 +442,7 @@ public abstract class CallService extends Service { * @hide */ public abstract void splitFromConference(String conferenceCallId, String callId); public void onPostDialContinue(String callId, boolean proceed) {} public void onPostDialWait(Connection conn, String remaining) {} } telecomm/java/android/telecomm/CallServiceAdapter.java +7 −0 Original line number Diff line number Diff line Loading @@ -217,4 +217,11 @@ public final class CallServiceAdapter { } catch (RemoteException ignored) { } } public void onPostDialWait(String callId, String remaining) { try { mAdapter.onPostDialWait(callId, remaining); } catch (RemoteException ignored) { } } } telecomm/java/android/telecomm/Connection.java +5 −0 Original line number Diff line number Diff line Loading @@ -444,6 +444,11 @@ public abstract class Connection { */ protected void onReject() {} /** * Notifies this Connection whether the user wishes to proceed with the post-dial DTMF codes. */ protected void onPostDialContinue(boolean proceed) {} private void setState(int state) { Log.d(this, "setState: %s", stateToString(state)); onSetState(state); Loading telecomm/java/android/telecomm/ConnectionService.java +21 −1 Original line number Diff line number Diff line Loading @@ -146,7 +146,8 @@ public abstract class ConnectionService extends CallService { } } else { addConnection(callInfo.getId(), result[0]); Log.d(this, "adapter handleSuccessfulOutgoingCall %s", callInfo.getId()); Log.d(this, "adapter handleSuccessfulOutgoingCall %s", callInfo.getId()); getAdapter().handleSuccessfulOutgoingCall(callInfo.getId()); } } Loading Loading @@ -288,6 +289,25 @@ public abstract class ConnectionService extends CallService { // TODO(santoscordon): Find existing conference call and invoke split(connection). } @Override public final void onPostDialContinue(String callId, boolean proceed) { Log.d(this, "onPostDialContinue(%s)", callId); Connection connection = findConnectionForAction(callId, "onPostDialContinue"); if (connection == NULL_CONNECTION) { Log.w(this, "Connection missing in post-dial request %s.", callId); return; } connection.onPostDialContinue(proceed); } @Override public final void onPostDialWait(Connection conn, String remaining) { Log.d(this, "onPostDialWait(%s, %s)", conn, remaining); getAdapter().onPostDialWait(mIdByConnection.get(conn), remaining); } /** * Find a set of Subscriptions matching a given handle (e.g. phone number). * Loading telecomm/java/android/telecomm/InCallAdapter.java +4 −3 Original line number Diff line number Diff line Loading @@ -174,13 +174,14 @@ public final class InCallAdapter { * will pause playing the tones and notify the {@link InCallService} that the call is in the * {@link InCallService#setPostDialWait(String,String)} state. When the user decides to continue * the postdial sequence, the {@link InCallService} should invoke the * {@link #postDialContinue(String)} method. * {@link #postDialContinue(String,boolean)} method. * * @param callId The unique ID of the call for which postdial string playing should continue. * @param proceed Whether or not to continue with the post-dial sequence. */ public void postDialContinue(String callId) { public void postDialContinue(String callId, boolean proceed) { try { mAdapter.postDialContinue(callId); mAdapter.postDialContinue(callId, proceed); } catch (RemoteException e) { } } Loading Loading
telecomm/java/android/telecomm/CallService.java +23 −0 Original line number Diff line number Diff line Loading @@ -63,6 +63,7 @@ public abstract class CallService extends Service { private static final int MSG_STOP_DTMF_TONE = 13; private static final int MSG_ADD_TO_CONFERENCE = 14; private static final int MSG_SPLIT_FROM_CONFERENCE = 15; private static final int MSG_ON_POST_DIAL_CONTINUE = 16; /** * Default Handler used to consolidate binder method calls onto a single thread. Loading Loading @@ -150,6 +151,17 @@ public abstract class CallService extends Service { } break; } case MSG_ON_POST_DIAL_CONTINUE: { SomeArgs args = (SomeArgs) msg.obj; try { String callId = (String) args.arg1; boolean proceed = (args.argi1 == 1); onPostDialContinue(callId, proceed); } finally { args.recycle(); } break; } default: break; } Loading Loading @@ -247,6 +259,14 @@ public abstract class CallService extends Service { args.arg2 = callId; mMessageHandler.obtainMessage(MSG_SPLIT_FROM_CONFERENCE, args).sendToTarget(); } @Override public void onPostDialContinue(String callId, boolean proceed) { SomeArgs args = SomeArgs.obtain(); args.arg1 = callId; args.argi1 = proceed ? 1 : 0; mMessageHandler.obtainMessage(MSG_ON_POST_DIAL_CONTINUE, args).sendToTarget(); } } /** Loading Loading @@ -422,4 +442,7 @@ public abstract class CallService extends Service { * @hide */ public abstract void splitFromConference(String conferenceCallId, String callId); public void onPostDialContinue(String callId, boolean proceed) {} public void onPostDialWait(Connection conn, String remaining) {} }
telecomm/java/android/telecomm/CallServiceAdapter.java +7 −0 Original line number Diff line number Diff line Loading @@ -217,4 +217,11 @@ public final class CallServiceAdapter { } catch (RemoteException ignored) { } } public void onPostDialWait(String callId, String remaining) { try { mAdapter.onPostDialWait(callId, remaining); } catch (RemoteException ignored) { } } }
telecomm/java/android/telecomm/Connection.java +5 −0 Original line number Diff line number Diff line Loading @@ -444,6 +444,11 @@ public abstract class Connection { */ protected void onReject() {} /** * Notifies this Connection whether the user wishes to proceed with the post-dial DTMF codes. */ protected void onPostDialContinue(boolean proceed) {} private void setState(int state) { Log.d(this, "setState: %s", stateToString(state)); onSetState(state); Loading
telecomm/java/android/telecomm/ConnectionService.java +21 −1 Original line number Diff line number Diff line Loading @@ -146,7 +146,8 @@ public abstract class ConnectionService extends CallService { } } else { addConnection(callInfo.getId(), result[0]); Log.d(this, "adapter handleSuccessfulOutgoingCall %s", callInfo.getId()); Log.d(this, "adapter handleSuccessfulOutgoingCall %s", callInfo.getId()); getAdapter().handleSuccessfulOutgoingCall(callInfo.getId()); } } Loading Loading @@ -288,6 +289,25 @@ public abstract class ConnectionService extends CallService { // TODO(santoscordon): Find existing conference call and invoke split(connection). } @Override public final void onPostDialContinue(String callId, boolean proceed) { Log.d(this, "onPostDialContinue(%s)", callId); Connection connection = findConnectionForAction(callId, "onPostDialContinue"); if (connection == NULL_CONNECTION) { Log.w(this, "Connection missing in post-dial request %s.", callId); return; } connection.onPostDialContinue(proceed); } @Override public final void onPostDialWait(Connection conn, String remaining) { Log.d(this, "onPostDialWait(%s, %s)", conn, remaining); getAdapter().onPostDialWait(mIdByConnection.get(conn), remaining); } /** * Find a set of Subscriptions matching a given handle (e.g. phone number). * Loading
telecomm/java/android/telecomm/InCallAdapter.java +4 −3 Original line number Diff line number Diff line Loading @@ -174,13 +174,14 @@ public final class InCallAdapter { * will pause playing the tones and notify the {@link InCallService} that the call is in the * {@link InCallService#setPostDialWait(String,String)} state. When the user decides to continue * the postdial sequence, the {@link InCallService} should invoke the * {@link #postDialContinue(String)} method. * {@link #postDialContinue(String,boolean)} method. * * @param callId The unique ID of the call for which postdial string playing should continue. * @param proceed Whether or not to continue with the post-dial sequence. */ public void postDialContinue(String callId) { public void postDialContinue(String callId, boolean proceed) { try { mAdapter.postDialContinue(callId); mAdapter.postDialContinue(callId, proceed); } catch (RemoteException e) { } } Loading