Loading src/com/android/server/telecom/Call.java +17 −1 Original line number Original line Diff line number Diff line Loading @@ -132,6 +132,7 @@ public class Call implements CreateConnectionResponse, EventManager.Loggable, void onConnectionManagerPhoneAccountChanged(Call call); void onConnectionManagerPhoneAccountChanged(Call call); void onPhoneAccountChanged(Call call); void onPhoneAccountChanged(Call call); void onConferenceableCallsChanged(Call call); void onConferenceableCallsChanged(Call call); void onConferenceStateChanged(Call call, boolean isConference); boolean onCanceledViaNewOutgoingCallBroadcast(Call call, long disconnectionTimeout); boolean onCanceledViaNewOutgoingCallBroadcast(Call call, long disconnectionTimeout); void onHoldToneRequested(Call call); void onHoldToneRequested(Call call); void onConnectionEvent(Call call, String event, Bundle extras); void onConnectionEvent(Call call, String event, Bundle extras); Loading Loading @@ -201,6 +202,8 @@ public class Call implements CreateConnectionResponse, EventManager.Loggable, @Override @Override public void onConferenceableCallsChanged(Call call) {} public void onConferenceableCallsChanged(Call call) {} @Override @Override public void onConferenceStateChanged(Call call, boolean isConference) {} @Override public boolean onCanceledViaNewOutgoingCallBroadcast(Call call, long disconnectionTimeout) { public boolean onCanceledViaNewOutgoingCallBroadcast(Call call, long disconnectionTimeout) { return false; return false; } } Loading Loading @@ -1472,7 +1475,6 @@ public class Call implements CreateConnectionResponse, EventManager.Loggable, "capable when not supported by the phone account."); "capable when not supported by the phone account."); connectionCapabilities = removeVideoCapabilities(connectionCapabilities); connectionCapabilities = removeVideoCapabilities(connectionCapabilities); } } int previousCapabilities = mConnectionCapabilities; int previousCapabilities = mConnectionCapabilities; mConnectionCapabilities = connectionCapabilities; mConnectionCapabilities = connectionCapabilities; for (Listener l : mListeners) { for (Listener l : mListeners) { Loading Loading @@ -3107,6 +3109,20 @@ public class Call implements CreateConnectionResponse, EventManager.Loggable, } } } } /** * Sets whether this {@link Call} is a conference or not. * @param isConference */ public void setConferenceState(boolean isConference) { mIsConference = isConference; Log.addEvent(this, LogUtils.Events.CONF_STATE_CHANGED, "isConference=" + isConference); // Ultimately CallsManager needs to know so it can update the "add call" state and inform // the UI to update itself. for (Listener l : mListeners) { l.onConferenceStateChanged(this, isConference); } } /** /** * Sets the video history based on the state and state transitions of the call. Always add the * Sets the video history based on the state and state transitions of the call. Always add the * current video state to the video state history during a call transition except for the * current video state to the video state history during a call transition except for the Loading src/com/android/server/telecom/CallsManager.java +10 −0 Original line number Original line Diff line number Diff line Loading @@ -146,6 +146,7 @@ public class CallsManager extends Call.ListenerBase void onExternalCallChanged(Call call, boolean isExternalCall); void onExternalCallChanged(Call call, boolean isExternalCall); void onDisconnectedTonePlaying(boolean isTonePlaying); void onDisconnectedTonePlaying(boolean isTonePlaying); void onConnectionTimeChanged(Call call); void onConnectionTimeChanged(Call call); void onConferenceStateChanged(Call call, boolean isConference); } } /** Interface used to define the action which is executed delay under some condition. */ /** Interface used to define the action which is executed delay under some condition. */ Loading Loading @@ -818,6 +819,15 @@ public class CallsManager extends Call.ListenerBase } } } } @Override public void onConferenceStateChanged(Call call, boolean isConference) { // Conference changed whether it is treated as a conference or not. updateCanAddCall(); for (CallsManagerListener listener : mListeners) { listener.onConferenceStateChanged(call, isConference); } } @Override @Override public void onIsVoipAudioModeChanged(Call call) { public void onIsVoipAudioModeChanged(Call call) { for (CallsManagerListener listener : mListeners) { for (CallsManagerListener listener : mListeners) { Loading src/com/android/server/telecom/CallsManagerListenerBase.java +4 −0 Original line number Original line Diff line number Diff line Loading @@ -96,4 +96,8 @@ public class CallsManagerListenerBase implements CallsManager.CallsManagerListen @Override @Override public void onConnectionTimeChanged(Call call) { public void onConnectionTimeChanged(Call call) { } } @Override public void onConferenceStateChanged(Call call, boolean isConference) { } } } src/com/android/server/telecom/ConnectionServiceWrapper.java +21 −0 Original line number Original line Diff line number Diff line Loading @@ -990,6 +990,27 @@ public class ConnectionServiceWrapper extends ServiceBinder implements Log.endSession(); Log.endSession(); } } } } @Override public void setConferenceState(String callId, boolean isConference, Session.Info sessionInfo) throws RemoteException { Log.startSession(sessionInfo, "CSW.sCS"); long token = Binder.clearCallingIdentity(); try { synchronized (mLock) { Call call = mCallIdMapper.getCall(callId); if (call != null) { call.setConferenceState(isConference); } } } catch (Throwable t) { Log.e(ConnectionServiceWrapper.this, t, ""); throw t; } finally { Binder.restoreCallingIdentity(token); Log.endSession(); } } } } private final Adapter mAdapter = new Adapter(); private final Adapter mAdapter = new Adapter(); Loading src/com/android/server/telecom/InCallController.java +6 −0 Original line number Original line Diff line number Diff line Loading @@ -972,6 +972,12 @@ public class InCallController extends CallsManagerListenerBase { updateCall(call); updateCall(call); } } @Override public void onConferenceStateChanged(Call call, boolean isConference) { Log.d(this, "onConferenceStateChanged %s ,isConf=%b", call, isConference); updateCall(call); } void bringToForeground(boolean showDialpad) { void bringToForeground(boolean showDialpad) { if (!mInCallServices.isEmpty()) { if (!mInCallServices.isEmpty()) { for (IInCallService inCallService : mInCallServices.values()) { for (IInCallService inCallService : mInCallServices.values()) { Loading Loading
src/com/android/server/telecom/Call.java +17 −1 Original line number Original line Diff line number Diff line Loading @@ -132,6 +132,7 @@ public class Call implements CreateConnectionResponse, EventManager.Loggable, void onConnectionManagerPhoneAccountChanged(Call call); void onConnectionManagerPhoneAccountChanged(Call call); void onPhoneAccountChanged(Call call); void onPhoneAccountChanged(Call call); void onConferenceableCallsChanged(Call call); void onConferenceableCallsChanged(Call call); void onConferenceStateChanged(Call call, boolean isConference); boolean onCanceledViaNewOutgoingCallBroadcast(Call call, long disconnectionTimeout); boolean onCanceledViaNewOutgoingCallBroadcast(Call call, long disconnectionTimeout); void onHoldToneRequested(Call call); void onHoldToneRequested(Call call); void onConnectionEvent(Call call, String event, Bundle extras); void onConnectionEvent(Call call, String event, Bundle extras); Loading Loading @@ -201,6 +202,8 @@ public class Call implements CreateConnectionResponse, EventManager.Loggable, @Override @Override public void onConferenceableCallsChanged(Call call) {} public void onConferenceableCallsChanged(Call call) {} @Override @Override public void onConferenceStateChanged(Call call, boolean isConference) {} @Override public boolean onCanceledViaNewOutgoingCallBroadcast(Call call, long disconnectionTimeout) { public boolean onCanceledViaNewOutgoingCallBroadcast(Call call, long disconnectionTimeout) { return false; return false; } } Loading Loading @@ -1472,7 +1475,6 @@ public class Call implements CreateConnectionResponse, EventManager.Loggable, "capable when not supported by the phone account."); "capable when not supported by the phone account."); connectionCapabilities = removeVideoCapabilities(connectionCapabilities); connectionCapabilities = removeVideoCapabilities(connectionCapabilities); } } int previousCapabilities = mConnectionCapabilities; int previousCapabilities = mConnectionCapabilities; mConnectionCapabilities = connectionCapabilities; mConnectionCapabilities = connectionCapabilities; for (Listener l : mListeners) { for (Listener l : mListeners) { Loading Loading @@ -3107,6 +3109,20 @@ public class Call implements CreateConnectionResponse, EventManager.Loggable, } } } } /** * Sets whether this {@link Call} is a conference or not. * @param isConference */ public void setConferenceState(boolean isConference) { mIsConference = isConference; Log.addEvent(this, LogUtils.Events.CONF_STATE_CHANGED, "isConference=" + isConference); // Ultimately CallsManager needs to know so it can update the "add call" state and inform // the UI to update itself. for (Listener l : mListeners) { l.onConferenceStateChanged(this, isConference); } } /** /** * Sets the video history based on the state and state transitions of the call. Always add the * Sets the video history based on the state and state transitions of the call. Always add the * current video state to the video state history during a call transition except for the * current video state to the video state history during a call transition except for the Loading
src/com/android/server/telecom/CallsManager.java +10 −0 Original line number Original line Diff line number Diff line Loading @@ -146,6 +146,7 @@ public class CallsManager extends Call.ListenerBase void onExternalCallChanged(Call call, boolean isExternalCall); void onExternalCallChanged(Call call, boolean isExternalCall); void onDisconnectedTonePlaying(boolean isTonePlaying); void onDisconnectedTonePlaying(boolean isTonePlaying); void onConnectionTimeChanged(Call call); void onConnectionTimeChanged(Call call); void onConferenceStateChanged(Call call, boolean isConference); } } /** Interface used to define the action which is executed delay under some condition. */ /** Interface used to define the action which is executed delay under some condition. */ Loading Loading @@ -818,6 +819,15 @@ public class CallsManager extends Call.ListenerBase } } } } @Override public void onConferenceStateChanged(Call call, boolean isConference) { // Conference changed whether it is treated as a conference or not. updateCanAddCall(); for (CallsManagerListener listener : mListeners) { listener.onConferenceStateChanged(call, isConference); } } @Override @Override public void onIsVoipAudioModeChanged(Call call) { public void onIsVoipAudioModeChanged(Call call) { for (CallsManagerListener listener : mListeners) { for (CallsManagerListener listener : mListeners) { Loading
src/com/android/server/telecom/CallsManagerListenerBase.java +4 −0 Original line number Original line Diff line number Diff line Loading @@ -96,4 +96,8 @@ public class CallsManagerListenerBase implements CallsManager.CallsManagerListen @Override @Override public void onConnectionTimeChanged(Call call) { public void onConnectionTimeChanged(Call call) { } } @Override public void onConferenceStateChanged(Call call, boolean isConference) { } } }
src/com/android/server/telecom/ConnectionServiceWrapper.java +21 −0 Original line number Original line Diff line number Diff line Loading @@ -990,6 +990,27 @@ public class ConnectionServiceWrapper extends ServiceBinder implements Log.endSession(); Log.endSession(); } } } } @Override public void setConferenceState(String callId, boolean isConference, Session.Info sessionInfo) throws RemoteException { Log.startSession(sessionInfo, "CSW.sCS"); long token = Binder.clearCallingIdentity(); try { synchronized (mLock) { Call call = mCallIdMapper.getCall(callId); if (call != null) { call.setConferenceState(isConference); } } } catch (Throwable t) { Log.e(ConnectionServiceWrapper.this, t, ""); throw t; } finally { Binder.restoreCallingIdentity(token); Log.endSession(); } } } } private final Adapter mAdapter = new Adapter(); private final Adapter mAdapter = new Adapter(); Loading
src/com/android/server/telecom/InCallController.java +6 −0 Original line number Original line Diff line number Diff line Loading @@ -972,6 +972,12 @@ public class InCallController extends CallsManagerListenerBase { updateCall(call); updateCall(call); } } @Override public void onConferenceStateChanged(Call call, boolean isConference) { Log.d(this, "onConferenceStateChanged %s ,isConf=%b", call, isConference); updateCall(call); } void bringToForeground(boolean showDialpad) { void bringToForeground(boolean showDialpad) { if (!mInCallServices.isEmpty()) { if (!mInCallServices.isEmpty()) { for (IInCallService inCallService : mInCallServices.values()) { for (IInCallService inCallService : mInCallServices.values()) { Loading