This site permanently moved to
https://droidscript.github.io
. Please update links accordingly.
You are being forwarded automatically in 3...
[stay here]
Back
RemovePermission
Hello World
Removes a granted permission
See Also:
GetPermission
CheckPermission
ListPermissions
.
app.RemovePermission(
uri
)
Example
click to expand contents
function
OnStart
(
)
{
var
lay
=
app
.
CreateLayout
(
"linear"
,
"VCenter,FillXY"
)
spn
=
app
.
AddSpinner
(
lay
,
app
.
ListPermissions
(
)
,
.5
)
;
btn
=
app
.
AddButton
(
lay
,
"Remove"
,
0.3
)
btn
.
SetOnTouch
(
btn_OnTouch
)
app
.
AddLayout
(
lay
)
}
function
btn_OnTouch
(
)
{
var
perm
=
spn
.
GetText
(
)
;
if
(
perm
)
{
app
.
RemovePermission
(
perm
)
;
app
.
ShowPopup
(
"Removed "
+
perm
)
;
}
}
Copy All
Run
String:
URI encoded
loading