Change app name from Etsudoku to Shirizu
This commit is contained in:
2
.idea/.name
generated
2
.idea/.name
generated
@@ -1 +1 @@
|
|||||||
Etsudoku
|
Shirizu
|
||||||
4
.idea/deploymentTargetDropDown.xml
generated
4
.idea/deploymentTargetDropDown.xml
generated
@@ -13,12 +13,12 @@
|
|||||||
<deviceKey>
|
<deviceKey>
|
||||||
<Key>
|
<Key>
|
||||||
<type value="VIRTUAL_DEVICE_PATH" />
|
<type value="VIRTUAL_DEVICE_PATH" />
|
||||||
<value value="C:\Users\xtimms\.android\avd\Pixel_API_27.avd" />
|
<value value="C:\Users\xtimms\.android\avd\Pixel_5_API_34.avd" />
|
||||||
</Key>
|
</Key>
|
||||||
</deviceKey>
|
</deviceKey>
|
||||||
</Target>
|
</Target>
|
||||||
</targetSelectedWithDropDown>
|
</targetSelectedWithDropDown>
|
||||||
<timeTargetWasSelectedWithDropDown value="2024-03-30T18:28:38.815975400Z" />
|
<timeTargetWasSelectedWithDropDown value="2024-04-06T08:29:40.034958200Z" />
|
||||||
</State>
|
</State>
|
||||||
</entry>
|
</entry>
|
||||||
</value>
|
</value>
|
||||||
|
|||||||
@@ -1,14 +1,14 @@
|
|||||||
<div align="center">
|
<div align="center">
|
||||||
|
|
||||||
<a>
|
<a>
|
||||||
<img src="./app/src/main/res/mipmap-xxxhdpi/ic_launcher.png" alt="Etsudoku logo" title="Etsudoku logo" width="80"/>
|
<img src="./app/src/main/res/mipmap-xxxhdpi/ic_launcher.png" alt="Shirizu logo" title="Shirizu logo" width="80"/>
|
||||||
</a>
|
</a>
|
||||||
|
|
||||||
# Etsudoku
|
# Shirizu
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
Etsudoku (閲読) - An attempt to write an Android manga reading application on Jetpack Compose using the [Kotatsu parser library](https://github.com/KotatsuApp/kotatsu-parsers).
|
Shirizu (シリーズ, from Japanese - series) - An attempt to write an Android manga reading application on Jetpack Compose using the [Kotatsu parser library](https://github.com/KotatsuApp/kotatsu-parsers).
|
||||||
|
|
||||||
## Is it possible to use it now?
|
## Is it possible to use it now?
|
||||||
|
|
||||||
|
|||||||
@@ -19,11 +19,11 @@ val acraAuthLogin: String = gradleLocalProperties(rootDir).getProperty("authLogi
|
|||||||
val acraAuthPassword: String = gradleLocalProperties(rootDir).getProperty("authPassword") ?: "\"acra_password\""
|
val acraAuthPassword: String = gradleLocalProperties(rootDir).getProperty("authPassword") ?: "\"acra_password\""
|
||||||
|
|
||||||
android {
|
android {
|
||||||
namespace = "org.xtimms.etsudoku"
|
namespace = "org.xtimms.shirizu"
|
||||||
compileSdk = 34
|
compileSdk = 34
|
||||||
|
|
||||||
defaultConfig {
|
defaultConfig {
|
||||||
applicationId = "org.xtimms.etsudoku"
|
applicationId = "org.xtimms.shirizu"
|
||||||
minSdk = 26
|
minSdk = 26
|
||||||
targetSdk = 34
|
targetSdk = 34
|
||||||
versionCode = 1
|
versionCode = 1
|
||||||
@@ -37,7 +37,7 @@ android {
|
|||||||
buildConfigField("String", "ACRA_AUTH_LOGIN", acraAuthLogin)
|
buildConfigField("String", "ACRA_AUTH_LOGIN", acraAuthLogin)
|
||||||
buildConfigField("String", "ACRA_AUTH_PASSWORD", acraAuthPassword)
|
buildConfigField("String", "ACRA_AUTH_PASSWORD", acraAuthPassword)
|
||||||
|
|
||||||
testInstrumentationRunner = "org.xtimms.etsudoku.HiltTestRunner"
|
testInstrumentationRunner = "org.xtimms.shirizu.HiltTestRunner"
|
||||||
vectorDrawables {
|
vectorDrawables {
|
||||||
useSupportLibrary = true
|
useSupportLibrary = true
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
package org.xtimms.etsudoku
|
package org.xtimms.shirizu
|
||||||
|
|
||||||
import android.app.Application
|
import android.app.Application
|
||||||
import android.content.Context
|
import android.content.Context
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
package org.xtimms.etsudoku
|
package org.xtimms.shirizu
|
||||||
|
|
||||||
import android.app.Instrumentation
|
import android.app.Instrumentation
|
||||||
import kotlin.coroutines.resume
|
import kotlin.coroutines.resume
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
package org.xtimms.etsudoku
|
package org.xtimms.shirizu
|
||||||
|
|
||||||
import androidx.test.platform.app.InstrumentationRegistry
|
import androidx.test.platform.app.InstrumentationRegistry
|
||||||
import com.squareup.moshi.FromJson
|
import com.squareup.moshi.FromJson
|
||||||
@@ -11,7 +11,7 @@ import com.squareup.moshi.kotlin.reflect.KotlinJsonAdapterFactory
|
|||||||
import okio.buffer
|
import okio.buffer
|
||||||
import okio.source
|
import okio.source
|
||||||
import org.koitharu.kotatsu.parsers.model.Manga
|
import org.koitharu.kotatsu.parsers.model.Manga
|
||||||
import org.xtimms.etsudoku.core.model.FavouriteCategory
|
import org.xtimms.shirizu.core.model.FavouriteCategory
|
||||||
import java.util.Date
|
import java.util.Date
|
||||||
import kotlin.reflect.KClass
|
import kotlin.reflect.KClass
|
||||||
|
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
package org.xtimms.etsudoku.sections.settings.backup
|
package org.xtimms.shirizu.sections.settings.backup
|
||||||
|
|
||||||
import android.content.res.AssetManager
|
import android.content.res.AssetManager
|
||||||
import androidx.test.ext.junit.runners.AndroidJUnit4
|
import androidx.test.ext.junit.runners.AndroidJUnit4
|
||||||
@@ -12,12 +12,12 @@ import org.junit.Before
|
|||||||
import org.junit.Rule
|
import org.junit.Rule
|
||||||
import org.junit.Test
|
import org.junit.Test
|
||||||
import org.junit.runner.RunWith
|
import org.junit.runner.RunWith
|
||||||
import org.xtimms.etsudoku.SampleData
|
import org.xtimms.shirizu.SampleData
|
||||||
import org.xtimms.etsudoku.core.database.EtsudokuDatabase
|
import org.xtimms.shirizu.core.database.ShirizuDatabase
|
||||||
import org.xtimms.etsudoku.core.database.entity.toMangaTags
|
import org.xtimms.shirizu.core.database.entity.toMangaTags
|
||||||
import org.xtimms.etsudoku.data.repository.FavouritesRepository
|
import org.xtimms.shirizu.data.repository.FavouritesRepository
|
||||||
import org.xtimms.etsudoku.data.repository.HistoryRepository
|
import org.xtimms.shirizu.data.repository.HistoryRepository
|
||||||
import org.xtimms.etsudoku.data.repository.backup.BackupRepository
|
import org.xtimms.shirizu.data.repository.backup.BackupRepository
|
||||||
import java.io.File
|
import java.io.File
|
||||||
import javax.inject.Inject
|
import javax.inject.Inject
|
||||||
|
|
||||||
@@ -38,7 +38,7 @@ class AppBackupAgentTest {
|
|||||||
lateinit var backupRepository: BackupRepository
|
lateinit var backupRepository: BackupRepository
|
||||||
|
|
||||||
@Inject
|
@Inject
|
||||||
lateinit var database: EtsudokuDatabase
|
lateinit var database: ShirizuDatabase
|
||||||
|
|
||||||
@Before
|
@Before
|
||||||
fun setUp() {
|
fun setUp() {
|
||||||
@@ -35,7 +35,7 @@
|
|||||||
android:label="@string/app_name"
|
android:label="@string/app_name"
|
||||||
android:largeHeap="true"
|
android:largeHeap="true"
|
||||||
android:supportsRtl="true"
|
android:supportsRtl="true"
|
||||||
android:theme="@style/Theme.Etsudoku.Starting"
|
android:theme="@style/Theme.Shirizu"
|
||||||
android:networkSecurityConfig="@xml/network_security_config"
|
android:networkSecurityConfig="@xml/network_security_config"
|
||||||
tools:targetApi="tiramisu">
|
tools:targetApi="tiramisu">
|
||||||
|
|
||||||
@@ -43,7 +43,7 @@
|
|||||||
android:name=".MainActivity"
|
android:name=".MainActivity"
|
||||||
android:exported="true"
|
android:exported="true"
|
||||||
android:launchMode="singleTop"
|
android:launchMode="singleTop"
|
||||||
android:theme="@style/Theme.Etsudoku">
|
android:theme="@style/Theme.Shirizu.SplashTheme">
|
||||||
<intent-filter>
|
<intent-filter>
|
||||||
<action android:name="android.intent.action.MAIN" />
|
<action android:name="android.intent.action.MAIN" />
|
||||||
|
|
||||||
|
|||||||
@@ -1,5 +0,0 @@
|
|||||||
package org.xtimms.etsudoku.sections.details
|
|
||||||
|
|
||||||
import org.xtimms.etsudoku.core.base.event.UiEvent
|
|
||||||
|
|
||||||
interface DetailsEvent : UiEvent
|
|
||||||
@@ -1,5 +0,0 @@
|
|||||||
package org.xtimms.etsudoku.sections.explore
|
|
||||||
|
|
||||||
import org.xtimms.etsudoku.core.base.event.UiEvent
|
|
||||||
|
|
||||||
interface ExploreEvent : UiEvent
|
|
||||||
@@ -1,5 +0,0 @@
|
|||||||
package org.xtimms.etsudoku.sections.list
|
|
||||||
|
|
||||||
import org.xtimms.etsudoku.core.base.event.PagedUiEvent
|
|
||||||
|
|
||||||
interface MangaListEvent : PagedUiEvent
|
|
||||||
@@ -1,8 +0,0 @@
|
|||||||
package org.xtimms.etsudoku.sections.reader
|
|
||||||
|
|
||||||
import org.xtimms.etsudoku.sections.reader.pager.ReaderPage
|
|
||||||
|
|
||||||
data class ReaderContent(
|
|
||||||
val pages: List<ReaderPage>,
|
|
||||||
val state: ReaderState?
|
|
||||||
)
|
|
||||||
@@ -1,88 +0,0 @@
|
|||||||
package org.xtimms.etsudoku.sections.settings.appearance
|
|
||||||
|
|
||||||
import androidx.compose.foundation.Image
|
|
||||||
import androidx.compose.foundation.layout.Arrangement
|
|
||||||
import androidx.compose.foundation.layout.Column
|
|
||||||
import androidx.compose.foundation.layout.Row
|
|
||||||
import androidx.compose.foundation.layout.fillMaxHeight
|
|
||||||
import androidx.compose.foundation.layout.fillMaxWidth
|
|
||||||
import androidx.compose.foundation.layout.height
|
|
||||||
import androidx.compose.foundation.layout.padding
|
|
||||||
import androidx.compose.material3.ElevatedCard
|
|
||||||
import androidx.compose.material3.MaterialTheme
|
|
||||||
import androidx.compose.material3.Text
|
|
||||||
import androidx.compose.runtime.Composable
|
|
||||||
import androidx.compose.ui.Modifier
|
|
||||||
import androidx.compose.ui.draw.clip
|
|
||||||
import androidx.compose.ui.res.painterResource
|
|
||||||
import androidx.compose.ui.text.style.TextOverflow
|
|
||||||
import androidx.compose.ui.tooling.preview.PreviewLightDark
|
|
||||||
import androidx.compose.ui.unit.dp
|
|
||||||
import org.xtimms.etsudoku.R
|
|
||||||
import org.xtimms.etsudoku.ui.theme.EtsudokuTheme
|
|
||||||
|
|
||||||
@Composable
|
|
||||||
fun MangaCard(
|
|
||||||
modifier: Modifier = Modifier,
|
|
||||||
title: String = "Ookami to Koushinryou",
|
|
||||||
author: String = "Hasekura Isuna",
|
|
||||||
thumbnailUrl: Any = "",
|
|
||||||
showCancelButton: Boolean = false,
|
|
||||||
onCancel: () -> Unit = {},
|
|
||||||
onClick: () -> Unit = {},
|
|
||||||
progress: Float = 75f,
|
|
||||||
) {
|
|
||||||
ElevatedCard(
|
|
||||||
modifier = modifier
|
|
||||||
.height(136.dp)
|
|
||||||
.fillMaxWidth(),
|
|
||||||
onClick = onClick,
|
|
||||||
shape = MaterialTheme.shapes.small,
|
|
||||||
) {
|
|
||||||
Row(
|
|
||||||
modifier = Modifier.fillMaxWidth()
|
|
||||||
) {
|
|
||||||
Image(
|
|
||||||
modifier = Modifier
|
|
||||||
.padding()
|
|
||||||
.fillMaxHeight()
|
|
||||||
.clip(MaterialTheme.shapes.small),
|
|
||||||
painter = painterResource(id = R.drawable.ookami),
|
|
||||||
contentDescription = null
|
|
||||||
)
|
|
||||||
Column(
|
|
||||||
modifier = Modifier
|
|
||||||
.weight(1f)
|
|
||||||
.padding(horizontal = 12.dp, vertical = 8.dp)
|
|
||||||
.fillMaxWidth(),
|
|
||||||
verticalArrangement = Arrangement.Top
|
|
||||||
) {
|
|
||||||
Text(
|
|
||||||
text = title,
|
|
||||||
style = MaterialTheme.typography.titleLarge,
|
|
||||||
color = MaterialTheme.colorScheme.onSurface,
|
|
||||||
maxLines = 2,
|
|
||||||
overflow = TextOverflow.Ellipsis
|
|
||||||
)
|
|
||||||
if (author != "null") Text(
|
|
||||||
modifier = Modifier.padding(top = 3.dp),
|
|
||||||
text = author,
|
|
||||||
style = MaterialTheme.typography.bodySmall,
|
|
||||||
color = MaterialTheme.colorScheme.onSurfaceVariant,
|
|
||||||
maxLines = 1,
|
|
||||||
overflow = TextOverflow.Ellipsis
|
|
||||||
)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
@PreviewLightDark
|
|
||||||
@Composable
|
|
||||||
fun MangaCardPreview() {
|
|
||||||
EtsudokuTheme {
|
|
||||||
MangaCard(
|
|
||||||
thumbnailUrl = "https://spice-and-wolf.com/special/img/visual_january.jpg"
|
|
||||||
)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,5 +0,0 @@
|
|||||||
package org.xtimms.etsudoku.sections.settings.storage
|
|
||||||
|
|
||||||
import org.xtimms.etsudoku.core.base.event.UiEvent
|
|
||||||
|
|
||||||
interface StorageEvent : UiEvent
|
|
||||||
@@ -1,3 +0,0 @@
|
|||||||
package org.xtimms.etsudoku.utils.material
|
|
||||||
|
|
||||||
const val SecondaryItemAlpha = .78f
|
|
||||||
@@ -1,8 +0,0 @@
|
|||||||
package org.xtimms.etsudoku.work.tracker
|
|
||||||
|
|
||||||
import org.xtimms.etsudoku.core.tracker.model.MangaTracking
|
|
||||||
|
|
||||||
data class TrackingItem(
|
|
||||||
val tracking: MangaTracking,
|
|
||||||
val channelId: String?,
|
|
||||||
)
|
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
package org.xtimms.etsudoku
|
package org.xtimms.shirizu
|
||||||
|
|
||||||
import android.app.Application
|
import android.app.Application
|
||||||
import android.content.Context
|
import android.content.Context
|
||||||
@@ -20,12 +20,12 @@ import org.acra.data.StringFormat
|
|||||||
import org.acra.ktx.initAcra
|
import org.acra.ktx.initAcra
|
||||||
import org.acra.sender.HttpSender
|
import org.acra.sender.HttpSender
|
||||||
import org.koitharu.kotatsu.parsers.MangaLoaderContext
|
import org.koitharu.kotatsu.parsers.MangaLoaderContext
|
||||||
import org.xtimms.etsudoku.core.database.EtsudokuDatabase
|
import org.xtimms.shirizu.core.database.ShirizuDatabase
|
||||||
import org.xtimms.etsudoku.core.prefs.AppSettings
|
import org.xtimms.shirizu.core.prefs.AppSettings
|
||||||
import org.xtimms.etsudoku.core.prefs.KotatsuAppSettings
|
import org.xtimms.shirizu.core.prefs.KotatsuAppSettings
|
||||||
import org.xtimms.etsudoku.core.updates.Updater
|
import org.xtimms.shirizu.core.updates.Updater
|
||||||
import org.xtimms.etsudoku.utils.lang.processLifecycleScope
|
import org.xtimms.shirizu.utils.lang.processLifecycleScope
|
||||||
import org.xtimms.etsudoku.work.WorkScheduleManager
|
import org.xtimms.shirizu.work.WorkScheduleManager
|
||||||
import javax.inject.Inject
|
import javax.inject.Inject
|
||||||
import javax.inject.Provider
|
import javax.inject.Provider
|
||||||
|
|
||||||
@@ -33,7 +33,7 @@ import javax.inject.Provider
|
|||||||
class App : Application(), Configuration.Provider {
|
class App : Application(), Configuration.Provider {
|
||||||
|
|
||||||
@Inject
|
@Inject
|
||||||
lateinit var database: Provider<EtsudokuDatabase>
|
lateinit var database: Provider<ShirizuDatabase>
|
||||||
|
|
||||||
@Inject
|
@Inject
|
||||||
lateinit var settings: KotatsuAppSettings
|
lateinit var settings: KotatsuAppSettings
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
package org.xtimms.etsudoku
|
package org.xtimms.shirizu
|
||||||
|
|
||||||
import android.os.Build
|
import android.os.Build
|
||||||
import androidx.compose.foundation.layout.PaddingValues
|
import androidx.compose.foundation.layout.PaddingValues
|
||||||
@@ -11,13 +11,13 @@ import androidx.compose.ui.graphics.Color
|
|||||||
import androidx.compose.ui.platform.LocalContext
|
import androidx.compose.ui.platform.LocalContext
|
||||||
import androidx.compose.ui.unit.Dp
|
import androidx.compose.ui.unit.Dp
|
||||||
import androidx.compose.ui.unit.dp
|
import androidx.compose.ui.unit.dp
|
||||||
import org.xtimms.etsudoku.ui.theme.SEED
|
import org.xtimms.shirizu.ui.theme.SEED
|
||||||
import org.xtimms.etsudoku.core.prefs.AppSettings
|
import org.xtimms.shirizu.core.prefs.AppSettings
|
||||||
import org.xtimms.etsudoku.core.prefs.DarkThemePreference
|
import org.xtimms.shirizu.core.prefs.DarkThemePreference
|
||||||
import org.xtimms.etsudoku.core.prefs.paletteStyles
|
import org.xtimms.shirizu.core.prefs.paletteStyles
|
||||||
import org.xtimms.etsudoku.ui.monet.LocalTonalPalettes
|
import org.xtimms.shirizu.ui.monet.LocalTonalPalettes
|
||||||
import org.xtimms.etsudoku.ui.monet.PaletteStyle
|
import org.xtimms.shirizu.ui.monet.PaletteStyle
|
||||||
import org.xtimms.etsudoku.ui.monet.TonalPalettes.Companion.toTonalPalettes
|
import org.xtimms.shirizu.ui.monet.TonalPalettes.Companion.toTonalPalettes
|
||||||
|
|
||||||
data class BottomSheetScrollState(
|
data class BottomSheetScrollState(
|
||||||
val topPadding: Dp,
|
val topPadding: Dp,
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
package org.xtimms.etsudoku
|
package org.xtimms.shirizu
|
||||||
|
|
||||||
import android.Manifest
|
import android.Manifest
|
||||||
import android.content.Intent
|
import android.content.Intent
|
||||||
@@ -58,18 +58,18 @@ import kotlinx.coroutines.Dispatchers
|
|||||||
import kotlinx.coroutines.Job
|
import kotlinx.coroutines.Job
|
||||||
import kotlinx.coroutines.launch
|
import kotlinx.coroutines.launch
|
||||||
import kotlinx.coroutines.runBlocking
|
import kotlinx.coroutines.runBlocking
|
||||||
import org.xtimms.etsudoku.core.Navigation
|
import org.xtimms.shirizu.core.Navigation
|
||||||
import org.xtimms.etsudoku.core.components.BottomNavBar
|
import org.xtimms.shirizu.core.components.BottomNavBar
|
||||||
import org.xtimms.etsudoku.core.components.ContinueReadingButton
|
import org.xtimms.shirizu.core.components.ContinueReadingButton
|
||||||
import org.xtimms.etsudoku.core.components.NavigationRail
|
import org.xtimms.shirizu.core.components.NavigationRail
|
||||||
import org.xtimms.etsudoku.core.components.TopAppBar
|
import org.xtimms.shirizu.core.components.TopAppBar
|
||||||
import org.xtimms.etsudoku.core.logs.FileLogger
|
import org.xtimms.shirizu.core.logs.FileLogger
|
||||||
import org.xtimms.etsudoku.core.prefs.AppSettings
|
import org.xtimms.shirizu.core.prefs.AppSettings
|
||||||
import org.xtimms.etsudoku.core.screens.UpdateDialogImpl
|
import org.xtimms.shirizu.core.screens.UpdateDialogImpl
|
||||||
import org.xtimms.etsudoku.core.updates.Updater
|
import org.xtimms.shirizu.core.updates.Updater
|
||||||
import org.xtimms.etsudoku.ui.theme.EtsudokuTheme
|
import org.xtimms.shirizu.ui.theme.ShirizuTheme
|
||||||
import org.xtimms.etsudoku.utils.system.setLanguage
|
import org.xtimms.shirizu.utils.system.setLanguage
|
||||||
import org.xtimms.etsudoku.utils.system.suspendToast
|
import org.xtimms.shirizu.utils.system.suspendToast
|
||||||
import javax.inject.Inject
|
import javax.inject.Inject
|
||||||
|
|
||||||
@OptIn(ExperimentalMaterial3WindowSizeClassApi::class)
|
@OptIn(ExperimentalMaterial3WindowSizeClassApi::class)
|
||||||
@@ -142,7 +142,7 @@ class MainActivity : ComponentActivity() {
|
|||||||
}
|
}
|
||||||
if (isReady.value) {
|
if (isReady.value) {
|
||||||
SettingsProvider {
|
SettingsProvider {
|
||||||
EtsudokuTheme(
|
ShirizuTheme(
|
||||||
darkTheme = LocalDarkTheme.current.isDarkTheme(),
|
darkTheme = LocalDarkTheme.current.isDarkTheme(),
|
||||||
isDynamicColorEnabled = LocalDynamicColorSwitch.current,
|
isDynamicColorEnabled = LocalDynamicColorSwitch.current,
|
||||||
isHighContrastModeEnabled = LocalDarkTheme.current.isHighContrastModeEnabled,
|
isHighContrastModeEnabled = LocalDarkTheme.current.isHighContrastModeEnabled,
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
package org.xtimms.etsudoku
|
package org.xtimms.shirizu
|
||||||
|
|
||||||
import android.app.Application
|
import android.app.Application
|
||||||
import android.content.Context
|
import android.content.Context
|
||||||
@@ -20,28 +20,28 @@ import kotlinx.coroutines.flow.SharedFlow
|
|||||||
import kotlinx.coroutines.flow.asSharedFlow
|
import kotlinx.coroutines.flow.asSharedFlow
|
||||||
import okhttp3.OkHttpClient
|
import okhttp3.OkHttpClient
|
||||||
import org.koitharu.kotatsu.parsers.MangaLoaderContext
|
import org.koitharu.kotatsu.parsers.MangaLoaderContext
|
||||||
import org.xtimms.etsudoku.core.cache.CacheDir
|
import org.xtimms.shirizu.core.cache.CacheDir
|
||||||
import org.xtimms.etsudoku.core.cache.ContentCache
|
import org.xtimms.shirizu.core.cache.ContentCache
|
||||||
import org.xtimms.etsudoku.core.cache.MemoryContentCache
|
import org.xtimms.shirizu.core.cache.MemoryContentCache
|
||||||
import org.xtimms.etsudoku.core.cache.StubContentCache
|
import org.xtimms.shirizu.core.cache.StubContentCache
|
||||||
import org.xtimms.etsudoku.core.database.EtsudokuDatabase
|
import org.xtimms.shirizu.core.database.ShirizuDatabase
|
||||||
import org.xtimms.etsudoku.core.model.LocalManga
|
import org.xtimms.shirizu.core.model.LocalManga
|
||||||
import org.xtimms.etsudoku.core.network.MangaHttpClient
|
import org.xtimms.shirizu.core.network.MangaHttpClient
|
||||||
import org.xtimms.etsudoku.core.network.interceptors.ImageProxyInterceptor
|
import org.xtimms.shirizu.core.network.interceptors.ImageProxyInterceptor
|
||||||
import org.xtimms.etsudoku.core.os.NetworkState
|
import org.xtimms.shirizu.core.os.NetworkState
|
||||||
import org.xtimms.etsudoku.core.parser.MangaLoaderContextImpl
|
import org.xtimms.shirizu.core.parser.MangaLoaderContextImpl
|
||||||
import org.xtimms.etsudoku.core.parser.MangaRepository
|
import org.xtimms.shirizu.core.parser.MangaRepository
|
||||||
import org.xtimms.etsudoku.core.parser.favicon.FaviconFetcher
|
import org.xtimms.shirizu.core.parser.favicon.FaviconFetcher
|
||||||
import org.xtimms.etsudoku.core.parser.local.LocalStorageChanges
|
import org.xtimms.shirizu.core.parser.local.LocalStorageChanges
|
||||||
import org.xtimms.etsudoku.sections.reader.thumbnails.MangaPageFetcher
|
import org.xtimms.shirizu.sections.reader.thumbnails.MangaPageFetcher
|
||||||
import org.xtimms.etsudoku.utils.CoilImageGetter
|
import org.xtimms.shirizu.utils.CoilImageGetter
|
||||||
import org.xtimms.etsudoku.utils.system.connectivityManager
|
import org.xtimms.shirizu.utils.system.connectivityManager
|
||||||
import org.xtimms.etsudoku.utils.system.isLowRamDevice
|
import org.xtimms.shirizu.utils.system.isLowRamDevice
|
||||||
import javax.inject.Singleton
|
import javax.inject.Singleton
|
||||||
|
|
||||||
@Module
|
@Module
|
||||||
@InstallIn(SingletonComponent::class)
|
@InstallIn(SingletonComponent::class)
|
||||||
interface EtsudokuModule {
|
interface ShirizuModule {
|
||||||
|
|
||||||
@Binds
|
@Binds
|
||||||
fun bindMangaLoaderContext(mangaLoaderContextImpl: MangaLoaderContextImpl): MangaLoaderContext
|
fun bindMangaLoaderContext(mangaLoaderContextImpl: MangaLoaderContextImpl): MangaLoaderContext
|
||||||
@@ -61,8 +61,8 @@ interface EtsudokuModule {
|
|||||||
@Singleton
|
@Singleton
|
||||||
fun provideMangaDatabase(
|
fun provideMangaDatabase(
|
||||||
@ApplicationContext context: Context,
|
@ApplicationContext context: Context,
|
||||||
): EtsudokuDatabase {
|
): ShirizuDatabase {
|
||||||
return EtsudokuDatabase(context)
|
return ShirizuDatabase(context)
|
||||||
}
|
}
|
||||||
|
|
||||||
@Provides
|
@Provides
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
package org.xtimms.etsudoku.core
|
package org.xtimms.shirizu.core
|
||||||
|
|
||||||
import androidx.compose.foundation.Image
|
import androidx.compose.foundation.Image
|
||||||
import androidx.compose.runtime.Composable
|
import androidx.compose.runtime.Composable
|
||||||
@@ -14,8 +14,8 @@ import androidx.compose.ui.res.painterResource
|
|||||||
import coil.ImageLoader
|
import coil.ImageLoader
|
||||||
import coil.compose.AsyncImage
|
import coil.compose.AsyncImage
|
||||||
import coil.compose.AsyncImagePainter
|
import coil.compose.AsyncImagePainter
|
||||||
import org.xtimms.etsudoku.R
|
import org.xtimms.shirizu.R
|
||||||
import org.xtimms.etsudoku.utils.composable.rememberResourceBitmapPainter
|
import org.xtimms.shirizu.utils.composable.rememberResourceBitmapPainter
|
||||||
|
|
||||||
@Composable
|
@Composable
|
||||||
fun AsyncImageImpl(
|
fun AsyncImageImpl(
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
package org.xtimms.etsudoku.core
|
package org.xtimms.shirizu.core
|
||||||
|
|
||||||
import androidx.annotation.StringRes
|
import androidx.annotation.StringRes
|
||||||
import androidx.compose.material.icons.Icons
|
import androidx.compose.material.icons.Icons
|
||||||
@@ -11,10 +11,10 @@ import androidx.compose.material.icons.outlined.LocalLibrary
|
|||||||
import androidx.compose.runtime.Composable
|
import androidx.compose.runtime.Composable
|
||||||
import androidx.compose.ui.graphics.vector.ImageVector
|
import androidx.compose.ui.graphics.vector.ImageVector
|
||||||
import androidx.compose.ui.res.stringResource
|
import androidx.compose.ui.res.stringResource
|
||||||
import org.xtimms.etsudoku.R
|
import org.xtimms.shirizu.R
|
||||||
import org.xtimms.etsudoku.sections.explore.EXPLORE_DESTINATION
|
import org.xtimms.shirizu.sections.explore.EXPLORE_DESTINATION
|
||||||
import org.xtimms.etsudoku.sections.history.HISTORY_DESTINATION
|
import org.xtimms.shirizu.sections.history.HISTORY_DESTINATION
|
||||||
import org.xtimms.etsudoku.sections.shelf.SHELF_DESTINATION
|
import org.xtimms.shirizu.sections.shelf.SHELF_DESTINATION
|
||||||
|
|
||||||
sealed class BottomNavDestination(
|
sealed class BottomNavDestination(
|
||||||
val value: String,
|
val value: String,
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
package org.xtimms.etsudoku.core
|
package org.xtimms.shirizu.core
|
||||||
|
|
||||||
import androidx.compose.animation.core.Animatable
|
import androidx.compose.animation.core.Animatable
|
||||||
import androidx.compose.animation.core.AnimationVector1D
|
import androidx.compose.animation.core.AnimationVector1D
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
package org.xtimms.etsudoku.core
|
package org.xtimms.shirizu.core
|
||||||
|
|
||||||
import android.graphics.Path
|
import android.graphics.Path
|
||||||
import android.view.animation.PathInterpolator
|
import android.view.animation.PathInterpolator
|
||||||
@@ -20,69 +20,69 @@ import androidx.navigation.compose.composable
|
|||||||
import androidx.navigation.navArgument
|
import androidx.navigation.navArgument
|
||||||
import coil.ImageLoader
|
import coil.ImageLoader
|
||||||
import org.koitharu.kotatsu.parsers.model.MangaSource
|
import org.koitharu.kotatsu.parsers.model.MangaSource
|
||||||
import org.xtimms.etsudoku.core.logs.FileLogger
|
import org.xtimms.shirizu.core.logs.FileLogger
|
||||||
import org.xtimms.etsudoku.sections.details.DETAILS_DESTINATION
|
import org.xtimms.shirizu.sections.details.DETAILS_DESTINATION
|
||||||
import org.xtimms.etsudoku.sections.details.DetailsView
|
import org.xtimms.shirizu.sections.details.DetailsView
|
||||||
import org.xtimms.etsudoku.sections.details.FULL_POSTER_DESTINATION
|
import org.xtimms.shirizu.sections.details.FULL_POSTER_DESTINATION
|
||||||
import org.xtimms.etsudoku.sections.details.FullImageView
|
import org.xtimms.shirizu.sections.details.FullImageView
|
||||||
import org.xtimms.etsudoku.sections.details.MANGA_ID_ARGUMENT
|
import org.xtimms.shirizu.sections.details.MANGA_ID_ARGUMENT
|
||||||
import org.xtimms.etsudoku.sections.details.PICTURES_ARGUMENT
|
import org.xtimms.shirizu.sections.details.PICTURES_ARGUMENT
|
||||||
import org.xtimms.etsudoku.sections.explore.ExploreView
|
import org.xtimms.shirizu.sections.explore.ExploreView
|
||||||
import org.xtimms.etsudoku.sections.feed.FEED_DESTINATION
|
import org.xtimms.shirizu.sections.feed.FEED_DESTINATION
|
||||||
import org.xtimms.etsudoku.sections.feed.FeedView
|
import org.xtimms.shirizu.sections.feed.FeedView
|
||||||
import org.xtimms.etsudoku.sections.history.HistoryView
|
import org.xtimms.shirizu.sections.history.HistoryView
|
||||||
import org.xtimms.etsudoku.sections.list.LIST_DESTINATION
|
import org.xtimms.shirizu.sections.list.LIST_DESTINATION
|
||||||
import org.xtimms.etsudoku.sections.list.MangaListView
|
import org.xtimms.shirizu.sections.list.MangaListView
|
||||||
import org.xtimms.etsudoku.sections.list.PROVIDER_ARGUMENT
|
import org.xtimms.shirizu.sections.list.PROVIDER_ARGUMENT
|
||||||
import org.xtimms.etsudoku.sections.reader.READER_DESTINATION
|
import org.xtimms.shirizu.sections.reader.READER_DESTINATION
|
||||||
import org.xtimms.etsudoku.sections.reader.ReaderView
|
import org.xtimms.shirizu.sections.reader.ReaderView
|
||||||
import org.xtimms.etsudoku.sections.search.SEARCH_DESTINATION
|
import org.xtimms.shirizu.sections.search.SEARCH_DESTINATION
|
||||||
import org.xtimms.etsudoku.sections.search.SearchHostView
|
import org.xtimms.shirizu.sections.search.SearchHostView
|
||||||
import org.xtimms.etsudoku.sections.settings.SETTINGS_DESTINATION
|
import org.xtimms.shirizu.sections.settings.SETTINGS_DESTINATION
|
||||||
import org.xtimms.etsudoku.sections.settings.SettingsView
|
import org.xtimms.shirizu.sections.settings.SettingsView
|
||||||
import org.xtimms.etsudoku.sections.settings.about.ABOUT_DESTINATION
|
import org.xtimms.shirizu.sections.settings.about.ABOUT_DESTINATION
|
||||||
import org.xtimms.etsudoku.sections.settings.about.AboutView
|
import org.xtimms.shirizu.sections.settings.about.AboutView
|
||||||
import org.xtimms.etsudoku.sections.settings.about.LICENSES_DESTINATION
|
import org.xtimms.shirizu.sections.settings.about.LICENSES_DESTINATION
|
||||||
import org.xtimms.etsudoku.sections.settings.about.LICENSE_CONTENT_ARGUMENT
|
import org.xtimms.shirizu.sections.settings.about.LICENSE_CONTENT_ARGUMENT
|
||||||
import org.xtimms.etsudoku.sections.settings.about.LICENSE_DESTINATION
|
import org.xtimms.shirizu.sections.settings.about.LICENSE_DESTINATION
|
||||||
import org.xtimms.etsudoku.sections.settings.about.LICENSE_NAME_ARGUMENT
|
import org.xtimms.shirizu.sections.settings.about.LICENSE_NAME_ARGUMENT
|
||||||
import org.xtimms.etsudoku.sections.settings.about.LICENSE_WEBSITE_ARGUMENT
|
import org.xtimms.shirizu.sections.settings.about.LICENSE_WEBSITE_ARGUMENT
|
||||||
import org.xtimms.etsudoku.sections.settings.about.LicenseView
|
import org.xtimms.shirizu.sections.settings.about.LicenseView
|
||||||
import org.xtimms.etsudoku.sections.settings.about.OpenSourceLicensesView
|
import org.xtimms.shirizu.sections.settings.about.OpenSourceLicensesView
|
||||||
import org.xtimms.etsudoku.sections.settings.about.UPDATES_DESTINATION
|
import org.xtimms.shirizu.sections.settings.about.UPDATES_DESTINATION
|
||||||
import org.xtimms.etsudoku.sections.settings.about.UpdateView
|
import org.xtimms.shirizu.sections.settings.about.UpdateView
|
||||||
import org.xtimms.etsudoku.sections.settings.advanced.ADVANCED_DESTINATION
|
import org.xtimms.shirizu.sections.settings.advanced.ADVANCED_DESTINATION
|
||||||
import org.xtimms.etsudoku.sections.settings.advanced.AdvancedView
|
import org.xtimms.shirizu.sections.settings.advanced.AdvancedView
|
||||||
import org.xtimms.etsudoku.sections.settings.appearance.APPEARANCE_DESTINATION
|
import org.xtimms.shirizu.sections.settings.appearance.APPEARANCE_DESTINATION
|
||||||
import org.xtimms.etsudoku.sections.settings.appearance.AppearanceView
|
import org.xtimms.shirizu.sections.settings.appearance.AppearanceView
|
||||||
import org.xtimms.etsudoku.sections.settings.appearance.DARK_THEME_DESTINATION
|
import org.xtimms.shirizu.sections.settings.appearance.DARK_THEME_DESTINATION
|
||||||
import org.xtimms.etsudoku.sections.settings.appearance.DarkThemeView
|
import org.xtimms.shirizu.sections.settings.appearance.DarkThemeView
|
||||||
import org.xtimms.etsudoku.sections.settings.appearance.LANGUAGES_DESTINATION
|
import org.xtimms.shirizu.sections.settings.appearance.LANGUAGES_DESTINATION
|
||||||
import org.xtimms.etsudoku.sections.settings.appearance.LanguagesView
|
import org.xtimms.shirizu.sections.settings.appearance.LanguagesView
|
||||||
import org.xtimms.etsudoku.sections.settings.backup.BACKUP_RESTORE_DESTINATION
|
import org.xtimms.shirizu.sections.settings.backup.BACKUP_RESTORE_DESTINATION
|
||||||
import org.xtimms.etsudoku.sections.settings.backup.BackupRestoreView
|
import org.xtimms.shirizu.sections.settings.backup.BackupRestoreView
|
||||||
import org.xtimms.etsudoku.sections.settings.backup.RESTORE_ARGUMENT
|
import org.xtimms.shirizu.sections.settings.backup.RESTORE_ARGUMENT
|
||||||
import org.xtimms.etsudoku.sections.settings.backup.RESTORE_DESTINATION
|
import org.xtimms.shirizu.sections.settings.backup.RESTORE_DESTINATION
|
||||||
import org.xtimms.etsudoku.sections.settings.backup.RestoreItemsView
|
import org.xtimms.shirizu.sections.settings.backup.RestoreItemsView
|
||||||
import org.xtimms.etsudoku.sections.settings.network.NETWORK_DESTINATION
|
import org.xtimms.shirizu.sections.settings.network.NETWORK_DESTINATION
|
||||||
import org.xtimms.etsudoku.sections.settings.network.NetworkView
|
import org.xtimms.shirizu.sections.settings.network.NetworkView
|
||||||
import org.xtimms.etsudoku.sections.settings.shelf.SHELF_SETTINGS_DESTINATION
|
import org.xtimms.shirizu.sections.settings.shelf.SHELF_SETTINGS_DESTINATION
|
||||||
import org.xtimms.etsudoku.sections.settings.shelf.ShelfSettingsView
|
import org.xtimms.shirizu.sections.settings.shelf.ShelfSettingsView
|
||||||
import org.xtimms.etsudoku.sections.settings.shelf.categories.CATEGORIES_DESTINATION
|
import org.xtimms.shirizu.sections.settings.shelf.categories.CATEGORIES_DESTINATION
|
||||||
import org.xtimms.etsudoku.sections.settings.shelf.categories.CategoriesView
|
import org.xtimms.shirizu.sections.settings.shelf.categories.CategoriesView
|
||||||
import org.xtimms.etsudoku.sections.settings.sources.SOURCES_DESTINATION
|
import org.xtimms.shirizu.sections.settings.sources.SOURCES_DESTINATION
|
||||||
import org.xtimms.etsudoku.sections.settings.sources.SourcesView
|
import org.xtimms.shirizu.sections.settings.sources.SourcesView
|
||||||
import org.xtimms.etsudoku.sections.settings.sources.catalog.CATALOG_DESTINATION
|
import org.xtimms.shirizu.sections.settings.sources.catalog.CATALOG_DESTINATION
|
||||||
import org.xtimms.etsudoku.sections.settings.sources.catalog.SourcesCatalogView
|
import org.xtimms.shirizu.sections.settings.sources.catalog.SourcesCatalogView
|
||||||
import org.xtimms.etsudoku.sections.settings.storage.STORAGE_DESTINATION
|
import org.xtimms.shirizu.sections.settings.storage.STORAGE_DESTINATION
|
||||||
import org.xtimms.etsudoku.sections.settings.storage.StorageView
|
import org.xtimms.shirizu.sections.settings.storage.StorageView
|
||||||
import org.xtimms.etsudoku.sections.shelf.ShelfView
|
import org.xtimms.shirizu.sections.shelf.ShelfView
|
||||||
import org.xtimms.etsudoku.sections.stats.STATS_DESTINATION
|
import org.xtimms.shirizu.sections.stats.STATS_DESTINATION
|
||||||
import org.xtimms.etsudoku.sections.stats.StatsView
|
import org.xtimms.shirizu.sections.stats.StatsView
|
||||||
import org.xtimms.etsudoku.sections.suggestions.SUGGESTIONS_DESTINATION
|
import org.xtimms.shirizu.sections.suggestions.SUGGESTIONS_DESTINATION
|
||||||
import org.xtimms.etsudoku.sections.suggestions.SuggestionsView
|
import org.xtimms.shirizu.sections.suggestions.SuggestionsView
|
||||||
import org.xtimms.etsudoku.utils.StringArrayNavType
|
import org.xtimms.shirizu.utils.StringArrayNavType
|
||||||
import org.xtimms.etsudoku.utils.lang.removeFirstAndLast
|
import org.xtimms.shirizu.utils.lang.removeFirstAndLast
|
||||||
|
|
||||||
const val DURATION_ENTER = 400
|
const val DURATION_ENTER = 400
|
||||||
const val DURATION_EXIT = 200
|
const val DURATION_EXIT = 200
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
package org.xtimms.etsudoku.core.base
|
package org.xtimms.shirizu.core.base
|
||||||
|
|
||||||
import android.app.Dialog
|
import android.app.Dialog
|
||||||
import android.os.Bundle
|
import android.os.Bundle
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
package org.xtimms.etsudoku.core.base
|
package org.xtimms.shirizu.core.base
|
||||||
|
|
||||||
import android.content.Intent
|
import android.content.Intent
|
||||||
import android.content.res.Configuration
|
import android.content.res.Configuration
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
package org.xtimms.etsudoku.core.base.event
|
package org.xtimms.shirizu.core.base.event
|
||||||
|
|
||||||
interface PagedUiEvent : UiEvent {
|
interface PagedUiEvent : UiEvent {
|
||||||
fun loadMore()
|
fun loadMore()
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
package org.xtimms.etsudoku.core.base.event
|
package org.xtimms.shirizu.core.base.event
|
||||||
|
|
||||||
interface UiEvent {
|
interface UiEvent {
|
||||||
fun showMessage(message: String?)
|
fun showMessage(message: String?)
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
package org.xtimms.etsudoku.core.base.state
|
package org.xtimms.shirizu.core.base.state
|
||||||
|
|
||||||
abstract class PagedUiState : UiState() {
|
abstract class PagedUiState : UiState() {
|
||||||
|
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
package org.xtimms.etsudoku.core.base.state
|
package org.xtimms.shirizu.core.base.state
|
||||||
|
|
||||||
abstract class UiState {
|
abstract class UiState {
|
||||||
abstract val isLoading: Boolean
|
abstract val isLoading: Boolean
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
package org.xtimms.etsudoku.core.base.viewmodel
|
package org.xtimms.shirizu.core.base.viewmodel
|
||||||
|
|
||||||
import androidx.lifecycle.ViewModel
|
import androidx.lifecycle.ViewModel
|
||||||
import androidx.lifecycle.viewModelScope
|
import androidx.lifecycle.viewModelScope
|
||||||
@@ -11,11 +11,11 @@ import kotlinx.coroutines.flow.StateFlow
|
|||||||
import kotlinx.coroutines.flow.asStateFlow
|
import kotlinx.coroutines.flow.asStateFlow
|
||||||
import kotlinx.coroutines.flow.update
|
import kotlinx.coroutines.flow.update
|
||||||
import kotlinx.coroutines.launch
|
import kotlinx.coroutines.launch
|
||||||
import org.xtimms.etsudoku.core.base.event.UiEvent
|
import org.xtimms.shirizu.core.base.event.UiEvent
|
||||||
import org.xtimms.etsudoku.core.base.state.UiState
|
import org.xtimms.shirizu.core.base.state.UiState
|
||||||
import org.xtimms.etsudoku.utils.lang.EventFlow
|
import org.xtimms.shirizu.utils.lang.EventFlow
|
||||||
import org.xtimms.etsudoku.utils.lang.MutableEventFlow
|
import org.xtimms.shirizu.utils.lang.MutableEventFlow
|
||||||
import org.xtimms.etsudoku.utils.lang.call
|
import org.xtimms.shirizu.utils.lang.call
|
||||||
import kotlin.coroutines.CoroutineContext
|
import kotlin.coroutines.CoroutineContext
|
||||||
import kotlin.coroutines.EmptyCoroutineContext
|
import kotlin.coroutines.EmptyCoroutineContext
|
||||||
import kotlin.coroutines.cancellation.CancellationException
|
import kotlin.coroutines.cancellation.CancellationException
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
package org.xtimms.etsudoku.core.base.viewmodel
|
package org.xtimms.shirizu.core.base.viewmodel
|
||||||
|
|
||||||
import androidx.lifecycle.ViewModel
|
import androidx.lifecycle.ViewModel
|
||||||
import androidx.lifecycle.viewModelScope
|
import androidx.lifecycle.viewModelScope
|
||||||
@@ -17,9 +17,9 @@ import kotlinx.coroutines.flow.onStart
|
|||||||
import kotlinx.coroutines.flow.stateIn
|
import kotlinx.coroutines.flow.stateIn
|
||||||
import kotlinx.coroutines.flow.update
|
import kotlinx.coroutines.flow.update
|
||||||
import kotlinx.coroutines.launch
|
import kotlinx.coroutines.launch
|
||||||
import org.xtimms.etsudoku.utils.lang.EventFlow
|
import org.xtimms.shirizu.utils.lang.EventFlow
|
||||||
import org.xtimms.etsudoku.utils.lang.MutableEventFlow
|
import org.xtimms.shirizu.utils.lang.MutableEventFlow
|
||||||
import org.xtimms.etsudoku.utils.lang.call
|
import org.xtimms.shirizu.utils.lang.call
|
||||||
import kotlin.coroutines.CoroutineContext
|
import kotlin.coroutines.CoroutineContext
|
||||||
import kotlin.coroutines.EmptyCoroutineContext
|
import kotlin.coroutines.EmptyCoroutineContext
|
||||||
import kotlin.coroutines.cancellation.CancellationException
|
import kotlin.coroutines.cancellation.CancellationException
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
package org.xtimms.etsudoku.core.cache
|
package org.xtimms.shirizu.core.cache
|
||||||
|
|
||||||
enum class CacheDir(val dir: String) {
|
enum class CacheDir(val dir: String) {
|
||||||
|
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
package org.xtimms.etsudoku.core.cache
|
package org.xtimms.shirizu.core.cache
|
||||||
|
|
||||||
import org.koitharu.kotatsu.parsers.model.Manga
|
import org.koitharu.kotatsu.parsers.model.Manga
|
||||||
import org.koitharu.kotatsu.parsers.model.MangaPage
|
import org.koitharu.kotatsu.parsers.model.MangaPage
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
package org.xtimms.etsudoku.core.cache
|
package org.xtimms.shirizu.core.cache
|
||||||
|
|
||||||
import androidx.collection.LruCache
|
import androidx.collection.LruCache
|
||||||
import java.util.concurrent.TimeUnit
|
import java.util.concurrent.TimeUnit
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
package org.xtimms.etsudoku.core.cache
|
package org.xtimms.shirizu.core.cache
|
||||||
|
|
||||||
import android.os.SystemClock
|
import android.os.SystemClock
|
||||||
import java.util.concurrent.TimeUnit
|
import java.util.concurrent.TimeUnit
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
package org.xtimms.etsudoku.core.cache
|
package org.xtimms.shirizu.core.cache
|
||||||
|
|
||||||
import android.app.Application
|
import android.app.Application
|
||||||
import android.content.ComponentCallbacks2
|
import android.content.ComponentCallbacks2
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
package org.xtimms.etsudoku.core.cache
|
package org.xtimms.shirizu.core.cache
|
||||||
|
|
||||||
import android.content.Context
|
import android.content.Context
|
||||||
import android.graphics.Bitmap
|
import android.graphics.Bitmap
|
||||||
@@ -13,13 +13,13 @@ import okio.buffer
|
|||||||
import okio.sink
|
import okio.sink
|
||||||
import org.koitharu.kotatsu.parsers.util.SuspendLazy
|
import org.koitharu.kotatsu.parsers.util.SuspendLazy
|
||||||
import org.koitharu.kotatsu.parsers.util.runCatchingCancellable
|
import org.koitharu.kotatsu.parsers.util.runCatchingCancellable
|
||||||
import org.xtimms.etsudoku.utils.FileSize
|
import org.xtimms.shirizu.utils.FileSize
|
||||||
import org.xtimms.etsudoku.utils.lang.longHashCode
|
import org.xtimms.shirizu.utils.lang.longHashCode
|
||||||
import org.xtimms.etsudoku.utils.lang.writeAllCancellable
|
import org.xtimms.shirizu.utils.lang.writeAllCancellable
|
||||||
import org.xtimms.etsudoku.utils.system.compressToPNG
|
import org.xtimms.shirizu.utils.system.compressToPNG
|
||||||
import org.xtimms.etsudoku.utils.system.subdir
|
import org.xtimms.shirizu.utils.system.subdir
|
||||||
import org.xtimms.etsudoku.utils.system.takeIfReadable
|
import org.xtimms.shirizu.utils.system.takeIfReadable
|
||||||
import org.xtimms.etsudoku.utils.system.takeIfWriteable
|
import org.xtimms.shirizu.utils.system.takeIfWriteable
|
||||||
import java.io.File
|
import java.io.File
|
||||||
import javax.inject.Inject
|
import javax.inject.Inject
|
||||||
import javax.inject.Singleton
|
import javax.inject.Singleton
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
package org.xtimms.etsudoku.core.cache
|
package org.xtimms.shirizu.core.cache
|
||||||
|
|
||||||
import kotlinx.coroutines.Deferred
|
import kotlinx.coroutines.Deferred
|
||||||
|
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
package org.xtimms.etsudoku.core.cache
|
package org.xtimms.shirizu.core.cache
|
||||||
|
|
||||||
import org.koitharu.kotatsu.parsers.model.Manga
|
import org.koitharu.kotatsu.parsers.model.Manga
|
||||||
import org.koitharu.kotatsu.parsers.model.MangaPage
|
import org.koitharu.kotatsu.parsers.model.MangaPage
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
package org.xtimms.etsudoku.core.components
|
package org.xtimms.shirizu.core.components
|
||||||
|
|
||||||
import androidx.compose.animation.core.animateDpAsState
|
import androidx.compose.animation.core.animateDpAsState
|
||||||
import androidx.compose.foundation.ExperimentalFoundationApi
|
import androidx.compose.foundation.ExperimentalFoundationApi
|
||||||
@@ -31,7 +31,7 @@ import androidx.compose.ui.platform.LocalDensity
|
|||||||
import androidx.compose.ui.tooling.preview.Preview
|
import androidx.compose.ui.tooling.preview.Preview
|
||||||
import androidx.compose.ui.unit.dp
|
import androidx.compose.ui.unit.dp
|
||||||
import androidx.compose.ui.unit.min
|
import androidx.compose.ui.unit.min
|
||||||
import org.xtimms.etsudoku.ui.theme.EtsudokuTheme
|
import org.xtimms.shirizu.ui.theme.ShirizuTheme
|
||||||
import java.lang.Integer.MAX_VALUE
|
import java.lang.Integer.MAX_VALUE
|
||||||
import kotlin.math.min
|
import kotlin.math.min
|
||||||
|
|
||||||
@@ -105,7 +105,7 @@ fun AnimatedButton(
|
|||||||
@Preview(name = "Icon")
|
@Preview(name = "Icon")
|
||||||
@Composable
|
@Composable
|
||||||
private fun PreviewWithIcon() {
|
private fun PreviewWithIcon() {
|
||||||
EtsudokuTheme {
|
ShirizuTheme {
|
||||||
AnimatedButton(
|
AnimatedButton(
|
||||||
type = ButtonType.PRIMARY,
|
type = ButtonType.PRIMARY,
|
||||||
icon = Icons.Outlined.Edit
|
icon = Icons.Outlined.Edit
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
package org.xtimms.etsudoku.core.components
|
package org.xtimms.shirizu.core.components
|
||||||
|
|
||||||
import androidx.compose.animation.AnimatedContent
|
import androidx.compose.animation.AnimatedContent
|
||||||
import androidx.compose.animation.SizeTransform
|
import androidx.compose.animation.SizeTransform
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
package org.xtimms.etsudoku.core.components
|
package org.xtimms.shirizu.core.components
|
||||||
|
|
||||||
import androidx.compose.animation.core.Animatable
|
import androidx.compose.animation.core.Animatable
|
||||||
import androidx.compose.animation.core.TweenSpec
|
import androidx.compose.animation.core.TweenSpec
|
||||||
@@ -14,8 +14,8 @@ import androidx.compose.ui.Modifier
|
|||||||
import androidx.compose.ui.graphics.Color
|
import androidx.compose.ui.graphics.Color
|
||||||
import androidx.compose.ui.unit.dp
|
import androidx.compose.ui.unit.dp
|
||||||
import androidx.compose.ui.unit.times
|
import androidx.compose.ui.unit.times
|
||||||
import org.xtimms.etsudoku.core.components.shape.WavyShape
|
import org.xtimms.shirizu.core.components.shape.WavyShape
|
||||||
import org.xtimms.etsudoku.utils.lang.clamp
|
import org.xtimms.shirizu.utils.lang.clamp
|
||||||
|
|
||||||
@Composable
|
@Composable
|
||||||
fun BackgroundProgress(
|
fun BackgroundProgress(
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
package org.xtimms.etsudoku.core.components
|
package org.xtimms.shirizu.core.components
|
||||||
|
|
||||||
import androidx.compose.animation.AnimatedVisibility
|
import androidx.compose.animation.AnimatedVisibility
|
||||||
import androidx.compose.animation.core.Animatable
|
import androidx.compose.animation.core.Animatable
|
||||||
@@ -19,11 +19,11 @@ import androidx.navigation.NavController
|
|||||||
import androidx.navigation.NavGraph.Companion.findStartDestination
|
import androidx.navigation.NavGraph.Companion.findStartDestination
|
||||||
import androidx.navigation.compose.currentBackStackEntryAsState
|
import androidx.navigation.compose.currentBackStackEntryAsState
|
||||||
import kotlinx.coroutines.launch
|
import kotlinx.coroutines.launch
|
||||||
import org.xtimms.etsudoku.core.BottomNavDestination
|
import org.xtimms.shirizu.core.BottomNavDestination
|
||||||
import org.xtimms.etsudoku.core.BottomNavDestination.Companion.Icon
|
import org.xtimms.shirizu.core.BottomNavDestination.Companion.Icon
|
||||||
import org.xtimms.etsudoku.sections.explore.EXPLORE_DESTINATION
|
import org.xtimms.shirizu.sections.explore.EXPLORE_DESTINATION
|
||||||
import org.xtimms.etsudoku.sections.history.HISTORY_DESTINATION
|
import org.xtimms.shirizu.sections.history.HISTORY_DESTINATION
|
||||||
import org.xtimms.etsudoku.sections.shelf.SHELF_DESTINATION
|
import org.xtimms.shirizu.sections.shelf.SHELF_DESTINATION
|
||||||
|
|
||||||
@Composable
|
@Composable
|
||||||
fun BottomNavBar(
|
fun BottomNavBar(
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
package org.xtimms.etsudoku.core.components
|
package org.xtimms.shirizu.core.components
|
||||||
|
|
||||||
import androidx.compose.foundation.layout.Arrangement
|
import androidx.compose.foundation.layout.Arrangement
|
||||||
import androidx.compose.foundation.layout.Column
|
import androidx.compose.foundation.layout.Column
|
||||||
@@ -12,7 +12,7 @@ import androidx.compose.ui.graphics.vector.ImageVector
|
|||||||
import androidx.compose.ui.res.stringResource
|
import androidx.compose.ui.res.stringResource
|
||||||
import androidx.compose.ui.text.style.TextAlign
|
import androidx.compose.ui.text.style.TextAlign
|
||||||
import androidx.compose.ui.unit.dp
|
import androidx.compose.ui.unit.dp
|
||||||
import org.xtimms.etsudoku.R
|
import org.xtimms.shirizu.R
|
||||||
|
|
||||||
@Composable
|
@Composable
|
||||||
fun ConfirmButton(
|
fun ConfirmButton(
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
package org.xtimms.etsudoku.core.components
|
package org.xtimms.shirizu.core.components
|
||||||
|
|
||||||
import androidx.compose.foundation.layout.Row
|
import androidx.compose.foundation.layout.Row
|
||||||
import androidx.compose.foundation.layout.fillMaxWidth
|
import androidx.compose.foundation.layout.fillMaxWidth
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
package org.xtimms.etsudoku.core.components
|
package org.xtimms.shirizu.core.components
|
||||||
|
|
||||||
import androidx.compose.animation.AnimatedVisibility
|
import androidx.compose.animation.AnimatedVisibility
|
||||||
import androidx.compose.animation.core.animateFloatAsState
|
import androidx.compose.animation.core.animateFloatAsState
|
||||||
@@ -23,9 +23,9 @@ import androidx.compose.ui.res.stringResource
|
|||||||
import androidx.compose.ui.unit.dp
|
import androidx.compose.ui.unit.dp
|
||||||
import androidx.navigation.NavController
|
import androidx.navigation.NavController
|
||||||
import androidx.navigation.compose.currentBackStackEntryAsState
|
import androidx.navigation.compose.currentBackStackEntryAsState
|
||||||
import org.xtimms.etsudoku.R
|
import org.xtimms.shirizu.R
|
||||||
import org.xtimms.etsudoku.sections.history.HISTORY_DESTINATION
|
import org.xtimms.shirizu.sections.history.HISTORY_DESTINATION
|
||||||
import org.xtimms.etsudoku.sections.reader.READER_DESTINATION
|
import org.xtimms.shirizu.sections.reader.READER_DESTINATION
|
||||||
|
|
||||||
@Composable
|
@Composable
|
||||||
fun ContinueReadingButton(
|
fun ContinueReadingButton(
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
package org.xtimms.etsudoku.core.components
|
package org.xtimms.shirizu.core.components
|
||||||
|
|
||||||
import androidx.compose.animation.core.animateDpAsState
|
import androidx.compose.animation.core.animateDpAsState
|
||||||
import androidx.compose.foundation.background
|
import androidx.compose.foundation.background
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
package org.xtimms.etsudoku.core.components
|
package org.xtimms.shirizu.core.components
|
||||||
|
|
||||||
import androidx.compose.foundation.layout.Arrangement
|
import androidx.compose.foundation.layout.Arrangement
|
||||||
import androidx.compose.foundation.layout.Box
|
import androidx.compose.foundation.layout.Box
|
||||||
@@ -34,7 +34,7 @@ private val ButtonsCrossAxisSpacing = Arrangement.spacedBy(12.dp, Alignment.Top)
|
|||||||
|
|
||||||
@OptIn(ExperimentalMaterial3Api::class, ExperimentalLayoutApi::class)
|
@OptIn(ExperimentalMaterial3Api::class, ExperimentalLayoutApi::class)
|
||||||
@Composable
|
@Composable
|
||||||
fun EtsudokuDialog(
|
fun ShirizuDialog(
|
||||||
onDismissRequest: () -> Unit,
|
onDismissRequest: () -> Unit,
|
||||||
confirmButton: @Composable () -> Unit,
|
confirmButton: @Composable () -> Unit,
|
||||||
modifier: Modifier = Modifier,
|
modifier: Modifier = Modifier,
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
package org.xtimms.etsudoku.core.components
|
package org.xtimms.shirizu.core.components
|
||||||
|
|
||||||
import androidx.compose.material3.Text
|
import androidx.compose.material3.Text
|
||||||
import androidx.compose.runtime.Composable
|
import androidx.compose.runtime.Composable
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
package org.xtimms.etsudoku.core.components
|
package org.xtimms.shirizu.core.components
|
||||||
|
|
||||||
import androidx.compose.foundation.layout.Row
|
import androidx.compose.foundation.layout.Row
|
||||||
import androidx.compose.foundation.layout.height
|
import androidx.compose.foundation.layout.height
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
package org.xtimms.etsudoku.core.components
|
package org.xtimms.shirizu.core.components
|
||||||
|
|
||||||
import androidx.compose.animation.AnimatedVisibility
|
import androidx.compose.animation.AnimatedVisibility
|
||||||
import androidx.compose.animation.core.CubicBezierEasing
|
import androidx.compose.animation.core.CubicBezierEasing
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
package org.xtimms.etsudoku.core.components
|
package org.xtimms.shirizu.core.components
|
||||||
|
|
||||||
import android.text.Spanned
|
import android.text.Spanned
|
||||||
import android.text.style.BulletSpan
|
import android.text.style.BulletSpan
|
||||||
@@ -28,7 +28,7 @@ import androidx.compose.ui.text.style.TextOverflow
|
|||||||
import androidx.compose.ui.unit.TextUnit
|
import androidx.compose.ui.unit.TextUnit
|
||||||
import androidx.compose.ui.unit.sp
|
import androidx.compose.ui.unit.sp
|
||||||
import androidx.core.text.HtmlCompat
|
import androidx.core.text.HtmlCompat
|
||||||
import org.xtimms.etsudoku.utils.spanStyle
|
import org.xtimms.shirizu.utils.spanStyle
|
||||||
|
|
||||||
private const val URL_TAG = "url_tag"
|
private const val URL_TAG = "url_tag"
|
||||||
|
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
package org.xtimms.etsudoku.core.components
|
package org.xtimms.shirizu.core.components
|
||||||
|
|
||||||
import androidx.compose.foundation.layout.padding
|
import androidx.compose.foundation.layout.padding
|
||||||
import androidx.compose.material.icons.Icons
|
import androidx.compose.material.icons.Icons
|
||||||
@@ -14,7 +14,7 @@ import androidx.compose.runtime.Composable
|
|||||||
import androidx.compose.ui.Modifier
|
import androidx.compose.ui.Modifier
|
||||||
import androidx.compose.ui.res.stringResource
|
import androidx.compose.ui.res.stringResource
|
||||||
import androidx.compose.ui.unit.dp
|
import androidx.compose.ui.unit.dp
|
||||||
import org.xtimms.etsudoku.R
|
import org.xtimms.shirizu.R
|
||||||
|
|
||||||
@Composable
|
@Composable
|
||||||
fun BackIconButton(
|
fun BackIconButton(
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
package org.xtimms.etsudoku.core.components
|
package org.xtimms.shirizu.core.components
|
||||||
|
|
||||||
import androidx.compose.foundation.layout.padding
|
import androidx.compose.foundation.layout.padding
|
||||||
import androidx.compose.material3.MaterialTheme
|
import androidx.compose.material3.MaterialTheme
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
package org.xtimms.etsudoku.core.components
|
package org.xtimms.shirizu.core.components
|
||||||
|
|
||||||
import androidx.compose.foundation.Image
|
import androidx.compose.foundation.Image
|
||||||
import androidx.compose.foundation.clickable
|
import androidx.compose.foundation.clickable
|
||||||
@@ -14,7 +14,7 @@ import androidx.compose.ui.layout.ContentScale
|
|||||||
import androidx.compose.ui.semantics.Role
|
import androidx.compose.ui.semantics.Role
|
||||||
import coil.ImageLoader
|
import coil.ImageLoader
|
||||||
import coil.compose.AsyncImage
|
import coil.compose.AsyncImage
|
||||||
import org.xtimms.etsudoku.core.AsyncImageImpl
|
import org.xtimms.shirizu.core.AsyncImageImpl
|
||||||
|
|
||||||
enum class MangaCover(val ratio: Float) {
|
enum class MangaCover(val ratio: Float) {
|
||||||
Square(1f / 1f),
|
Square(1f / 1f),
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
package org.xtimms.etsudoku.core.components
|
package org.xtimms.shirizu.core.components
|
||||||
|
|
||||||
import androidx.compose.foundation.ExperimentalFoundationApi
|
import androidx.compose.foundation.ExperimentalFoundationApi
|
||||||
import androidx.compose.foundation.background
|
import androidx.compose.foundation.background
|
||||||
@@ -33,7 +33,7 @@ import androidx.compose.ui.unit.dp
|
|||||||
import androidx.compose.ui.unit.sp
|
import androidx.compose.ui.unit.sp
|
||||||
import coil.ImageLoader
|
import coil.ImageLoader
|
||||||
import org.koitharu.kotatsu.parsers.model.Manga
|
import org.koitharu.kotatsu.parsers.model.Manga
|
||||||
import org.xtimms.etsudoku.core.AsyncImageImpl
|
import org.xtimms.shirizu.core.AsyncImageImpl
|
||||||
|
|
||||||
private const val GridSelectedCoverAlpha = 0.76f
|
private const val GridSelectedCoverAlpha = 0.76f
|
||||||
|
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
package org.xtimms.etsudoku.core.components
|
package org.xtimms.shirizu.core.components
|
||||||
|
|
||||||
import androidx.compose.foundation.layout.Arrangement
|
import androidx.compose.foundation.layout.Arrangement
|
||||||
import androidx.compose.foundation.layout.Column
|
import androidx.compose.foundation.layout.Column
|
||||||
@@ -19,9 +19,9 @@ import androidx.compose.ui.res.stringResource
|
|||||||
import androidx.navigation.NavController
|
import androidx.navigation.NavController
|
||||||
import androidx.navigation.NavGraph.Companion.findStartDestination
|
import androidx.navigation.NavGraph.Companion.findStartDestination
|
||||||
import androidx.navigation.compose.currentBackStackEntryAsState
|
import androidx.navigation.compose.currentBackStackEntryAsState
|
||||||
import org.xtimms.etsudoku.core.BottomNavDestination
|
import org.xtimms.shirizu.core.BottomNavDestination
|
||||||
import org.xtimms.etsudoku.core.BottomNavDestination.Companion.Icon
|
import org.xtimms.shirizu.core.BottomNavDestination.Companion.Icon
|
||||||
import org.xtimms.etsudoku.sections.search.SEARCH_DESTINATION
|
import org.xtimms.shirizu.sections.search.SEARCH_DESTINATION
|
||||||
|
|
||||||
@Composable
|
@Composable
|
||||||
fun NavigationRail(
|
fun NavigationRail(
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
package org.xtimms.etsudoku.core.components
|
package org.xtimms.shirizu.core.components
|
||||||
|
|
||||||
import androidx.compose.foundation.layout.Box
|
import androidx.compose.foundation.layout.Box
|
||||||
import androidx.compose.foundation.layout.padding
|
import androidx.compose.foundation.layout.padding
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
package org.xtimms.etsudoku.core.components
|
package org.xtimms.shirizu.core.components
|
||||||
|
|
||||||
import androidx.compose.animation.AnimatedContent
|
import androidx.compose.animation.AnimatedContent
|
||||||
import androidx.compose.animation.SizeTransform
|
import androidx.compose.animation.SizeTransform
|
||||||
@@ -65,14 +65,14 @@ import androidx.compose.ui.text.style.TextOverflow
|
|||||||
import androidx.compose.ui.tooling.preview.Preview
|
import androidx.compose.ui.tooling.preview.Preview
|
||||||
import androidx.compose.ui.unit.dp
|
import androidx.compose.ui.unit.dp
|
||||||
import androidx.compose.ui.unit.sp
|
import androidx.compose.ui.unit.sp
|
||||||
import org.xtimms.etsudoku.ui.theme.FixedAccentColors
|
import org.xtimms.shirizu.ui.theme.FixedAccentColors
|
||||||
import org.xtimms.etsudoku.R
|
import org.xtimms.shirizu.R
|
||||||
import org.xtimms.etsudoku.ui.monet.LocalTonalPalettes
|
import org.xtimms.shirizu.ui.monet.LocalTonalPalettes
|
||||||
import org.xtimms.etsudoku.ui.monet.TonalPalettes.Companion.toTonalPalettes
|
import org.xtimms.shirizu.ui.monet.TonalPalettes.Companion.toTonalPalettes
|
||||||
import org.xtimms.etsudoku.ui.theme.PreviewThemeLight
|
import org.xtimms.shirizu.ui.theme.PreviewThemeLight
|
||||||
import org.xtimms.etsudoku.ui.theme.EtsudokuTheme
|
import org.xtimms.shirizu.ui.theme.ShirizuTheme
|
||||||
import org.xtimms.etsudoku.ui.theme.applyOpacity
|
import org.xtimms.shirizu.ui.theme.applyOpacity
|
||||||
import org.xtimms.etsudoku.utils.FileSize
|
import org.xtimms.shirizu.utils.FileSize
|
||||||
|
|
||||||
private const val horizontal = 8
|
private const val horizontal = 8
|
||||||
private const val vertical = 16
|
private const val vertical = 16
|
||||||
@@ -754,7 +754,7 @@ fun PreferenceStorageItem(
|
|||||||
@Composable
|
@Composable
|
||||||
@Preview(showBackground = true)
|
@Preview(showBackground = true)
|
||||||
fun PreferenceStorageHeaderPreview() {
|
fun PreferenceStorageHeaderPreview() {
|
||||||
EtsudokuTheme {
|
ShirizuTheme {
|
||||||
PreferenceStorageHeader()
|
PreferenceStorageHeader()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -762,7 +762,7 @@ fun PreferenceStorageHeaderPreview() {
|
|||||||
@Composable
|
@Composable
|
||||||
@Preview(showBackground = true)
|
@Preview(showBackground = true)
|
||||||
fun PreferenceStorageItemPreview() {
|
fun PreferenceStorageItemPreview() {
|
||||||
EtsudokuTheme {
|
ShirizuTheme {
|
||||||
PreferenceStorageItem(title = "Saved manga", icon = Icons.Outlined.Save, total = 0F)
|
PreferenceStorageItem(title = "Saved manga", icon = Icons.Outlined.Save, total = 0F)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
package org.xtimms.etsudoku.core.components
|
package org.xtimms.shirizu.core.components
|
||||||
|
|
||||||
import androidx.compose.animation.core.animate
|
import androidx.compose.animation.core.animate
|
||||||
import androidx.compose.foundation.layout.Box
|
import androidx.compose.foundation.layout.Box
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
package org.xtimms.etsudoku.core.components
|
package org.xtimms.shirizu.core.components
|
||||||
|
|
||||||
import android.content.res.Configuration.UI_MODE_NIGHT_YES
|
import android.content.res.Configuration.UI_MODE_NIGHT_YES
|
||||||
import androidx.compose.animation.AnimatedContent
|
import androidx.compose.animation.AnimatedContent
|
||||||
@@ -46,10 +46,10 @@ import androidx.compose.ui.res.stringResource
|
|||||||
import androidx.compose.ui.tooling.preview.Preview
|
import androidx.compose.ui.tooling.preview.Preview
|
||||||
import androidx.compose.ui.unit.dp
|
import androidx.compose.ui.unit.dp
|
||||||
import kotlinx.coroutines.launch
|
import kotlinx.coroutines.launch
|
||||||
import org.xtimms.etsudoku.R
|
import org.xtimms.shirizu.R
|
||||||
import org.xtimms.etsudoku.core.model.MangaHistory
|
import org.xtimms.shirizu.core.model.MangaHistory
|
||||||
import org.xtimms.etsudoku.sections.details.model.HistoryInfo
|
import org.xtimms.shirizu.sections.details.model.HistoryInfo
|
||||||
import org.xtimms.etsudoku.ui.theme.EtsudokuTheme
|
import org.xtimms.shirizu.ui.theme.ShirizuTheme
|
||||||
import java.time.Instant
|
import java.time.Instant
|
||||||
|
|
||||||
@Composable
|
@Composable
|
||||||
@@ -198,7 +198,7 @@ fun Modifier.drawWithLayer(block: ContentDrawScope.() -> Unit) = this.then(
|
|||||||
@Preview
|
@Preview
|
||||||
@Composable
|
@Composable
|
||||||
private fun Preview() {
|
private fun Preview() {
|
||||||
EtsudokuTheme {
|
ShirizuTheme {
|
||||||
Row {
|
Row {
|
||||||
ReadButton(
|
ReadButton(
|
||||||
HistoryInfo(
|
HistoryInfo(
|
||||||
@@ -222,7 +222,7 @@ private fun Preview() {
|
|||||||
@Preview(name = "Night mode", uiMode = UI_MODE_NIGHT_YES)
|
@Preview(name = "Night mode", uiMode = UI_MODE_NIGHT_YES)
|
||||||
@Composable
|
@Composable
|
||||||
private fun PreviewNightMode() {
|
private fun PreviewNightMode() {
|
||||||
EtsudokuTheme {
|
ShirizuTheme {
|
||||||
Row {
|
Row {
|
||||||
ReadButton(
|
ReadButton(
|
||||||
HistoryInfo(
|
HistoryInfo(
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
package org.xtimms.etsudoku.core.components
|
package org.xtimms.shirizu.core.components
|
||||||
|
|
||||||
import androidx.compose.foundation.layout.PaddingValues
|
import androidx.compose.foundation.layout.PaddingValues
|
||||||
import androidx.compose.foundation.layout.RowScope
|
import androidx.compose.foundation.layout.RowScope
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
package org.xtimms.etsudoku.core.components
|
package org.xtimms.shirizu.core.components
|
||||||
|
|
||||||
import androidx.compose.foundation.layout.Row
|
import androidx.compose.foundation.layout.Row
|
||||||
import androidx.compose.foundation.layout.padding
|
import androidx.compose.foundation.layout.padding
|
||||||
@@ -15,9 +15,9 @@ import androidx.compose.ui.tooling.preview.Preview
|
|||||||
import androidx.compose.ui.unit.TextUnit
|
import androidx.compose.ui.unit.TextUnit
|
||||||
import androidx.compose.ui.unit.dp
|
import androidx.compose.ui.unit.dp
|
||||||
import androidx.compose.ui.unit.sp
|
import androidx.compose.ui.unit.sp
|
||||||
import org.xtimms.etsudoku.R
|
import org.xtimms.shirizu.R
|
||||||
import org.xtimms.etsudoku.ui.theme.EtsudokuTheme
|
import org.xtimms.shirizu.ui.theme.ShirizuTheme
|
||||||
import org.xtimms.etsudoku.utils.lang.toStringPositiveValueOrUnknown
|
import org.xtimms.shirizu.utils.lang.toStringPositiveValueOrUnknown
|
||||||
|
|
||||||
@Composable
|
@Composable
|
||||||
fun SmallScoreIndicator(
|
fun SmallScoreIndicator(
|
||||||
@@ -48,7 +48,7 @@ fun SmallScoreIndicator(
|
|||||||
@Preview(showBackground = true)
|
@Preview(showBackground = true)
|
||||||
@Composable
|
@Composable
|
||||||
fun SmallScoreIndicatorPreview() {
|
fun SmallScoreIndicatorPreview() {
|
||||||
EtsudokuTheme {
|
ShirizuTheme {
|
||||||
SmallScoreIndicator(score = 1f)
|
SmallScoreIndicator(score = 1f)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
package org.xtimms.etsudoku.core.components
|
package org.xtimms.shirizu.core.components
|
||||||
|
|
||||||
import androidx.compose.animation.animateContentSize
|
import androidx.compose.animation.animateContentSize
|
||||||
import androidx.compose.animation.core.Spring
|
import androidx.compose.animation.core.Spring
|
||||||
@@ -25,7 +25,7 @@ import androidx.compose.runtime.setValue
|
|||||||
import androidx.compose.ui.Modifier
|
import androidx.compose.ui.Modifier
|
||||||
import androidx.compose.ui.res.stringResource
|
import androidx.compose.ui.res.stringResource
|
||||||
import androidx.compose.ui.unit.dp
|
import androidx.compose.ui.unit.dp
|
||||||
import org.xtimms.etsudoku.R
|
import org.xtimms.shirizu.R
|
||||||
|
|
||||||
@Composable
|
@Composable
|
||||||
@OptIn(ExperimentalMaterial3Api::class)
|
@OptIn(ExperimentalMaterial3Api::class)
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
package org.xtimms.etsudoku.core.components
|
package org.xtimms.shirizu.core.components
|
||||||
|
|
||||||
import androidx.compose.animation.AnimatedContent
|
import androidx.compose.animation.AnimatedContent
|
||||||
import androidx.compose.animation.SizeTransform
|
import androidx.compose.animation.SizeTransform
|
||||||
@@ -20,7 +20,7 @@ import androidx.compose.ui.Alignment
|
|||||||
import androidx.compose.ui.Modifier
|
import androidx.compose.ui.Modifier
|
||||||
import androidx.compose.ui.graphics.vector.ImageVector
|
import androidx.compose.ui.graphics.vector.ImageVector
|
||||||
import androidx.compose.ui.unit.dp
|
import androidx.compose.ui.unit.dp
|
||||||
import org.xtimms.etsudoku.ui.theme.applyOpacity
|
import org.xtimms.shirizu.ui.theme.applyOpacity
|
||||||
|
|
||||||
@Composable
|
@Composable
|
||||||
fun SettingTitle(text: String) {
|
fun SettingTitle(text: String) {
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
package org.xtimms.etsudoku.core.components
|
package org.xtimms.shirizu.core.components
|
||||||
|
|
||||||
import android.net.Uri
|
import android.net.Uri
|
||||||
import androidx.compose.foundation.clickable
|
import androidx.compose.foundation.clickable
|
||||||
@@ -24,8 +24,8 @@ import androidx.compose.ui.unit.dp
|
|||||||
import androidx.compose.ui.unit.sp
|
import androidx.compose.ui.unit.sp
|
||||||
import androidx.core.net.toUri
|
import androidx.core.net.toUri
|
||||||
import coil.ImageLoader
|
import coil.ImageLoader
|
||||||
import org.xtimms.etsudoku.core.AsyncImageImpl
|
import org.xtimms.shirizu.core.AsyncImageImpl
|
||||||
import org.xtimms.etsudoku.ui.theme.EtsudokuTheme
|
import org.xtimms.shirizu.ui.theme.ShirizuTheme
|
||||||
|
|
||||||
@Composable
|
@Composable
|
||||||
fun SourceItem(
|
fun SourceItem(
|
||||||
@@ -77,7 +77,7 @@ fun SourceItem(
|
|||||||
@Preview
|
@Preview
|
||||||
@Composable
|
@Composable
|
||||||
fun SourceItemPreview() {
|
fun SourceItemPreview() {
|
||||||
EtsudokuTheme {
|
ShirizuTheme {
|
||||||
SourceItem(
|
SourceItem(
|
||||||
coil = ImageLoader(LocalContext.current),
|
coil = ImageLoader(LocalContext.current),
|
||||||
faviconUrl = "".toUri(),
|
faviconUrl = "".toUri(),
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
package org.xtimms.etsudoku.core.components
|
package org.xtimms.shirizu.core.components
|
||||||
|
|
||||||
import androidx.compose.foundation.isSystemInDarkTheme
|
import androidx.compose.foundation.isSystemInDarkTheme
|
||||||
import androidx.compose.foundation.layout.Row
|
import androidx.compose.foundation.layout.Row
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
package org.xtimms.etsudoku.core.components
|
package org.xtimms.shirizu.core.components
|
||||||
|
|
||||||
import android.graphics.Path
|
import android.graphics.Path
|
||||||
import android.view.animation.PathInterpolator
|
import android.view.animation.PathInterpolator
|
||||||
@@ -84,18 +84,18 @@ import androidx.compose.ui.unit.dp
|
|||||||
import androidx.navigation.NavController
|
import androidx.navigation.NavController
|
||||||
import androidx.navigation.NavHostController
|
import androidx.navigation.NavHostController
|
||||||
import androidx.navigation.compose.currentBackStackEntryAsState
|
import androidx.navigation.compose.currentBackStackEntryAsState
|
||||||
import org.xtimms.etsudoku.R
|
import org.xtimms.shirizu.R
|
||||||
import org.xtimms.etsudoku.core.DURATION_ENTER
|
import org.xtimms.shirizu.core.DURATION_ENTER
|
||||||
import org.xtimms.etsudoku.core.DURATION_EXIT
|
import org.xtimms.shirizu.core.DURATION_EXIT
|
||||||
import org.xtimms.etsudoku.core.initialOffset
|
import org.xtimms.shirizu.core.initialOffset
|
||||||
import org.xtimms.etsudoku.core.toEasing
|
import org.xtimms.shirizu.core.toEasing
|
||||||
import org.xtimms.etsudoku.sections.explore.EXPLORE_DESTINATION
|
import org.xtimms.shirizu.sections.explore.EXPLORE_DESTINATION
|
||||||
import org.xtimms.etsudoku.sections.feed.FEED_DESTINATION
|
import org.xtimms.shirizu.sections.feed.FEED_DESTINATION
|
||||||
import org.xtimms.etsudoku.sections.history.HISTORY_DESTINATION
|
import org.xtimms.shirizu.sections.history.HISTORY_DESTINATION
|
||||||
import org.xtimms.etsudoku.sections.search.SEARCH_DESTINATION
|
import org.xtimms.shirizu.sections.search.SEARCH_DESTINATION
|
||||||
import org.xtimms.etsudoku.sections.settings.SETTINGS_DESTINATION
|
import org.xtimms.shirizu.sections.settings.SETTINGS_DESTINATION
|
||||||
import org.xtimms.etsudoku.sections.shelf.SHELF_DESTINATION
|
import org.xtimms.shirizu.sections.shelf.SHELF_DESTINATION
|
||||||
import org.xtimms.etsudoku.ui.theme.EtsudokuTheme
|
import org.xtimms.shirizu.ui.theme.ShirizuTheme
|
||||||
import java.time.LocalDate
|
import java.time.LocalDate
|
||||||
import java.time.format.DateTimeFormatter
|
import java.time.format.DateTimeFormatter
|
||||||
|
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
package org.xtimms.etsudoku.core.components.effects
|
package org.xtimms.shirizu.core.components.effects
|
||||||
|
|
||||||
import android.annotation.SuppressLint
|
import android.annotation.SuppressLint
|
||||||
import androidx.compose.animation.AnimatedVisibility
|
import androidx.compose.animation.AnimatedVisibility
|
||||||
@@ -22,7 +22,7 @@ import androidx.recyclerview.widget.DiffUtil
|
|||||||
import androidx.recyclerview.widget.ListUpdateCallback
|
import androidx.recyclerview.widget.ListUpdateCallback
|
||||||
import kotlinx.coroutines.Dispatchers
|
import kotlinx.coroutines.Dispatchers
|
||||||
import kotlinx.coroutines.withContext
|
import kotlinx.coroutines.withContext
|
||||||
import org.xtimms.etsudoku.core.model.ListModel
|
import org.xtimms.shirizu.core.model.ListModel
|
||||||
import java.time.Instant
|
import java.time.Instant
|
||||||
|
|
||||||
enum class RowEntityType { Header, Item }
|
enum class RowEntityType { Header, Item }
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
package org.xtimms.etsudoku.core.components.effects
|
package org.xtimms.shirizu.core.components.effects
|
||||||
|
|
||||||
import androidx.compose.animation.core.LinearEasing
|
import androidx.compose.animation.core.LinearEasing
|
||||||
import androidx.compose.animation.core.RepeatMode
|
import androidx.compose.animation.core.RepeatMode
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
package org.xtimms.etsudoku.core.components.icons
|
package org.xtimms.shirizu.core.components.icons
|
||||||
|
|
||||||
import androidx.compose.material.icons.Icons
|
import androidx.compose.material.icons.Icons
|
||||||
import androidx.compose.material.icons.materialIcon
|
import androidx.compose.material.icons.materialIcon
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
package org.xtimms.etsudoku.core.components.icons
|
package org.xtimms.shirizu.core.components.icons
|
||||||
|
|
||||||
import androidx.compose.material.icons.Icons
|
import androidx.compose.material.icons.Icons
|
||||||
import androidx.compose.material.icons.materialIcon
|
import androidx.compose.material.icons.materialIcon
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
package org.xtimms.etsudoku.core.components.icons
|
package org.xtimms.shirizu.core.components.icons
|
||||||
|
|
||||||
import androidx.compose.material.icons.Icons
|
import androidx.compose.material.icons.Icons
|
||||||
import androidx.compose.ui.graphics.Color
|
import androidx.compose.ui.graphics.Color
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
package org.xtimms.etsudoku.core.components.shape
|
package org.xtimms.shirizu.core.components.shape
|
||||||
|
|
||||||
import androidx.compose.ui.geometry.Offset
|
import androidx.compose.ui.geometry.Offset
|
||||||
import androidx.compose.ui.geometry.Rect
|
import androidx.compose.ui.geometry.Rect
|
||||||
@@ -1,10 +1,10 @@
|
|||||||
package org.xtimms.etsudoku.core.database
|
package org.xtimms.shirizu.core.database
|
||||||
|
|
||||||
import android.content.res.Resources
|
import android.content.res.Resources
|
||||||
import androidx.room.RoomDatabase
|
import androidx.room.RoomDatabase
|
||||||
import androidx.sqlite.db.SupportSQLiteDatabase
|
import androidx.sqlite.db.SupportSQLiteDatabase
|
||||||
import org.koitharu.kotatsu.parsers.model.SortOrder
|
import org.koitharu.kotatsu.parsers.model.SortOrder
|
||||||
import org.xtimms.etsudoku.R
|
import org.xtimms.shirizu.R
|
||||||
|
|
||||||
class DatabasePrePopulateCallback(private val resources: Resources) : RoomDatabase.Callback() {
|
class DatabasePrePopulateCallback(private val resources: Resources) : RoomDatabase.Callback() {
|
||||||
|
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
package org.xtimms.etsudoku.core.database
|
package org.xtimms.shirizu.core.database
|
||||||
|
|
||||||
import android.content.Context
|
import android.content.Context
|
||||||
import androidx.room.Database
|
import androidx.room.Database
|
||||||
@@ -10,28 +10,28 @@ import kotlinx.coroutines.Dispatchers
|
|||||||
import kotlinx.coroutines.ExperimentalCoroutinesApi
|
import kotlinx.coroutines.ExperimentalCoroutinesApi
|
||||||
import kotlinx.coroutines.isActive
|
import kotlinx.coroutines.isActive
|
||||||
import kotlinx.coroutines.launch
|
import kotlinx.coroutines.launch
|
||||||
import org.xtimms.etsudoku.core.database.dao.BookmarksDao
|
import org.xtimms.shirizu.core.database.dao.BookmarksDao
|
||||||
import org.xtimms.etsudoku.core.database.dao.FavouriteCategoriesDao
|
import org.xtimms.shirizu.core.database.dao.FavouriteCategoriesDao
|
||||||
import org.xtimms.etsudoku.core.database.dao.FavouritesDao
|
import org.xtimms.shirizu.core.database.dao.FavouritesDao
|
||||||
import org.xtimms.etsudoku.core.database.dao.HistoryDao
|
import org.xtimms.shirizu.core.database.dao.HistoryDao
|
||||||
import org.xtimms.etsudoku.core.database.dao.MangaDao
|
import org.xtimms.shirizu.core.database.dao.MangaDao
|
||||||
import org.xtimms.etsudoku.core.database.dao.MangaSourcesDao
|
import org.xtimms.shirizu.core.database.dao.MangaSourcesDao
|
||||||
import org.xtimms.etsudoku.core.database.dao.SuggestionDao
|
import org.xtimms.shirizu.core.database.dao.SuggestionDao
|
||||||
import org.xtimms.etsudoku.core.database.dao.TagsDao
|
import org.xtimms.shirizu.core.database.dao.TagsDao
|
||||||
import org.xtimms.etsudoku.core.database.dao.TrackLogsDao
|
import org.xtimms.shirizu.core.database.dao.TrackLogsDao
|
||||||
import org.xtimms.etsudoku.core.database.dao.TracksDao
|
import org.xtimms.shirizu.core.database.dao.TracksDao
|
||||||
import org.xtimms.etsudoku.core.database.entity.BookmarkEntity
|
import org.xtimms.shirizu.core.database.entity.BookmarkEntity
|
||||||
import org.xtimms.etsudoku.core.database.entity.FavouriteCategoryEntity
|
import org.xtimms.shirizu.core.database.entity.FavouriteCategoryEntity
|
||||||
import org.xtimms.etsudoku.core.database.entity.FavouriteEntity
|
import org.xtimms.shirizu.core.database.entity.FavouriteEntity
|
||||||
import org.xtimms.etsudoku.core.database.entity.HistoryEntity
|
import org.xtimms.shirizu.core.database.entity.HistoryEntity
|
||||||
import org.xtimms.etsudoku.core.database.entity.MangaEntity
|
import org.xtimms.shirizu.core.database.entity.MangaEntity
|
||||||
import org.xtimms.etsudoku.core.database.entity.MangaSourceEntity
|
import org.xtimms.shirizu.core.database.entity.MangaSourceEntity
|
||||||
import org.xtimms.etsudoku.core.database.entity.MangaTagsEntity
|
import org.xtimms.shirizu.core.database.entity.MangaTagsEntity
|
||||||
import org.xtimms.etsudoku.core.database.entity.SuggestionEntity
|
import org.xtimms.shirizu.core.database.entity.SuggestionEntity
|
||||||
import org.xtimms.etsudoku.core.database.entity.TagEntity
|
import org.xtimms.shirizu.core.database.entity.TagEntity
|
||||||
import org.xtimms.etsudoku.core.database.entity.TrackEntity
|
import org.xtimms.shirizu.core.database.entity.TrackEntity
|
||||||
import org.xtimms.etsudoku.core.database.entity.TrackLogEntity
|
import org.xtimms.shirizu.core.database.entity.TrackLogEntity
|
||||||
import org.xtimms.etsudoku.utils.lang.processLifecycleScope
|
import org.xtimms.shirizu.utils.lang.processLifecycleScope
|
||||||
|
|
||||||
const val DATABASE_VERSION = 1
|
const val DATABASE_VERSION = 1
|
||||||
|
|
||||||
@@ -51,7 +51,7 @@ const val DATABASE_VERSION = 1
|
|||||||
],
|
],
|
||||||
version = DATABASE_VERSION
|
version = DATABASE_VERSION
|
||||||
)
|
)
|
||||||
abstract class EtsudokuDatabase : RoomDatabase() {
|
abstract class ShirizuDatabase : RoomDatabase() {
|
||||||
|
|
||||||
abstract fun getTagsDao(): TagsDao
|
abstract fun getTagsDao(): TagsDao
|
||||||
|
|
||||||
@@ -75,8 +75,8 @@ abstract class EtsudokuDatabase : RoomDatabase() {
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
fun EtsudokuDatabase(context: Context): EtsudokuDatabase = Room
|
fun ShirizuDatabase(context: Context): ShirizuDatabase = Room
|
||||||
.databaseBuilder(context, EtsudokuDatabase::class.java, "etsudoku-db")
|
.databaseBuilder(context, ShirizuDatabase::class.java, "shirizu-db")
|
||||||
.addCallback(DatabasePrePopulateCallback(context.resources))
|
.addCallback(DatabasePrePopulateCallback(context.resources))
|
||||||
.build()
|
.build()
|
||||||
|
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
package org.xtimms.etsudoku.core.database
|
package org.xtimms.shirizu.core.database
|
||||||
|
|
||||||
const val TABLE_MANGA = "manga"
|
const val TABLE_MANGA = "manga"
|
||||||
const val TABLE_TAGS = "tags"
|
const val TABLE_TAGS = "tags"
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
package org.xtimms.etsudoku.core.database.dao
|
package org.xtimms.shirizu.core.database.dao
|
||||||
|
|
||||||
import androidx.room.Dao
|
import androidx.room.Dao
|
||||||
import androidx.room.Delete
|
import androidx.room.Delete
|
||||||
@@ -7,8 +7,8 @@ import androidx.room.Query
|
|||||||
import androidx.room.Transaction
|
import androidx.room.Transaction
|
||||||
import androidx.room.Upsert
|
import androidx.room.Upsert
|
||||||
import kotlinx.coroutines.flow.Flow
|
import kotlinx.coroutines.flow.Flow
|
||||||
import org.xtimms.etsudoku.core.database.entity.BookmarkEntity
|
import org.xtimms.shirizu.core.database.entity.BookmarkEntity
|
||||||
import org.xtimms.etsudoku.core.database.entity.MangaWithTags
|
import org.xtimms.shirizu.core.database.entity.MangaWithTags
|
||||||
|
|
||||||
@Dao
|
@Dao
|
||||||
abstract class BookmarksDao {
|
abstract class BookmarksDao {
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
package org.xtimms.etsudoku.core.database.dao
|
package org.xtimms.shirizu.core.database.dao
|
||||||
|
|
||||||
import androidx.room.Dao
|
import androidx.room.Dao
|
||||||
import androidx.room.Insert
|
import androidx.room.Insert
|
||||||
@@ -6,7 +6,7 @@ import androidx.room.OnConflictStrategy
|
|||||||
import androidx.room.Query
|
import androidx.room.Query
|
||||||
import androidx.room.Upsert
|
import androidx.room.Upsert
|
||||||
import kotlinx.coroutines.flow.Flow
|
import kotlinx.coroutines.flow.Flow
|
||||||
import org.xtimms.etsudoku.core.database.entity.FavouriteCategoryEntity
|
import org.xtimms.shirizu.core.database.entity.FavouriteCategoryEntity
|
||||||
|
|
||||||
@Dao
|
@Dao
|
||||||
abstract class FavouriteCategoriesDao {
|
abstract class FavouriteCategoriesDao {
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
package org.xtimms.etsudoku.core.database.dao
|
package org.xtimms.shirizu.core.database.dao
|
||||||
|
|
||||||
import androidx.room.Dao
|
import androidx.room.Dao
|
||||||
import androidx.room.Insert
|
import androidx.room.Insert
|
||||||
@@ -11,10 +11,10 @@ import androidx.sqlite.db.SimpleSQLiteQuery
|
|||||||
import androidx.sqlite.db.SupportSQLiteQuery
|
import androidx.sqlite.db.SupportSQLiteQuery
|
||||||
import kotlinx.coroutines.flow.Flow
|
import kotlinx.coroutines.flow.Flow
|
||||||
import org.intellij.lang.annotations.Language
|
import org.intellij.lang.annotations.Language
|
||||||
import org.xtimms.etsudoku.core.database.entity.FavouriteEntity
|
import org.xtimms.shirizu.core.database.entity.FavouriteEntity
|
||||||
import org.xtimms.etsudoku.core.database.entity.MangaEntity
|
import org.xtimms.shirizu.core.database.entity.MangaEntity
|
||||||
import org.xtimms.etsudoku.core.model.ListSortOrder
|
import org.xtimms.shirizu.core.model.ListSortOrder
|
||||||
import org.xtimms.etsudoku.sections.shelf.FavouriteManga
|
import org.xtimms.shirizu.sections.shelf.FavouriteManga
|
||||||
|
|
||||||
@Dao
|
@Dao
|
||||||
abstract class FavouritesDao {
|
abstract class FavouritesDao {
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
package org.xtimms.etsudoku.core.database.dao
|
package org.xtimms.shirizu.core.database.dao
|
||||||
|
|
||||||
import androidx.room.Dao
|
import androidx.room.Dao
|
||||||
import androidx.room.Insert
|
import androidx.room.Insert
|
||||||
@@ -10,11 +10,11 @@ import androidx.sqlite.db.SimpleSQLiteQuery
|
|||||||
import androidx.sqlite.db.SupportSQLiteQuery
|
import androidx.sqlite.db.SupportSQLiteQuery
|
||||||
import kotlinx.coroutines.flow.Flow
|
import kotlinx.coroutines.flow.Flow
|
||||||
import org.intellij.lang.annotations.Language
|
import org.intellij.lang.annotations.Language
|
||||||
import org.xtimms.etsudoku.core.database.entity.HistoryEntity
|
import org.xtimms.shirizu.core.database.entity.HistoryEntity
|
||||||
import org.xtimms.etsudoku.core.database.entity.HistoryWithManga
|
import org.xtimms.shirizu.core.database.entity.HistoryWithManga
|
||||||
import org.xtimms.etsudoku.core.database.entity.MangaEntity
|
import org.xtimms.shirizu.core.database.entity.MangaEntity
|
||||||
import org.xtimms.etsudoku.core.database.entity.TagEntity
|
import org.xtimms.shirizu.core.database.entity.TagEntity
|
||||||
import org.xtimms.etsudoku.core.model.ListSortOrder
|
import org.xtimms.shirizu.core.model.ListSortOrder
|
||||||
|
|
||||||
@Dao
|
@Dao
|
||||||
abstract class HistoryDao {
|
abstract class HistoryDao {
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
package org.xtimms.etsudoku.core.database.dao
|
package org.xtimms.shirizu.core.database.dao
|
||||||
|
|
||||||
import androidx.room.Dao
|
import androidx.room.Dao
|
||||||
import androidx.room.Delete
|
import androidx.room.Delete
|
||||||
@@ -8,10 +8,10 @@ import androidx.room.Query
|
|||||||
import androidx.room.Transaction
|
import androidx.room.Transaction
|
||||||
import androidx.room.Update
|
import androidx.room.Update
|
||||||
import androidx.room.Upsert
|
import androidx.room.Upsert
|
||||||
import org.xtimms.etsudoku.core.database.entity.MangaEntity
|
import org.xtimms.shirizu.core.database.entity.MangaEntity
|
||||||
import org.xtimms.etsudoku.core.database.entity.MangaTagsEntity
|
import org.xtimms.shirizu.core.database.entity.MangaTagsEntity
|
||||||
import org.xtimms.etsudoku.core.database.entity.MangaWithTags
|
import org.xtimms.shirizu.core.database.entity.MangaWithTags
|
||||||
import org.xtimms.etsudoku.core.database.entity.TagEntity
|
import org.xtimms.shirizu.core.database.entity.TagEntity
|
||||||
|
|
||||||
@Dao
|
@Dao
|
||||||
abstract class MangaDao {
|
abstract class MangaDao {
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
package org.xtimms.etsudoku.core.database.dao
|
package org.xtimms.shirizu.core.database.dao
|
||||||
|
|
||||||
import androidx.room.Dao
|
import androidx.room.Dao
|
||||||
import androidx.room.Query
|
import androidx.room.Query
|
||||||
@@ -9,8 +9,8 @@ import androidx.sqlite.db.SimpleSQLiteQuery
|
|||||||
import androidx.sqlite.db.SupportSQLiteQuery
|
import androidx.sqlite.db.SupportSQLiteQuery
|
||||||
import kotlinx.coroutines.flow.Flow
|
import kotlinx.coroutines.flow.Flow
|
||||||
import org.intellij.lang.annotations.Language
|
import org.intellij.lang.annotations.Language
|
||||||
import org.xtimms.etsudoku.core.database.entity.MangaSourceEntity
|
import org.xtimms.shirizu.core.database.entity.MangaSourceEntity
|
||||||
import org.xtimms.etsudoku.sections.explore.data.SourcesSortOrder
|
import org.xtimms.shirizu.sections.explore.data.SourcesSortOrder
|
||||||
|
|
||||||
@Dao
|
@Dao
|
||||||
abstract class MangaSourcesDao {
|
abstract class MangaSourcesDao {
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
package org.xtimms.etsudoku.core.database.dao
|
package org.xtimms.shirizu.core.database.dao
|
||||||
|
|
||||||
import androidx.room.Dao
|
import androidx.room.Dao
|
||||||
import androidx.room.Insert
|
import androidx.room.Insert
|
||||||
@@ -7,8 +7,8 @@ import androidx.room.Query
|
|||||||
import androidx.room.Transaction
|
import androidx.room.Transaction
|
||||||
import androidx.room.Update
|
import androidx.room.Update
|
||||||
import kotlinx.coroutines.flow.Flow
|
import kotlinx.coroutines.flow.Flow
|
||||||
import org.xtimms.etsudoku.core.database.entity.SuggestionEntity
|
import org.xtimms.shirizu.core.database.entity.SuggestionEntity
|
||||||
import org.xtimms.etsudoku.core.database.entity.SuggestionWithManga
|
import org.xtimms.shirizu.core.database.entity.SuggestionWithManga
|
||||||
|
|
||||||
@Dao
|
@Dao
|
||||||
abstract class SuggestionDao {
|
abstract class SuggestionDao {
|
||||||
@@ -1,9 +1,9 @@
|
|||||||
package org.xtimms.etsudoku.core.database.dao
|
package org.xtimms.shirizu.core.database.dao
|
||||||
|
|
||||||
import androidx.room.Dao
|
import androidx.room.Dao
|
||||||
import androidx.room.Query
|
import androidx.room.Query
|
||||||
import androidx.room.Upsert
|
import androidx.room.Upsert
|
||||||
import org.xtimms.etsudoku.core.database.entity.TagEntity
|
import org.xtimms.shirizu.core.database.entity.TagEntity
|
||||||
|
|
||||||
@Dao
|
@Dao
|
||||||
abstract class TagsDao {
|
abstract class TagsDao {
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
package org.xtimms.etsudoku.core.database.dao
|
package org.xtimms.shirizu.core.database.dao
|
||||||
|
|
||||||
import androidx.room.Dao
|
import androidx.room.Dao
|
||||||
import androidx.room.Insert
|
import androidx.room.Insert
|
||||||
@@ -6,8 +6,8 @@ import androidx.room.OnConflictStrategy
|
|||||||
import androidx.room.Query
|
import androidx.room.Query
|
||||||
import androidx.room.Transaction
|
import androidx.room.Transaction
|
||||||
import kotlinx.coroutines.flow.Flow
|
import kotlinx.coroutines.flow.Flow
|
||||||
import org.xtimms.etsudoku.core.database.entity.TrackLogEntity
|
import org.xtimms.shirizu.core.database.entity.TrackLogEntity
|
||||||
import org.xtimms.etsudoku.core.database.entity.TrackLogWithManga
|
import org.xtimms.shirizu.core.database.entity.TrackLogWithManga
|
||||||
|
|
||||||
@Dao
|
@Dao
|
||||||
interface TrackLogsDao {
|
interface TrackLogsDao {
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
package org.xtimms.etsudoku.core.database.dao
|
package org.xtimms.shirizu.core.database.dao
|
||||||
|
|
||||||
import androidx.room.Dao
|
import androidx.room.Dao
|
||||||
import androidx.room.MapColumn
|
import androidx.room.MapColumn
|
||||||
@@ -6,8 +6,8 @@ import androidx.room.Query
|
|||||||
import androidx.room.Transaction
|
import androidx.room.Transaction
|
||||||
import androidx.room.Upsert
|
import androidx.room.Upsert
|
||||||
import kotlinx.coroutines.flow.Flow
|
import kotlinx.coroutines.flow.Flow
|
||||||
import org.xtimms.etsudoku.core.database.entity.MangaWithTags
|
import org.xtimms.shirizu.core.database.entity.MangaWithTags
|
||||||
import org.xtimms.etsudoku.core.database.entity.TrackEntity
|
import org.xtimms.shirizu.core.database.entity.TrackEntity
|
||||||
|
|
||||||
@Dao
|
@Dao
|
||||||
abstract class TracksDao {
|
abstract class TracksDao {
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
package org.xtimms.etsudoku.core.database.entity
|
package org.xtimms.shirizu.core.database.entity
|
||||||
|
|
||||||
import androidx.room.ColumnInfo
|
import androidx.room.ColumnInfo
|
||||||
import androidx.room.Entity
|
import androidx.room.Entity
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
package org.xtimms.etsudoku.core.database.entity
|
package org.xtimms.shirizu.core.database.entity
|
||||||
|
|
||||||
import org.koitharu.kotatsu.parsers.model.Manga
|
import org.koitharu.kotatsu.parsers.model.Manga
|
||||||
import org.koitharu.kotatsu.parsers.model.MangaState
|
import org.koitharu.kotatsu.parsers.model.MangaState
|
||||||
@@ -6,14 +6,14 @@ import org.koitharu.kotatsu.parsers.model.MangaTag
|
|||||||
import org.koitharu.kotatsu.parsers.model.SortOrder
|
import org.koitharu.kotatsu.parsers.model.SortOrder
|
||||||
import org.koitharu.kotatsu.parsers.util.mapToSet
|
import org.koitharu.kotatsu.parsers.util.mapToSet
|
||||||
import org.koitharu.kotatsu.parsers.util.toTitleCase
|
import org.koitharu.kotatsu.parsers.util.toTitleCase
|
||||||
import org.xtimms.etsudoku.core.model.Bookmark
|
import org.xtimms.shirizu.core.model.Bookmark
|
||||||
import org.xtimms.etsudoku.core.model.FavouriteCategory
|
import org.xtimms.shirizu.core.model.FavouriteCategory
|
||||||
import org.xtimms.etsudoku.core.model.ListSortOrder
|
import org.xtimms.shirizu.core.model.ListSortOrder
|
||||||
import org.xtimms.etsudoku.core.model.MangaHistory
|
import org.xtimms.shirizu.core.model.MangaHistory
|
||||||
import org.xtimms.etsudoku.core.model.MangaSource
|
import org.xtimms.shirizu.core.model.MangaSource
|
||||||
import org.xtimms.etsudoku.core.tracker.model.TrackingLogItem
|
import org.xtimms.shirizu.core.tracker.model.TrackingLogItem
|
||||||
import org.xtimms.etsudoku.sections.shelf.FavouriteManga
|
import org.xtimms.shirizu.sections.shelf.FavouriteManga
|
||||||
import org.xtimms.etsudoku.utils.lang.longHashCode
|
import org.xtimms.shirizu.utils.lang.longHashCode
|
||||||
import java.time.Instant
|
import java.time.Instant
|
||||||
|
|
||||||
// Entity to model
|
// Entity to model
|
||||||
@@ -1,9 +1,9 @@
|
|||||||
package org.xtimms.etsudoku.core.database.entity
|
package org.xtimms.shirizu.core.database.entity
|
||||||
|
|
||||||
import androidx.room.ColumnInfo
|
import androidx.room.ColumnInfo
|
||||||
import androidx.room.Entity
|
import androidx.room.Entity
|
||||||
import androidx.room.PrimaryKey
|
import androidx.room.PrimaryKey
|
||||||
import org.xtimms.etsudoku.core.database.TABLE_FAVOURITE_CATEGORIES
|
import org.xtimms.shirizu.core.database.TABLE_FAVOURITE_CATEGORIES
|
||||||
|
|
||||||
@Entity(tableName = TABLE_FAVOURITE_CATEGORIES)
|
@Entity(tableName = TABLE_FAVOURITE_CATEGORIES)
|
||||||
data class FavouriteCategoryEntity(
|
data class FavouriteCategoryEntity(
|
||||||
@@ -1,9 +1,9 @@
|
|||||||
package org.xtimms.etsudoku.core.database.entity
|
package org.xtimms.shirizu.core.database.entity
|
||||||
|
|
||||||
import androidx.room.ColumnInfo
|
import androidx.room.ColumnInfo
|
||||||
import androidx.room.Entity
|
import androidx.room.Entity
|
||||||
import androidx.room.ForeignKey
|
import androidx.room.ForeignKey
|
||||||
import org.xtimms.etsudoku.core.database.TABLE_FAVOURITES
|
import org.xtimms.shirizu.core.database.TABLE_FAVOURITES
|
||||||
|
|
||||||
@Entity(
|
@Entity(
|
||||||
tableName = TABLE_FAVOURITES,
|
tableName = TABLE_FAVOURITES,
|
||||||
@@ -1,10 +1,10 @@
|
|||||||
package org.xtimms.etsudoku.core.database.entity
|
package org.xtimms.shirizu.core.database.entity
|
||||||
|
|
||||||
import androidx.room.ColumnInfo
|
import androidx.room.ColumnInfo
|
||||||
import androidx.room.Entity
|
import androidx.room.Entity
|
||||||
import androidx.room.ForeignKey
|
import androidx.room.ForeignKey
|
||||||
import androidx.room.PrimaryKey
|
import androidx.room.PrimaryKey
|
||||||
import org.xtimms.etsudoku.core.database.TABLE_HISTORY
|
import org.xtimms.shirizu.core.database.TABLE_HISTORY
|
||||||
|
|
||||||
@Entity(
|
@Entity(
|
||||||
tableName = TABLE_HISTORY,
|
tableName = TABLE_HISTORY,
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
package org.xtimms.etsudoku.core.database.entity
|
package org.xtimms.shirizu.core.database.entity
|
||||||
|
|
||||||
import androidx.room.Embedded
|
import androidx.room.Embedded
|
||||||
import androidx.room.Junction
|
import androidx.room.Junction
|
||||||
@@ -1,9 +1,9 @@
|
|||||||
package org.xtimms.etsudoku.core.database.entity
|
package org.xtimms.shirizu.core.database.entity
|
||||||
|
|
||||||
import androidx.room.ColumnInfo
|
import androidx.room.ColumnInfo
|
||||||
import androidx.room.Entity
|
import androidx.room.Entity
|
||||||
import androidx.room.PrimaryKey
|
import androidx.room.PrimaryKey
|
||||||
import org.xtimms.etsudoku.core.database.TABLE_MANGA
|
import org.xtimms.shirizu.core.database.TABLE_MANGA
|
||||||
|
|
||||||
@Entity(tableName = TABLE_MANGA)
|
@Entity(tableName = TABLE_MANGA)
|
||||||
data class MangaEntity(
|
data class MangaEntity(
|
||||||
@@ -1,9 +1,9 @@
|
|||||||
package org.xtimms.etsudoku.core.database.entity
|
package org.xtimms.shirizu.core.database.entity
|
||||||
|
|
||||||
import androidx.room.ColumnInfo
|
import androidx.room.ColumnInfo
|
||||||
import androidx.room.Entity
|
import androidx.room.Entity
|
||||||
import androidx.room.PrimaryKey
|
import androidx.room.PrimaryKey
|
||||||
import org.xtimms.etsudoku.core.database.TABLE_SOURCES
|
import org.xtimms.shirizu.core.database.TABLE_SOURCES
|
||||||
|
|
||||||
@Entity(tableName = TABLE_SOURCES)
|
@Entity(tableName = TABLE_SOURCES)
|
||||||
data class MangaSourceEntity(
|
data class MangaSourceEntity(
|
||||||
@@ -1,9 +1,9 @@
|
|||||||
package org.xtimms.etsudoku.core.database.entity
|
package org.xtimms.shirizu.core.database.entity
|
||||||
|
|
||||||
import androidx.room.ColumnInfo
|
import androidx.room.ColumnInfo
|
||||||
import androidx.room.Entity
|
import androidx.room.Entity
|
||||||
import androidx.room.ForeignKey
|
import androidx.room.ForeignKey
|
||||||
import org.xtimms.etsudoku.core.database.TABLE_MANGA_TAGS
|
import org.xtimms.shirizu.core.database.TABLE_MANGA_TAGS
|
||||||
|
|
||||||
@Entity(
|
@Entity(
|
||||||
tableName = TABLE_MANGA_TAGS,
|
tableName = TABLE_MANGA_TAGS,
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
package org.xtimms.etsudoku.core.database.entity
|
package org.xtimms.shirizu.core.database.entity
|
||||||
|
|
||||||
import androidx.room.Embedded
|
import androidx.room.Embedded
|
||||||
import androidx.room.Junction
|
import androidx.room.Junction
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
package org.xtimms.etsudoku.core.database.entity
|
package org.xtimms.shirizu.core.database.entity
|
||||||
|
|
||||||
import androidx.annotation.FloatRange
|
import androidx.annotation.FloatRange
|
||||||
import androidx.room.ColumnInfo
|
import androidx.room.ColumnInfo
|
||||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user