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

Commit edb2308e authored by Narayan Kamath's avatar Narayan Kamath Committed by Android Git Automerger
Browse files

am f2feb8c1: am 7ff76d63: Add a hidden telephony API for querying SIM derived locales.

* commit 'f2feb8c1':
  Add a hidden telephony API for querying SIM derived locales.
parents 0cc1baf0 f2feb8c1
Loading
Loading
Loading
Loading
+14 −0
Original line number Diff line number Diff line
@@ -4580,4 +4580,18 @@ public class TelephonyManager {
        } catch (RemoteException e) {
        }
    }


    /** @hide */
    public String getLocaleFromDefaultSim() {
        try {
            final ITelephony telephony = getITelephony();
            if (telephony != null) {
                return telephony.getLocaleFromDefaultSim();
            }
        } catch (RemoteException ex) {
        }

        return null;
    }
}
+8 −0
Original line number Diff line number Diff line
@@ -945,4 +945,12 @@ interface ITelephony {
    int getSubIdForPhoneAccount(in PhoneAccount phoneAccount);

    void factoryReset(int subId);

    /**
     * An estimate of the users's current locale based on the default SIM.
     *
     * The returned string will be a well formed BCP-47 language tag, or {@code null}
     * if no locale could be derived.
     */
    String getLocaleFromDefaultSim();
}