Lines Matching refs:appOpsManager
23 import android.app.AppOpsManager;
24 import android.app.AppOpsManager.PackageOps;
218 private static final int[] MOCK_LOCATION_APP_OPS = new int[] {AppOpsManager.OP_MOCK_LOCATION};
847 AppOpsManager appOpsManager = (AppOpsManager) getSystemService(Context.APP_OPS_SERVICE);
850 List<PackageOps> packageOps = appOpsManager.getPackagesForOps(MOCK_LOCATION_APP_OPS);
854 if (packageOp.getOps().get(0).getMode() != AppOpsManager.MODE_ERRORED) {
859 appOpsManager.setMode(AppOpsManager.OP_MOCK_LOCATION, ai.uid,
860 oldMockLocationApp, AppOpsManager.MODE_ERRORED);
873 appOpsManager.setMode(AppOpsManager.OP_MOCK_LOCATION, ai.uid,
874 mMockLocationApp, AppOpsManager.MODE_ALLOWED);
914 AppOpsManager appOpsManager = (AppOpsManager) getSystemService(Context.APP_OPS_SERVICE);
916 List<PackageOps> packageOps = appOpsManager.getPackagesForOps(MOCK_LOCATION_APP_OPS);
919 if (packageOp.getOps().get(0).getMode() == AppOpsManager.MODE_ALLOWED) {