Home
last modified time | relevance | path

Searched refs:grantResults (Results 1 – 17 of 17) sorted by relevance

/development/samples/browseable/RuntimePermissions/src/com.example.android.system.runtimepermissions/
DPermissionUtil.java34 public static boolean verifyPermissions(int[] grantResults) { in verifyPermissions() argument
36 if(grantResults.length < 1){ in verifyPermissions()
41 for (int result : grantResults) { in verifyPermissions()
DMainActivity.java265 @NonNull int[] grantResults) { in onRequestPermissionsResult() argument
273 if (grantResults.length == 1 && grantResults[0] == PackageManager.PERMISSION_GRANTED) { in onRequestPermissionsResult()
291 if (PermissionUtil.verifyPermissions(grantResults)) { in onRequestPermissionsResult()
304 super.onRequestPermissionsResult(requestCode, permissions, grantResults); in onRequestPermissionsResult()
/development/samples/browseable/WatchFace/Wearable/src/com.example.android.wearable.watchface/
DCalendarWatchFacePermissionActivity.java45 int requestCode, @NonNull String[] permissions, @NonNull int[] grantResults) { in onRequestPermissionsResult() argument
50 if ((grantResults.length == 1) in onRequestPermissionsResult()
51 && (grantResults[0] == PackageManager.PERMISSION_GRANTED)) { in onRequestPermissionsResult()
/development/samples/browseable/RuntimePermissionsBasic/src/com.example.android.basicpermissions/
DMainActivity.java80 int[] grantResults) { in onRequestPermissionsResult() argument
84 if (grantResults.length == 1 && grantResults[0] == PackageManager.PERMISSION_GRANTED) { in onRequestPermissionsResult()
/development/samples/browseable/RuntimePermissionsWear/Application/src/com.example.android.wearable.runtimepermissions/
DPhonePermissionRequestActivity.java84 int requestCode, @NonNull String[] permissions, @NonNull int[] grantResults) { in onRequestPermissionsResult() argument
87 + ", Results: " + grantResults; in onRequestPermissionsResult()
/development/samples/browseable/PermissionRequest/src/com.example.android.permissionrequest/
DPermissionRequestFragment.java111 @NonNull int[] grantResults) { in onRequestPermissionsResult() argument
115 if (permissions.length != 1 || grantResults.length != 1 || in onRequestPermissionsResult()
116 grantResults[0] != PackageManager.PERMISSION_GRANTED) { in onRequestPermissionsResult()
122 super.onRequestPermissionsResult(requestCode, permissions, grantResults); in onRequestPermissionsResult()
/development/samples/ApiDemos/src/com/example/android/apis/content/
DMediaContentObserver.java106 int[] grantResults) { in onRequestPermissionsResult() argument
108 if (grantResults.length > 0 && grantResults[0] == PackageManager.PERMISSION_GRANTED) { in onRequestPermissionsResult()
/development/samples/browseable/AgendaData/Application/src/com.example.android.wearable.agendadata/
DMainActivity.java304 int requestCode, @NonNull String[] permissions, @NonNull int[] grantResults) { in onRequestPermissionsResult() argument
316 if ((grantResults.length == 2) in onRequestPermissionsResult()
317 && (grantResults[0] == PackageManager.PERMISSION_GRANTED) in onRequestPermissionsResult()
318 && (grantResults[1] == PackageManager.PERMISSION_GRANTED)) { in onRequestPermissionsResult()
332 super.onRequestPermissionsResult(requestCode, permissions, grantResults); in onRequestPermissionsResult()
/development/samples/browseable/XYZTouristAttractions/Application/src/com.example.android.xyztouristattractions/ui/
DAttractionListActivity.java119 int requestCode, String[] permissions, int[] grantResults) { in onRequestPermissionsResult() argument
122 if (grantResults[0] == PackageManager.PERMISSION_GRANTED) { in onRequestPermissionsResult()
/development/samples/browseable/WearSpeakerSample/src/com.example.android.wearable.speaker/
DMainActivity.java199 String permissions[], int[] grantResults) { in onRequestPermissionsResult() argument
201 if (grantResults.length > 0 && grantResults[0] == PackageManager.PERMISSION_GRANTED) { in onRequestPermissionsResult()
/development/samples/browseable/RuntimePermissionsWear/Wearable/src/com.example.android.wearable.runtimepermissions/
DMainWearActivity.java319 int requestCode, @NonNull String[] permissions, @NonNull int[] grantResults) { in onRequestPermissionsResult() argument
322 + ", Results: " + grantResults; in onRequestPermissionsResult()
328 if ((grantResults.length == 1) in onRequestPermissionsResult()
329 && (grantResults[0] == PackageManager.PERMISSION_GRANTED)) { in onRequestPermissionsResult()
/development/samples/browseable/SpeedTracker/Wearable/src/com.example.android.wearable.speedtracker/
DWearableMainActivity.java464 int requestCode, @NonNull String[] permissions, @NonNull int[] grantResults) { in onRequestPermissionsResult() argument
472 if ((grantResults.length == 1) in onRequestPermissionsResult()
473 && (grantResults[0] == PackageManager.PERMISSION_GRANTED)) { in onRequestPermissionsResult()
/development/samples/WiFiDirectDemo/src/com/example/android/wifidirect/
DWiFiDirectActivity.java75 int[] grantResults) { in onRequestPermissionsResult() argument
78 if (grantResults[0] != PackageManager.PERMISSION_GRANTED) { in onRequestPermissionsResult()
/development/samples/browseable/Camera2Video/src/com.example.android.camera2video/
DCamera2VideoFragment.java383 @NonNull int[] grantResults) { in onRequestPermissionsResult() argument
386 if (grantResults.length == VIDEO_PERMISSIONS.length) { in onRequestPermissionsResult()
387 for (int result : grantResults) { in onRequestPermissionsResult()
399 super.onRequestPermissionsResult(requestCode, permissions, grantResults); in onRequestPermissionsResult()
/development/samples/WiFiDirectServiceDiscovery/src/com/example/android/wifidirect/discovery/
DWiFiServiceDiscoveryActivity.java92 int[] grantResults) { in onRequestPermissionsResult() argument
95 if (grantResults[0] != PackageManager.PERMISSION_GRANTED) { in onRequestPermissionsResult()
/development/samples/browseable/HdrViewfinder/src/com.example.android.hdrviewfinder/
DHdrViewfinderActivity.java335 @NonNull int[] grantResults) { in onRequestPermissionsResult() argument
338 if (grantResults.length <= 0) { in onRequestPermissionsResult()
342 } else if (grantResults[0] == PackageManager.PERMISSION_GRANTED) { in onRequestPermissionsResult()
/development/samples/browseable/Camera2Basic/src/com.example.android.camera2basic/
DCamera2BasicFragment.java474 @NonNull int[] grantResults) { in onRequestPermissionsResult() argument
476 if (grantResults.length != 1 || grantResults[0] != PackageManager.PERMISSION_GRANTED) { in onRequestPermissionsResult()
481 super.onRequestPermissionsResult(requestCode, permissions, grantResults); in onRequestPermissionsResult()