mirror of
https://github.com/FossifyOrg/Gallery.git
synced 2024-11-30 00:17:58 +01:00
commit
401569043a
1 changed files with 3 additions and 1 deletions
|
@ -171,7 +171,9 @@ class Utils {
|
||||||
}
|
}
|
||||||
|
|
||||||
fun isShowingWritePermissions(activity: Activity, file: File): Boolean {
|
fun isShowingWritePermissions(activity: Activity, file: File): Boolean {
|
||||||
return if (needsStupidWritePermissions(activity, file.absolutePath) && !file.canWrite() && Config.newInstance(activity).treeUri.isEmpty()) {
|
return if ((needsStupidWritePermissions(activity, file.absolutePath) &&
|
||||||
|
!file.canWrite()) ||
|
||||||
|
Config.newInstance(activity).treeUri.isEmpty()) {
|
||||||
WritePermissionDialog(activity, object : WritePermissionDialog.OnWritePermissionListener {
|
WritePermissionDialog(activity, object : WritePermissionDialog.OnWritePermissionListener {
|
||||||
override fun onConfirmed() {
|
override fun onConfirmed() {
|
||||||
val intent = Intent(Intent.ACTION_OPEN_DOCUMENT_TREE)
|
val intent = Intent(Intent.ACTION_OPEN_DOCUMENT_TREE)
|
||||||
|
|
Loading…
Reference in a new issue