diff --git a/app/build.gradle b/app/build.gradle index 2fcb26f..f75da92 100644 --- a/app/build.gradle +++ b/app/build.gradle @@ -9,7 +9,7 @@ android { compileSdk 32 defaultConfig { - applicationId "space.taran.arkshelf" + applicationId "dev.arkbuilders.arkshelf" minSdk 26 targetSdk 32 versionCode 1 @@ -67,7 +67,7 @@ android { } dependencies { - implementation "space.taran:arklib:0.1.0-SNAPSHOT-f81e34a657" + implementation "dev.arkbuilders:arklib:0.3.3" implementation 'androidx.core:core-ktx:1.7.0' implementation 'androidx.appcompat:appcompat:1.4.1' @@ -90,7 +90,7 @@ dependencies { implementation "org.orbit-mvi:orbit-viewmodel:4.3.2" implementation "com.ericktijerou.koleton:koleton:1.0.0-beta01" - implementation 'com.github.ARK-Builders:ark-filepicker:c6d66141c1' + implementation 'dev.arkbuilders:arkfilepicker:0.1.1' testImplementation 'junit:junit:4.+' androidTestImplementation 'androidx.test.ext:junit:1.1.3' diff --git a/app/src/androidTest/java/space/taran/arkshelf/ExampleInstrumentedTest.kt b/app/src/androidTest/java/dev/arkbuilders/arkshelf/ExampleInstrumentedTest.kt similarity index 84% rename from app/src/androidTest/java/space/taran/arkshelf/ExampleInstrumentedTest.kt rename to app/src/androidTest/java/dev/arkbuilders/arkshelf/ExampleInstrumentedTest.kt index 928c288..e08773a 100644 --- a/app/src/androidTest/java/space/taran/arkshelf/ExampleInstrumentedTest.kt +++ b/app/src/androidTest/java/dev/arkbuilders/arkshelf/ExampleInstrumentedTest.kt @@ -1,4 +1,4 @@ -package space.taran.arkshelf +package dev.arkbuilders.arkshelf import androidx.test.platform.app.InstrumentationRegistry import androidx.test.ext.junit.runners.AndroidJUnit4 @@ -19,6 +19,6 @@ class ExampleInstrumentedTest { fun useAppContext() { // Context of the app under test. val appContext = InstrumentationRegistry.getInstrumentation().targetContext - assertEquals("space.taran.arkshelf", appContext.packageName) + assertEquals("dev.arkbuilders.arkshelf", appContext.packageName) } } \ No newline at end of file diff --git a/app/src/main/AndroidManifest.xml b/app/src/main/AndroidManifest.xml index bab5176..1b286b5 100644 --- a/app/src/main/AndroidManifest.xml +++ b/app/src/main/AndroidManifest.xml @@ -1,7 +1,7 @@ + package="dev.arkbuilders.arkshelf"> diff --git a/app/src/main/java/space/taran/arkshelf/data/LinkLocalDataSource.kt b/app/src/main/java/dev/arkbuilders/arkshelf/data/LinkLocalDataSource.kt similarity index 84% rename from app/src/main/java/space/taran/arkshelf/data/LinkLocalDataSource.kt rename to app/src/main/java/dev/arkbuilders/arkshelf/data/LinkLocalDataSource.kt index bd0d0cd..9fa6a3b 100644 --- a/app/src/main/java/space/taran/arkshelf/data/LinkLocalDataSource.kt +++ b/app/src/main/java/dev/arkbuilders/arkshelf/data/LinkLocalDataSource.kt @@ -1,17 +1,17 @@ -package space.taran.arkshelf.data +package dev.arkbuilders.arkshelf.data +import dev.arkbuilders.arkfilepicker.folders.FoldersRepo import kotlinx.coroutines.Dispatchers import kotlinx.coroutines.async import kotlinx.coroutines.awaitAll import kotlinx.coroutines.withContext -import space.taran.arkfilepicker.folders.FoldersRepo -import space.taran.arklib.arkFolder -import space.taran.arklib.arkPreviews -import space.taran.arklib.getLinkHash -import space.taran.arklib.loadLinkFile -import space.taran.arkshelf.domain.Link -import space.taran.arkshelf.domain.UserPreferences -import space.taran.arkshelf.presentation.listChildren +import dev.arkbuilders.arklib.arkFolder +import dev.arkbuilders.arklib.arkPreviews +import dev.arkbuilders.arklib.getLinkHash +import dev.arkbuilders.arklib.loadLinkFile +import dev.arkbuilders.arkshelf.domain.Link +import dev.arkbuilders.arkshelf.domain.UserPreferences +import dev.arkbuilders.arkshelf.presentation.listChildren import timber.log.Timber import java.nio.file.Path import javax.inject.Inject @@ -21,7 +21,7 @@ import kotlin.io.path.exists import kotlin.io.path.extension import kotlin.io.path.getLastModifiedTime import kotlin.io.path.isDirectory -import space.taran.arklib.createLinkFile as createLinkFileN +import dev.arkbuilders.arklib.createLinkFile as createLinkFileN class LinkLocalDataSource @Inject constructor( diff --git a/app/src/main/java/space/taran/arkshelf/data/LinkRemoteDataSource.kt b/app/src/main/java/dev/arkbuilders/arkshelf/data/LinkRemoteDataSource.kt similarity index 91% rename from app/src/main/java/space/taran/arkshelf/data/LinkRemoteDataSource.kt rename to app/src/main/java/dev/arkbuilders/arkshelf/data/LinkRemoteDataSource.kt index e21e5ec..8c102c1 100644 --- a/app/src/main/java/space/taran/arkshelf/data/LinkRemoteDataSource.kt +++ b/app/src/main/java/dev/arkbuilders/arkshelf/data/LinkRemoteDataSource.kt @@ -1,10 +1,10 @@ -package space.taran.arkshelf.data +package dev.arkbuilders.arkshelf.data import android.content.Context import android.graphics.Bitmap import com.bumptech.glide.Glide -import space.taran.arklib.fetchLinkData -import space.taran.arkshelf.domain.Link +import dev.arkbuilders.arklib.fetchLinkData +import dev.arkbuilders.arkshelf.domain.Link import java.nio.file.Path import javax.inject.Inject import kotlin.io.path.createTempFile diff --git a/app/src/main/java/space/taran/arkshelf/data/LinkRepoImpl.kt b/app/src/main/java/dev/arkbuilders/arkshelf/data/LinkRepoImpl.kt similarity index 77% rename from app/src/main/java/space/taran/arkshelf/data/LinkRepoImpl.kt rename to app/src/main/java/dev/arkbuilders/arkshelf/data/LinkRepoImpl.kt index cfd56a1..9892ef5 100644 --- a/app/src/main/java/space/taran/arkshelf/data/LinkRepoImpl.kt +++ b/app/src/main/java/dev/arkbuilders/arkshelf/data/LinkRepoImpl.kt @@ -1,11 +1,11 @@ -package space.taran.arkshelf.data +package dev.arkbuilders.arkshelf.data import kotlinx.coroutines.Dispatchers import kotlinx.coroutines.withContext -import space.taran.arkshelf.data.network.NetworkStatus -import space.taran.arkshelf.domain.Link -import space.taran.arkshelf.domain.LinkRepo -import space.taran.arkshelf.domain.NoInternetException +import dev.arkbuilders.arkshelf.data.network.NetworkStatus +import dev.arkbuilders.arkshelf.domain.Link +import dev.arkbuilders.arkshelf.domain.LinkRepo +import dev.arkbuilders.arkshelf.domain.NoInternetException import java.nio.file.Path import javax.inject.Inject diff --git a/app/src/main/java/space/taran/arkshelf/data/UserPreferencesImpl.kt b/app/src/main/java/dev/arkbuilders/arkshelf/data/UserPreferencesImpl.kt similarity index 84% rename from app/src/main/java/space/taran/arkshelf/data/UserPreferencesImpl.kt rename to app/src/main/java/dev/arkbuilders/arkshelf/data/UserPreferencesImpl.kt index d31a01d..4538829 100644 --- a/app/src/main/java/space/taran/arkshelf/data/UserPreferencesImpl.kt +++ b/app/src/main/java/dev/arkbuilders/arkshelf/data/UserPreferencesImpl.kt @@ -1,8 +1,7 @@ -package space.taran.arkshelf.data +package dev.arkbuilders.arkshelf.data import android.content.Context -import android.os.Environment -import space.taran.arkshelf.domain.UserPreferences +import dev.arkbuilders.arkshelf.domain.UserPreferences import java.nio.file.Path import javax.inject.Inject import kotlin.io.path.Path diff --git a/app/src/main/java/space/taran/arkshelf/data/network/NetworkStatus.kt b/app/src/main/java/dev/arkbuilders/arkshelf/data/network/NetworkStatus.kt similarity index 54% rename from app/src/main/java/space/taran/arkshelf/data/network/NetworkStatus.kt rename to app/src/main/java/dev/arkbuilders/arkshelf/data/network/NetworkStatus.kt index 6bb69ac..957740b 100644 --- a/app/src/main/java/space/taran/arkshelf/data/network/NetworkStatus.kt +++ b/app/src/main/java/dev/arkbuilders/arkshelf/data/network/NetworkStatus.kt @@ -1,4 +1,4 @@ -package space.taran.arkshelf.data.network +package dev.arkbuilders.arkshelf.data.network interface NetworkStatus { fun isOnline(): Boolean diff --git a/app/src/main/java/space/taran/arkshelf/data/network/NetworkStatusImpl.kt b/app/src/main/java/dev/arkbuilders/arkshelf/data/network/NetworkStatusImpl.kt similarity index 94% rename from app/src/main/java/space/taran/arkshelf/data/network/NetworkStatusImpl.kt rename to app/src/main/java/dev/arkbuilders/arkshelf/data/network/NetworkStatusImpl.kt index e84e9f7..92bc0ad 100644 --- a/app/src/main/java/space/taran/arkshelf/data/network/NetworkStatusImpl.kt +++ b/app/src/main/java/dev/arkbuilders/arkshelf/data/network/NetworkStatusImpl.kt @@ -1,10 +1,9 @@ -package space.taran.arkshelf.data.network +package dev.arkbuilders.arkshelf.data.network import android.content.Context import android.net.ConnectivityManager import android.net.Network import android.net.NetworkCapabilities -import android.net.NetworkRequest import android.os.Build import javax.inject.Inject diff --git a/app/src/main/java/space/taran/arkshelf/di/AppComponent.kt b/app/src/main/java/dev/arkbuilders/arkshelf/di/AppComponent.kt similarity index 70% rename from app/src/main/java/space/taran/arkshelf/di/AppComponent.kt rename to app/src/main/java/dev/arkbuilders/arkshelf/di/AppComponent.kt index 05ad741..b28cd76 100644 --- a/app/src/main/java/space/taran/arkshelf/di/AppComponent.kt +++ b/app/src/main/java/dev/arkbuilders/arkshelf/di/AppComponent.kt @@ -1,12 +1,12 @@ -package space.taran.arkshelf.di +package dev.arkbuilders.arkshelf.di import android.app.Application import android.content.Context import dagger.BindsInstance import dagger.Component -import space.taran.arkshelf.di.module.RepoModule -import space.taran.arkshelf.presentation.searchedit.SearchEditFragment -import space.taran.arkshelf.presentation.settings.SettingsFragment +import dev.arkbuilders.arkshelf.di.module.RepoModule +import dev.arkbuilders.arkshelf.presentation.searchedit.SearchEditFragment +import dev.arkbuilders.arkshelf.presentation.settings.SettingsFragment import javax.inject.Singleton @Singleton diff --git a/app/src/main/java/space/taran/arkshelf/di/DIManager.kt b/app/src/main/java/dev/arkbuilders/arkshelf/di/DIManager.kt similarity index 86% rename from app/src/main/java/space/taran/arkshelf/di/DIManager.kt rename to app/src/main/java/dev/arkbuilders/arkshelf/di/DIManager.kt index 12bdc6d..39e7d6d 100644 --- a/app/src/main/java/space/taran/arkshelf/di/DIManager.kt +++ b/app/src/main/java/dev/arkbuilders/arkshelf/di/DIManager.kt @@ -1,4 +1,4 @@ -package space.taran.arkshelf.di +package dev.arkbuilders.arkshelf.di import android.app.Application diff --git a/app/src/main/java/space/taran/arkshelf/di/module/RepoModule.kt b/app/src/main/java/dev/arkbuilders/arkshelf/di/module/RepoModule.kt similarity index 51% rename from app/src/main/java/space/taran/arkshelf/di/module/RepoModule.kt rename to app/src/main/java/dev/arkbuilders/arkshelf/di/module/RepoModule.kt index 73948f6..ba7d27c 100644 --- a/app/src/main/java/space/taran/arkshelf/di/module/RepoModule.kt +++ b/app/src/main/java/dev/arkbuilders/arkshelf/di/module/RepoModule.kt @@ -1,13 +1,13 @@ -package space.taran.arkshelf.di.module +package dev.arkbuilders.arkshelf.di.module import dagger.Binds import dagger.Module -import space.taran.arkshelf.data.LinkRepoImpl -import space.taran.arkshelf.data.UserPreferencesImpl -import space.taran.arkshelf.data.network.NetworkStatus -import space.taran.arkshelf.data.network.NetworkStatusImpl -import space.taran.arkshelf.domain.LinkRepo -import space.taran.arkshelf.domain.UserPreferences +import dev.arkbuilders.arkshelf.data.LinkRepoImpl +import dev.arkbuilders.arkshelf.data.UserPreferencesImpl +import dev.arkbuilders.arkshelf.data.network.NetworkStatus +import dev.arkbuilders.arkshelf.data.network.NetworkStatusImpl +import dev.arkbuilders.arkshelf.domain.LinkRepo +import dev.arkbuilders.arkshelf.domain.UserPreferences import javax.inject.Singleton @Module diff --git a/app/src/main/java/space/taran/arkshelf/domain/Link.kt b/app/src/main/java/dev/arkbuilders/arkshelf/domain/Link.kt similarity index 77% rename from app/src/main/java/space/taran/arkshelf/domain/Link.kt rename to app/src/main/java/dev/arkbuilders/arkshelf/domain/Link.kt index 8766794..31ca0f6 100644 --- a/app/src/main/java/space/taran/arkshelf/domain/Link.kt +++ b/app/src/main/java/dev/arkbuilders/arkshelf/domain/Link.kt @@ -1,4 +1,4 @@ -package space.taran.arkshelf.domain +package dev.arkbuilders.arkshelf.domain import java.nio.file.Path diff --git a/app/src/main/java/space/taran/arkshelf/domain/LinkRepo.kt b/app/src/main/java/dev/arkbuilders/arkshelf/domain/LinkRepo.kt similarity index 83% rename from app/src/main/java/space/taran/arkshelf/domain/LinkRepo.kt rename to app/src/main/java/dev/arkbuilders/arkshelf/domain/LinkRepo.kt index b0dd677..2ac9807 100644 --- a/app/src/main/java/space/taran/arkshelf/domain/LinkRepo.kt +++ b/app/src/main/java/dev/arkbuilders/arkshelf/domain/LinkRepo.kt @@ -1,4 +1,4 @@ -package space.taran.arkshelf.domain +package dev.arkbuilders.arkshelf.domain import java.nio.file.Path diff --git a/app/src/main/java/dev/arkbuilders/arkshelf/domain/NoInternetException.kt b/app/src/main/java/dev/arkbuilders/arkshelf/domain/NoInternetException.kt new file mode 100644 index 0000000..c83b8c1 --- /dev/null +++ b/app/src/main/java/dev/arkbuilders/arkshelf/domain/NoInternetException.kt @@ -0,0 +1,3 @@ +package dev.arkbuilders.arkshelf.domain + +class NoInternetException: Exception() \ No newline at end of file diff --git a/app/src/main/java/space/taran/arkshelf/domain/UserPreferences.kt b/app/src/main/java/dev/arkbuilders/arkshelf/domain/UserPreferences.kt similarity index 75% rename from app/src/main/java/space/taran/arkshelf/domain/UserPreferences.kt rename to app/src/main/java/dev/arkbuilders/arkshelf/domain/UserPreferences.kt index b7867ec..908eb42 100644 --- a/app/src/main/java/space/taran/arkshelf/domain/UserPreferences.kt +++ b/app/src/main/java/dev/arkbuilders/arkshelf/domain/UserPreferences.kt @@ -1,4 +1,4 @@ -package space.taran.arkshelf.domain +package dev.arkbuilders.arkshelf.domain import java.nio.file.Path diff --git a/app/src/main/java/space/taran/arkshelf/presentation/App.kt b/app/src/main/java/dev/arkbuilders/arkshelf/presentation/App.kt similarity index 57% rename from app/src/main/java/space/taran/arkshelf/presentation/App.kt rename to app/src/main/java/dev/arkbuilders/arkshelf/presentation/App.kt index 44d905f..568f1de 100644 --- a/app/src/main/java/space/taran/arkshelf/presentation/App.kt +++ b/app/src/main/java/dev/arkbuilders/arkshelf/presentation/App.kt @@ -1,13 +1,10 @@ -package space.taran.arkshelf.presentation +package dev.arkbuilders.arkshelf.presentation import android.app.Application -import kotlinx.coroutines.CoroutineScope -import kotlinx.coroutines.Dispatchers -import kotlinx.coroutines.launch -import space.taran.arkfilepicker.folders.FoldersRepo -import space.taran.arklib.initArkLib -import space.taran.arklib.initRustLogger -import space.taran.arkshelf.di.DIManager +import dev.arkbuilders.arkfilepicker.folders.FoldersRepo +import dev.arkbuilders.arklib.initArkLib +import dev.arkbuilders.arklib.initRustLogger +import dev.arkbuilders.arkshelf.di.DIManager import timber.log.Timber class App : Application() { diff --git a/app/src/main/java/space/taran/arkshelf/presentation/LogTags.kt b/app/src/main/java/dev/arkbuilders/arkshelf/presentation/LogTags.kt similarity index 56% rename from app/src/main/java/space/taran/arkshelf/presentation/LogTags.kt rename to app/src/main/java/dev/arkbuilders/arkshelf/presentation/LogTags.kt index 6407e29..f2a06b9 100644 --- a/app/src/main/java/space/taran/arkshelf/presentation/LogTags.kt +++ b/app/src/main/java/dev/arkbuilders/arkshelf/presentation/LogTags.kt @@ -1,4 +1,4 @@ -package space.taran.arkshelf.presentation +package dev.arkbuilders.arkshelf.presentation object LogTags { const val OKHTTP: String = "okhttp" diff --git a/app/src/main/java/space/taran/arkshelf/presentation/RelaxedTransitionListener.kt b/app/src/main/java/dev/arkbuilders/arkshelf/presentation/RelaxedTransitionListener.kt similarity index 95% rename from app/src/main/java/space/taran/arkshelf/presentation/RelaxedTransitionListener.kt rename to app/src/main/java/dev/arkbuilders/arkshelf/presentation/RelaxedTransitionListener.kt index 94a2797..c713b06 100644 --- a/app/src/main/java/space/taran/arkshelf/presentation/RelaxedTransitionListener.kt +++ b/app/src/main/java/dev/arkbuilders/arkshelf/presentation/RelaxedTransitionListener.kt @@ -1,4 +1,4 @@ -package space.taran.arkshelf.presentation +package dev.arkbuilders.arkshelf.presentation import androidx.constraintlayout.motion.widget.MotionLayout diff --git a/app/src/main/java/space/taran/arkshelf/presentation/Utils.kt b/app/src/main/java/dev/arkbuilders/arkshelf/presentation/Utils.kt similarity index 94% rename from app/src/main/java/space/taran/arkshelf/presentation/Utils.kt rename to app/src/main/java/dev/arkbuilders/arkshelf/presentation/Utils.kt index cc696d4..532acdc 100644 --- a/app/src/main/java/space/taran/arkshelf/presentation/Utils.kt +++ b/app/src/main/java/dev/arkbuilders/arkshelf/presentation/Utils.kt @@ -1,4 +1,4 @@ -package space.taran.arkshelf.presentation +package dev.arkbuilders.arkshelf.presentation import android.Manifest import android.content.Intent @@ -18,12 +18,10 @@ import kotlinx.coroutines.launch import kotlinx.coroutines.sync.Mutex import kotlinx.coroutines.sync.withLock import kotlinx.coroutines.withContext -import space.taran.arkshelf.BuildConfig -import space.taran.arkshelf.R -import space.taran.arkshelf.presentation.main.MainActivity +import dev.arkbuilders.arkshelf.BuildConfig +import dev.arkbuilders.arkshelf.presentation.main.MainActivity import java.nio.file.Path import java.nio.file.Paths -import java.text.DecimalFormat import kotlin.coroutines.CoroutineContext import kotlin.io.path.Path import kotlin.io.path.isHidden diff --git a/app/src/main/java/space/taran/arkshelf/presentation/main/MainActivity.kt b/app/src/main/java/dev/arkbuilders/arkshelf/presentation/main/MainActivity.kt similarity index 87% rename from app/src/main/java/space/taran/arkshelf/presentation/main/MainActivity.kt rename to app/src/main/java/dev/arkbuilders/arkshelf/presentation/main/MainActivity.kt index 8bedb57..fe47364 100644 --- a/app/src/main/java/space/taran/arkshelf/presentation/main/MainActivity.kt +++ b/app/src/main/java/dev/arkbuilders/arkshelf/presentation/main/MainActivity.kt @@ -1,15 +1,13 @@ -package space.taran.arkshelf.presentation.main +package dev.arkbuilders.arkshelf.presentation.main import android.content.Intent import android.os.Bundle -import android.util.Log import androidx.appcompat.app.AppCompatActivity import by.kirich1409.viewbindingdelegate.viewBinding -import space.taran.arklib.initRustLogger -import space.taran.arkshelf.R -import space.taran.arkshelf.databinding.ActivityMainBinding -import space.taran.arkshelf.presentation.searchedit.SearchEditFragment -import space.taran.arkshelf.presentation.settings.SettingsFragment +import dev.arkbuilders.arkshelf.R +import dev.arkbuilders.arkshelf.databinding.ActivityMainBinding +import dev.arkbuilders.arkshelf.presentation.searchedit.SearchEditFragment +import dev.arkbuilders.arkshelf.presentation.settings.SettingsFragment class MainActivity : AppCompatActivity(R.layout.activity_main) { private val binding by viewBinding(ActivityMainBinding::bind) diff --git a/app/src/main/java/space/taran/arkshelf/presentation/searchedit/LinkListAdapter.kt b/app/src/main/java/dev/arkbuilders/arkshelf/presentation/searchedit/LinkListAdapter.kt similarity index 95% rename from app/src/main/java/space/taran/arkshelf/presentation/searchedit/LinkListAdapter.kt rename to app/src/main/java/dev/arkbuilders/arkshelf/presentation/searchedit/LinkListAdapter.kt index f086194..bd3be04 100644 --- a/app/src/main/java/space/taran/arkshelf/presentation/searchedit/LinkListAdapter.kt +++ b/app/src/main/java/dev/arkbuilders/arkshelf/presentation/searchedit/LinkListAdapter.kt @@ -1,4 +1,4 @@ -package space.taran.arkshelf.presentation.searchedit +package dev.arkbuilders.arkshelf.presentation.searchedit import android.content.ClipData import android.content.ClipboardManager @@ -8,16 +8,14 @@ import android.net.Uri import android.view.LayoutInflater import android.view.ViewGroup import android.widget.Toast -import androidx.paging.PagingDataAdapter import androidx.recyclerview.widget.DiffUtil import androidx.recyclerview.widget.RecyclerView import com.bumptech.glide.Glide import com.bumptech.glide.load.resource.bitmap.CenterCrop import com.bumptech.glide.load.resource.bitmap.RoundedCorners -import kotlinx.coroutines.CoroutineScope -import space.taran.arkshelf.R -import space.taran.arkshelf.databinding.ItemLinkBinding -import space.taran.arkshelf.domain.Link +import dev.arkbuilders.arkshelf.R +import dev.arkbuilders.arkshelf.databinding.ItemLinkBinding +import dev.arkbuilders.arkshelf.domain.Link class LinkListAdapter( private val context: Context, diff --git a/app/src/main/java/space/taran/arkshelf/presentation/searchedit/SearchEditFragment.kt b/app/src/main/java/dev/arkbuilders/arkshelf/presentation/searchedit/SearchEditFragment.kt similarity index 89% rename from app/src/main/java/space/taran/arkshelf/presentation/searchedit/SearchEditFragment.kt rename to app/src/main/java/dev/arkbuilders/arkshelf/presentation/searchedit/SearchEditFragment.kt index 95e600a..3644a02 100644 --- a/app/src/main/java/space/taran/arkshelf/presentation/searchedit/SearchEditFragment.kt +++ b/app/src/main/java/dev/arkbuilders/arkshelf/presentation/searchedit/SearchEditFragment.kt @@ -1,4 +1,4 @@ -package space.taran.arkshelf.presentation.searchedit +package dev.arkbuilders.arkshelf.presentation.searchedit import android.content.Context import android.os.Bundle @@ -12,28 +12,27 @@ import androidx.fragment.app.Fragment import androidx.fragment.app.setFragmentResultListener import androidx.fragment.app.viewModels import androidx.lifecycle.lifecycleScope -import androidx.paging.LoadState import by.kirich1409.viewbindingdelegate.viewBinding import com.bumptech.glide.Glide import com.bumptech.glide.load.engine.DiskCacheStrategy +import dev.arkbuilders.arkfilepicker.ArkFilePickerConfig +import dev.arkbuilders.arkfilepicker.presentation.filepicker.ArkFilePickerFragment +import dev.arkbuilders.arkfilepicker.presentation.filepicker.ArkFilePickerMode +import dev.arkbuilders.arkfilepicker.presentation.onArkPathPicked import koleton.api.hideSkeleton import koleton.api.loadSkeleton import kotlinx.coroutines.Dispatchers import kotlinx.coroutines.launch import kotlinx.coroutines.withContext import org.orbitmvi.orbit.viewmodel.observe -import space.taran.arkfilepicker.ArkFilePickerConfig -import space.taran.arkfilepicker.presentation.filepicker.ArkFilePickerFragment -import space.taran.arkfilepicker.presentation.filepicker.ArkFilePickerMode -import space.taran.arkfilepicker.presentation.onArkPathPicked -import space.taran.arkshelf.R -import space.taran.arkshelf.databinding.FragmentSearchEditBinding -import space.taran.arkshelf.di.DIManager -import space.taran.arkshelf.domain.NoInternetException -import space.taran.arkshelf.presentation.askWritePermissions -import space.taran.arkshelf.presentation.hideKeyboard -import space.taran.arkshelf.presentation.isWritePermGranted -import space.taran.arkshelf.presentation.main.MainActivity +import dev.arkbuilders.arkshelf.R +import dev.arkbuilders.arkshelf.databinding.FragmentSearchEditBinding +import dev.arkbuilders.arkshelf.di.DIManager +import dev.arkbuilders.arkshelf.domain.NoInternetException +import dev.arkbuilders.arkshelf.presentation.askWritePermissions +import dev.arkbuilders.arkshelf.presentation.hideKeyboard +import dev.arkbuilders.arkshelf.presentation.isWritePermGranted +import dev.arkbuilders.arkshelf.presentation.main.MainActivity import java.net.UnknownHostException import javax.inject.Inject @@ -58,7 +57,7 @@ class SearchEditFragment : Fragment(R.layout.fragment_search_edit) { initUI() initResultListener() checkWritePermissions() - viewModel.observe(this, ::render, ::handleSideEffect) + viewModel.observe(lifecycleOwner = this, state = ::render, sideEffect = ::handleSideEffect) handleShareIntent() } diff --git a/app/src/main/java/space/taran/arkshelf/presentation/searchedit/SearchEditViewModel.kt b/app/src/main/java/dev/arkbuilders/arkshelf/presentation/searchedit/SearchEditViewModel.kt similarity index 96% rename from app/src/main/java/space/taran/arkshelf/presentation/searchedit/SearchEditViewModel.kt rename to app/src/main/java/dev/arkbuilders/arkshelf/presentation/searchedit/SearchEditViewModel.kt index b0f6936..cc0afbd 100644 --- a/app/src/main/java/space/taran/arkshelf/presentation/searchedit/SearchEditViewModel.kt +++ b/app/src/main/java/dev/arkbuilders/arkshelf/presentation/searchedit/SearchEditViewModel.kt @@ -1,4 +1,4 @@ -package space.taran.arkshelf.presentation.searchedit +package dev.arkbuilders.arkshelf.presentation.searchedit import androidx.lifecycle.ViewModel import androidx.lifecycle.ViewModelProvider @@ -14,9 +14,9 @@ import org.orbitmvi.orbit.syntax.simple.intent import org.orbitmvi.orbit.syntax.simple.postSideEffect import org.orbitmvi.orbit.syntax.simple.reduce import org.orbitmvi.orbit.viewmodel.container -import space.taran.arkshelf.domain.Link -import space.taran.arkshelf.domain.LinkRepo -import space.taran.arkshelf.domain.UserPreferences +import dev.arkbuilders.arkshelf.domain.Link +import dev.arkbuilders.arkshelf.domain.LinkRepo +import dev.arkbuilders.arkshelf.domain.UserPreferences import java.nio.file.Path data class SearchEditState( diff --git a/app/src/main/java/space/taran/arkshelf/presentation/settings/SettingsFragment.kt b/app/src/main/java/dev/arkbuilders/arkshelf/presentation/settings/SettingsFragment.kt similarity index 78% rename from app/src/main/java/space/taran/arkshelf/presentation/settings/SettingsFragment.kt rename to app/src/main/java/dev/arkbuilders/arkshelf/presentation/settings/SettingsFragment.kt index 3c215c2..a2c8efc 100644 --- a/app/src/main/java/space/taran/arkshelf/presentation/settings/SettingsFragment.kt +++ b/app/src/main/java/dev/arkbuilders/arkshelf/presentation/settings/SettingsFragment.kt @@ -1,4 +1,4 @@ -package space.taran.arkshelf.presentation.settings +package dev.arkbuilders.arkshelf.presentation.settings import android.content.Context import android.os.Bundle @@ -7,14 +7,14 @@ import androidx.fragment.app.Fragment import androidx.fragment.app.viewModels import androidx.lifecycle.lifecycleScope import by.kirich1409.viewbindingdelegate.viewBinding +import dev.arkbuilders.arkfilepicker.ArkFilePickerConfig +import dev.arkbuilders.arkfilepicker.presentation.filepicker.ArkFilePickerFragment +import dev.arkbuilders.arkfilepicker.presentation.filepicker.ArkFilePickerMode +import dev.arkbuilders.arkfilepicker.presentation.onArkPathPicked import kotlinx.coroutines.launch -import space.taran.arkfilepicker.ArkFilePickerConfig -import space.taran.arkfilepicker.presentation.filepicker.ArkFilePickerFragment -import space.taran.arkfilepicker.presentation.filepicker.ArkFilePickerMode -import space.taran.arkfilepicker.presentation.onArkPathPicked -import space.taran.arkshelf.R -import space.taran.arkshelf.databinding.FragmentSettingsBinding -import space.taran.arkshelf.di.DIManager +import dev.arkbuilders.arkshelf.R +import dev.arkbuilders.arkshelf.databinding.FragmentSettingsBinding +import dev.arkbuilders.arkshelf.di.DIManager import javax.inject.Inject class SettingsFragment: Fragment(R.layout.fragment_settings) { diff --git a/app/src/main/java/space/taran/arkshelf/presentation/settings/SettingsViewModel.kt b/app/src/main/java/dev/arkbuilders/arkshelf/presentation/settings/SettingsViewModel.kt similarity index 89% rename from app/src/main/java/space/taran/arkshelf/presentation/settings/SettingsViewModel.kt rename to app/src/main/java/dev/arkbuilders/arkshelf/presentation/settings/SettingsViewModel.kt index 68a61e4..5f7e3bc 100644 --- a/app/src/main/java/space/taran/arkshelf/presentation/settings/SettingsViewModel.kt +++ b/app/src/main/java/dev/arkbuilders/arkshelf/presentation/settings/SettingsViewModel.kt @@ -1,9 +1,9 @@ -package space.taran.arkshelf.presentation.settings +package dev.arkbuilders.arkshelf.presentation.settings import androidx.lifecycle.ViewModel import androidx.lifecycle.ViewModelProvider import kotlinx.coroutines.flow.MutableStateFlow -import space.taran.arkshelf.domain.UserPreferences +import dev.arkbuilders.arkshelf.domain.UserPreferences import java.nio.file.Path import javax.inject.Inject diff --git a/app/src/main/java/space/taran/arkshelf/domain/NoInternetException.kt b/app/src/main/java/space/taran/arkshelf/domain/NoInternetException.kt deleted file mode 100644 index 3cce49c..0000000 --- a/app/src/main/java/space/taran/arkshelf/domain/NoInternetException.kt +++ /dev/null @@ -1,3 +0,0 @@ -package space.taran.arkshelf.domain - -class NoInternetException: Exception() \ No newline at end of file diff --git a/app/src/test/java/space/taran/arkshelf/ExampleUnitTest.kt b/app/src/test/java/dev/arkbuilders/arkshelf/ExampleUnitTest.kt similarity index 90% rename from app/src/test/java/space/taran/arkshelf/ExampleUnitTest.kt rename to app/src/test/java/dev/arkbuilders/arkshelf/ExampleUnitTest.kt index f0a8e5b..6caeb69 100644 --- a/app/src/test/java/space/taran/arkshelf/ExampleUnitTest.kt +++ b/app/src/test/java/dev/arkbuilders/arkshelf/ExampleUnitTest.kt @@ -1,4 +1,4 @@ -package space.taran.arkshelf +package dev.arkbuilders.arkshelf import org.junit.Test