diff --git a/app/build.gradle b/app/build.gradle index 0f5ca0ef..334dacc2 100644 --- a/app/build.gradle +++ b/app/build.gradle @@ -11,7 +11,7 @@ android { buildToolsVersion "28.0.3" defaultConfig { - applicationId "com.simplemobiletools.notes" + applicationId "com.simplemobiletools.notes.pro" minSdkVersion 21 targetSdkVersion 28 versionCode 54 diff --git a/app/src/main/AndroidManifest.xml b/app/src/main/AndroidManifest.xml index 0fcdd7ad..1d30e984 100644 --- a/app/src/main/AndroidManifest.xml +++ b/app/src/main/AndroidManifest.xml @@ -2,7 +2,7 @@ diff --git a/app/src/main/kotlin/com/simplemobiletools/notes/App.kt b/app/src/main/kotlin/com/simplemobiletools/notes/pro/App.kt similarity index 84% rename from app/src/main/kotlin/com/simplemobiletools/notes/App.kt rename to app/src/main/kotlin/com/simplemobiletools/notes/pro/App.kt index 649c7c38..5885e823 100644 --- a/app/src/main/kotlin/com/simplemobiletools/notes/App.kt +++ b/app/src/main/kotlin/com/simplemobiletools/notes/pro/App.kt @@ -1,4 +1,4 @@ -package com.simplemobiletools.notes +package com.simplemobiletools.notes.pro import android.app.Application import com.simplemobiletools.commons.extensions.checkUseEnglish diff --git a/app/src/main/kotlin/com/simplemobiletools/notes/activities/MainActivity.kt b/app/src/main/kotlin/com/simplemobiletools/notes/pro/activities/MainActivity.kt similarity index 96% rename from app/src/main/kotlin/com/simplemobiletools/notes/activities/MainActivity.kt rename to app/src/main/kotlin/com/simplemobiletools/notes/pro/activities/MainActivity.kt index 7ae5a081..4f95f644 100644 --- a/app/src/main/kotlin/com/simplemobiletools/notes/activities/MainActivity.kt +++ b/app/src/main/kotlin/com/simplemobiletools/notes/pro/activities/MainActivity.kt @@ -1,4 +1,4 @@ -package com.simplemobiletools.notes.activities +package com.simplemobiletools.notes.pro.activities import android.content.Intent import android.net.Uri @@ -22,18 +22,18 @@ import com.simplemobiletools.commons.models.FileDirItem import com.simplemobiletools.commons.models.RadioItem import com.simplemobiletools.commons.models.Release import com.simplemobiletools.commons.views.MyEditText -import com.simplemobiletools.notes.BuildConfig -import com.simplemobiletools.notes.R -import com.simplemobiletools.notes.adapters.NotesPagerAdapter -import com.simplemobiletools.notes.dialogs.* -import com.simplemobiletools.notes.extensions.config -import com.simplemobiletools.notes.extensions.dbHelper -import com.simplemobiletools.notes.extensions.getTextSize -import com.simplemobiletools.notes.extensions.updateWidgets -import com.simplemobiletools.notes.helpers.MIME_TEXT_PLAIN -import com.simplemobiletools.notes.helpers.OPEN_NOTE_ID -import com.simplemobiletools.notes.helpers.TYPE_NOTE -import com.simplemobiletools.notes.models.Note +import com.simplemobiletools.notes.pro.BuildConfig +import com.simplemobiletools.notes.pro.R +import com.simplemobiletools.notes.pro.adapters.NotesPagerAdapter +import com.simplemobiletools.notes.pro.dialogs.* +import com.simplemobiletools.notes.pro.extensions.config +import com.simplemobiletools.notes.pro.extensions.dbHelper +import com.simplemobiletools.notes.pro.extensions.getTextSize +import com.simplemobiletools.notes.pro.extensions.updateWidgets +import com.simplemobiletools.notes.pro.helpers.MIME_TEXT_PLAIN +import com.simplemobiletools.notes.pro.helpers.OPEN_NOTE_ID +import com.simplemobiletools.notes.pro.helpers.TYPE_NOTE +import com.simplemobiletools.notes.pro.models.Note import kotlinx.android.synthetic.main.activity_main.* import java.io.File import java.nio.charset.Charset diff --git a/app/src/main/kotlin/com/simplemobiletools/notes/activities/SettingsActivity.kt b/app/src/main/kotlin/com/simplemobiletools/notes/pro/activities/SettingsActivity.kt similarity index 95% rename from app/src/main/kotlin/com/simplemobiletools/notes/activities/SettingsActivity.kt rename to app/src/main/kotlin/com/simplemobiletools/notes/pro/activities/SettingsActivity.kt index 588cd099..03d2caef 100644 --- a/app/src/main/kotlin/com/simplemobiletools/notes/activities/SettingsActivity.kt +++ b/app/src/main/kotlin/com/simplemobiletools/notes/pro/activities/SettingsActivity.kt @@ -1,4 +1,4 @@ -package com.simplemobiletools.notes.activities +package com.simplemobiletools.notes.pro.activities import android.content.Intent import android.os.Bundle @@ -9,11 +9,11 @@ import com.simplemobiletools.commons.extensions.updateTextColors import com.simplemobiletools.commons.helpers.IS_CUSTOMIZING_COLORS import com.simplemobiletools.commons.helpers.isOreoPlus import com.simplemobiletools.commons.models.RadioItem -import com.simplemobiletools.notes.R -import com.simplemobiletools.notes.extensions.config -import com.simplemobiletools.notes.extensions.dbHelper -import com.simplemobiletools.notes.extensions.updateWidgets -import com.simplemobiletools.notes.helpers.* +import com.simplemobiletools.notes.pro.R +import com.simplemobiletools.notes.pro.extensions.config +import com.simplemobiletools.notes.pro.extensions.dbHelper +import com.simplemobiletools.notes.pro.extensions.updateWidgets +import com.simplemobiletools.notes.pro.helpers.* import kotlinx.android.synthetic.main.activity_settings.* import java.util.* diff --git a/app/src/main/kotlin/com/simplemobiletools/notes/activities/SimpleActivity.kt b/app/src/main/kotlin/com/simplemobiletools/notes/pro/activities/SimpleActivity.kt similarity index 91% rename from app/src/main/kotlin/com/simplemobiletools/notes/activities/SimpleActivity.kt rename to app/src/main/kotlin/com/simplemobiletools/notes/pro/activities/SimpleActivity.kt index a322e5da..3c11eae2 100644 --- a/app/src/main/kotlin/com/simplemobiletools/notes/activities/SimpleActivity.kt +++ b/app/src/main/kotlin/com/simplemobiletools/notes/pro/activities/SimpleActivity.kt @@ -1,7 +1,7 @@ -package com.simplemobiletools.notes.activities +package com.simplemobiletools.notes.pro.activities import com.simplemobiletools.commons.activities.BaseSimpleActivity -import com.simplemobiletools.notes.R +import com.simplemobiletools.notes.pro.R open class SimpleActivity : BaseSimpleActivity() { override fun getAppIconIDs() = arrayListOf( diff --git a/app/src/main/kotlin/com/simplemobiletools/notes/activities/SplashActivity.kt b/app/src/main/kotlin/com/simplemobiletools/notes/pro/activities/SplashActivity.kt similarity index 83% rename from app/src/main/kotlin/com/simplemobiletools/notes/activities/SplashActivity.kt rename to app/src/main/kotlin/com/simplemobiletools/notes/pro/activities/SplashActivity.kt index e0f06329..f47128a7 100644 --- a/app/src/main/kotlin/com/simplemobiletools/notes/activities/SplashActivity.kt +++ b/app/src/main/kotlin/com/simplemobiletools/notes/pro/activities/SplashActivity.kt @@ -1,8 +1,8 @@ -package com.simplemobiletools.notes.activities +package com.simplemobiletools.notes.pro.activities import android.content.Intent import com.simplemobiletools.commons.activities.BaseSplashActivity -import com.simplemobiletools.notes.helpers.OPEN_NOTE_ID +import com.simplemobiletools.notes.pro.helpers.OPEN_NOTE_ID class SplashActivity : BaseSplashActivity() { override fun initActivity() { diff --git a/app/src/main/kotlin/com/simplemobiletools/notes/activities/WidgetConfigureActivity.kt b/app/src/main/kotlin/com/simplemobiletools/notes/pro/activities/WidgetConfigureActivity.kt similarity index 92% rename from app/src/main/kotlin/com/simplemobiletools/notes/activities/WidgetConfigureActivity.kt rename to app/src/main/kotlin/com/simplemobiletools/notes/pro/activities/WidgetConfigureActivity.kt index f017a8fd..ce661f4b 100644 --- a/app/src/main/kotlin/com/simplemobiletools/notes/activities/WidgetConfigureActivity.kt +++ b/app/src/main/kotlin/com/simplemobiletools/notes/pro/activities/WidgetConfigureActivity.kt @@ -1,4 +1,4 @@ -package com.simplemobiletools.notes.activities +package com.simplemobiletools.notes.pro.activities import android.app.Activity import android.appwidget.AppWidgetManager @@ -13,13 +13,13 @@ import com.simplemobiletools.commons.dialogs.RadioGroupDialog import com.simplemobiletools.commons.extensions.* import com.simplemobiletools.commons.helpers.IS_CUSTOMIZING_COLORS import com.simplemobiletools.commons.models.RadioItem -import com.simplemobiletools.notes.R -import com.simplemobiletools.notes.extensions.config -import com.simplemobiletools.notes.extensions.dbHelper -import com.simplemobiletools.notes.extensions.getTextSize -import com.simplemobiletools.notes.helpers.MyWidgetProvider -import com.simplemobiletools.notes.models.Note -import com.simplemobiletools.notes.models.Widget +import com.simplemobiletools.notes.pro.R +import com.simplemobiletools.notes.pro.extensions.config +import com.simplemobiletools.notes.pro.extensions.dbHelper +import com.simplemobiletools.notes.pro.extensions.getTextSize +import com.simplemobiletools.notes.pro.helpers.MyWidgetProvider +import com.simplemobiletools.notes.pro.models.Note +import com.simplemobiletools.notes.pro.models.Widget import kotlinx.android.synthetic.main.widget_config.* class WidgetConfigureActivity : SimpleActivity() { diff --git a/app/src/main/kotlin/com/simplemobiletools/notes/adapters/NotesPagerAdapter.kt b/app/src/main/kotlin/com/simplemobiletools/notes/pro/adapters/NotesPagerAdapter.kt similarity index 91% rename from app/src/main/kotlin/com/simplemobiletools/notes/adapters/NotesPagerAdapter.kt rename to app/src/main/kotlin/com/simplemobiletools/notes/pro/adapters/NotesPagerAdapter.kt index 24ee1fc2..66013c2f 100644 --- a/app/src/main/kotlin/com/simplemobiletools/notes/adapters/NotesPagerAdapter.kt +++ b/app/src/main/kotlin/com/simplemobiletools/notes/pro/adapters/NotesPagerAdapter.kt @@ -1,4 +1,4 @@ -package com.simplemobiletools.notes.adapters +package com.simplemobiletools.notes.pro.adapters import android.app.Activity import android.os.Bundle @@ -6,9 +6,9 @@ import android.view.ViewGroup import androidx.fragment.app.FragmentManager import androidx.fragment.app.FragmentStatePagerAdapter import com.simplemobiletools.commons.extensions.showErrorToast -import com.simplemobiletools.notes.fragments.NoteFragment -import com.simplemobiletools.notes.helpers.NOTE_ID -import com.simplemobiletools.notes.models.Note +import com.simplemobiletools.notes.pro.fragments.NoteFragment +import com.simplemobiletools.notes.pro.helpers.NOTE_ID +import com.simplemobiletools.notes.pro.models.Note class NotesPagerAdapter(fm: FragmentManager, val notes: List, val activity: Activity) : FragmentStatePagerAdapter(fm) { private var fragments: HashMap = LinkedHashMap() diff --git a/app/src/main/kotlin/com/simplemobiletools/notes/adapters/WidgetAdapter.kt b/app/src/main/kotlin/com/simplemobiletools/notes/pro/adapters/WidgetAdapter.kt similarity index 79% rename from app/src/main/kotlin/com/simplemobiletools/notes/adapters/WidgetAdapter.kt rename to app/src/main/kotlin/com/simplemobiletools/notes/pro/adapters/WidgetAdapter.kt index 5a273dd4..0e612df3 100644 --- a/app/src/main/kotlin/com/simplemobiletools/notes/adapters/WidgetAdapter.kt +++ b/app/src/main/kotlin/com/simplemobiletools/notes/pro/adapters/WidgetAdapter.kt @@ -1,4 +1,4 @@ -package com.simplemobiletools.notes.adapters +package com.simplemobiletools.notes.pro.adapters import android.content.Context import android.content.Intent @@ -7,15 +7,15 @@ import android.widget.RemoteViews import android.widget.RemoteViewsService import com.simplemobiletools.commons.extensions.setText import com.simplemobiletools.commons.extensions.setTextSize -import com.simplemobiletools.notes.R -import com.simplemobiletools.notes.R.id.widget_text_holder -import com.simplemobiletools.notes.extensions.config -import com.simplemobiletools.notes.extensions.dbHelper -import com.simplemobiletools.notes.extensions.getTextSize -import com.simplemobiletools.notes.helpers.GRAVITY_CENTER -import com.simplemobiletools.notes.helpers.GRAVITY_RIGHT -import com.simplemobiletools.notes.helpers.NOTE_ID -import com.simplemobiletools.notes.helpers.OPEN_NOTE_ID +import com.simplemobiletools.notes.pro.R +import com.simplemobiletools.notes.pro.R.id.widget_text_holder +import com.simplemobiletools.notes.pro.extensions.config +import com.simplemobiletools.notes.pro.extensions.dbHelper +import com.simplemobiletools.notes.pro.extensions.getTextSize +import com.simplemobiletools.notes.pro.helpers.GRAVITY_CENTER +import com.simplemobiletools.notes.pro.helpers.GRAVITY_RIGHT +import com.simplemobiletools.notes.pro.helpers.NOTE_ID +import com.simplemobiletools.notes.pro.helpers.OPEN_NOTE_ID class WidgetAdapter(val context: Context, val intent: Intent) : RemoteViewsService.RemoteViewsFactory { private val textIds = arrayOf(R.id.widget_text_left, R.id.widget_text_center, R.id.widget_text_right) diff --git a/app/src/main/kotlin/com/simplemobiletools/notes/dialogs/DeleteNoteDialog.kt b/app/src/main/kotlin/com/simplemobiletools/notes/pro/dialogs/DeleteNoteDialog.kt similarity index 86% rename from app/src/main/kotlin/com/simplemobiletools/notes/dialogs/DeleteNoteDialog.kt rename to app/src/main/kotlin/com/simplemobiletools/notes/pro/dialogs/DeleteNoteDialog.kt index 87c02722..b176d0f5 100644 --- a/app/src/main/kotlin/com/simplemobiletools/notes/dialogs/DeleteNoteDialog.kt +++ b/app/src/main/kotlin/com/simplemobiletools/notes/pro/dialogs/DeleteNoteDialog.kt @@ -1,11 +1,11 @@ -package com.simplemobiletools.notes.dialogs +package com.simplemobiletools.notes.pro.dialogs import androidx.appcompat.app.AlertDialog import com.simplemobiletools.commons.extensions.beVisible import com.simplemobiletools.commons.extensions.setupDialogStuff -import com.simplemobiletools.notes.R -import com.simplemobiletools.notes.activities.SimpleActivity -import com.simplemobiletools.notes.models.Note +import com.simplemobiletools.notes.pro.R +import com.simplemobiletools.notes.pro.activities.SimpleActivity +import com.simplemobiletools.notes.pro.models.Note import kotlinx.android.synthetic.main.dialog_delete_note.view.* class DeleteNoteDialog(val activity: SimpleActivity, val note: Note, val callback: (deleteFile: Boolean) -> Unit) { diff --git a/app/src/main/kotlin/com/simplemobiletools/notes/dialogs/ExportFileDialog.kt b/app/src/main/kotlin/com/simplemobiletools/notes/pro/dialogs/ExportFileDialog.kt similarity index 90% rename from app/src/main/kotlin/com/simplemobiletools/notes/dialogs/ExportFileDialog.kt rename to app/src/main/kotlin/com/simplemobiletools/notes/pro/dialogs/ExportFileDialog.kt index 2861016f..d96b65fd 100644 --- a/app/src/main/kotlin/com/simplemobiletools/notes/dialogs/ExportFileDialog.kt +++ b/app/src/main/kotlin/com/simplemobiletools/notes/pro/dialogs/ExportFileDialog.kt @@ -1,12 +1,12 @@ -package com.simplemobiletools.notes.dialogs +package com.simplemobiletools.notes.pro.dialogs import androidx.appcompat.app.AlertDialog import com.simplemobiletools.commons.dialogs.FilePickerDialog import com.simplemobiletools.commons.extensions.* -import com.simplemobiletools.notes.R -import com.simplemobiletools.notes.activities.SimpleActivity -import com.simplemobiletools.notes.extensions.config -import com.simplemobiletools.notes.models.Note +import com.simplemobiletools.notes.pro.R +import com.simplemobiletools.notes.pro.activities.SimpleActivity +import com.simplemobiletools.notes.pro.extensions.config +import com.simplemobiletools.notes.pro.models.Note import kotlinx.android.synthetic.main.dialog_export_file.view.* import java.io.File diff --git a/app/src/main/kotlin/com/simplemobiletools/notes/dialogs/ExportFilesDialog.kt b/app/src/main/kotlin/com/simplemobiletools/notes/pro/dialogs/ExportFilesDialog.kt similarity index 88% rename from app/src/main/kotlin/com/simplemobiletools/notes/dialogs/ExportFilesDialog.kt rename to app/src/main/kotlin/com/simplemobiletools/notes/pro/dialogs/ExportFilesDialog.kt index 40e10ea5..b01f8028 100644 --- a/app/src/main/kotlin/com/simplemobiletools/notes/dialogs/ExportFilesDialog.kt +++ b/app/src/main/kotlin/com/simplemobiletools/notes/pro/dialogs/ExportFilesDialog.kt @@ -1,4 +1,4 @@ -package com.simplemobiletools.notes.dialogs +package com.simplemobiletools.notes.pro.dialogs import androidx.appcompat.app.AlertDialog import com.simplemobiletools.commons.dialogs.FilePickerDialog @@ -6,10 +6,10 @@ import com.simplemobiletools.commons.extensions.humanizePath import com.simplemobiletools.commons.extensions.setupDialogStuff import com.simplemobiletools.commons.extensions.showKeyboard import com.simplemobiletools.commons.extensions.value -import com.simplemobiletools.notes.R -import com.simplemobiletools.notes.activities.SimpleActivity -import com.simplemobiletools.notes.extensions.config -import com.simplemobiletools.notes.models.Note +import com.simplemobiletools.notes.pro.R +import com.simplemobiletools.notes.pro.activities.SimpleActivity +import com.simplemobiletools.notes.pro.extensions.config +import com.simplemobiletools.notes.pro.models.Note import kotlinx.android.synthetic.main.dialog_export_files.view.* class ExportFilesDialog(val activity: SimpleActivity, val notes: ArrayList, val callback: (parent: String, extension: String) -> Unit) { diff --git a/app/src/main/kotlin/com/simplemobiletools/notes/dialogs/ImportFolderDialog.kt b/app/src/main/kotlin/com/simplemobiletools/notes/pro/dialogs/ImportFolderDialog.kt similarity index 89% rename from app/src/main/kotlin/com/simplemobiletools/notes/dialogs/ImportFolderDialog.kt rename to app/src/main/kotlin/com/simplemobiletools/notes/pro/dialogs/ImportFolderDialog.kt index 3b80bb5b..a91e3a8b 100644 --- a/app/src/main/kotlin/com/simplemobiletools/notes/dialogs/ImportFolderDialog.kt +++ b/app/src/main/kotlin/com/simplemobiletools/notes/pro/dialogs/ImportFolderDialog.kt @@ -1,4 +1,4 @@ -package com.simplemobiletools.notes.dialogs +package com.simplemobiletools.notes.pro.dialogs import android.view.ViewGroup import androidx.appcompat.app.AlertDialog @@ -6,11 +6,11 @@ import com.simplemobiletools.commons.extensions.getFilenameFromPath import com.simplemobiletools.commons.extensions.humanizePath import com.simplemobiletools.commons.extensions.isMediaFile import com.simplemobiletools.commons.extensions.setupDialogStuff -import com.simplemobiletools.notes.R -import com.simplemobiletools.notes.activities.SimpleActivity -import com.simplemobiletools.notes.extensions.dbHelper -import com.simplemobiletools.notes.helpers.TYPE_NOTE -import com.simplemobiletools.notes.models.Note +import com.simplemobiletools.notes.pro.R +import com.simplemobiletools.notes.pro.activities.SimpleActivity +import com.simplemobiletools.notes.pro.extensions.dbHelper +import com.simplemobiletools.notes.pro.helpers.TYPE_NOTE +import com.simplemobiletools.notes.pro.models.Note import kotlinx.android.synthetic.main.dialog_import_folder.view.* import java.io.File diff --git a/app/src/main/kotlin/com/simplemobiletools/notes/dialogs/NewNoteDialog.kt b/app/src/main/kotlin/com/simplemobiletools/notes/pro/dialogs/NewNoteDialog.kt similarity index 91% rename from app/src/main/kotlin/com/simplemobiletools/notes/dialogs/NewNoteDialog.kt rename to app/src/main/kotlin/com/simplemobiletools/notes/pro/dialogs/NewNoteDialog.kt index c7c2b9e1..7040084b 100644 --- a/app/src/main/kotlin/com/simplemobiletools/notes/dialogs/NewNoteDialog.kt +++ b/app/src/main/kotlin/com/simplemobiletools/notes/pro/dialogs/NewNoteDialog.kt @@ -1,4 +1,4 @@ -package com.simplemobiletools.notes.dialogs +package com.simplemobiletools.notes.pro.dialogs import android.app.Activity import android.content.DialogInterface.BUTTON_POSITIVE @@ -7,8 +7,8 @@ import com.simplemobiletools.commons.extensions.setupDialogStuff import com.simplemobiletools.commons.extensions.showKeyboard import com.simplemobiletools.commons.extensions.toast import com.simplemobiletools.commons.extensions.value -import com.simplemobiletools.notes.R -import com.simplemobiletools.notes.helpers.DBHelper +import com.simplemobiletools.notes.pro.R +import com.simplemobiletools.notes.pro.helpers.DBHelper import kotlinx.android.synthetic.main.dialog_new_note.view.* class NewNoteDialog(val activity: Activity, val db: DBHelper, callback: (title: String) -> Unit) { diff --git a/app/src/main/kotlin/com/simplemobiletools/notes/dialogs/OpenFileDialog.kt b/app/src/main/kotlin/com/simplemobiletools/notes/pro/dialogs/OpenFileDialog.kt similarity index 84% rename from app/src/main/kotlin/com/simplemobiletools/notes/dialogs/OpenFileDialog.kt rename to app/src/main/kotlin/com/simplemobiletools/notes/pro/dialogs/OpenFileDialog.kt index b3ed2473..a8e85403 100644 --- a/app/src/main/kotlin/com/simplemobiletools/notes/dialogs/OpenFileDialog.kt +++ b/app/src/main/kotlin/com/simplemobiletools/notes/pro/dialogs/OpenFileDialog.kt @@ -1,15 +1,15 @@ -package com.simplemobiletools.notes.dialogs +package com.simplemobiletools.notes.pro.dialogs import android.view.ViewGroup import androidx.appcompat.app.AlertDialog import com.simplemobiletools.commons.extensions.getFilenameFromPath import com.simplemobiletools.commons.extensions.humanizePath import com.simplemobiletools.commons.extensions.setupDialogStuff -import com.simplemobiletools.notes.R -import com.simplemobiletools.notes.R.id.open_file_update_file -import com.simplemobiletools.notes.activities.SimpleActivity -import com.simplemobiletools.notes.helpers.TYPE_NOTE -import com.simplemobiletools.notes.models.Note +import com.simplemobiletools.notes.pro.R +import com.simplemobiletools.notes.pro.activities.SimpleActivity +import com.simplemobiletools.notes.pro.helpers.TYPE_NOTE +import com.simplemobiletools.notes.pro.models.Note +import kotlinx.android.synthetic.main.dialog_open_file.* import kotlinx.android.synthetic.main.dialog_open_file.view.* import java.io.File @@ -27,7 +27,7 @@ class OpenFileDialog(val activity: SimpleActivity, val path: String, val callbac .create().apply { activity.setupDialogStuff(view, this, R.string.open_file) { getButton(AlertDialog.BUTTON_POSITIVE).setOnClickListener { - val updateFileOnEdit = view.open_file_type.checkedRadioButtonId == open_file_update_file + val updateFileOnEdit = view.open_file_type.checkedRadioButtonId == open_file_update_file.id val storePath = if (updateFileOnEdit) path else "" val storeContent = if (updateFileOnEdit) "" else File(path).readText() diff --git a/app/src/main/kotlin/com/simplemobiletools/notes/dialogs/OpenNoteDialog.kt b/app/src/main/kotlin/com/simplemobiletools/notes/pro/dialogs/OpenNoteDialog.kt similarity index 90% rename from app/src/main/kotlin/com/simplemobiletools/notes/dialogs/OpenNoteDialog.kt rename to app/src/main/kotlin/com/simplemobiletools/notes/pro/dialogs/OpenNoteDialog.kt index 1092b953..eb07f3f6 100644 --- a/app/src/main/kotlin/com/simplemobiletools/notes/dialogs/OpenNoteDialog.kt +++ b/app/src/main/kotlin/com/simplemobiletools/notes/pro/dialogs/OpenNoteDialog.kt @@ -1,4 +1,4 @@ -package com.simplemobiletools.notes.dialogs +package com.simplemobiletools.notes.pro.dialogs import android.app.Activity import android.view.ViewGroup @@ -8,9 +8,9 @@ import com.simplemobiletools.commons.extensions.applyColorFilter import com.simplemobiletools.commons.extensions.beVisibleIf import com.simplemobiletools.commons.extensions.setupDialogStuff import com.simplemobiletools.commons.extensions.toast -import com.simplemobiletools.notes.R -import com.simplemobiletools.notes.extensions.config -import com.simplemobiletools.notes.extensions.dbHelper +import com.simplemobiletools.notes.pro.R +import com.simplemobiletools.notes.pro.extensions.config +import com.simplemobiletools.notes.pro.extensions.dbHelper import kotlinx.android.synthetic.main.dialog_open_note.view.* import kotlinx.android.synthetic.main.open_note_item.view.* diff --git a/app/src/main/kotlin/com/simplemobiletools/notes/dialogs/RenameNoteDialog.kt b/app/src/main/kotlin/com/simplemobiletools/notes/pro/dialogs/RenameNoteDialog.kt similarity index 92% rename from app/src/main/kotlin/com/simplemobiletools/notes/dialogs/RenameNoteDialog.kt rename to app/src/main/kotlin/com/simplemobiletools/notes/pro/dialogs/RenameNoteDialog.kt index f271d349..2051a2c3 100644 --- a/app/src/main/kotlin/com/simplemobiletools/notes/dialogs/RenameNoteDialog.kt +++ b/app/src/main/kotlin/com/simplemobiletools/notes/pro/dialogs/RenameNoteDialog.kt @@ -1,12 +1,12 @@ -package com.simplemobiletools.notes.dialogs +package com.simplemobiletools.notes.pro.dialogs import android.content.DialogInterface.BUTTON_POSITIVE import androidx.appcompat.app.AlertDialog import com.simplemobiletools.commons.extensions.* -import com.simplemobiletools.notes.R -import com.simplemobiletools.notes.activities.SimpleActivity -import com.simplemobiletools.notes.extensions.dbHelper -import com.simplemobiletools.notes.models.Note +import com.simplemobiletools.notes.pro.R +import com.simplemobiletools.notes.pro.activities.SimpleActivity +import com.simplemobiletools.notes.pro.extensions.dbHelper +import com.simplemobiletools.notes.pro.models.Note import kotlinx.android.synthetic.main.dialog_new_note.view.* import java.io.File diff --git a/app/src/main/kotlin/com/simplemobiletools/notes/extensions/Context.kt b/app/src/main/kotlin/com/simplemobiletools/notes/pro/extensions/Context.kt similarity index 88% rename from app/src/main/kotlin/com/simplemobiletools/notes/extensions/Context.kt rename to app/src/main/kotlin/com/simplemobiletools/notes/pro/extensions/Context.kt index fd7b20fc..fb674abf 100644 --- a/app/src/main/kotlin/com/simplemobiletools/notes/extensions/Context.kt +++ b/app/src/main/kotlin/com/simplemobiletools/notes/pro/extensions/Context.kt @@ -1,11 +1,11 @@ -package com.simplemobiletools.notes.extensions +package com.simplemobiletools.notes.pro.extensions import android.appwidget.AppWidgetManager import android.content.ComponentName import android.content.Context import android.content.Intent -import com.simplemobiletools.notes.R -import com.simplemobiletools.notes.helpers.* +import com.simplemobiletools.notes.pro.R +import com.simplemobiletools.notes.pro.helpers.* val Context.config: Config get() = Config.newInstance(applicationContext) diff --git a/app/src/main/kotlin/com/simplemobiletools/notes/extensions/Fragment.kt b/app/src/main/kotlin/com/simplemobiletools/notes/pro/extensions/Fragment.kt similarity index 56% rename from app/src/main/kotlin/com/simplemobiletools/notes/extensions/Fragment.kt rename to app/src/main/kotlin/com/simplemobiletools/notes/pro/extensions/Fragment.kt index abd584f6..4a1bc2ee 100644 --- a/app/src/main/kotlin/com/simplemobiletools/notes/extensions/Fragment.kt +++ b/app/src/main/kotlin/com/simplemobiletools/notes/pro/extensions/Fragment.kt @@ -1,6 +1,6 @@ -package com.simplemobiletools.notes.extensions +package com.simplemobiletools.notes.pro.extensions import androidx.fragment.app.Fragment -import com.simplemobiletools.notes.helpers.Config +import com.simplemobiletools.notes.pro.helpers.Config val Fragment.config: Config? get() = if (context != null) Config.newInstance(context!!) else null diff --git a/app/src/main/kotlin/com/simplemobiletools/notes/fragments/NoteFragment.kt b/app/src/main/kotlin/com/simplemobiletools/notes/pro/fragments/NoteFragment.kt similarity index 93% rename from app/src/main/kotlin/com/simplemobiletools/notes/fragments/NoteFragment.kt rename to app/src/main/kotlin/com/simplemobiletools/notes/pro/fragments/NoteFragment.kt index 86290443..82aa46df 100644 --- a/app/src/main/kotlin/com/simplemobiletools/notes/fragments/NoteFragment.kt +++ b/app/src/main/kotlin/com/simplemobiletools/notes/pro/fragments/NoteFragment.kt @@ -1,4 +1,4 @@ -package com.simplemobiletools.notes.fragments +package com.simplemobiletools.notes.pro.fragments import android.annotation.SuppressLint import android.graphics.Typeface @@ -17,16 +17,16 @@ import android.view.ViewGroup import android.view.inputmethod.EditorInfo import androidx.annotation.RequiresApi import com.simplemobiletools.commons.extensions.* -import com.simplemobiletools.notes.R -import com.simplemobiletools.notes.activities.MainActivity -import com.simplemobiletools.notes.extensions.config -import com.simplemobiletools.notes.extensions.dbHelper -import com.simplemobiletools.notes.extensions.getTextSize -import com.simplemobiletools.notes.extensions.updateWidgets -import com.simplemobiletools.notes.helpers.* -import com.simplemobiletools.notes.models.Note -import com.simplemobiletools.notes.models.TextHistory -import com.simplemobiletools.notes.models.TextHistoryItem +import com.simplemobiletools.notes.pro.R +import com.simplemobiletools.notes.pro.activities.MainActivity +import com.simplemobiletools.notes.pro.extensions.config +import com.simplemobiletools.notes.pro.extensions.dbHelper +import com.simplemobiletools.notes.pro.extensions.getTextSize +import com.simplemobiletools.notes.pro.extensions.updateWidgets +import com.simplemobiletools.notes.pro.helpers.* +import com.simplemobiletools.notes.pro.models.Note +import com.simplemobiletools.notes.pro.models.TextHistory +import com.simplemobiletools.notes.pro.models.TextHistoryItem import kotlinx.android.synthetic.main.fragment_note.* import kotlinx.android.synthetic.main.fragment_note.view.* import kotlinx.android.synthetic.main.note_view_horiz_scrollable.view.* diff --git a/app/src/main/kotlin/com/simplemobiletools/notes/helpers/Config.kt b/app/src/main/kotlin/com/simplemobiletools/notes/pro/helpers/Config.kt similarity index 98% rename from app/src/main/kotlin/com/simplemobiletools/notes/helpers/Config.kt rename to app/src/main/kotlin/com/simplemobiletools/notes/pro/helpers/Config.kt index 62347ff5..41b9808c 100644 --- a/app/src/main/kotlin/com/simplemobiletools/notes/helpers/Config.kt +++ b/app/src/main/kotlin/com/simplemobiletools/notes/pro/helpers/Config.kt @@ -1,4 +1,4 @@ -package com.simplemobiletools.notes.helpers +package com.simplemobiletools.notes.pro.helpers import android.content.Context import android.os.Environment diff --git a/app/src/main/kotlin/com/simplemobiletools/notes/helpers/Constants.kt b/app/src/main/kotlin/com/simplemobiletools/notes/pro/helpers/Constants.kt similarity index 96% rename from app/src/main/kotlin/com/simplemobiletools/notes/helpers/Constants.kt rename to app/src/main/kotlin/com/simplemobiletools/notes/pro/helpers/Constants.kt index f8745be0..a48417a0 100644 --- a/app/src/main/kotlin/com/simplemobiletools/notes/helpers/Constants.kt +++ b/app/src/main/kotlin/com/simplemobiletools/notes/pro/helpers/Constants.kt @@ -1,4 +1,4 @@ -package com.simplemobiletools.notes.helpers +package com.simplemobiletools.notes.pro.helpers const val NOTE_ID = "note_id" const val OPEN_NOTE_ID = "open_note_id" diff --git a/app/src/main/kotlin/com/simplemobiletools/notes/helpers/DBHelper.kt b/app/src/main/kotlin/com/simplemobiletools/notes/pro/helpers/DBHelper.kt similarity index 97% rename from app/src/main/kotlin/com/simplemobiletools/notes/helpers/DBHelper.kt rename to app/src/main/kotlin/com/simplemobiletools/notes/pro/helpers/DBHelper.kt index 0b90dbd8..d1d01c96 100644 --- a/app/src/main/kotlin/com/simplemobiletools/notes/helpers/DBHelper.kt +++ b/app/src/main/kotlin/com/simplemobiletools/notes/pro/helpers/DBHelper.kt @@ -1,4 +1,4 @@ -package com.simplemobiletools.notes.helpers +package com.simplemobiletools.notes.pro.helpers import android.appwidget.AppWidgetManager import android.content.ComponentName @@ -10,10 +10,10 @@ import android.database.sqlite.SQLiteDatabase.CONFLICT_IGNORE import android.database.sqlite.SQLiteOpenHelper import com.simplemobiletools.commons.extensions.getIntValue import com.simplemobiletools.commons.extensions.getStringValue -import com.simplemobiletools.notes.R -import com.simplemobiletools.notes.extensions.config -import com.simplemobiletools.notes.models.Note -import com.simplemobiletools.notes.models.Widget +import com.simplemobiletools.notes.pro.R +import com.simplemobiletools.notes.pro.extensions.config +import com.simplemobiletools.notes.pro.models.Note +import com.simplemobiletools.notes.pro.models.Widget import java.io.File import java.util.* diff --git a/app/src/main/kotlin/com/simplemobiletools/notes/helpers/MyMovementMethod.kt b/app/src/main/kotlin/com/simplemobiletools/notes/pro/helpers/MyMovementMethod.kt similarity index 97% rename from app/src/main/kotlin/com/simplemobiletools/notes/helpers/MyMovementMethod.kt rename to app/src/main/kotlin/com/simplemobiletools/notes/pro/helpers/MyMovementMethod.kt index 4e76d179..90a5fed4 100644 --- a/app/src/main/kotlin/com/simplemobiletools/notes/helpers/MyMovementMethod.kt +++ b/app/src/main/kotlin/com/simplemobiletools/notes/pro/helpers/MyMovementMethod.kt @@ -1,4 +1,4 @@ -package com.simplemobiletools.notes.helpers +package com.simplemobiletools.notes.pro.helpers import android.text.Selection import android.text.Spannable diff --git a/app/src/main/kotlin/com/simplemobiletools/notes/helpers/MyWidgetProvider.kt b/app/src/main/kotlin/com/simplemobiletools/notes/pro/helpers/MyWidgetProvider.kt similarity index 85% rename from app/src/main/kotlin/com/simplemobiletools/notes/helpers/MyWidgetProvider.kt rename to app/src/main/kotlin/com/simplemobiletools/notes/pro/helpers/MyWidgetProvider.kt index 3f76af3f..9654c917 100644 --- a/app/src/main/kotlin/com/simplemobiletools/notes/helpers/MyWidgetProvider.kt +++ b/app/src/main/kotlin/com/simplemobiletools/notes/pro/helpers/MyWidgetProvider.kt @@ -1,4 +1,4 @@ -package com.simplemobiletools.notes.helpers +package com.simplemobiletools.notes.pro.helpers import android.app.PendingIntent import android.appwidget.AppWidgetManager @@ -9,12 +9,12 @@ import android.net.Uri import android.widget.RemoteViews import com.simplemobiletools.commons.extensions.getLaunchIntent import com.simplemobiletools.commons.extensions.setBackgroundColor -import com.simplemobiletools.notes.R -import com.simplemobiletools.notes.activities.SplashActivity -import com.simplemobiletools.notes.extensions.config -import com.simplemobiletools.notes.extensions.dbHelper -import com.simplemobiletools.notes.models.Widget -import com.simplemobiletools.notes.services.WidgetService +import com.simplemobiletools.notes.pro.R +import com.simplemobiletools.notes.pro.activities.SplashActivity +import com.simplemobiletools.notes.pro.extensions.config +import com.simplemobiletools.notes.pro.extensions.dbHelper +import com.simplemobiletools.notes.pro.models.Widget +import com.simplemobiletools.notes.pro.services.WidgetService class MyWidgetProvider : AppWidgetProvider() { private fun setupAppOpenIntent(context: Context, views: RemoteViews, id: Int, widget: Widget) { diff --git a/app/src/main/kotlin/com/simplemobiletools/notes/models/Note.kt b/app/src/main/kotlin/com/simplemobiletools/notes/pro/models/Note.kt similarity index 90% rename from app/src/main/kotlin/com/simplemobiletools/notes/models/Note.kt rename to app/src/main/kotlin/com/simplemobiletools/notes/pro/models/Note.kt index cc35314d..3b462d2e 100644 --- a/app/src/main/kotlin/com/simplemobiletools/notes/models/Note.kt +++ b/app/src/main/kotlin/com/simplemobiletools/notes/pro/models/Note.kt @@ -1,4 +1,4 @@ -package com.simplemobiletools.notes.models +package com.simplemobiletools.notes.pro.models import java.io.File import java.io.FileNotFoundException diff --git a/app/src/main/kotlin/com/simplemobiletools/notes/models/TextHistory.kt b/app/src/main/kotlin/com/simplemobiletools/notes/pro/models/TextHistory.kt similarity index 93% rename from app/src/main/kotlin/com/simplemobiletools/notes/models/TextHistory.kt rename to app/src/main/kotlin/com/simplemobiletools/notes/pro/models/TextHistory.kt index e3d76165..3de176e6 100644 --- a/app/src/main/kotlin/com/simplemobiletools/notes/models/TextHistory.kt +++ b/app/src/main/kotlin/com/simplemobiletools/notes/pro/models/TextHistory.kt @@ -1,4 +1,4 @@ -package com.simplemobiletools.notes.models +package com.simplemobiletools.notes.pro.models import java.util.* diff --git a/app/src/main/kotlin/com/simplemobiletools/notes/models/TextHistoryItem.kt b/app/src/main/kotlin/com/simplemobiletools/notes/pro/models/TextHistoryItem.kt similarity index 67% rename from app/src/main/kotlin/com/simplemobiletools/notes/models/TextHistoryItem.kt rename to app/src/main/kotlin/com/simplemobiletools/notes/pro/models/TextHistoryItem.kt index e96c3cb1..72d7d720 100644 --- a/app/src/main/kotlin/com/simplemobiletools/notes/models/TextHistoryItem.kt +++ b/app/src/main/kotlin/com/simplemobiletools/notes/pro/models/TextHistoryItem.kt @@ -1,3 +1,3 @@ -package com.simplemobiletools.notes.models +package com.simplemobiletools.notes.pro.models data class TextHistoryItem(val start: Int, val before: CharSequence?, val after: CharSequence?) diff --git a/app/src/main/kotlin/com/simplemobiletools/notes/models/Widget.kt b/app/src/main/kotlin/com/simplemobiletools/notes/pro/models/Widget.kt similarity index 53% rename from app/src/main/kotlin/com/simplemobiletools/notes/models/Widget.kt rename to app/src/main/kotlin/com/simplemobiletools/notes/pro/models/Widget.kt index e2107a0b..34eff9c2 100644 --- a/app/src/main/kotlin/com/simplemobiletools/notes/models/Widget.kt +++ b/app/src/main/kotlin/com/simplemobiletools/notes/pro/models/Widget.kt @@ -1,3 +1,3 @@ -package com.simplemobiletools.notes.models +package com.simplemobiletools.notes.pro.models data class Widget(var widgetId: Int, var noteId: Int) diff --git a/app/src/main/kotlin/com/simplemobiletools/notes/services/WidgetService.kt b/app/src/main/kotlin/com/simplemobiletools/notes/pro/services/WidgetService.kt similarity index 65% rename from app/src/main/kotlin/com/simplemobiletools/notes/services/WidgetService.kt rename to app/src/main/kotlin/com/simplemobiletools/notes/pro/services/WidgetService.kt index da8244e2..f313220a 100644 --- a/app/src/main/kotlin/com/simplemobiletools/notes/services/WidgetService.kt +++ b/app/src/main/kotlin/com/simplemobiletools/notes/pro/services/WidgetService.kt @@ -1,8 +1,8 @@ -package com.simplemobiletools.notes.services +package com.simplemobiletools.notes.pro.services import android.content.Intent import android.widget.RemoteViewsService -import com.simplemobiletools.notes.adapters.WidgetAdapter +import com.simplemobiletools.notes.pro.adapters.WidgetAdapter class WidgetService : RemoteViewsService() { override fun onGetViewFactory(intent: Intent) = WidgetAdapter(applicationContext, intent) diff --git a/app/src/main/kotlin/com/simplemobiletools/notes/views/MyHorizontalScrollView.kt b/app/src/main/kotlin/com/simplemobiletools/notes/pro/views/MyHorizontalScrollView.kt similarity index 91% rename from app/src/main/kotlin/com/simplemobiletools/notes/views/MyHorizontalScrollView.kt rename to app/src/main/kotlin/com/simplemobiletools/notes/pro/views/MyHorizontalScrollView.kt index 30b8fbe9..51383591 100644 --- a/app/src/main/kotlin/com/simplemobiletools/notes/views/MyHorizontalScrollView.kt +++ b/app/src/main/kotlin/com/simplemobiletools/notes/pro/views/MyHorizontalScrollView.kt @@ -1,4 +1,4 @@ -package com.simplemobiletools.notes.views +package com.simplemobiletools.notes.pro.views import android.content.Context import android.util.AttributeSet diff --git a/app/src/main/res/layout/note_view_horiz_scrollable.xml b/app/src/main/res/layout/note_view_horiz_scrollable.xml index 514c6a5d..3b2e07b8 100644 --- a/app/src/main/res/layout/note_view_horiz_scrollable.xml +++ b/app/src/main/res/layout/note_view_horiz_scrollable.xml @@ -1,5 +1,5 @@ - - + diff --git a/app/src/main/res/xml/widget_info.xml b/app/src/main/res/xml/widget_info.xml index 95c08e25..942ca566 100644 --- a/app/src/main/res/xml/widget_info.xml +++ b/app/src/main/res/xml/widget_info.xml @@ -1,7 +1,7 @@