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

Commit 89319a95 authored by Yorke Lee's avatar Yorke Lee Committed by Android Git Automerger
Browse files

am e6a8bf80: am 08b51bfe: Merge "Add default dialer checks to Telecom/Telephony" into mnc-dev

* commit 'e6a8bf80':
  Add default dialer checks to Telecom/Telephony
parents 7ea13e85 e6a8bf80
Loading
Loading
Loading
Loading
+6 −5
Original line number Diff line number Diff line
@@ -921,7 +921,7 @@ public class TelecomManager {
    public void silenceRinger() {
        try {
            if (isServiceConnected()) {
                getTelecomService().silenceRinger();
                getTelecomService().silenceRinger(mContext.getOpPackageName());
            }
        } catch (RemoteException e) {
            Log.e(TAG, "Error calling ITelecomService#silenceRinger", e);
@@ -1029,7 +1029,7 @@ public class TelecomManager {
        ITelecomService service = getTelecomService();
        if (service != null) {
            try {
                return service.handlePinMmi(dialString);
                return service.handlePinMmi(dialString, mContext.getOpPackageName());
            } catch (RemoteException e) {
                Log.e(TAG, "Error calling ITelecomService#handlePinMmi", e);
            }
@@ -1053,7 +1053,8 @@ public class TelecomManager {
        ITelecomService service = getTelecomService();
        if (service != null) {
            try {
                return service.handlePinMmiForPhoneAccount(accountHandle, dialString);
                return service.handlePinMmiForPhoneAccount(accountHandle, dialString,
                        mContext.getOpPackageName());
            } catch (RemoteException e) {
                Log.e(TAG, "Error calling ITelecomService#handlePinMmi", e);
            }
@@ -1071,7 +1072,7 @@ public class TelecomManager {
        ITelecomService service = getTelecomService();
        if (service != null && accountHandle != null) {
            try {
                return service.getAdnUriForPhoneAccount(accountHandle);
                return service.getAdnUriForPhoneAccount(accountHandle, mContext.getOpPackageName());
            } catch (RemoteException e) {
                Log.e(TAG, "Error calling ITelecomService#getAdnUriForPhoneAccount", e);
            }
@@ -1089,7 +1090,7 @@ public class TelecomManager {
        ITelecomService service = getTelecomService();
        if (service != null) {
            try {
                service.cancelMissedCallsNotification();
                service.cancelMissedCallsNotification(mContext.getOpPackageName());
            } catch (RemoteException e) {
                Log.e(TAG, "Error calling ITelecomService#cancelMissedCallsNotification", e);
            }
+6 −5
Original line number Diff line number Diff line
@@ -154,7 +154,7 @@ interface ITelecomService {
    /**
     * @see TelecomServiceImpl#silenceRinger
     */
    void silenceRinger();
    void silenceRinger(String callingPackage);

    /**
     * @see TelecomServiceImpl#isInCall
@@ -184,22 +184,23 @@ interface ITelecomService {
    /**
     * @see TelecomServiceImpl#cancelMissedCallsNotification
     */
    void cancelMissedCallsNotification();
    void cancelMissedCallsNotification(String callingPackage);

    /**
     * @see TelecomServiceImpl#handleMmi
     */
    boolean handlePinMmi(String dialString);
    boolean handlePinMmi(String dialString, String callingPackage);

    /**
     * @see TelecomServiceImpl#handleMmi
     */
    boolean handlePinMmiForPhoneAccount(in PhoneAccountHandle accountHandle, String dialString);
    boolean handlePinMmiForPhoneAccount(in PhoneAccountHandle accountHandle, String dialString,
            String callingPackage);

    /**
     * @see TelecomServiceImpl#getAdnUriForPhoneAccount
     */
    Uri getAdnUriForPhoneAccount(in PhoneAccountHandle accountHandle);
    Uri getAdnUriForPhoneAccount(in PhoneAccountHandle accountHandle, String callingPackage);

    /**
     * @see TelecomServiceImpl#isTtySupported
+1 −1
Original line number Diff line number Diff line
@@ -3703,7 +3703,7 @@ public class TelephonyManager {
    @SystemApi
    public void silenceRinger() {
        try {
            getTelecomService().silenceRinger();
            getTelecomService().silenceRinger(mContext.getOpPackageName());
        } catch (RemoteException e) {
            Log.e(TAG, "Error calling ITelecomService#silenceRinger", e);
        }