Minor fix
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
apply plugin: "com.android.application"
|
||||
apply plugin: "kotlin-android"
|
||||
apply plugin: "kotlin-kapt"
|
||||
apply plugin: "kotlin-android-extensions"
|
||||
apply plugin: "kotlin-parcelize"
|
||||
apply plugin: "kotlinx-serialization"
|
||||
apply plugin: "com.google.android.gms.oss-licenses-plugin"
|
||||
|
||||
@@ -38,7 +38,7 @@ android {
|
||||
minSdkVersion 16
|
||||
targetSdkVersion 30
|
||||
versionCode 64
|
||||
versionName "5.1.7-alpha1"
|
||||
versionName "5.1.7-beta1"
|
||||
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
|
||||
vectorDrawables.useSupportLibrary = true
|
||||
}
|
||||
@@ -63,6 +63,9 @@ android {
|
||||
proguardFiles getDefaultProguardFile("proguard-android-optimize.txt"), "proguard-rules.pro"
|
||||
}
|
||||
}
|
||||
buildFeatures {
|
||||
viewBinding true
|
||||
}
|
||||
kotlinOptions {
|
||||
jvmTarget = JavaVersion.VERSION_1_8.toString()
|
||||
freeCompilerArgs += "-Xuse-experimental=kotlin.Experimental"
|
||||
@@ -79,7 +82,7 @@ dependencies {
|
||||
implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk8"
|
||||
implementation "org.jetbrains.kotlinx:kotlinx-coroutines-android:1.4.1"
|
||||
implementation "org.jetbrains.kotlinx:kotlinx-serialization-json:1.0.1"
|
||||
|
||||
|
||||
implementation "androidx.appcompat:appcompat:1.2.0"
|
||||
implementation "androidx.activity:activity-ktx:1.2.0-beta01"
|
||||
implementation "androidx.fragment:fragment-ktx:1.3.0-beta01"
|
||||
@@ -100,6 +103,7 @@ dependencies {
|
||||
implementation "com.google.firebase:firebase-perf"
|
||||
|
||||
implementation "com.google.android.gms:play-services-oss-licenses:17.0.0"
|
||||
implementation "com.google.android.gms:play-services-mlkit-face-detection:16.1.1"
|
||||
|
||||
implementation "com.github.clans:fab:1.6.4"
|
||||
|
||||
@@ -131,8 +135,4 @@ dependencies {
|
||||
androidTestImplementation "androidx.test:rules:1.3.0"
|
||||
androidTestImplementation "androidx.test:runner:1.3.0"
|
||||
androidTestImplementation "androidx.test.espresso:espresso-core:3.3.0"
|
||||
}
|
||||
|
||||
androidExtensions {
|
||||
experimental = true
|
||||
}
|
||||
@@ -144,6 +144,7 @@ class SearchResultsAdapter(private val results: List<SearchResult>) : RecyclerSw
|
||||
|
||||
binding.thumbnail.controller = Fresco.newDraweeControllerBuilder()
|
||||
.setUri(result.thumbnail)
|
||||
.setOldController(binding.thumbnail.controller)
|
||||
.setControllerListener(controllerListener)
|
||||
.build()
|
||||
|
||||
|
||||
@@ -22,6 +22,7 @@ import kotlinx.coroutines.CoroutineScope
|
||||
import kotlinx.coroutines.Dispatchers
|
||||
import kotlinx.coroutines.channels.Channel
|
||||
import kotlinx.coroutines.launch
|
||||
import xyz.quaver.hitomi.galleryblockdir
|
||||
import xyz.quaver.hiyobi.*
|
||||
import xyz.quaver.pupil.R
|
||||
import xyz.quaver.pupil.sources.DefaultSortMode
|
||||
@@ -41,7 +42,7 @@ class Hiyobi : Source<DefaultSortMode> {
|
||||
val (results, total) = if (query.isEmpty())
|
||||
list(range)
|
||||
else
|
||||
search(query, range)
|
||||
search(query.trim(), range)
|
||||
|
||||
CoroutineScope(Dispatchers.Unconfined).launch {
|
||||
results.forEach {
|
||||
@@ -65,7 +66,8 @@ class Hiyobi : Source<DefaultSortMode> {
|
||||
SearchResult.ExtraType.CHARACTER to { galleryBlock.characters.joinToString { it.value.wordCapitalize() } },
|
||||
SearchResult.ExtraType.SERIES to { galleryBlock.parodys.joinToString { it.value.wordCapitalize() } },
|
||||
SearchResult.ExtraType.TYPE to { galleryBlock.type.name.replace('_', ' ').wordCapitalize() },
|
||||
SearchResult.ExtraType.PAGECOUNT to { getGalleryInfo(galleryBlock.id).files.size.toString() }
|
||||
SearchResult.ExtraType.PAGECOUNT to { getGalleryInfo(galleryBlock.id).files.size.toString() },
|
||||
SearchResult.ExtraType.GROUP to { galleryBlock.groups.joinToString { it.value.wordCapitalize() } }
|
||||
),
|
||||
galleryBlock.tags.map { it.value }
|
||||
)
|
||||
|
||||
@@ -98,8 +98,6 @@ class MainActivity :
|
||||
binding = MainActivityBinding.inflate(layoutInflater)
|
||||
setContentView(binding.root)
|
||||
|
||||
setSource(sources.values.first())
|
||||
|
||||
if (intent.action == Intent.ACTION_VIEW) {
|
||||
intent.dataString?.let { url ->
|
||||
restore(url,
|
||||
@@ -340,6 +338,7 @@ class MainActivity :
|
||||
|
||||
setupSearchBar()
|
||||
setupRecyclerView()
|
||||
setSource(sources.values.first())
|
||||
query()
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user