mirror of
https://github.com/rebelonion/Dantotsu.git
synced 2026-01-20 06:53:59 +00:00
fix: smol changes
This commit is contained in:
@@ -10,7 +10,6 @@ import ani.dantotsu.addons.torrent.TorrentAddonManager
|
||||
import ani.dantotsu.media.AddonType
|
||||
import ani.dantotsu.media.MediaType
|
||||
import ani.dantotsu.parsers.novel.NovelExtensionManager
|
||||
import ani.dantotsu.themes.ThemeManager
|
||||
import eu.kanade.tachiyomi.extension.InstallStep
|
||||
import eu.kanade.tachiyomi.extension.anime.AnimeExtensionManager
|
||||
import eu.kanade.tachiyomi.extension.manga.MangaExtensionManager
|
||||
@@ -38,8 +37,6 @@ class ExtensionInstallActivity : AppCompatActivity() {
|
||||
override fun onCreate(savedInstanceState: Bundle?) {
|
||||
super.onCreate(savedInstanceState)
|
||||
|
||||
ThemeManager(this).applyTheme()
|
||||
|
||||
if (intent.hasExtra(ExtensionInstaller.EXTRA_EXTENSION_TYPE))
|
||||
mediaType =
|
||||
intent.getSerializableExtraCompat<MediaType>(ExtensionInstaller.EXTRA_EXTENSION_TYPE)
|
||||
@@ -86,6 +83,7 @@ class ExtensionInstallActivity : AppCompatActivity() {
|
||||
}
|
||||
}
|
||||
|
||||
@Suppress("all")
|
||||
private fun checkInstallationResult(resultCode: Int) {
|
||||
val downloadId = intent.extras!!.getLong(ExtensionInstaller.EXTRA_DOWNLOAD_ID)
|
||||
val newStep = when (resultCode) {
|
||||
@@ -103,11 +101,9 @@ class ExtensionInstallActivity : AppCompatActivity() {
|
||||
Injekt.get<MangaExtensionManager>().updateInstallStep(downloadId, newStep)
|
||||
}
|
||||
|
||||
MediaType.NOVEL -> {
|
||||
else -> {
|
||||
Injekt.get<NovelExtensionManager>().updateInstallStep(downloadId, newStep)
|
||||
}
|
||||
|
||||
null -> {}
|
||||
}
|
||||
} else {
|
||||
when (addonType) {
|
||||
|
||||
@@ -62,7 +62,9 @@ class ExtensionInstaller(private val context: Context) {
|
||||
* step in the installation process.
|
||||
*
|
||||
* @param url The url of the apk.
|
||||
* @param extension The extension to install.
|
||||
* @param pkgName The package name of the extension.
|
||||
* @param name The name of the extension.
|
||||
* @param type The type of the extension.
|
||||
*/
|
||||
fun <T : Type> downloadAndInstall(
|
||||
url: String,
|
||||
|
||||
Reference in New Issue
Block a user