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

Commit 76299d96 authored by Mengjun Leng's avatar Mengjun Leng
Browse files

Support CDMA call duration reset in telephony connection

Support original connection call time reset for CDMA call.

Change-Id: Ibd10de7ad8baacbb1c225562ba3f01eb0de28b1a
parent 182b81be
Loading
Loading
Loading
Loading
+12 −0
Original line number Diff line number Diff line
@@ -1052,6 +1052,18 @@ public abstract class Connection {
        return mPhoneType;
    }

    /**
     * Reset the Connection time and Duration
     */
    public void resetConnectionTime() {
        if (mPhoneType == PhoneConstants.PHONE_TYPE_CDMA_LTE ||
                mPhoneType == PhoneConstants.PHONE_TYPE_CDMA) {
            mConnectTime = System.currentTimeMillis();
            mConnectTimeReal = SystemClock.elapsedRealtime();
            mDuration = 0;
        }
    }

    /**
     * Build a human representation of a connection instance, suitable for debugging.
     * Don't log personal stuff unless in debug mode.