From 9712fe249df5c9ca66eabb5e4999c0ab4b42c23b Mon Sep 17 00:00:00 2001 From: tibbi Date: Mon, 6 Mar 2017 18:54:00 +0100 Subject: [PATCH] couple small tweaks here and there --- .../com/simplemobiletools/notes/dialogs/RenameNoteDialog.kt | 3 +-- .../main/kotlin/com/simplemobiletools/notes/models/Note.kt | 6 +----- app/src/main/res/values-de/strings.xml | 1 + app/src/main/res/values-es/strings.xml | 1 + app/src/main/res/values-fr/strings.xml | 1 + app/src/main/res/values-hu/strings.xml | 1 + app/src/main/res/values-it/strings.xml | 1 + app/src/main/res/values-ja/strings.xml | 1 + app/src/main/res/values-pt-rPT/strings.xml | 1 + app/src/main/res/values-sv/strings.xml | 1 + app/src/main/res/values/donottranslate.xml | 3 --- app/src/main/res/values/strings.xml | 1 + 12 files changed, 11 insertions(+), 10 deletions(-) delete mode 100644 app/src/main/res/values/donottranslate.xml diff --git a/app/src/main/kotlin/com/simplemobiletools/notes/dialogs/RenameNoteDialog.kt b/app/src/main/kotlin/com/simplemobiletools/notes/dialogs/RenameNoteDialog.kt index 26a43422..a229f931 100644 --- a/app/src/main/kotlin/com/simplemobiletools/notes/dialogs/RenameNoteDialog.kt +++ b/app/src/main/kotlin/com/simplemobiletools/notes/dialogs/RenameNoteDialog.kt @@ -3,7 +3,6 @@ package com.simplemobiletools.notes.dialogs import android.app.Activity import android.content.DialogInterface.BUTTON_POSITIVE import android.support.v7.app.AlertDialog -import android.view.LayoutInflater import android.view.WindowManager import com.simplemobiletools.commons.extensions.setupDialogStuff import com.simplemobiletools.commons.extensions.toast @@ -16,7 +15,7 @@ import kotlinx.android.synthetic.main.new_note.view.* class RenameNoteDialog(val activity: Activity, val db: DBHelper, val note: Note, callback: (note: Note) -> Unit) { init { - val view = LayoutInflater.from(activity).inflate(R.layout.rename_note, null) + val view = activity.layoutInflater.inflate(R.layout.rename_note, null) view.note_name.setText(note.title) AlertDialog.Builder(activity) diff --git a/app/src/main/kotlin/com/simplemobiletools/notes/models/Note.kt b/app/src/main/kotlin/com/simplemobiletools/notes/models/Note.kt index 0a1afdc1..697f50c0 100644 --- a/app/src/main/kotlin/com/simplemobiletools/notes/models/Note.kt +++ b/app/src/main/kotlin/com/simplemobiletools/notes/models/Note.kt @@ -1,8 +1,4 @@ package com.simplemobiletools.notes.models -class Note(var id: Int, var title: String, var value: String, val type: Int) { +data class Note(var id: Int, var title: String, var value: String, val type: Int) - override fun equals(other: Any?) = other != null && this.toString() == other.toString() - - override fun toString() = "Note {id=$id, title=$title, value=$value, type=$type}" -} diff --git a/app/src/main/res/values-de/strings.xml b/app/src/main/res/values-de/strings.xml index 88fd274a..e27e8542 100644 --- a/app/src/main/res/values-de/strings.xml +++ b/app/src/main/res/values-de/strings.xml @@ -1,4 +1,5 @@ + Simple Notes Notizen Vielen dank, dass du Simple Notes benutzt.\nWeitere einfache Apps findest du auf SimpleMobileTools.com.\n Leerer Text kann nicht geteilt werden diff --git a/app/src/main/res/values-es/strings.xml b/app/src/main/res/values-es/strings.xml index 617672e8..32e27434 100644 --- a/app/src/main/res/values-es/strings.xml +++ b/app/src/main/res/values-es/strings.xml @@ -1,4 +1,5 @@ + Simple Notes Notas Gracias por usar Simple Notes.\nPara más aplicaciones simples, por favor visite SimpleMobileTools.com.\n No se puede compartir una nota vacía diff --git a/app/src/main/res/values-fr/strings.xml b/app/src/main/res/values-fr/strings.xml index a4da09a7..6fafbec7 100644 --- a/app/src/main/res/values-fr/strings.xml +++ b/app/src/main/res/values-fr/strings.xml @@ -1,4 +1,5 @@ + Simple Notes Notes Merci d\'utiliser Simple Notes.\nPour plus d\'applications simples merci de visiter SimpleMobileTools.com.\n Impossible de partager un texte vide diff --git a/app/src/main/res/values-hu/strings.xml b/app/src/main/res/values-hu/strings.xml index 7b395ea8..274ded13 100644 --- a/app/src/main/res/values-hu/strings.xml +++ b/app/src/main/res/values-hu/strings.xml @@ -1,4 +1,5 @@ + Egyszerű Jegyzetek Jegyzetek Köszönjük, hogy az Egyszerű Jegyzetfüzetet használod.\nTovábbi egyszerű alkalmazásokért látogass a SimpleMobileTools.com-ra.\n Nem létező szöveget nem lehet megosztani diff --git a/app/src/main/res/values-it/strings.xml b/app/src/main/res/values-it/strings.xml index 9a290887..300c721e 100644 --- a/app/src/main/res/values-it/strings.xml +++ b/app/src/main/res/values-it/strings.xml @@ -1,4 +1,5 @@ + Simple Notes Notes Grazie per avere scelto Simple Notes.\nPer altre semplici app visita SimpleMobileTools.com.\n Impossibile condividere un testo vuoto diff --git a/app/src/main/res/values-ja/strings.xml b/app/src/main/res/values-ja/strings.xml index 7f13db06..a76ed89a 100644 --- a/app/src/main/res/values-ja/strings.xml +++ b/app/src/main/res/values-ja/strings.xml @@ -1,4 +1,5 @@  + Simple Notes メモ シンプルメモのご利用ありがとうございます。\n他のシンプルアプリは SimpleMobileTools.com をご覧ください。\n 空のテキストは共有できません diff --git a/app/src/main/res/values-pt-rPT/strings.xml b/app/src/main/res/values-pt-rPT/strings.xml index 8b11ee0f..399860b9 100644 --- a/app/src/main/res/values-pt-rPT/strings.xml +++ b/app/src/main/res/values-pt-rPT/strings.xml @@ -1,4 +1,5 @@ + Simple Notes Notas Obrigado por usar o Simple Notes.\nPara mais aplicações Simple, aceda a SimpleMobileTools.com.\n Não pode partilhar texto em branco diff --git a/app/src/main/res/values-sv/strings.xml b/app/src/main/res/values-sv/strings.xml index cd871c10..1753351b 100644 --- a/app/src/main/res/values-sv/strings.xml +++ b/app/src/main/res/values-sv/strings.xml @@ -1,4 +1,5 @@ + Simple Notes Notes Tack för att du använder Simple Notes.\nFör fler enkla appar, gå till simplemobiletools.com.\n Det går inte att dela utan text diff --git a/app/src/main/res/values/donottranslate.xml b/app/src/main/res/values/donottranslate.xml deleted file mode 100644 index 0c93cc05..00000000 --- a/app/src/main/res/values/donottranslate.xml +++ /dev/null @@ -1,3 +0,0 @@ - - Simple Notes - diff --git a/app/src/main/res/values/strings.xml b/app/src/main/res/values/strings.xml index 3dacd79b..566c3193 100644 --- a/app/src/main/res/values/strings.xml +++ b/app/src/main/res/values/strings.xml @@ -1,4 +1,5 @@ + Simple Notes Notes Thank you for using Simple Notes.\nFor more simple apps please visit SimpleMobileTools.com.\n Cannot share empty text