Skip to content

Instantly share code, notes, and snippets.

@deepak140596
Created August 28, 2019 13:48
Show Gist options
  • Save deepak140596/85df4ec4776fbd38033d815aed20382e to your computer and use it in GitHub Desktop.
Save deepak140596/85df4ec4776fbd38033d815aed20382e to your computer and use it in GitHub Desktop.
// Your IDE likely can auto-import these classes, but there are several
// different implementations so we list them here to disambiguate
import android.Manifest
import android.util.Size
import android.graphics.Matrix
import java.util.concurrent.TimeUnit
// This is an arbitrary number we are using to keep tab of the permission
// request. Where an app has multiple context for requesting permission,
// this can help differentiate the different contexts
private const val REQUEST_CODE_PERMISSIONS = 10
// This is an array of all the permission specified in the manifest
private val REQUIRED_PERMISSIONS = arrayOf(Manifest.permission.CAMERA)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment