mirror of
https://github.com/fankes/termux-app.git
synced 2025-09-06 10:45:23 +08:00
Changed|Fixed: Add java docs to PermissionUtils and fix permission checking
ContextCompat.checkSelfPermission() may return true for permissions not even requested so it now checked if permissions are even requested in app manifest before checking if they are granted and before asking for permission to be granted. Also some general improvements in code quality, including using ActivityUtils to request non-standard permissions and added support for AppCompatActivity instances to request permissions in addition to Activity instances.
This commit is contained in:
@@ -36,9 +36,11 @@
|
||||
|
||||
|
||||
|
||||
|
||||
<!-- PermissionUtils -->
|
||||
<string name="message_sudo_please_grant_permissions">Please grant permissions on next screen</string>
|
||||
<string name="message_sudo_please_grant_permissions">Please grant requested permission(s)</string>
|
||||
<string name="error_failed_to_request_permissions">Failed to request permissions with request code %1$d: %2$s</string>
|
||||
<string name="error_attempted_to_check_for_permissions_not_requested">Attempted to check for permissions that have not been requested in app manifest: %1$s</string>
|
||||
<string name="error_attempted_to_ask_for_permissions_not_requested">Attempted to ask for permissions that have not been requested in app manifest: %1$s</string>
|
||||
|
||||
|
||||
|
||||
|
Reference in New Issue
Block a user