summaryrefslogtreecommitdiffstats
path: root/src/com/android/settings/ApnPreference.java
diff options
context:
space:
mode:
Diffstat (limited to 'src/com/android/settings/ApnPreference.java')
-rw-r--r--src/com/android/settings/ApnPreference.java9
1 files changed, 8 insertions, 1 deletions
diff --git a/src/com/android/settings/ApnPreference.java b/src/com/android/settings/ApnPreference.java
index 1e29d22..dc697ea 100644
--- a/src/com/android/settings/ApnPreference.java
+++ b/src/com/android/settings/ApnPreference.java
@@ -51,6 +51,7 @@ public class ApnPreference extends Preference implements
private static CompoundButton mCurrentChecked = null;
private boolean mProtectFromCheckedChange = false;
private boolean mSelectable = true;
+ private boolean mApnReadOnly = false;
@Override
public View getView(View convertView, ViewGroup parent) {
@@ -118,7 +119,9 @@ public class ApnPreference extends Preference implements
if (context != null) {
int pos = Integer.parseInt(getKey());
Uri url = ContentUris.withAppendedId(Telephony.Carriers.CONTENT_URI, pos);
- context.startActivity(new Intent(Intent.ACTION_EDIT, url));
+ Intent intent = new Intent(Intent.ACTION_EDIT, url);
+ intent.putExtra("DISABLE_EDITOR", mApnReadOnly);
+ context.startActivity(intent);
}
}
}
@@ -130,4 +133,8 @@ public class ApnPreference extends Preference implements
public boolean getSelectable() {
return mSelectable;
}
+
+ public void setApnReadOnly(boolean apnReadOnly) {
+ mApnReadOnly = apnReadOnly;
+ }
}