App ops: add UI for SMS ops.

Change-Id: I595df9a286ba5389f9e309516dc4a8ab34773277
This commit is contained in:
Dianne Hackborn
2013-02-04 18:27:40 -08:00
parent 82562e2696
commit 9833787387
3 changed files with 46 additions and 5 deletions

View File

@@ -124,6 +124,27 @@ public class AppOpsState {
true }
);
public static final OpsTemplate MESSAGING_TEMPLATE = new OpsTemplate(
new int[] { AppOpsManager.OP_READ_SMS,
AppOpsManager.OP_RECEIVE_SMS,
AppOpsManager.OP_RECEIVE_EMERGECY_SMS,
AppOpsManager.OP_RECEIVE_MMS,
AppOpsManager.OP_RECEIVE_WAP_PUSH,
AppOpsManager.OP_WRITE_SMS,
AppOpsManager.OP_SEND_SMS,
AppOpsManager.OP_READ_ICC_SMS,
AppOpsManager.OP_WRITE_ICC_SMS },
new boolean[] { true,
true,
true,
true,
true,
true,
true,
true,
true }
);
public static final OpsTemplate DEVICE_TEMPLATE = new OpsTemplate(
new int[] { AppOpsManager.OP_VIBRATE,
AppOpsManager.OP_POST_NOTIFICATION,
@@ -134,7 +155,7 @@ public class AppOpsState {
);
public static final OpsTemplate[] ALL_TEMPLATES = new OpsTemplate[] {
LOCATION_TEMPLATE, PERSONAL_TEMPLATE, DEVICE_TEMPLATE
LOCATION_TEMPLATE, PERSONAL_TEMPLATE, MESSAGING_TEMPLATE, DEVICE_TEMPLATE
};
/**

View File

@@ -42,6 +42,7 @@ public class AppOpsSummary extends Fragment {
static AppOpsState.OpsTemplate[] sPageTemplates = new AppOpsState.OpsTemplate[] {
AppOpsState.LOCATION_TEMPLATE,
AppOpsState.PERSONAL_TEMPLATE,
AppOpsState.MESSAGING_TEMPLATE,
AppOpsState.DEVICE_TEMPLATE
};