public final class PermissMeConfig extends Object
Modifier and Type | Method and Description |
---|---|
static void |
config(int defaultPermissionDeniedMessage,
int defaultCtaButtonString,
int textColorRes,
int snackbarBgColorRes)
Config method to setup the strings and color resources pertaining to
PermissMe |
int |
getDefaultCtaButtonMsg()
The string on the cta button of the
Snackbar that will take the user to
the app settings to toggle their permissions |
int |
getDefaultPermissionDeniedMsg()
The message that will show when a permission is auto-denied through the user checking "do not ask again" on
the permission dialog
|
static PermissMeConfig |
getInstance() |
int |
getSnackBarBgColorRes()
The resource id of the color that will be set as the background color of the permission auto-denied
Snackbar |
int |
getTextColorRes()
The resource id of the color that will be set as the CTA button color on the permission denied
Snackbar |
public static PermissMeConfig getInstance()
public static void config(@StringRes int defaultPermissionDeniedMessage, @StringRes int defaultCtaButtonString, @ColorRes int textColorRes, @ColorRes int snackbarBgColorRes)
PermissMe
defaultPermissionDeniedMessage
- The res id for the message that will show on the auto-denied permission snackbar; will use default if this
is 0defaultCtaButtonString
- The res id for the cta string that will show on the auto-denied permission snackbar; will use default if
this is 0textColorRes
- The resource id of the color that will be the cta color on the auto-denied permission snackbar; will use
default if this is 0snackbarBgColorRes
- The resource id of the color that will be the bg color on the auto-denied permission snackbar; will use
default if this is 0@StringRes public int getDefaultPermissionDeniedMsg()
@StringRes public int getDefaultCtaButtonMsg()
Snackbar
that will take the user to
the app settings to toggle their permissions@ColorRes public int getSnackBarBgColorRes()
Snackbar