Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit d42ae74a authored by Treehugger Robot's avatar Treehugger Robot Committed by Gerrit Code Review
Browse files

Merge "Conference Call at connection"

parents 70f695c4 438b6e4d
Loading
Loading
Loading
Loading
+5 −0
Original line number Diff line number Diff line
@@ -578,6 +578,11 @@ public class HeadsetClientStateMachine extends StateMachine {
        BluetoothHeadsetClientCall c = getCall(BluetoothHeadsetClientCall.CALL_STATE_DIALING,
                BluetoothHeadsetClientCall.CALL_STATE_ALERTING,
                BluetoothHeadsetClientCall.CALL_STATE_ACTIVE);
        if (c == null) {
            // If the call being terminated is currently held, switch the action to CHLD_0
            c = getCall(BluetoothHeadsetClientCall.CALL_STATE_HELD);
            action = HeadsetClientHalConstants.CALL_ACTION_CHLD_0;
        }
        if (c != null) {
            if (NativeInterface.handleCallActionNative(getByteAddress(mCurrentDevice), action, 0)) {
                addQueuedAction(TERMINATE_CALL, action);
+4 −5
Original line number Diff line number Diff line
@@ -88,10 +88,9 @@ public class HfpClientDeviceBlock {
    }

    synchronized Connection onCreateIncomingConnection(BluetoothHeadsetClientCall call) {
        HfpClientConnection connection = connection = mConnections.get(call.getUUID());
        HfpClientConnection connection = mConnections.get(call.getUUID());
        if (connection != null) {
            connection.onAdded();
            updateConferenceableConnections();
            return connection;
        } else {
            Log.e(mTAG, "Call " + call + " ignored: connection does not exist");
@@ -109,11 +108,10 @@ public class HfpClientDeviceBlock {

    synchronized Connection onCreateUnknownConnection(BluetoothHeadsetClientCall call) {
        Uri number = Uri.fromParts(PhoneAccount.SCHEME_TEL, call.getNumber(), null);
        HfpClientConnection connection = connection = mConnections.get(call.getUUID());
        HfpClientConnection connection = mConnections.get(call.getUUID());

        if (connection != null) {
            connection.onAdded();
            updateConferenceableConnections();
            return connection;
        } else {
            Log.e(mTAG, "Call " + call + " ignored: connection does not exist");
@@ -176,7 +174,8 @@ public class HfpClientDeviceBlock {
            Bundle b = new Bundle();
            if (call.getState() == BluetoothHeadsetClientCall.CALL_STATE_DIALING
                    || call.getState() == BluetoothHeadsetClientCall.CALL_STATE_ALERTING
                    || call.getState() == BluetoothHeadsetClientCall.CALL_STATE_ACTIVE) {
                    || call.getState() == BluetoothHeadsetClientCall.CALL_STATE_ACTIVE
                    || call.getState() == BluetoothHeadsetClientCall.CALL_STATE_HELD) {
                // This is an outgoing call. Even if it is an active call we do not have a way of
                // putting that parcelable in a seaprate field.
                b.putParcelable(TelecomManager.EXTRA_OUTGOING_CALL_EXTRAS, call);