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

Commit 9462b4cb authored by Linux Build Service Account's avatar Linux Build Service Account Committed by Gerrit - the friendly Code Review server
Browse files

Merge "Settings: The APN cannot be edited after tapping right of APN"

parents 853a5240 244d10a1
Loading
Loading
Loading
Loading
+4 −0
Original line number Diff line number Diff line
@@ -135,4 +135,8 @@ public class ApnPreference extends Preference implements
    public void setApnReadOnly(boolean apnReadOnly) {
        mApnReadOnly = apnReadOnly;
    }

    public boolean getApnReadOnly() {
        return mApnReadOnly;
    }
}
+5 −1
Original line number Diff line number Diff line
@@ -561,7 +561,11 @@ public class ApnSettings extends RestrictedSettingsFragment implements
    public boolean onPreferenceTreeClick(Preference preference) {
        int pos = Integer.parseInt(preference.getKey());
        Uri url = ContentUris.withAppendedId(Telephony.Carriers.CONTENT_URI, pos);
        startActivity(new Intent(Intent.ACTION_EDIT, url));
        Intent intent = new Intent(Intent.ACTION_EDIT, url);
        if (preference instanceof ApnPreference) {
            intent.putExtra("DISABLE_EDITOR", ((ApnPreference) preference).getApnReadOnly());
        }
        startActivity(intent);
        return true;
    }