Merge "Add read/write external storage app ops" into mnc-dev
This commit is contained in:
@@ -3879,6 +3879,7 @@ package android.app {
|
|||||||
field public static final java.lang.String OPSTR_READ_CALL_LOG = "android:read_call_log";
|
field public static final java.lang.String OPSTR_READ_CALL_LOG = "android:read_call_log";
|
||||||
field public static final java.lang.String OPSTR_READ_CELL_BROADCASTS = "android:read_cell_broadcasts";
|
field public static final java.lang.String OPSTR_READ_CELL_BROADCASTS = "android:read_cell_broadcasts";
|
||||||
field public static final java.lang.String OPSTR_READ_CONTACTS = "android:read_contacts";
|
field public static final java.lang.String OPSTR_READ_CONTACTS = "android:read_contacts";
|
||||||
|
field public static final java.lang.String OPSTR_READ_EXTERNAL_STORAGE = "android:read_external_storage";
|
||||||
field public static final java.lang.String OPSTR_READ_PHONE_STATE = "android:read_phone_state";
|
field public static final java.lang.String OPSTR_READ_PHONE_STATE = "android:read_phone_state";
|
||||||
field public static final java.lang.String OPSTR_READ_SMS = "android:read_sms";
|
field public static final java.lang.String OPSTR_READ_SMS = "android:read_sms";
|
||||||
field public static final java.lang.String OPSTR_RECEIVE_MMS = "android:receive_mms";
|
field public static final java.lang.String OPSTR_RECEIVE_MMS = "android:receive_mms";
|
||||||
@@ -3891,6 +3892,7 @@ package android.app {
|
|||||||
field public static final java.lang.String OPSTR_WRITE_CALENDAR = "android:write_calendar";
|
field public static final java.lang.String OPSTR_WRITE_CALENDAR = "android:write_calendar";
|
||||||
field public static final java.lang.String OPSTR_WRITE_CALL_LOG = "android:write_call_log";
|
field public static final java.lang.String OPSTR_WRITE_CALL_LOG = "android:write_call_log";
|
||||||
field public static final java.lang.String OPSTR_WRITE_CONTACTS = "android:write_contacts";
|
field public static final java.lang.String OPSTR_WRITE_CONTACTS = "android:write_contacts";
|
||||||
|
field public static final java.lang.String OPSTR_WRITE_EXTERNAL_STORAGE = "android:write_external_storage";
|
||||||
}
|
}
|
||||||
|
|
||||||
public static abstract interface AppOpsManager.OnOpChangedListener {
|
public static abstract interface AppOpsManager.OnOpChangedListener {
|
||||||
|
|||||||
@@ -3989,6 +3989,7 @@ package android.app {
|
|||||||
field public static final java.lang.String OPSTR_READ_CALL_LOG = "android:read_call_log";
|
field public static final java.lang.String OPSTR_READ_CALL_LOG = "android:read_call_log";
|
||||||
field public static final java.lang.String OPSTR_READ_CELL_BROADCASTS = "android:read_cell_broadcasts";
|
field public static final java.lang.String OPSTR_READ_CELL_BROADCASTS = "android:read_cell_broadcasts";
|
||||||
field public static final java.lang.String OPSTR_READ_CONTACTS = "android:read_contacts";
|
field public static final java.lang.String OPSTR_READ_CONTACTS = "android:read_contacts";
|
||||||
|
field public static final java.lang.String OPSTR_READ_EXTERNAL_STORAGE = "android:read_external_storage";
|
||||||
field public static final java.lang.String OPSTR_READ_PHONE_STATE = "android:read_phone_state";
|
field public static final java.lang.String OPSTR_READ_PHONE_STATE = "android:read_phone_state";
|
||||||
field public static final java.lang.String OPSTR_READ_SMS = "android:read_sms";
|
field public static final java.lang.String OPSTR_READ_SMS = "android:read_sms";
|
||||||
field public static final java.lang.String OPSTR_RECEIVE_MMS = "android:receive_mms";
|
field public static final java.lang.String OPSTR_RECEIVE_MMS = "android:receive_mms";
|
||||||
@@ -4001,6 +4002,7 @@ package android.app {
|
|||||||
field public static final java.lang.String OPSTR_WRITE_CALENDAR = "android:write_calendar";
|
field public static final java.lang.String OPSTR_WRITE_CALENDAR = "android:write_calendar";
|
||||||
field public static final java.lang.String OPSTR_WRITE_CALL_LOG = "android:write_call_log";
|
field public static final java.lang.String OPSTR_WRITE_CALL_LOG = "android:write_call_log";
|
||||||
field public static final java.lang.String OPSTR_WRITE_CONTACTS = "android:write_contacts";
|
field public static final java.lang.String OPSTR_WRITE_CONTACTS = "android:write_contacts";
|
||||||
|
field public static final java.lang.String OPSTR_WRITE_EXTERNAL_STORAGE = "android:write_external_storage";
|
||||||
}
|
}
|
||||||
|
|
||||||
public static abstract interface AppOpsManager.OnOpChangedListener {
|
public static abstract interface AppOpsManager.OnOpChangedListener {
|
||||||
|
|||||||
@@ -229,8 +229,12 @@ public class AppOpsManager {
|
|||||||
public static final int OP_READ_CELL_BROADCASTS = 57;
|
public static final int OP_READ_CELL_BROADCASTS = 57;
|
||||||
/** @hide Inject mock location into the system. */
|
/** @hide Inject mock location into the system. */
|
||||||
public static final int OP_MOCK_LOCATION = 58;
|
public static final int OP_MOCK_LOCATION = 58;
|
||||||
|
/** @hide Read external storage. */
|
||||||
|
public static final int OP_READ_EXTERNAL_STORAGE = 59;
|
||||||
|
/** @hide Write external storage. */
|
||||||
|
public static final int OP_WRITE_EXTERNAL_STORAGE = 60;
|
||||||
/** @hide */
|
/** @hide */
|
||||||
public static final int _NUM_OP = 59;
|
public static final int _NUM_OP = 61;
|
||||||
|
|
||||||
/** Access to coarse location information. */
|
/** Access to coarse location information. */
|
||||||
public static final String OPSTR_COARSE_LOCATION = "android:coarse_location";
|
public static final String OPSTR_COARSE_LOCATION = "android:coarse_location";
|
||||||
@@ -313,6 +317,12 @@ public class AppOpsManager {
|
|||||||
/** Inject mock location into the system. */
|
/** Inject mock location into the system. */
|
||||||
public static final String OPSTR_MOCK_LOCATION
|
public static final String OPSTR_MOCK_LOCATION
|
||||||
= "android:mock_location";
|
= "android:mock_location";
|
||||||
|
/** Read external storage. */
|
||||||
|
public static final String OPSTR_READ_EXTERNAL_STORAGE
|
||||||
|
= "android:read_external_storage";
|
||||||
|
/** Write external storage. */
|
||||||
|
public static final String OPSTR_WRITE_EXTERNAL_STORAGE
|
||||||
|
= "android:write_external_storage";
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* This maps each operation to the operation that serves as the
|
* This maps each operation to the operation that serves as the
|
||||||
@@ -381,7 +391,9 @@ public class AppOpsManager {
|
|||||||
OP_USE_FINGERPRINT,
|
OP_USE_FINGERPRINT,
|
||||||
OP_BODY_SENSORS,
|
OP_BODY_SENSORS,
|
||||||
OP_READ_CELL_BROADCASTS,
|
OP_READ_CELL_BROADCASTS,
|
||||||
OP_MOCK_LOCATION
|
OP_MOCK_LOCATION,
|
||||||
|
OP_READ_EXTERNAL_STORAGE,
|
||||||
|
OP_WRITE_EXTERNAL_STORAGE
|
||||||
};
|
};
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -447,7 +459,9 @@ public class AppOpsManager {
|
|||||||
OPSTR_USE_FINGERPRINT,
|
OPSTR_USE_FINGERPRINT,
|
||||||
OPSTR_BODY_SENSORS,
|
OPSTR_BODY_SENSORS,
|
||||||
OPSTR_READ_CELL_BROADCASTS,
|
OPSTR_READ_CELL_BROADCASTS,
|
||||||
OPSTR_MOCK_LOCATION
|
OPSTR_MOCK_LOCATION,
|
||||||
|
OPSTR_READ_EXTERNAL_STORAGE,
|
||||||
|
OPSTR_WRITE_EXTERNAL_STORAGE
|
||||||
};
|
};
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -513,7 +527,9 @@ public class AppOpsManager {
|
|||||||
"USE_FINGERPRINT",
|
"USE_FINGERPRINT",
|
||||||
"BODY_SENSORS",
|
"BODY_SENSORS",
|
||||||
"READ_CELL_BROADCASTS",
|
"READ_CELL_BROADCASTS",
|
||||||
"MOCK_LOCATION"
|
"MOCK_LOCATION",
|
||||||
|
"OPSTR_READ_EXTERNAL_STORAGE",
|
||||||
|
"OPSTR_WRITE_EXTERNAL_STORAGE",
|
||||||
};
|
};
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -579,7 +595,9 @@ public class AppOpsManager {
|
|||||||
Manifest.permission.USE_FINGERPRINT,
|
Manifest.permission.USE_FINGERPRINT,
|
||||||
Manifest.permission.BODY_SENSORS,
|
Manifest.permission.BODY_SENSORS,
|
||||||
Manifest.permission.READ_CELL_BROADCASTS,
|
Manifest.permission.READ_CELL_BROADCASTS,
|
||||||
null
|
null,
|
||||||
|
Manifest.permission.READ_EXTERNAL_STORAGE,
|
||||||
|
Manifest.permission.WRITE_EXTERNAL_STORAGE,
|
||||||
};
|
};
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -646,7 +664,9 @@ public class AppOpsManager {
|
|||||||
null, // USE_FINGERPRINT
|
null, // USE_FINGERPRINT
|
||||||
null, // BODY_SENSORS
|
null, // BODY_SENSORS
|
||||||
null, // READ_CELL_BROADCASTS
|
null, // READ_CELL_BROADCASTS
|
||||||
null // MOCK_LOCATION
|
null, // MOCK_LOCATION
|
||||||
|
null, // READ_EXTERNAL_STORAGE
|
||||||
|
null // WRITE_EXTERNAL_STORAGE
|
||||||
};
|
};
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -712,7 +732,9 @@ public class AppOpsManager {
|
|||||||
false, // USE_FINGERPRINT
|
false, // USE_FINGERPRINT
|
||||||
false, // BODY_SENSORS
|
false, // BODY_SENSORS
|
||||||
false, // READ_CELL_BROADCASTS
|
false, // READ_CELL_BROADCASTS
|
||||||
false // MOCK_LOCATION
|
false, // MOCK_LOCATION
|
||||||
|
false, // READ_EXTERNAL_STORAGE
|
||||||
|
false // WRITE_EXTERNAL_STORAGE
|
||||||
};
|
};
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -777,7 +799,9 @@ public class AppOpsManager {
|
|||||||
AppOpsManager.MODE_ALLOWED,
|
AppOpsManager.MODE_ALLOWED,
|
||||||
AppOpsManager.MODE_ALLOWED,
|
AppOpsManager.MODE_ALLOWED,
|
||||||
AppOpsManager.MODE_ALLOWED,
|
AppOpsManager.MODE_ALLOWED,
|
||||||
AppOpsManager.MODE_ERRORED // OP_MOCK_LOCATION
|
AppOpsManager.MODE_ERRORED, // OP_MOCK_LOCATION
|
||||||
|
AppOpsManager.MODE_ALLOWED,
|
||||||
|
AppOpsManager.MODE_ALLOWED
|
||||||
};
|
};
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -846,6 +870,8 @@ public class AppOpsManager {
|
|||||||
false,
|
false,
|
||||||
false,
|
false,
|
||||||
false,
|
false,
|
||||||
|
false,
|
||||||
|
false,
|
||||||
false
|
false
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user