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

Commit 6c244cdc authored by Jack Yu's avatar Jack Yu Committed by Gerrit Code Review
Browse files

Merge "Added missed incoming call SMS support"

parents 3083cf5e 583b81ec
Loading
Loading
Loading
Loading
+12 −1
Original line number Diff line number Diff line
@@ -311,7 +311,18 @@ public final class CallLogManager extends CallsManagerListenerBase {
     */
    void logCall(Call call, int callLogType,
        @Nullable LogCallCompletedListener logCallCompletedListener, CallFilteringResult result) {
        final long creationTime = call.getCreationTimeMillis();
        long creationTime;

        if (call.getConnectTimeMillis() != 0
                && call.getConnectTimeMillis() < call.getCreationTimeMillis()) {
            // If connected time is available, use connected time. The connected time might be
            // earlier than created time since it might come from carrier sent special SMS to
            // notifier user earlier missed call.
            creationTime = call.getConnectTimeMillis();
        } else {
            creationTime = call.getCreationTimeMillis();
        }

        final long age = call.getAgeMillis();

        final String logNumber = getLogNumber(call);
+5 −1
Original line number Diff line number Diff line
@@ -43,7 +43,6 @@ import android.telecom.PhoneAccountHandle;
import android.telecom.StatusHints;
import android.telecom.TelecomManager;
import android.telecom.VideoProfile;
import android.telephony.TelephonyManager;

import com.android.internal.annotations.VisibleForTesting;
import com.android.internal.telecom.IConnectionService;
@@ -1918,6 +1917,11 @@ public class ConnectionServiceWrapper extends ServiceBinder implements
            // A connection that begins in the DISCONNECTED state is an indication of
            // failure to connect; we handle all failures uniformly
            Call foundCall = mCallIdMapper.getCall(callId);

            if (connection.getConnectTimeMillis() != 0) {
                foundCall.setConnectTimeMillis(connection.getConnectTimeMillis());
            }

            if (foundCall != null) {
                // The post-dial digits are created when the call is first created.  Normally
                // the ConnectionService is responsible for stripping them from the address, but