Merge pull request #2379 from KryptKode/feat/sdk30-changes

SDK 30 changes
This commit is contained in:
Tibor Kaputa 2022-03-13 17:40:54 +01:00 committed by GitHub
commit 4493fde942
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
47 changed files with 91 additions and 20 deletions

View file

@ -626,9 +626,9 @@ class DirectoryAdapter(
return@handleSAFDialog
}
activity.handleSAFDeleteSdk30Dialog(SAFPath){
activity.handleSAFDialogSdk30(SAFPath){
if (!it) {
return@handleSAFDeleteSdk30Dialog
return@handleSAFDialogSdk30
}
var foldersToDelete = ArrayList<File>(selectedKeys.size)

View file

@ -468,9 +468,9 @@ class MediaAdapter(
}
val sdk30SafPath = selectedPaths.firstOrNull { activity.isAccessibleWithSAFSdk30(it) } ?: getFirstSelectedItemPath() ?: return@handleSAFDialog
activity.handleSAFDeleteSdk30Dialog(sdk30SafPath){
activity.handleSAFDialogSdk30(sdk30SafPath){
if (!it) {
return@handleSAFDeleteSdk30Dialog
return@handleSAFDialogSdk30
}
val fileDirItems = ArrayList<FileDirItem>(selectedKeys.size)

View file

@ -7,6 +7,7 @@ import com.simplemobiletools.commons.activities.BaseSimpleActivity
import com.simplemobiletools.commons.dialogs.FilePickerDialog
import com.simplemobiletools.commons.extensions.*
import com.simplemobiletools.commons.helpers.VIEW_TYPE_GRID
import com.simplemobiletools.commons.helpers.isRPlus
import com.simplemobiletools.commons.views.MyGridLayoutManager
import com.simplemobiletools.gallery.pro.R
import com.simplemobiletools.gallery.pro.adapters.DirectoryAdapter
@ -110,6 +111,9 @@ class PickDirectoryDialog(
if (path.trimEnd('/') == sourcePath) {
activity.toast(R.string.source_and_destination_same)
return@DirectoryAdapter
} else if (isRPlus() && path.isBasePath(activity)) {
activity.toast(R.string.copy_to_restricted_folder_message)
return@DirectoryAdapter
} else {
activity.handleLockedFolderOpening(path) { success ->
if (success) {

View file

@ -249,12 +249,16 @@ fun BaseSimpleActivity.tryCopyMoveFilesTo(fileDirItems: ArrayList<FileDirItem>,
PickDirectoryDialog(this, source, true, false) {
val destination = it
handleSAFDialog(source) {
if (it) {
handleSAFDialogSdk30(fileDirItems[0].path){
if (it) {
copyMoveFilesTo(fileDirItems, source.trimEnd('/'), destination, isCopyOperation, true, config.shouldShowHidden, callback)
}
}
}
}
}
}
fun BaseSimpleActivity.tryDeleteFileDirItem(
fileDirItem: FileDirItem, allowDeleteFolder: Boolean = false, deleteFromDatabase: Boolean,

View file

@ -39,6 +39,8 @@
<string name="set_as_default_folder">تعيين كمجلد افتراضي</string>
<string name="unset_as_default_folder">إلغاء التعيين كمجلد افتراضي</string>
<string name="reorder_by_dragging">إعادة ترتيب المجلدات عن طريق السحب</string>
<string name="copy_to_restricted_folder_message">Unable to use this folder.\nThe system does not allow us to copy/move to this folder</string>
<!-- Filter -->
<string name="filter_media">فلترة الوسائط</string>
<string name="images">الصور</string>

View file

@ -33,6 +33,7 @@
<string name="set_as_default_folder">Set as default folder</string>
<string name="unset_as_default_folder">Unset as default folder</string>
<string name="reorder_by_dragging">Reorder folders by dragging</string>
<string name="copy_to_restricted_folder_message">Unable to use this folder.\nThe system does not allow us to copy/move to this folder</string>
<!-- Filter -->
<string name="filter_media">Filter media</string>

View file

@ -33,6 +33,7 @@
<string name="set_as_default_folder">ডিফল্ট ফোল্ডার হিশেবে সেট করুন</string>
<string name="unset_as_default_folder">ডিফল্ট ফোল্ডার হিশেবে আর রাখবেন না</string>
<string name="reorder_by_dragging">Reorder folders by dragging</string>
<string name="copy_to_restricted_folder_message">Unable to use this folder.\nThe system does not allow us to copy/move to this folder</string>
<!-- Filter -->
<string name="filter_media">মিডিয়া ফিল্টার করুন</string>

View file

@ -39,6 +39,8 @@
<string name="set_as_default_folder">Estableix com a carpeta predeterminada</string>
<string name="unset_as_default_folder">Desactiva com a carpeta predeterminada</string>
<string name="reorder_by_dragging">Reordeneu les carpetes arrossegant-les</string>
<string name="copy_to_restricted_folder_message">Unable to use this folder.\nThe system does not allow us to copy/move to this folder</string>
<!-- Filter -->
<string name="filter_media">Filtre multimèdia</string>
<string name="images">Imatges</string>

View file

@ -33,6 +33,8 @@
<string name="set_as_default_folder">Set as default folder</string>
<string name="unset_as_default_folder">Unset as default folder</string>
<string name="reorder_by_dragging">Reorder folders by dragging</string>
<string name="copy_to_restricted_folder_message">Unable to use this folder.\nThe system does not allow us to copy/move to this folder</string>
<!-- Filter -->
<string name="filter_media">Filtr médií</string>
<string name="images">Obrázky</string>

View file

@ -33,6 +33,8 @@
<string name="set_as_default_folder">Vælg som standardmappe</string>
<string name="unset_as_default_folder">Fravælg som standardmappe</string>
<string name="reorder_by_dragging">Omorganiser mapper ved at trække</string>
<string name="copy_to_restricted_folder_message">Unable to use this folder.\nThe system does not allow us to copy/move to this folder</string>
<!-- Filter -->
<string name="filter_media">Filtrer medier</string>
<string name="images">Billeder</string>

View file

@ -39,6 +39,8 @@
<string name="set_as_default_folder">Als Standardordner festlegen</string>
<string name="unset_as_default_folder">Nicht mehr als Standardordner festlegen</string>
<string name="reorder_by_dragging">Neuordnung von Ordnern durch Ziehen</string>
<string name="copy_to_restricted_folder_message">Unable to use this folder.\nThe system does not allow us to copy/move to this folder</string>
<!-- Filter -->
<string name="filter_media">Filter</string>
<string name="images">Bilder</string>

View file

@ -33,6 +33,7 @@
<string name="set_as_default_folder">Ορισμός ως προεπιλεγμένου φακέλου</string>
<string name="unset_as_default_folder">Κατάργηση ως προεπιλεγμένου φακέλου</string>
<string name="reorder_by_dragging">Αναδιάταξη φακέλων με μεταφορά</string>
<string name="copy_to_restricted_folder_message">Unable to use this folder.\nThe system does not allow us to copy/move to this folder</string>
<!-- Filter -->
<string name="filter_media">Φιλτράρισμα πολυμέσων</string>

View file

@ -33,6 +33,7 @@
<string name="set_as_default_folder">Set as default folder</string>
<string name="unset_as_default_folder">Unset as default folder</string>
<string name="reorder_by_dragging">Reorder folders by dragging</string>
<string name="copy_to_restricted_folder_message">Unable to use this folder.\nThe system does not allow us to copy/move to this folder</string>
<!-- Filter -->
<string name="filter_media">Filter media</string>
<string name="images">Bildoj</string>

View file

@ -33,6 +33,7 @@
<string name="set_as_default_folder">Poner como carpeta predeterminada</string>
<string name="unset_as_default_folder">Quitar como carpeta predeterminada</string>
<string name="reorder_by_dragging">Reordenar carpetas arrastrándolas</string>
<string name="copy_to_restricted_folder_message">Unable to use this folder.\nThe system does not allow us to copy/move to this folder</string>
<!-- Filter -->
<string name="filter_media">Filtro de medios</string>

View file

@ -33,6 +33,8 @@
<string name="set_as_default_folder">Set as default folder</string>
<string name="unset_as_default_folder">Unset as default folder</string>
<string name="reorder_by_dragging">Reorder folders by dragging</string>
<string name="copy_to_restricted_folder_message">Unable to use this folder.\nThe system does not allow us to copy/move to this folder</string>
<!-- Filter -->
<string name="filter_media">Filter media</string>
<string name="images">Pildid</string>

View file

@ -33,6 +33,7 @@
<string name="set_as_default_folder">Ezarri lehenetsitako karpeta gisa</string>
<string name="unset_as_default_folder">Kendu karpeta lehenetsitako karpeta gisa</string>
<string name="reorder_by_dragging">Berrordenatu karpetak arrastatuz</string>
<string name="copy_to_restricted_folder_message">Unable to use this folder.\nThe system does not allow us to copy/move to this folder</string>
<!-- Filter -->
<string name="filter_media">Iragazi multimedia</string>

View file

@ -33,6 +33,8 @@
<string name="set_as_default_folder">تنظیم به عنوان شاخهٔ پیش‌گزیده</string>
<string name="unset_as_default_folder">برداشتن تنظیم به عنوان شاخهٔ پیش‌گزیده</string>
<string name="reorder_by_dragging">مرتب‌سازی مجدد شاخه‌ها با کشیدن</string>
<string name="copy_to_restricted_folder_message">Unable to use this folder.\nThe system does not allow us to copy/move to this folder</string>
<!-- Filter -->
<string name="filter_media">پالایش رسانه</string>
<string name="images">تصاویر</string>

View file

@ -39,6 +39,8 @@
<string name="set_as_default_folder">Aseta oletushakemistoksi</string>
<string name="unset_as_default_folder">Älä käytä oletushakemistona</string>
<string name="reorder_by_dragging">Järjestä kansiot uudelleen vetämällä</string>
<string name="copy_to_restricted_folder_message">Unable to use this folder.\nThe system does not allow us to copy/move to this folder</string>
<!-- Filter -->
<string name="filter_media">Suodata media</string>
<string name="images">Kuvat</string>

View file

@ -33,6 +33,8 @@
<string name="set_as_default_folder">Dossier par défaut</string>
<string name="unset_as_default_folder">Oublier le dossier</string>
<string name="reorder_by_dragging">Réordonner par glisser</string>
<string name="copy_to_restricted_folder_message">Unable to use this folder.\nThe system does not allow us to copy/move to this folder</string>
<!-- Filter -->
<string name="filter_media">Filtrer les médias</string>
<string name="images">Images</string>

View file

@ -33,6 +33,7 @@
<string name="set_as_default_folder">Set as default folder</string>
<string name="unset_as_default_folder">Unset as default folder</string>
<string name="reorder_by_dragging">Reorder folders by dragging</string>
<string name="copy_to_restricted_folder_message">Unable to use this folder.\nThe system does not allow us to copy/move to this folder</string>
<!-- Filter -->
<string name="filter_media">Filtrar medios</string>

View file

@ -33,6 +33,7 @@
<string name="set_as_default_folder">Set as default folder</string>
<string name="unset_as_default_folder">Unset as default folder</string>
<string name="reorder_by_dragging">Reorder folders by dragging</string>
<string name="copy_to_restricted_folder_message">Unable to use this folder.\nThe system does not allow us to copy/move to this folder</string>
<!-- Filter -->
<string name="filter_media">Filtriranje medija</string>

View file

@ -39,6 +39,8 @@
<string name="set_as_default_folder">Beállítás alapértelmezett mappaként</string>
<string name="unset_as_default_folder">Eltávolítás mint alapértelmezett mappa</string>
<string name="reorder_by_dragging">Mappák átrendezése húzással</string>
<string name="copy_to_restricted_folder_message">Unable to use this folder.\nThe system does not allow us to copy/move to this folder</string>
<!-- Filter -->
<string name="filter_media">Médiafájlok szűrése</string>
<string name="images">Képek</string>

View file

@ -33,6 +33,8 @@
<string name="set_as_default_folder">Set as default folder</string>
<string name="unset_as_default_folder">Unset as default folder</string>
<string name="reorder_by_dragging">Reorder folders by dragging</string>
<string name="copy_to_restricted_folder_message">Unable to use this folder.\nThe system does not allow us to copy/move to this folder</string>
<!-- Filter -->
<string name="filter_media">Filter media</string>
<string name="images">Gambar</string>

View file

@ -33,6 +33,7 @@
<string name="set_as_default_folder">Imposta come cartella predefinita</string>
<string name="unset_as_default_folder">Non impostare come cartella predefinita</string>
<string name="reorder_by_dragging">Riordina cartelle trascinandole</string>
<string name="copy_to_restricted_folder_message">Unable to use this folder.\nThe system does not allow us to copy/move to this folder</string>
<!-- Filter -->
<string name="filter_media">Filtra i file</string>
<string name="images">Immagini</string>

View file

@ -33,6 +33,7 @@
<string name="set_as_default_folder">デフォルトのフォルダとして設定</string>
<string name="unset_as_default_folder">デフォルトのフォルダから外す</string>
<string name="reorder_by_dragging">Reorder folders by dragging</string>
<string name="copy_to_restricted_folder_message">Unable to use this folder.\nThe system does not allow us to copy/move to this folder</string>
<!-- Filter -->
<string name="filter_media">表示する形式</string>

View file

@ -33,6 +33,7 @@
<string name="set_as_default_folder">Set as default folder</string>
<string name="unset_as_default_folder">Unset as default folder</string>
<string name="reorder_by_dragging">Reorder folders by dragging</string>
<string name="copy_to_restricted_folder_message">Unable to use this folder.\nThe system does not allow us to copy/move to this folder</string>
<!-- Filter -->
<string name="filter_media">필터 설정</string>

View file

@ -33,6 +33,8 @@
<string name="set_as_default_folder">Set as default folder</string>
<string name="unset_as_default_folder">Unset as default folder</string>
<string name="reorder_by_dragging">Reorder folders by dragging</string>
<string name="copy_to_restricted_folder_message">Unable to use this folder.\nThe system does not allow us to copy/move to this folder</string>
<!-- Filter -->
<string name="filter_media">Filtruoti mediją</string>
<string name="images">Paveikslai</string>

View file

@ -33,6 +33,8 @@
<string name="set_as_default_folder">Sett som standardmappe</string>
<string name="unset_as_default_folder">Ikke lenger sett som standardmappe</string>
<string name="reorder_by_dragging">Endre mapperekkefølge ved å dra</string>
<string name="copy_to_restricted_folder_message">Unable to use this folder.\nThe system does not allow us to copy/move to this folder</string>
<!-- Filter -->
<string name="filter_media">Filtrer media</string>
<string name="images">Bilder</string>

View file

@ -33,6 +33,7 @@
<string name="set_as_default_folder">Set as default folder</string>
<string name="unset_as_default_folder">Unset as default folder</string>
<string name="reorder_by_dragging">Reorder folders by dragging</string>
<string name="copy_to_restricted_folder_message">Unable to use this folder.\nThe system does not allow us to copy/move to this folder</string>
<!-- Filter -->
<string name="filter_media">Filter media</string>

View file

@ -35,6 +35,8 @@
<string name="set_as_default_folder">Als standaardmap instellen</string>
<string name="unset_as_default_folder">Standaardmap herstellen</string>
<string name="reorder_by_dragging">Volgorde mappen bepalen met sleepgebaren</string>
<string name="copy_to_restricted_folder_message">Unable to use this folder.\nThe system does not allow us to copy/move to this folder</string>
<!-- Filter -->
<string name="filter_media">Media filteren</string>
<string name="images">Afbeeldingen</string>

View file

@ -39,6 +39,8 @@
<string name="set_as_default_folder">Ustaw jako folder domyślny</string>
<string name="unset_as_default_folder">Anuluj ustawienie folderu domyślnego</string>
<string name="reorder_by_dragging">Przeorganizuj foldery przeciągając</string>
<string name="copy_to_restricted_folder_message">Unable to use this folder.\nThe system does not allow us to copy/move to this folder</string>
<!-- Filter -->
<string name="filter_media">Filtruj multimedia</string>
<string name="images">Obrazy</string>

View file

@ -39,6 +39,8 @@
<string name="set_as_default_folder">Definir como pasta padrão</string>
<string name="unset_as_default_folder">Indefinir como pasta padrão</string>
<string name="reorder_by_dragging">Reordenar as pastas ao arrastar</string>
<string name="copy_to_restricted_folder_message">Unable to use this folder.\nThe system does not allow us to copy/move to this folder</string>
<!-- Filter -->
<string name="filter_media">Filtrar mídia</string>
<string name="images">Imagens</string>

View file

@ -39,6 +39,8 @@
<string name="set_as_default_folder">Utilizar como pasta padrão</string>
<string name="unset_as_default_folder">Deixar de utilizar como pasta padrão</string>
<string name="reorder_by_dragging">Organizar pasta por arrasto</string>
<string name="copy_to_restricted_folder_message">Unable to use this folder.\nThe system does not allow us to copy/move to this folder</string>
<!-- Filter -->
<string name="filter_media">Filtrar multimédia</string>
<string name="images">Imagens</string>

View file

@ -33,6 +33,7 @@
<string name="set_as_default_folder">Setază ca dosar implicit</string>
<string name="unset_as_default_folder">Dezactivează ca dosar implicit</string>
<string name="reorder_by_dragging">Reordonează dosarele prin tragere</string>
<string name="copy_to_restricted_folder_message">Unable to use this folder.\nThe system does not allow us to copy/move to this folder</string>
<!-- Filter -->
<string name="filter_media">Filtrează elementele media</string>

View file

@ -33,6 +33,8 @@
<string name="set_as_default_folder">Установить как папку по умолчанию</string>
<string name="unset_as_default_folder">Отключить как папку по умолчанию</string>
<string name="reorder_by_dragging">Менять порядок папок перетаскиванием</string>
<string name="copy_to_restricted_folder_message">Unable to use this folder.\nThe system does not allow us to copy/move to this folder</string>
<!-- Filter -->
<string name="filter_media">Фильтр медиа</string>
<string name="images">Изображения</string>

View file

@ -33,6 +33,7 @@
<string name="set_as_default_folder">Nastaviť ako predvolený priečinok</string>
<string name="unset_as_default_folder">Odobrať predvolený priečinok</string>
<string name="reorder_by_dragging">Zmeniť poradie priečinkov presunutím</string>
<string name="copy_to_restricted_folder_message">Unable to use this folder.\nThe system does not allow us to copy/move to this folder</string>
<!-- Filter -->
<string name="filter_media">Filter médií</string>

View file

@ -33,6 +33,7 @@
<string name="set_as_default_folder">Set as default folder</string>
<string name="unset_as_default_folder">Unset as default folder</string>
<string name="reorder_by_dragging">Reorder folders by dragging</string>
<string name="copy_to_restricted_folder_message">Unable to use this folder.\nThe system does not allow us to copy/move to this folder</string>
<!-- Filter -->
<string name="filter_media">Filtriranje datotek</string>

View file

@ -33,6 +33,7 @@
<string name="set_as_default_folder">Set as default folder</string>
<string name="unset_as_default_folder">Unset as default folder</string>
<string name="reorder_by_dragging">Reorder folders by dragging</string>
<string name="copy_to_restricted_folder_message">Unable to use this folder.\nThe system does not allow us to copy/move to this folder</string>
<!-- Filter -->
<string name="filter_media">Филтрирај медију</string>

View file

@ -33,6 +33,7 @@
<string name="set_as_default_folder">Set as default folder</string>
<string name="unset_as_default_folder">Unset as default folder</string>
<string name="reorder_by_dragging">Reorder folders by dragging</string>
<string name="copy_to_restricted_folder_message">Unable to use this folder.\nThe system does not allow us to copy/move to this folder</string>
<!-- Filter -->
<string name="filter_media">Filtrera media</string>

View file

@ -39,6 +39,8 @@
<string name="set_as_default_folder">இயல்புநிலை அடைவாக அமை</string>
<string name="unset_as_default_folder">இயல்புநிலை அடைவாக அமைக்காதே</string>
<string name="reorder_by_dragging">பிடித்திழுத்து அடைவுகளை மறுசீரமை</string>
<string name="copy_to_restricted_folder_message">Unable to use this folder.\nThe system does not allow us to copy/move to this folder</string>
<!-- Filter -->
<string name="filter_media">ஊடகத்தை வடிகட்டு</string>
<string name="images">படங்கள்</string>

View file

@ -39,6 +39,8 @@
<string name="set_as_default_folder">Öntanımlı klasör olarak ayarla</string>
<string name="unset_as_default_folder">Öntanımlı klasör ayarını kaldır</string>
<string name="reorder_by_dragging">Sürükleyerek klasörleri yeniden sırala</string>
<string name="copy_to_restricted_folder_message">Unable to use this folder.\nThe system does not allow us to copy/move to this folder</string>
<!-- Filter -->
<string name="filter_media">Medyayı filtrele</string>
<string name="images">Resimler</string>

View file

@ -33,6 +33,7 @@
<string name="set_as_default_folder">Встановити теку за замовчуванням</string>
<string name="unset_as_default_folder">Відмінити встановлення теки за замовчуванням</string>
<string name="reorder_by_dragging">Сортувати папки шляхом переміщення</string>
<string name="copy_to_restricted_folder_message">Unable to use this folder.\nThe system does not allow us to copy/move to this folder</string>
<!-- Filter -->
<string name="filter_media">Фільтр мультимедійних файлів</string>

View file

@ -33,6 +33,7 @@
<string name="set_as_default_folder">Set as default folder</string>
<string name="unset_as_default_folder">Unset as default folder</string>
<string name="reorder_by_dragging">Reorder folders by dragging</string>
<string name="copy_to_restricted_folder_message">Unable to use this folder.\nThe system does not allow us to copy/move to this folder</string>
<!-- Filter -->
<string name="filter_media">Lọc</string>

View file

@ -39,6 +39,7 @@
<string name="set_as_default_folder">设置为默认文件夹</string>
<string name="unset_as_default_folder">取消设置为默认文件夹</string>
<string name="reorder_by_dragging">通过拖动重新排序文件夹</string>
<string name="copy_to_restricted_folder_message">Unable to use this folder.\nThe system does not allow us to copy/move to this folder</string>
<!-- Filter -->
<string name="filter_media">筛选媒体文件</string>
<string name="images">图片</string>

View file

@ -33,6 +33,7 @@
<string name="set_as_default_folder">Set as default folder</string>
<string name="unset_as_default_folder">Unset as default folder</string>
<string name="reorder_by_dragging">Reorder folders by dragging</string>
<string name="copy_to_restricted_folder_message">Unable to use this folder.\nThe system does not allow us to copy/move to this folder</string>
<!-- Filter -->
<string name="filter_media">篩選媒體檔案</string>

View file

@ -33,6 +33,7 @@
<string name="set_as_default_folder">設為預設資料夾</string>
<string name="unset_as_default_folder">取消設為預設資料夾</string>
<string name="reorder_by_dragging">Reorder folders by dragging</string>
<string name="copy_to_restricted_folder_message">Unable to use this folder.\nThe system does not allow us to copy/move to this folder</string>
<!-- Filter -->
<string name="filter_media">篩選媒體檔案</string>

View file

@ -33,6 +33,7 @@
<string name="set_as_default_folder">Set as default folder</string>
<string name="unset_as_default_folder">Unset as default folder</string>
<string name="reorder_by_dragging">Reorder folders by dragging</string>
<string name="copy_to_restricted_folder_message">Unable to use this folder.\nThe system does not allow us to copy/move to this folder</string>
<!-- Filter -->
<string name="filter_media">Filter media</string>