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

Commit 511a4915 authored by Treehugger Robot's avatar Treehugger Robot Committed by Automerger Merge Worker
Browse files

Merge "Populate recently added sim_mccmnc into ActiveSubscriptionInfo." am: 27ccf3d8

Original change: https://android-review.googlesource.com/c/platform/frameworks/opt/telephony/+/1323712

Change-Id: Ifb9f8a79dd1f4fccb8a8a19d88e46f1405d5c3dd
parents 3ed20882 27ccf3d8
Loading
Loading
Loading
Loading
+8 −0
Original line number Diff line number Diff line
@@ -1841,6 +1841,14 @@ message ActiveSubscriptionInfo {

  /** whether subscription is opportunistic (0 - false, 1 - true, -1 - unknown). */
  optional int32 is_opportunistic = 3;

  /** The mccmnc associated with the subscription. Useful for differentiating
   * between subscriptions with different mccmnc but same carrier_id (eg. Fi
   * Sprint vs. Fi T-Mobile).*/
  optional string sim_mccmnc = 4 /*[
    (datapol.semantic_type) = ST_LOCATION,
    (datapol.location_qualifier) = { precise_location: false }
  ]*/;
};

enum SimState {
+3 −0
Original line number Diff line number Diff line
@@ -786,6 +786,9 @@ public class TelephonyMetrics {
            activeSubscriptionInfo.slotIndex = phoneId;
            activeSubscriptionInfo.isOpportunistic = info.isOpportunistic() ? 1 : 0;
            activeSubscriptionInfo.carrierId = info.getCarrierId();
            if (info.getMccString() != null && info.getMncString() != null) {
                activeSubscriptionInfo.simMccmnc = info.getMccString() + info.getMncString();
            }
            if (!MessageNano.messageNanoEquals(
                    mLastActiveSubscriptionInfos.get(phoneId), activeSubscriptionInfo)) {
                addTelephonyEvent(new TelephonyEventBuilder(phoneId)