From 2e872db837974a66297d5e7ed17679b582ede40d Mon Sep 17 00:00:00 2001 From: Agnieszka C <85929121+Aga-C@users.noreply.github.com> Date: Sun, 20 Feb 2022 11:07:13 +0100 Subject: [PATCH 1/5] Added exporting and importing all notes for Android 10+ --- .../notes/pro/activities/MainActivity.kt | 112 ++++++++++++++++-- .../notes/pro/helpers/Constants.kt | 1 + .../notes/pro/helpers/NotesExporter.kt | 52 ++++++++ .../notes/pro/helpers/NotesImporter.kt | 64 ++++++++++ app/src/main/res/menu/menu.xml | 8 ++ app/src/main/res/values-ar/strings.xml | 3 +- app/src/main/res/values-az/strings.xml | 3 +- app/src/main/res/values-ca/strings.xml | 5 +- app/src/main/res/values-cs/strings.xml | 3 +- app/src/main/res/values-cy/strings.xml | 3 +- app/src/main/res/values-da/strings.xml | 3 +- app/src/main/res/values-de/strings.xml | 5 +- app/src/main/res/values-el/strings.xml | 3 +- app/src/main/res/values-eo/strings.xml | 3 +- app/src/main/res/values-es/strings.xml | 3 +- app/src/main/res/values-et/strings.xml | 5 +- app/src/main/res/values-fa/strings.xml | 3 +- app/src/main/res/values-fi/strings.xml | 3 +- app/src/main/res/values-fr/strings.xml | 5 +- app/src/main/res/values-gl/strings.xml | 3 +- app/src/main/res/values-hr/strings.xml | 5 +- app/src/main/res/values-hu/strings.xml | 3 +- app/src/main/res/values-id/strings.xml | 3 +- app/src/main/res/values-it/strings.xml | 5 +- app/src/main/res/values-ja/strings.xml | 3 +- app/src/main/res/values-lt/strings.xml | 3 +- app/src/main/res/values-nb-rNO/strings.xml | 3 +- app/src/main/res/values-nl/strings.xml | 3 +- app/src/main/res/values-pl/strings.xml | 3 +- app/src/main/res/values-pt-rBR/strings.xml | 5 +- app/src/main/res/values-pt/strings.xml | 5 +- app/src/main/res/values-ru/strings.xml | 3 +- app/src/main/res/values-sk/strings.xml | 3 +- app/src/main/res/values-sv/strings.xml | 5 +- app/src/main/res/values-tr/strings.xml | 5 +- app/src/main/res/values-uk/strings.xml | 3 +- app/src/main/res/values-zh-rCN/strings.xml | 5 +- app/src/main/res/values-zh-rTW/strings.xml | 3 +- app/src/main/res/values/strings.xml | 3 +- 39 files changed, 307 insertions(+), 54 deletions(-) create mode 100644 app/src/main/kotlin/com/simplemobiletools/notes/pro/helpers/NotesExporter.kt create mode 100644 app/src/main/kotlin/com/simplemobiletools/notes/pro/helpers/NotesImporter.kt diff --git a/app/src/main/kotlin/com/simplemobiletools/notes/pro/activities/MainActivity.kt b/app/src/main/kotlin/com/simplemobiletools/notes/pro/activities/MainActivity.kt index 9e61b798..c9aff8c8 100644 --- a/app/src/main/kotlin/com/simplemobiletools/notes/pro/activities/MainActivity.kt +++ b/app/src/main/kotlin/com/simplemobiletools/notes/pro/activities/MainActivity.kt @@ -44,6 +44,8 @@ import com.simplemobiletools.notes.pro.helpers.* import com.simplemobiletools.notes.pro.models.Note import kotlinx.android.synthetic.main.activity_main.* import java.io.File +import java.io.FileOutputStream +import java.io.OutputStream import java.nio.charset.Charset import java.util.* import kotlin.collections.ArrayList @@ -58,6 +60,9 @@ class MainActivity : SimpleActivity() { private val PICK_OPEN_FILE_INTENT = 1 private val PICK_EXPORT_FILE_INTENT = 2 + private val PICK_IMPORT_NOTES_INTENT = 3 + private val PICK_EXPORT_NOTES_INTENT = 4 + private lateinit var mCurrentNote: Note private var mNotes = ArrayList() private var mAdapter: NotesPagerAdapter? = null @@ -72,6 +77,7 @@ class MainActivity : SimpleActivity() { private var searchIndex = 0 private var searchMatches = emptyList() private var isSearchActive = false + private val notesExporter by lazy { NotesExporter(this) } private lateinit var searchQueryET: MyEditText private lateinit var searchPrevBtn: ImageView @@ -171,11 +177,13 @@ class MainActivity : SimpleActivity() { findItem(R.id.rename_note).isVisible = multipleNotesExist findItem(R.id.open_note).isVisible = multipleNotesExist findItem(R.id.delete_note).isVisible = multipleNotesExist - findItem(R.id.export_all_notes).isVisible = multipleNotesExist && hasPermission(PERMISSION_WRITE_STORAGE) + findItem(R.id.export_all_notes).isVisible = multipleNotesExist && !isQPlus() + findItem(R.id.export_notes).isVisible = multipleNotesExist && isQPlus() findItem(R.id.open_search).isVisible = !isCurrentItemChecklist findItem(R.id.remove_done_items).isVisible = isCurrentItemChecklist findItem(R.id.sort_checklist).isVisible = isCurrentItemChecklist - findItem(R.id.import_folder).isVisible = hasPermission(PERMISSION_READ_STORAGE) + findItem(R.id.import_folder).isVisible = !isQPlus() + findItem(R.id.import_notes).isVisible = isQPlus() findItem(R.id.lock_note).isVisible = mNotes.isNotEmpty() && !mCurrentNote.isLocked() findItem(R.id.unlock_note).isVisible = mNotes.isNotEmpty() && mCurrentNote.isLocked() @@ -208,6 +216,8 @@ class MainActivity : SimpleActivity() { R.id.import_folder -> openFolder() R.id.export_as_file -> fragment?.handleUnlocking { tryExportAsFile() } R.id.export_all_notes -> tryExportAllNotes() + R.id.export_notes -> tryExportNotes() + R.id.import_notes -> tryImportNotes() R.id.print -> fragment?.handleUnlocking { printText() } R.id.delete_note -> fragment?.handleUnlocking { displayDeleteNotePrompt() } R.id.settings -> launchSettings() @@ -269,6 +279,11 @@ class MainActivity : SimpleActivity() { val takeFlags = Intent.FLAG_GRANT_READ_URI_PERMISSION or Intent.FLAG_GRANT_WRITE_URI_PERMISSION applicationContext.contentResolver.takePersistableUriPermission(resultData.data!!, takeFlags) showExportFilePickUpdateDialog(resultData.dataString!!, getCurrentNoteValue()) + } else if (requestCode == PICK_EXPORT_NOTES_INTENT && resultCode == Activity.RESULT_OK && resultData != null && resultData.data != null) { + val outputStream = contentResolver.openOutputStream(resultData.data!!) + exportNotesTo(outputStream) + } else if (requestCode == PICK_IMPORT_NOTES_INTENT && resultCode == Activity.RESULT_OK && resultData != null && resultData.data != null) { + importNotesFrom(resultData.data!!) } } @@ -785,15 +800,21 @@ class MainActivity : SimpleActivity() { } private fun openFolder() { - FilePickerDialog(this, pickFile = false, canAddShowHiddenButton = true) { - openFolder(it) { - ImportFolderDialog(this, it.path) { - NotesHelper(this).getNotes { - mNotes = it - showSaveButton = false - initViewPager() + handlePermission(PERMISSION_READ_STORAGE) { hasPermission -> + if (hasPermission) { + FilePickerDialog(this, pickFile = false, canAddShowHiddenButton = true) { + openFolder(it) { + ImportFolderDialog(this, it.path) { + NotesHelper(this).getNotes { + mNotes = it + showSaveButton = false + initViewPager() + } + } } } + } else { + toast(R.string.no_storage_permissions) } } } @@ -842,6 +863,77 @@ class MainActivity : SimpleActivity() { } } + private fun tryExportNotes() { + val fileName = "${getString(R.string.notes)}_${getCurrentFormattedDateTime()}" + Intent(Intent.ACTION_CREATE_DOCUMENT).apply { + type = EXPORT_MIME_TYPE + putExtra(Intent.EXTRA_TITLE, fileName) + addCategory(Intent.CATEGORY_OPENABLE) + startActivityForResult(this, PICK_EXPORT_NOTES_INTENT) + } + } + + private fun exportNotesTo(outputStream: OutputStream?) { + toast(R.string.exporting) + ensureBackgroundThread { + notesExporter.exportNotes(outputStream) { + val toastId = when (it) { + NotesExporter.ExportResult.EXPORT_OK -> R.string.exporting_successful + else -> R.string.exporting_failed + } + + toast(toastId) + } + } + } + + private fun tryImportNotes() { + Intent(Intent.ACTION_GET_CONTENT).apply { + addCategory(Intent.CATEGORY_OPENABLE) + type = EXPORT_MIME_TYPE + startActivityForResult(this, PICK_IMPORT_NOTES_INTENT) + } + } + + private fun importNotes(path: String) { + toast(R.string.importing) + ensureBackgroundThread { + NotesImporter(this).importNotes(path) { + toast( + when (it) { + NotesImporter.ImportResult.IMPORT_OK -> R.string.importing_successful + NotesImporter.ImportResult.IMPORT_PARTIAL -> R.string.importing_some_entries_failed + else -> R.string.no_items_found + } + ) + initViewPager() + } + } + } + + private fun importNotesFrom(uri: Uri) { + when (uri.scheme) { + "file" -> importNotes(uri.path!!) + "content" -> { + val tempFile = getTempFile("messages", "backup.json") + if (tempFile == null) { + toast(R.string.unknown_error_occurred) + return + } + + try { + val inputStream = contentResolver.openInputStream(uri) + val out = FileOutputStream(tempFile) + inputStream!!.copyTo(out) + importNotes(tempFile.absolutePath) + } catch (e: Exception) { + showErrorToast(e) + } + } + else -> toast(R.string.invalid_file_format) + } + } + private fun showExportFilePickUpdateDialog(exportPath: String, textToExport: String) { val items = arrayListOf( RadioItem(EXPORT_FILE_SYNC, getString(R.string.update_file_at_note)), @@ -871,6 +963,8 @@ class MainActivity : SimpleActivity() { handlePermission(PERMISSION_WRITE_STORAGE) { if (it) { exportAllNotes() + } else { + toast(R.string.no_storage_permissions) } } } diff --git a/app/src/main/kotlin/com/simplemobiletools/notes/pro/helpers/Constants.kt b/app/src/main/kotlin/com/simplemobiletools/notes/pro/helpers/Constants.kt index 3ca91baa..2a27309a 100644 --- a/app/src/main/kotlin/com/simplemobiletools/notes/pro/helpers/Constants.kt +++ b/app/src/main/kotlin/com/simplemobiletools/notes/pro/helpers/Constants.kt @@ -36,6 +36,7 @@ const val USE_INCOGNITO_MODE = "use_incognito_mode" const val LAST_CREATED_NOTE_TYPE = "last_created_note_type" const val MOVE_DONE_CHECKLIST_ITEMS = "move_undone_checklist_items" // it has been replaced from moving undone items at the top to moving done to bottom const val FONT_SIZE_PERCENTAGE = "font_size_percentage" +const val EXPORT_MIME_TYPE = "application/json" // gravity const val GRAVITY_LEFT = 0 diff --git a/app/src/main/kotlin/com/simplemobiletools/notes/pro/helpers/NotesExporter.kt b/app/src/main/kotlin/com/simplemobiletools/notes/pro/helpers/NotesExporter.kt new file mode 100644 index 00000000..8aeeba5a --- /dev/null +++ b/app/src/main/kotlin/com/simplemobiletools/notes/pro/helpers/NotesExporter.kt @@ -0,0 +1,52 @@ +package com.simplemobiletools.notes.pro.helpers + +import android.content.Context +import com.google.gson.Gson +import com.google.gson.stream.JsonWriter +import com.simplemobiletools.commons.helpers.PROTECTION_NONE +import com.simplemobiletools.commons.helpers.ensureBackgroundThread +import com.simplemobiletools.notes.pro.extensions.notesDB +import com.simplemobiletools.notes.pro.models.Note +import java.io.OutputStream + +class NotesExporter(private val context: Context) { + enum class ExportResult { + EXPORT_FAIL, EXPORT_OK + } + + private val gson = Gson() + + fun exportNotes(outputStream: OutputStream?, onProgress: (total: Int, current: Int) -> Unit = { _, _ -> }, callback: (result: ExportResult) -> Unit) { + ensureBackgroundThread { + if (outputStream == null) { + callback.invoke(ExportResult.EXPORT_FAIL) + return@ensureBackgroundThread + } + val writer = JsonWriter(outputStream.bufferedWriter()) + writer.use { + try { + var written = 0 + writer.beginArray() + val notes = context.notesDB.getNotes() as ArrayList + val totalNotes = notes.size + for (note in notes) { + if (note.protectionType === PROTECTION_NONE) { + val noteToSave = getNoteToExport(note) + writer.jsonValue(gson.toJson(noteToSave)) + written++ + onProgress.invoke(totalNotes, written) + } + } + writer.endArray() + callback.invoke(ExportResult.EXPORT_OK) + } catch (e: Exception) { + callback.invoke(ExportResult.EXPORT_FAIL) + } + } + } + } + + private fun getNoteToExport(note: Note): Note { + return Note(null, note.title, note.getNoteStoredValue(context) ?: "", note.type, "", PROTECTION_NONE, "") + } +} diff --git a/app/src/main/kotlin/com/simplemobiletools/notes/pro/helpers/NotesImporter.kt b/app/src/main/kotlin/com/simplemobiletools/notes/pro/helpers/NotesImporter.kt new file mode 100644 index 00000000..e96384e2 --- /dev/null +++ b/app/src/main/kotlin/com/simplemobiletools/notes/pro/helpers/NotesImporter.kt @@ -0,0 +1,64 @@ +package com.simplemobiletools.notes.pro.helpers + +import android.content.Context +import com.google.gson.Gson +import com.google.gson.reflect.TypeToken +import com.simplemobiletools.commons.extensions.showErrorToast +import com.simplemobiletools.commons.helpers.ensureBackgroundThread +import com.simplemobiletools.notes.pro.extensions.notesDB +import com.simplemobiletools.notes.pro.models.Note +import java.io.File + +class NotesImporter(private val context: Context) { + enum class ImportResult { + IMPORT_FAIL, IMPORT_OK, IMPORT_PARTIAL, IMPORT_NOTHING_NEW + } + + private val gson = Gson() + private var notesImported = 0 + private var notesFailed = 0 + + fun importNotes(path: String, onProgress: (total: Int, current: Int) -> Unit = { _, _ -> }, callback: (result: ImportResult) -> Unit) { + ensureBackgroundThread { + try { + val inputStream = if (path.contains("/")) { + File(path).inputStream() + } else { + context.assets.open(path) + } + + inputStream.bufferedReader().use { reader -> + val json = reader.readText() + val type = object : TypeToken>() {}.type + val notes = gson.fromJson>(json, type) + val totalNotes = notes.size + if (totalNotes <= 0) { + callback.invoke(ImportResult.IMPORT_NOTHING_NEW) + return@ensureBackgroundThread + } + + onProgress.invoke(totalNotes, notesImported) + for (note in notes) { + val exists = context.notesDB.getNoteIdWithTitle(note.title) != null + if (!exists) { + context.notesDB.insertOrUpdate(note) + notesImported++ + onProgress.invoke(totalNotes, notesImported) + } + } + } + } catch (e: Exception) { + context.showErrorToast(e) + notesFailed++ + } + + callback.invoke( + when { + notesImported == 0 -> ImportResult.IMPORT_FAIL + notesFailed > 0 -> ImportResult.IMPORT_PARTIAL + else -> ImportResult.IMPORT_OK + } + ) + } + } +} diff --git a/app/src/main/res/menu/menu.xml b/app/src/main/res/menu/menu.xml index 568f5eba..5973b55b 100644 --- a/app/src/main/res/menu/menu.xml +++ b/app/src/main/res/menu/menu.xml @@ -66,6 +66,10 @@ android:id="@+id/import_folder" android:title="@string/import_folder" app:showAsAction="never" /> + + إزالة العناصر التي تم إنجازها تصدير جميع الملاحظات كملفات - استيراد ملفات متعددة كملاحظات مجلد الاستيراد + Export notes + Import notes كيف يمكنني تغيير لون القطع؟ في حال كان لديك عنصر واجهة مستخدم نشط واحد فقط، يمكنك إما إعادة إنشائه، أو استخدام الزر في إعدادات التطبيق لتخصيصه. إذا كان لديك العديد من الحاجيات النشطة، لن يكون الزر الموجود في إعدادات التطبيق متاحا. بما أن التطبيق يدعم تخصيص الألوان لكل عنصر واجهة مستخدم ، سيكون عليك إعادة إنشاء القطعة التي تريد تخصيصها. diff --git a/app/src/main/res/values-az/strings.xml b/app/src/main/res/values-az/strings.xml index 4ebeb542..af5b538b 100644 --- a/app/src/main/res/values-az/strings.xml +++ b/app/src/main/res/values-az/strings.xml @@ -69,8 +69,9 @@ Bütün qeydləri fayl şəklində çıxar - Toplu faylları qeyd şəklində daxil et Qovluq daxil et + Export notes + Import notes How can I change the widgets color? diff --git a/app/src/main/res/values-ca/strings.xml b/app/src/main/res/values-ca/strings.xml index ad6df41b..14e6f9b3 100644 --- a/app/src/main/res/values-ca/strings.xml +++ b/app/src/main/res/values-ca/strings.xml @@ -66,8 +66,9 @@ Elimina els elements fets Exporta totes les notes com a fitxers - Importa diversos fitxers com a notes Importa una carpeta + Export notes + Import notes Com puc canviar el color dels ginys\? En cas que només tingueu 1 giny actiu, podeu tornar-lo a crear o utilitzar el botó de configuració de l\'aplicació per personalitzar-lo. Si teniu diversos ginys actius, el botó de configuració de l\'aplicació no estarà disponible. Com que l\'aplicació admet la personalització del color per giny, haureu de tornar a crear el giny que vulgueu personalitzar. @@ -81,4 +82,4 @@ Haven't found some strings? There's more at https://github.com/SimpleMobileTools/Simple-Commons/tree/master/commons/src/main/res --> - \ No newline at end of file + diff --git a/app/src/main/res/values-cs/strings.xml b/app/src/main/res/values-cs/strings.xml index 2bdbff75..48f5318d 100644 --- a/app/src/main/res/values-cs/strings.xml +++ b/app/src/main/res/values-cs/strings.xml @@ -69,8 +69,9 @@ Exportovat všechny poznámky jako soubory - Importovat vícero souborů jako poznámky Importovat složku + Export notes + Import notes Jak mohu změnit barvy widgetu? diff --git a/app/src/main/res/values-cy/strings.xml b/app/src/main/res/values-cy/strings.xml index 4781b3ba..2d5937e4 100644 --- a/app/src/main/res/values-cy/strings.xml +++ b/app/src/main/res/values-cy/strings.xml @@ -69,8 +69,9 @@ Allforio pob nodyn fel ffeil - Mewnforio nifer o ffeiliau fel nodiadau Mewnforio ffolder + Export notes + Import notes How can I change the widgets color? diff --git a/app/src/main/res/values-da/strings.xml b/app/src/main/res/values-da/strings.xml index c777c341..f001c4b8 100644 --- a/app/src/main/res/values-da/strings.xml +++ b/app/src/main/res/values-da/strings.xml @@ -69,8 +69,9 @@ Eksporter alle noter som filer - Importer flere filer som noter Importer mappe + Export notes + Import notes How can I change the widgets color? diff --git a/app/src/main/res/values-de/strings.xml b/app/src/main/res/values-de/strings.xml index 159efd9e..a8465867 100644 --- a/app/src/main/res/values-de/strings.xml +++ b/app/src/main/res/values-de/strings.xml @@ -66,8 +66,9 @@ Abgeschlossene Einträge entfernen Alle Notizen als Dateien exportieren - Mehrere Dateien als Notizen importieren Ordner importieren + Export notes + Import notes Wie kann ich die Farbe der Widgets ändern\? Wenn nur ein Widget aktiv ist, kann die Farbe über die Einstellungen unter dem Punkt Widgets angepasst werden, ansonsten muss es neu erstellt werden. @@ -81,4 +82,4 @@ Haven't found some strings? There's more at https://github.com/SimpleMobileTools/Simple-Commons/tree/master/commons/src/main/res --> - \ No newline at end of file + diff --git a/app/src/main/res/values-el/strings.xml b/app/src/main/res/values-el/strings.xml index ac555616..f5f93866 100644 --- a/app/src/main/res/values-el/strings.xml +++ b/app/src/main/res/values-el/strings.xml @@ -69,8 +69,9 @@ Εξαγωγή όλων των σημειώσεων ως αρχεία - Εισαγωγή πολλών αρχείων ως σημειώσεις Εισαγωγή φακέλου + Export notes + Import notes Πώς μπορώ να αλλάξω το χρώμα των Γραφικών στοιχείων; diff --git a/app/src/main/res/values-eo/strings.xml b/app/src/main/res/values-eo/strings.xml index 3aea8513..baa2d3f2 100644 --- a/app/src/main/res/values-eo/strings.xml +++ b/app/src/main/res/values-eo/strings.xml @@ -66,8 +66,9 @@ Remove done items Export all notes as files - Import multiple files as notes Import folder + Export notes + Import notes How can I change the widgets color? In case you have only 1 active widget, you can either recreate it, or use the button in the app settings for customizing it. If you have multiple active widgets, the button in the app settings will not be available. As the app supports color customization per-widget, you will have to recreate the widget that you want to customize. diff --git a/app/src/main/res/values-es/strings.xml b/app/src/main/res/values-es/strings.xml index ab8e6029..87015ed2 100644 --- a/app/src/main/res/values-es/strings.xml +++ b/app/src/main/res/values-es/strings.xml @@ -69,8 +69,9 @@ Exportar todas las notas como archivos - Importar múltiples archivos como notas Importar carpeta + Export notes + Import notes ¿Cómo puedo cambiar los colores del widget? diff --git a/app/src/main/res/values-et/strings.xml b/app/src/main/res/values-et/strings.xml index 8168ff5c..4fb8c174 100644 --- a/app/src/main/res/values-et/strings.xml +++ b/app/src/main/res/values-et/strings.xml @@ -66,8 +66,9 @@ Kustuta tehtuks märgitud kirjed Ekspordi kõik märkmed failidena - Impordi mitu faili märkmeteks Impordi kaust + Export notes + Import notes Kuidas ma saan muuta vidinate värvi\? Kui sa kasutad vaid üht vidinat, siis kas saad ta uuesti luua või kasutada rakenduse seadistusi värvide kohandamiseks. Kui sul on pidevas kasutuses mitu vidinat, siis rakenduste seadistuste nupp ei toimi. Kuna rakendus võimaldab eri vidinatele määrata erinevaid värve, siis sa pead muudetava vidina uuesti looma. @@ -111,4 +112,4 @@ Haven't found some strings? There's more at https://github.com/SimpleMobileTools/Simple-Commons/tree/master/commons/src/main/res --> - \ No newline at end of file + diff --git a/app/src/main/res/values-fa/strings.xml b/app/src/main/res/values-fa/strings.xml index 49526057..0895035e 100644 --- a/app/src/main/res/values-fa/strings.xml +++ b/app/src/main/res/values-fa/strings.xml @@ -69,8 +69,9 @@ برون‌ریزی همه یادداشت‌ها به عنوان پرونده - درون‌ریزی چندین پرونده به عنوان یادداشت درون‌ریزی پوشه + Export notes + Import notes چگونه میتوانم رنگ ابزارک‌ها را تغییر دهم؟ diff --git a/app/src/main/res/values-fi/strings.xml b/app/src/main/res/values-fi/strings.xml index 53ab75d7..d9c272aa 100644 --- a/app/src/main/res/values-fi/strings.xml +++ b/app/src/main/res/values-fi/strings.xml @@ -66,8 +66,9 @@ Poista tehdyt kohdat Vie kaikki muistiinpanot tiedostoina - Tuo useita tiedostoja muistiinpanoina Tuo kansio + Export notes + Import notes Kuinka voin vaihtaa pienoissovelluksen väriä\? Jos sinulla on vain yksi aktiivinen pienoissovellus, voit joko luoda sen uudelleen tai mukauttaa sitä sovelluksen asetukset-painikkeella. Jos sinulla on useita aktiivisia pienoissovelluksia, sovelluksessa oleva asetukset-painike ei ole käytettävissä. Koska sovellus tukee värien mukauttamista pienoissovellusta kohti, sinun on luotava uudelleen pienoissovellus, jonka haluat muokata. diff --git a/app/src/main/res/values-fr/strings.xml b/app/src/main/res/values-fr/strings.xml index 6f1fe2bc..dd1e988e 100644 --- a/app/src/main/res/values-fr/strings.xml +++ b/app/src/main/res/values-fr/strings.xml @@ -66,8 +66,9 @@ Supprimer les éléments cochés Exporter toutes les notes en tant que fichiers - Importer plusieurs fichiers en tant que notes Importer depuis un dossier + Export notes + Import notes Comment puis-je changer la couleur des widgets \? Si vous avez seulement un widget actif, vous pouvez soit le recréer, soit utiliser le bouton dans les paramètres pour le personnaliser. Si vous avez plusieurs widgets actifs, le bouton dans les paramètres ne sera pas disponible. Comme l\'application supporte la personnalisation de la couleur par widget, vous devrez recréer le widget que vous voulez personnaliser. @@ -81,4 +82,4 @@ Haven't found some strings? There's more at https://github.com/SimpleMobileTools/Simple-Commons/tree/master/commons/src/main/res --> - \ No newline at end of file + diff --git a/app/src/main/res/values-gl/strings.xml b/app/src/main/res/values-gl/strings.xml index 8593bd40..f243ab76 100644 --- a/app/src/main/res/values-gl/strings.xml +++ b/app/src/main/res/values-gl/strings.xml @@ -69,8 +69,9 @@ Exportar todas as notas como ficheiros - Importar varios ficheiros como notas Importar cartafoles + Export notes + Import notes Como cambio a cor dos widgets? diff --git a/app/src/main/res/values-hr/strings.xml b/app/src/main/res/values-hr/strings.xml index ec5db7e4..362b72bb 100644 --- a/app/src/main/res/values-hr/strings.xml +++ b/app/src/main/res/values-hr/strings.xml @@ -66,8 +66,9 @@ Ukloni gotove stavke Izvezi sve bilješke kao datoteke - Uvezi više datoteka kao bilješke Mapa za uvoz + Export notes + Import notes Kako mogu promijeniti boju widgeta\? In case you have only 1 active widget, you can either recreate it, or use the button in the app settings for customizing it. If you have multiple active widgets, the button in the app settings will not be available. As the app supports color customization per-widget, you will have to recreate the widget that you want to customize. @@ -111,4 +112,4 @@ Haven't found some strings? There's more at https://github.com/SimpleMobileTools/Simple-Commons/tree/master/commons/src/main/res --> - \ No newline at end of file + diff --git a/app/src/main/res/values-hu/strings.xml b/app/src/main/res/values-hu/strings.xml index 33d746dd..b263f36f 100644 --- a/app/src/main/res/values-hu/strings.xml +++ b/app/src/main/res/values-hu/strings.xml @@ -70,8 +70,9 @@ Kész elemek eltávolítása Összes jegyzet exportálása fájlként - Több fájl importálása jegyzetként Mappa importálása + Export notes + Import notes Hogyan módosíthatom a modulok színét\? Ha csak 1 aktív modulja van, akkor vagy újra létrehozhatja, vagy használja az alkalmazásbeállításokban lévő gombot, hogy testreszabja. Ha több modulja van, akkor az alkalmazásbeállításokban nem lesz elérhető a gomb. Mivel az alkalmazás támogatja szín modulonkénti testreszabását, azért a módosítandó modult újra létre kell hoznia. diff --git a/app/src/main/res/values-id/strings.xml b/app/src/main/res/values-id/strings.xml index 183140c9..8517ceed 100644 --- a/app/src/main/res/values-id/strings.xml +++ b/app/src/main/res/values-id/strings.xml @@ -69,8 +69,9 @@ Ekspor semua catatan ke berkas - Impor beberapa berkas ke catatan Impor folder + Export notes + Import notes Bagaimana caranya mengubah warna widget? diff --git a/app/src/main/res/values-it/strings.xml b/app/src/main/res/values-it/strings.xml index 9804a19f..92422532 100644 --- a/app/src/main/res/values-it/strings.xml +++ b/app/src/main/res/values-it/strings.xml @@ -66,8 +66,9 @@ Rimuovi gli elementi finiti Esporta le note come file - Importa file multipli come note Importa cartella + Export notes + Import notes Come posso cambiare il colore dei widget\? Se hai un solo widget attivo, puoi ricrearlo oppure usare il pulsante nelle impostazioni dell\'app per personalizzaro. Se hai più di un widget, il pulsante nelle impostazioni dell\'app non sarà disponibile. Dato che l\'app supporta la personalizzazione dei colori per ogni widget, dovrai ricreare il widget che vuoi personalizzare. @@ -81,4 +82,4 @@ Haven't found some strings? There's more at https://github.com/SimpleMobileTools/Simple-Commons/tree/master/commons/src/main/res --> - \ No newline at end of file + diff --git a/app/src/main/res/values-ja/strings.xml b/app/src/main/res/values-ja/strings.xml index a5fbf55f..a0ee9d9b 100644 --- a/app/src/main/res/values-ja/strings.xml +++ b/app/src/main/res/values-ja/strings.xml @@ -69,8 +69,9 @@ すべてのメモをファイルとしてエクスポート - 複数のファイルをメモとしてインポート フォルダからインポート + Export notes + Import notes ウィジェットの色はどうやって変更出来ますか? diff --git a/app/src/main/res/values-lt/strings.xml b/app/src/main/res/values-lt/strings.xml index 3512658a..b04ff0f6 100644 --- a/app/src/main/res/values-lt/strings.xml +++ b/app/src/main/res/values-lt/strings.xml @@ -69,8 +69,9 @@ Eksportuoti visus užrašus kaip bylas - Importuoti keletą bylų, kaip užrašus Importuoti aplanką + Export notes + Import notes How can I change the widgets color? diff --git a/app/src/main/res/values-nb-rNO/strings.xml b/app/src/main/res/values-nb-rNO/strings.xml index 17359490..d66aef2a 100644 --- a/app/src/main/res/values-nb-rNO/strings.xml +++ b/app/src/main/res/values-nb-rNO/strings.xml @@ -66,8 +66,9 @@ Fjern utførte elementer Eksporter alle notater som filer - Importer flere filer som notater Importer mappe + Export notes + Import notes Hvordan endrer jeg miniprogramsfargen\? In case you have only 1 active widget, you can either recreate it, or use the button in the app settings for customizing it. If you have multiple active widgets, the button in the app settings will not be available. As the app supports color customization per-widget, you will have to recreate the widget that you want to customize. diff --git a/app/src/main/res/values-nl/strings.xml b/app/src/main/res/values-nl/strings.xml index c9ba9669..580216e4 100644 --- a/app/src/main/res/values-nl/strings.xml +++ b/app/src/main/res/values-nl/strings.xml @@ -69,8 +69,9 @@ Alle notities naar bestanden exporteren - Bestanden als notitites importeren Map importeren + Export notes + Import notes Hoe verander ik de kleuren van de widgets? diff --git a/app/src/main/res/values-pl/strings.xml b/app/src/main/res/values-pl/strings.xml index 79306c45..c3231033 100644 --- a/app/src/main/res/values-pl/strings.xml +++ b/app/src/main/res/values-pl/strings.xml @@ -66,8 +66,9 @@ Usuń wykonane elementy Eksportuj wszystkie notatki jako pliki - Importuj wiele plików jako notatki Importuj folder + Eksportuj notatki + Importuj notatki Jak mogę zmienić kolor widżetów\? Jeśli masz tylko 1 aktywny widżet, możesz go odtworzyć lub użyć przycisku w ustawieniach aplikacji, aby go dostosować. Jeśli masz wiele aktywnych widżetów, przycisk w ustawieniach aplikacji nie będzie dostępny. Ponieważ aplikacja obsługuje dostosowywanie kolorów dla poszczególnych widżetów, konieczne będzie ponowne utworzenie widżetu, który chcesz dostosować. diff --git a/app/src/main/res/values-pt-rBR/strings.xml b/app/src/main/res/values-pt-rBR/strings.xml index ce2f361e..5b176e21 100644 --- a/app/src/main/res/values-pt-rBR/strings.xml +++ b/app/src/main/res/values-pt-rBR/strings.xml @@ -66,8 +66,9 @@ Remover itens concluídos Exportar todas as notas como arquivo - Importar múltiplos arquivos como notas Importar pasta + Export notes + Import notes Como mudar a cor do widget? Caso você possua apenas 1 widget ativo, você poderá recriá-lo, ou usar o botão nas configurações do aplicativo para personalizá-lo. Caso você possua vários widgets ativos, o botão nas configurações do aplicativo não estará disponível. Como o aplicativo suporta personalização de cores por widget, você terá que recriar o widget que deseja personalizar. @@ -111,4 +112,4 @@ Haven't found some strings? There's more at https://github.com/SimpleMobileTools/Simple-Commons/tree/master/commons/src/main/res --> - \ No newline at end of file + diff --git a/app/src/main/res/values-pt/strings.xml b/app/src/main/res/values-pt/strings.xml index e2a669e2..93d6c71e 100644 --- a/app/src/main/res/values-pt/strings.xml +++ b/app/src/main/res/values-pt/strings.xml @@ -67,8 +67,9 @@ Remover itens concluídos Exportar todas as notas como ficheiros - Importar ficheiros para notas Importar pasta + Export notes + Import notes Como posso alterar a cor do widget\? Se apenas tiver um widget ativo, pode recriá-lo ou utilizar o botão nas definições o personalizar. Se tiver vários widgets, este botão não estará disponível. Como cada um dos widgets pode ser personalizado, terá que os recriar sempre que o quiser personalizar. @@ -82,4 +83,4 @@ Não encontrou todas as cadeias a traduzir? Existem mais algumas em: https://github.com/SimpleMobileTools/Simple-Commons/tree/master/commons/src/main/res --> - \ No newline at end of file + diff --git a/app/src/main/res/values-ru/strings.xml b/app/src/main/res/values-ru/strings.xml index 6e28ad33..e3eb4c66 100644 --- a/app/src/main/res/values-ru/strings.xml +++ b/app/src/main/res/values-ru/strings.xml @@ -66,8 +66,9 @@ Удалить выполненные позиции Экспортировать все заметки в файлы - Импортировать несколько файлов в заметки Импортировать папку + Export notes + Import notes Как я могу изменить цвет виджета\? Если у вас только 1 активный виджет, вы можете либо пересоздать его, либо использовать кнопку в настройках приложения. Если у вас несколько активных виджетов, кнопка в настройках будет недоступна. Поскольку приложение поддерживает настройку цвета для каждого виджета, вам придётся пересоздать виджет, который вы хотите настроить. diff --git a/app/src/main/res/values-sk/strings.xml b/app/src/main/res/values-sk/strings.xml index c5fea0b3..b425476e 100644 --- a/app/src/main/res/values-sk/strings.xml +++ b/app/src/main/res/values-sk/strings.xml @@ -69,8 +69,9 @@ Exportovať všetky poznámky ako súbory - Importovať viacero súborov ako poznámky Importovať priečinok + Export notes + Import notes Ako viem zmeniť farby widgetu? diff --git a/app/src/main/res/values-sv/strings.xml b/app/src/main/res/values-sv/strings.xml index 90e7b62a..b56f339b 100644 --- a/app/src/main/res/values-sv/strings.xml +++ b/app/src/main/res/values-sv/strings.xml @@ -66,8 +66,9 @@ Remove done items Exportera alla anteckningar som filer - Importera flera filer som anteckningar Importera mapp + Export notes + Import notes How can I change the widgets color? In case you have only 1 active widget, you can either recreate it, or use the button in the app settings for customizing it. If you have multiple active widgets, the button in the app settings will not be available. As the app supports color customization per-widget, you will have to recreate the widget that you want to customize. @@ -111,4 +112,4 @@ Haven't found some strings? There's more at https://github.com/SimpleMobileTools/Simple-Commons/tree/master/commons/src/main/res --> - \ No newline at end of file + diff --git a/app/src/main/res/values-tr/strings.xml b/app/src/main/res/values-tr/strings.xml index 0ab8e5ca..2d6c4a1e 100644 --- a/app/src/main/res/values-tr/strings.xml +++ b/app/src/main/res/values-tr/strings.xml @@ -66,8 +66,9 @@ Tamamlanan ögeleri kaldır Tüm notları dosya olarak dışa aktar - Birden çok dosyayı not olarak içe aktar Klasörü içe aktar + Export notes + Import notes Widget rengini nasıl değiştirebilirim\? Yalnızca 1 etkin widget\'ınız varsa, yeniden oluşturabilir veya özelleştirmek için uygulama ayarlarındaki düğmeyi kullanabilirsiniz. Birden fazla etkin widget\'ınız varsa, uygulama ayarlarındaki düğme kullanılamaz. Uygulama, widget başına renk özelleştirmeyi desteklediğinden, özelleştirmek istediğiniz widget\'ı yeniden oluşturmanız gerekir. @@ -81,4 +82,4 @@ Haven't found some strings? There's more at https://github.com/SimpleMobileTools/Simple-Commons/tree/master/commons/src/main/res --> - \ No newline at end of file + diff --git a/app/src/main/res/values-uk/strings.xml b/app/src/main/res/values-uk/strings.xml index e584b730..4fdd04fd 100644 --- a/app/src/main/res/values-uk/strings.xml +++ b/app/src/main/res/values-uk/strings.xml @@ -69,8 +69,9 @@ Експортувати всі нотатки як файли - Імпортувати файли як нотатки Імпортувати теку + Export notes + Import notes Як я можу змінити колір віджета? diff --git a/app/src/main/res/values-zh-rCN/strings.xml b/app/src/main/res/values-zh-rCN/strings.xml index 29cbd246..d66e4936 100644 --- a/app/src/main/res/values-zh-rCN/strings.xml +++ b/app/src/main/res/values-zh-rCN/strings.xml @@ -66,8 +66,9 @@ 删除完成的项目 以文件导出所有笔记 - 导入多个文件为笔记 导入文件夹 + Export notes + Import notes 我如何更改小工具颜色? 如果您仅用一个活动的小工具,您既可以重新创建它,或者使用应用程序设定的按钮来自定义它。如果您拥有多个活动的小工具,应用程序设定中的按钮将不可用。因为应用程序支持小工具分别自定义,您必须要重新创建小工具来自定义它们。 @@ -81,4 +82,4 @@ Haven't found some strings? There's more at https://github.com/SimpleMobileTools/Simple-Commons/tree/master/commons/src/main/res --> - \ No newline at end of file + diff --git a/app/src/main/res/values-zh-rTW/strings.xml b/app/src/main/res/values-zh-rTW/strings.xml index 8f438d2e..a2f07876 100644 --- a/app/src/main/res/values-zh-rTW/strings.xml +++ b/app/src/main/res/values-zh-rTW/strings.xml @@ -69,8 +69,9 @@ 將全部筆記匯出成檔案 - 將多個檔案匯入成筆記 匯入資料夾 + Export notes + Import notes 我如何變更小工具的顏色? diff --git a/app/src/main/res/values/strings.xml b/app/src/main/res/values/strings.xml index d90f9a8f..772699e5 100644 --- a/app/src/main/res/values/strings.xml +++ b/app/src/main/res/values/strings.xml @@ -70,8 +70,9 @@ Export all notes as files - Import multiple files as notes Import folder + Export notes + Import notes How can I change the widgets color? From 84620282a8021d22c0283e90118e281dcdc3ed2c Mon Sep 17 00:00:00 2001 From: Agnieszka C <85929121+Aga-C@users.noreply.github.com> Date: Tue, 8 Mar 2022 13:03:21 +0100 Subject: [PATCH 2/5] Updated string --- app/src/main/res/values-ar/strings.xml | 2 +- app/src/main/res/values-az/strings.xml | 2 +- app/src/main/res/values-ca/strings.xml | 2 +- app/src/main/res/values-cs/strings.xml | 2 +- app/src/main/res/values-cy/strings.xml | 2 +- app/src/main/res/values-da/strings.xml | 2 +- app/src/main/res/values-de/strings.xml | 2 +- app/src/main/res/values-el/strings.xml | 2 +- app/src/main/res/values-eo/strings.xml | 2 +- app/src/main/res/values-es/strings.xml | 2 +- app/src/main/res/values-et/strings.xml | 2 +- app/src/main/res/values-fa/strings.xml | 2 +- app/src/main/res/values-fi/strings.xml | 2 +- app/src/main/res/values-fr/strings.xml | 2 +- app/src/main/res/values-gl/strings.xml | 2 +- app/src/main/res/values-hr/strings.xml | 2 +- app/src/main/res/values-hu/strings.xml | 2 +- app/src/main/res/values-id/strings.xml | 2 +- app/src/main/res/values-it/strings.xml | 2 +- app/src/main/res/values-ja/strings.xml | 2 +- app/src/main/res/values-lt/strings.xml | 2 +- app/src/main/res/values-nb-rNO/strings.xml | 2 +- app/src/main/res/values-nl/strings.xml | 2 +- app/src/main/res/values-pl/strings.xml | 2 +- app/src/main/res/values-pt-rBR/strings.xml | 2 +- app/src/main/res/values-pt/strings.xml | 2 +- app/src/main/res/values-ru/strings.xml | 4 ++-- app/src/main/res/values-sk/strings.xml | 2 +- app/src/main/res/values-sv/strings.xml | 2 +- app/src/main/res/values-tr/strings.xml | 2 +- app/src/main/res/values-uk/strings.xml | 2 +- app/src/main/res/values-zh-rCN/strings.xml | 2 +- app/src/main/res/values-zh-rTW/strings.xml | 2 +- app/src/main/res/values/strings.xml | 2 +- 34 files changed, 35 insertions(+), 35 deletions(-) diff --git a/app/src/main/res/values-ar/strings.xml b/app/src/main/res/values-ar/strings.xml index d306a09b..f26a7559 100644 --- a/app/src/main/res/values-ar/strings.xml +++ b/app/src/main/res/values-ar/strings.xml @@ -68,7 +68,7 @@ تصدير جميع الملاحظات كملفات مجلد الاستيراد - Export notes + Export all notes Import notes كيف يمكنني تغيير لون القطع؟ diff --git a/app/src/main/res/values-az/strings.xml b/app/src/main/res/values-az/strings.xml index af5b538b..37f6b91e 100644 --- a/app/src/main/res/values-az/strings.xml +++ b/app/src/main/res/values-az/strings.xml @@ -70,7 +70,7 @@ Bütün qeydləri fayl şəklində çıxar Qovluq daxil et - Export notes + Export all notes Import notes diff --git a/app/src/main/res/values-ca/strings.xml b/app/src/main/res/values-ca/strings.xml index 14e6f9b3..bd688c14 100644 --- a/app/src/main/res/values-ca/strings.xml +++ b/app/src/main/res/values-ca/strings.xml @@ -67,7 +67,7 @@ Exporta totes les notes com a fitxers Importa una carpeta - Export notes + Export all notes Import notes Com puc canviar el color dels ginys\? diff --git a/app/src/main/res/values-cs/strings.xml b/app/src/main/res/values-cs/strings.xml index 48f5318d..0bc6e512 100644 --- a/app/src/main/res/values-cs/strings.xml +++ b/app/src/main/res/values-cs/strings.xml @@ -70,7 +70,7 @@ Exportovat všechny poznámky jako soubory Importovat složku - Export notes + Export all notes Import notes diff --git a/app/src/main/res/values-cy/strings.xml b/app/src/main/res/values-cy/strings.xml index 2d5937e4..17c06cb1 100644 --- a/app/src/main/res/values-cy/strings.xml +++ b/app/src/main/res/values-cy/strings.xml @@ -70,7 +70,7 @@ Allforio pob nodyn fel ffeil Mewnforio ffolder - Export notes + Export all notes Import notes diff --git a/app/src/main/res/values-da/strings.xml b/app/src/main/res/values-da/strings.xml index 839173ca..ed9ced95 100644 --- a/app/src/main/res/values-da/strings.xml +++ b/app/src/main/res/values-da/strings.xml @@ -67,7 +67,7 @@ Eksporter alle noter som filer Importer mappe - Export notes + Export all notes Import notes Hvordan kan jeg ændre widgets farve\? diff --git a/app/src/main/res/values-de/strings.xml b/app/src/main/res/values-de/strings.xml index a8465867..c5bc6b55 100644 --- a/app/src/main/res/values-de/strings.xml +++ b/app/src/main/res/values-de/strings.xml @@ -67,7 +67,7 @@ Alle Notizen als Dateien exportieren Ordner importieren - Export notes + Export all notes Import notes Wie kann ich die Farbe der Widgets ändern\? diff --git a/app/src/main/res/values-el/strings.xml b/app/src/main/res/values-el/strings.xml index f5f93866..6162a7fe 100644 --- a/app/src/main/res/values-el/strings.xml +++ b/app/src/main/res/values-el/strings.xml @@ -70,7 +70,7 @@ Εξαγωγή όλων των σημειώσεων ως αρχεία Εισαγωγή φακέλου - Export notes + Export all notes Import notes diff --git a/app/src/main/res/values-eo/strings.xml b/app/src/main/res/values-eo/strings.xml index baa2d3f2..d73c08af 100644 --- a/app/src/main/res/values-eo/strings.xml +++ b/app/src/main/res/values-eo/strings.xml @@ -67,7 +67,7 @@ Export all notes as files Import folder - Export notes + Export all notes Import notes How can I change the widgets color? diff --git a/app/src/main/res/values-es/strings.xml b/app/src/main/res/values-es/strings.xml index 87015ed2..0faf2905 100644 --- a/app/src/main/res/values-es/strings.xml +++ b/app/src/main/res/values-es/strings.xml @@ -70,7 +70,7 @@ Exportar todas las notas como archivos Importar carpeta - Export notes + Export all notes Import notes diff --git a/app/src/main/res/values-et/strings.xml b/app/src/main/res/values-et/strings.xml index 4fb8c174..4ac7a06f 100644 --- a/app/src/main/res/values-et/strings.xml +++ b/app/src/main/res/values-et/strings.xml @@ -67,7 +67,7 @@ Ekspordi kõik märkmed failidena Impordi kaust - Export notes + Export all notes Import notes Kuidas ma saan muuta vidinate värvi\? diff --git a/app/src/main/res/values-fa/strings.xml b/app/src/main/res/values-fa/strings.xml index 0895035e..225f2122 100644 --- a/app/src/main/res/values-fa/strings.xml +++ b/app/src/main/res/values-fa/strings.xml @@ -70,7 +70,7 @@ برون‌ریزی همه یادداشت‌ها به عنوان پرونده درون‌ریزی پوشه - Export notes + Export all notes Import notes diff --git a/app/src/main/res/values-fi/strings.xml b/app/src/main/res/values-fi/strings.xml index d9c272aa..10ad67e5 100644 --- a/app/src/main/res/values-fi/strings.xml +++ b/app/src/main/res/values-fi/strings.xml @@ -67,7 +67,7 @@ Vie kaikki muistiinpanot tiedostoina Tuo kansio - Export notes + Export all notes Import notes Kuinka voin vaihtaa pienoissovelluksen väriä\? diff --git a/app/src/main/res/values-fr/strings.xml b/app/src/main/res/values-fr/strings.xml index dd1e988e..8fd91680 100644 --- a/app/src/main/res/values-fr/strings.xml +++ b/app/src/main/res/values-fr/strings.xml @@ -67,7 +67,7 @@ Exporter toutes les notes en tant que fichiers Importer depuis un dossier - Export notes + Export all notes Import notes Comment puis-je changer la couleur des widgets \? diff --git a/app/src/main/res/values-gl/strings.xml b/app/src/main/res/values-gl/strings.xml index f243ab76..d92863f0 100644 --- a/app/src/main/res/values-gl/strings.xml +++ b/app/src/main/res/values-gl/strings.xml @@ -70,7 +70,7 @@ Exportar todas as notas como ficheiros Importar cartafoles - Export notes + Export all notes Import notes diff --git a/app/src/main/res/values-hr/strings.xml b/app/src/main/res/values-hr/strings.xml index 0c1e4616..4773ee76 100644 --- a/app/src/main/res/values-hr/strings.xml +++ b/app/src/main/res/values-hr/strings.xml @@ -67,7 +67,7 @@ Izvezi sve bilješke kao datoteke Mapa za uvoz - Export notes + Export all notes Import notes Kako mogu promijeniti boju widgeta\? diff --git a/app/src/main/res/values-hu/strings.xml b/app/src/main/res/values-hu/strings.xml index b263f36f..debb1555 100644 --- a/app/src/main/res/values-hu/strings.xml +++ b/app/src/main/res/values-hu/strings.xml @@ -71,7 +71,7 @@ Összes jegyzet exportálása fájlként Mappa importálása - Export notes + Export all notes Import notes Hogyan módosíthatom a modulok színét\? diff --git a/app/src/main/res/values-id/strings.xml b/app/src/main/res/values-id/strings.xml index 34cccfef..8def505f 100644 --- a/app/src/main/res/values-id/strings.xml +++ b/app/src/main/res/values-id/strings.xml @@ -67,7 +67,7 @@ Ekspor semua catatan ke berkas Impor folder - Export notes + Export all notes Import notes Bagaimana caranya mengubah warna widget? diff --git a/app/src/main/res/values-it/strings.xml b/app/src/main/res/values-it/strings.xml index 92422532..141171bb 100644 --- a/app/src/main/res/values-it/strings.xml +++ b/app/src/main/res/values-it/strings.xml @@ -67,7 +67,7 @@ Esporta le note come file Importa cartella - Export notes + Export all notes Import notes Come posso cambiare il colore dei widget\? diff --git a/app/src/main/res/values-ja/strings.xml b/app/src/main/res/values-ja/strings.xml index a0ee9d9b..81a31ea8 100644 --- a/app/src/main/res/values-ja/strings.xml +++ b/app/src/main/res/values-ja/strings.xml @@ -70,7 +70,7 @@ すべてのメモをファイルとしてエクスポート フォルダからインポート - Export notes + Export all notes Import notes diff --git a/app/src/main/res/values-lt/strings.xml b/app/src/main/res/values-lt/strings.xml index b04ff0f6..59fb390b 100644 --- a/app/src/main/res/values-lt/strings.xml +++ b/app/src/main/res/values-lt/strings.xml @@ -70,7 +70,7 @@ Eksportuoti visus užrašus kaip bylas Importuoti aplanką - Export notes + Export all notes Import notes diff --git a/app/src/main/res/values-nb-rNO/strings.xml b/app/src/main/res/values-nb-rNO/strings.xml index d66aef2a..5b2be49b 100644 --- a/app/src/main/res/values-nb-rNO/strings.xml +++ b/app/src/main/res/values-nb-rNO/strings.xml @@ -67,7 +67,7 @@ Eksporter alle notater som filer Importer mappe - Export notes + Export all notes Import notes Hvordan endrer jeg miniprogramsfargen\? diff --git a/app/src/main/res/values-nl/strings.xml b/app/src/main/res/values-nl/strings.xml index 4e10620c..0afeab75 100644 --- a/app/src/main/res/values-nl/strings.xml +++ b/app/src/main/res/values-nl/strings.xml @@ -67,7 +67,7 @@ Alle notities naar bestanden exporteren Map importeren - Export notes + Export all notes Import notes Hoe verander ik de kleuren van de widgets\? diff --git a/app/src/main/res/values-pl/strings.xml b/app/src/main/res/values-pl/strings.xml index c3231033..0ca3577d 100644 --- a/app/src/main/res/values-pl/strings.xml +++ b/app/src/main/res/values-pl/strings.xml @@ -67,7 +67,7 @@ Eksportuj wszystkie notatki jako pliki Importuj folder - Eksportuj notatki + Eksportuj wszystkie notatki Importuj notatki Jak mogę zmienić kolor widżetów\? diff --git a/app/src/main/res/values-pt-rBR/strings.xml b/app/src/main/res/values-pt-rBR/strings.xml index da0a26cd..7de09b75 100644 --- a/app/src/main/res/values-pt-rBR/strings.xml +++ b/app/src/main/res/values-pt-rBR/strings.xml @@ -68,7 +68,7 @@ Exportar todas as notas como arquivo Importar pasta - Export notes + Export all notes Import notes Como mudar a cor do widget? diff --git a/app/src/main/res/values-pt/strings.xml b/app/src/main/res/values-pt/strings.xml index 93d6c71e..d560b8b5 100644 --- a/app/src/main/res/values-pt/strings.xml +++ b/app/src/main/res/values-pt/strings.xml @@ -68,7 +68,7 @@ Exportar todas as notas como ficheiros Importar pasta - Export notes + Export all notes Import notes Como posso alterar a cor do widget\? diff --git a/app/src/main/res/values-ru/strings.xml b/app/src/main/res/values-ru/strings.xml index e5cfdc53..3b9f189a 100644 --- a/app/src/main/res/values-ru/strings.xml +++ b/app/src/main/res/values-ru/strings.xml @@ -67,7 +67,7 @@ Экспортировать все заметки в файлы Импортировать папку - Export notes + Export all notes Import notes Как я могу изменить цвет виджета\? @@ -112,4 +112,4 @@ Haven't found some strings? There's more at https://github.com/SimpleMobileTools/Simple-Commons/tree/master/commons/src/main/res --> - \ No newline at end of file + diff --git a/app/src/main/res/values-sk/strings.xml b/app/src/main/res/values-sk/strings.xml index b425476e..64f6a7c5 100644 --- a/app/src/main/res/values-sk/strings.xml +++ b/app/src/main/res/values-sk/strings.xml @@ -70,7 +70,7 @@ Exportovať všetky poznámky ako súbory Importovať priečinok - Export notes + Export all notes Import notes diff --git a/app/src/main/res/values-sv/strings.xml b/app/src/main/res/values-sv/strings.xml index b56f339b..41d62714 100644 --- a/app/src/main/res/values-sv/strings.xml +++ b/app/src/main/res/values-sv/strings.xml @@ -67,7 +67,7 @@ Exportera alla anteckningar som filer Importera mapp - Export notes + Export all notes Import notes How can I change the widgets color? diff --git a/app/src/main/res/values-tr/strings.xml b/app/src/main/res/values-tr/strings.xml index 7c3235cc..4f4e09a5 100644 --- a/app/src/main/res/values-tr/strings.xml +++ b/app/src/main/res/values-tr/strings.xml @@ -69,7 +69,7 @@ Tüm notları dosya olarak dışa aktar Klasörü içe aktar - Export notes + Export all notes Import notes Widget rengini nasıl değiştirebilirim\? diff --git a/app/src/main/res/values-uk/strings.xml b/app/src/main/res/values-uk/strings.xml index f5141f43..1d285abb 100644 --- a/app/src/main/res/values-uk/strings.xml +++ b/app/src/main/res/values-uk/strings.xml @@ -67,7 +67,7 @@ Експортувати всі нотатки як файли Імпортувати теку - Export notes + Export all notes Import notes Як я можу змінити колір віджета? diff --git a/app/src/main/res/values-zh-rCN/strings.xml b/app/src/main/res/values-zh-rCN/strings.xml index d66e4936..90adcf41 100644 --- a/app/src/main/res/values-zh-rCN/strings.xml +++ b/app/src/main/res/values-zh-rCN/strings.xml @@ -67,7 +67,7 @@ 以文件导出所有笔记 导入文件夹 - Export notes + Export all notes Import notes 我如何更改小工具颜色? diff --git a/app/src/main/res/values-zh-rTW/strings.xml b/app/src/main/res/values-zh-rTW/strings.xml index a2f07876..d32dc479 100644 --- a/app/src/main/res/values-zh-rTW/strings.xml +++ b/app/src/main/res/values-zh-rTW/strings.xml @@ -70,7 +70,7 @@ 將全部筆記匯出成檔案 匯入資料夾 - Export notes + Export all notes Import notes diff --git a/app/src/main/res/values/strings.xml b/app/src/main/res/values/strings.xml index 772699e5..974a366c 100644 --- a/app/src/main/res/values/strings.xml +++ b/app/src/main/res/values/strings.xml @@ -71,7 +71,7 @@ Export all notes as files Import folder - Export notes + Export all notes Import notes From 3137d6273b6f895c91aa4feaf5c0a99b1d0c0fab Mon Sep 17 00:00:00 2001 From: Agnieszka C <85929121+Aga-C@users.noreply.github.com> Date: Tue, 8 Mar 2022 13:03:51 +0100 Subject: [PATCH 3/5] Removed lazy option --- .../com/simplemobiletools/notes/pro/activities/MainActivity.kt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/src/main/kotlin/com/simplemobiletools/notes/pro/activities/MainActivity.kt b/app/src/main/kotlin/com/simplemobiletools/notes/pro/activities/MainActivity.kt index 2143c1d9..d7b6ac19 100644 --- a/app/src/main/kotlin/com/simplemobiletools/notes/pro/activities/MainActivity.kt +++ b/app/src/main/kotlin/com/simplemobiletools/notes/pro/activities/MainActivity.kt @@ -77,7 +77,6 @@ class MainActivity : SimpleActivity() { private var searchIndex = 0 private var searchMatches = emptyList() private var isSearchActive = false - private val notesExporter by lazy { NotesExporter(this) } private lateinit var searchQueryET: MyEditText private lateinit var searchPrevBtn: ImageView @@ -883,6 +882,7 @@ class MainActivity : SimpleActivity() { private fun exportNotesTo(outputStream: OutputStream?) { toast(R.string.exporting) ensureBackgroundThread { + val notesExporter = NotesExporter(this) notesExporter.exportNotes(outputStream) { val toastId = when (it) { NotesExporter.ExportResult.EXPORT_OK -> R.string.exporting_successful From 6bd9500c8ce6281fec61b81f671f6521351ca566 Mon Sep 17 00:00:00 2001 From: Agnieszka C <85929121+Aga-C@users.noreply.github.com> Date: Tue, 8 Mar 2022 13:46:44 +0100 Subject: [PATCH 4/5] Removed onProgress --- .../com/simplemobiletools/notes/pro/helpers/NotesExporter.kt | 4 +--- .../com/simplemobiletools/notes/pro/helpers/NotesImporter.kt | 4 +--- 2 files changed, 2 insertions(+), 6 deletions(-) diff --git a/app/src/main/kotlin/com/simplemobiletools/notes/pro/helpers/NotesExporter.kt b/app/src/main/kotlin/com/simplemobiletools/notes/pro/helpers/NotesExporter.kt index 8aeeba5a..2a56d2d2 100644 --- a/app/src/main/kotlin/com/simplemobiletools/notes/pro/helpers/NotesExporter.kt +++ b/app/src/main/kotlin/com/simplemobiletools/notes/pro/helpers/NotesExporter.kt @@ -16,7 +16,7 @@ class NotesExporter(private val context: Context) { private val gson = Gson() - fun exportNotes(outputStream: OutputStream?, onProgress: (total: Int, current: Int) -> Unit = { _, _ -> }, callback: (result: ExportResult) -> Unit) { + fun exportNotes(outputStream: OutputStream?, callback: (result: ExportResult) -> Unit) { ensureBackgroundThread { if (outputStream == null) { callback.invoke(ExportResult.EXPORT_FAIL) @@ -28,13 +28,11 @@ class NotesExporter(private val context: Context) { var written = 0 writer.beginArray() val notes = context.notesDB.getNotes() as ArrayList - val totalNotes = notes.size for (note in notes) { if (note.protectionType === PROTECTION_NONE) { val noteToSave = getNoteToExport(note) writer.jsonValue(gson.toJson(noteToSave)) written++ - onProgress.invoke(totalNotes, written) } } writer.endArray() diff --git a/app/src/main/kotlin/com/simplemobiletools/notes/pro/helpers/NotesImporter.kt b/app/src/main/kotlin/com/simplemobiletools/notes/pro/helpers/NotesImporter.kt index e96384e2..86555d41 100644 --- a/app/src/main/kotlin/com/simplemobiletools/notes/pro/helpers/NotesImporter.kt +++ b/app/src/main/kotlin/com/simplemobiletools/notes/pro/helpers/NotesImporter.kt @@ -18,7 +18,7 @@ class NotesImporter(private val context: Context) { private var notesImported = 0 private var notesFailed = 0 - fun importNotes(path: String, onProgress: (total: Int, current: Int) -> Unit = { _, _ -> }, callback: (result: ImportResult) -> Unit) { + fun importNotes(path: String, callback: (result: ImportResult) -> Unit) { ensureBackgroundThread { try { val inputStream = if (path.contains("/")) { @@ -37,13 +37,11 @@ class NotesImporter(private val context: Context) { return@ensureBackgroundThread } - onProgress.invoke(totalNotes, notesImported) for (note in notes) { val exists = context.notesDB.getNoteIdWithTitle(note.title) != null if (!exists) { context.notesDB.insertOrUpdate(note) notesImported++ - onProgress.invoke(totalNotes, notesImported) } } } From 8c8a4d3d093fb8564a704391612410765bd075a9 Mon Sep 17 00:00:00 2001 From: Tibor Kaputa Date: Tue, 8 Mar 2022 18:18:59 +0100 Subject: [PATCH 5/5] updating the slovak translation --- app/src/main/res/values-sk/strings.xml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/src/main/res/values-sk/strings.xml b/app/src/main/res/values-sk/strings.xml index 64f6a7c5..52f3a40b 100644 --- a/app/src/main/res/values-sk/strings.xml +++ b/app/src/main/res/values-sk/strings.xml @@ -70,8 +70,8 @@ Exportovať všetky poznámky ako súbory Importovať priečinok - Export all notes - Import notes + Exportovať všetky poznámky + Importovať poznámky Ako viem zmeniť farby widgetu?