Dragon Ball Multiverse: fix languages (#6024)

* Dragon Ball Multiverse: fix languages

* Forgot to remove a comment
This commit is contained in:
scb261 2021-03-02 17:39:31 +02:00 committed by GitHub
parent 50689b24b6
commit 618aba4fa8
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 42 additions and 40 deletions

View File

@ -5,7 +5,7 @@ ext {
extName = 'Dragon Ball Multiverse'
pkgNameSuffix = 'all.dragonball_multiverse'
extClass = '.DbMFactory'
extVersionCode = 1
extVersionCode = 2
libVersion = '1.2'
}

View File

@ -46,38 +46,38 @@ class DbMFactory : SourceFactory {
)
}
class DbMultiverseFR : DbMultiverse("fr")
class DbMultiverseJP : DbMultiverse("jp")
class DbMultiverseCN : DbMultiverse("cn")
class DbMultiverseES : DbMultiverse("es")
class DbMultiverseIT : DbMultiverse("it")
class DbMultiversePT : DbMultiverse("pt")
class DbMultiverseDE : DbMultiverse("de")
class DbMultiversePL : DbMultiverse("pl")
class DbMultiverseNL : DbMultiverse("nl")
class DbMultiverseFR_PA : DbMultiverse("fr-PA")
class DbMultiverseTR_TR : DbMultiverse("tr-TR")
class DbMultiversePT_BR : DbMultiverse("pt-BR")
class DbMultiverseHU_HU : DbMultiverse("hu-HU")
class DbMultiverseGA_ES : DbMultiverse("ga-ES")
class DbMultiverseCT_CT : DbMultiverse("ct-CT")
class DbMultiverseNO_NO : DbMultiverse("no-NO")
class DbMultiverseRU_RU : DbMultiverse("ru-RU")
class DbMultiverseRO_RO : DbMultiverse("ro-RO")
class DbMultiverseEU_EH : DbMultiverse("eu-EH")
class DbMultiverseLT_LT : DbMultiverse("lt-LT")
class DbMultiverseHR_HR : DbMultiverse("hr-HR")
class DbMultiverseKR_KR : DbMultiverse("kr-KR")
class DbMultiverseFI_FI : DbMultiverse("fi-FI")
class DbMultiverseHE_HE : DbMultiverse("he-HE")
class DbMultiverseBG_BG : DbMultiverse("bg-BG")
class DbMultiverseSV_SE : DbMultiverse("sv-SE")
class DbMultiverseGR_GR : DbMultiverse("gr-GR")
class DbMultiverseES_CO : DbMultiverse("es-CO")
class DbMultiverseAR_JO : DbMultiverse("ar-JO")
class DbMultiverseTL_PI : DbMultiverse("tl-PI")
class DbMultiverseLA_LA : DbMultiverse("la-LA")
class DbMultiverseDA_DK : DbMultiverse("da-DK")
class DbMultiverseCO_FR : DbMultiverse("co-FR")
class DbMultiverseBR_FR : DbMultiverse("br-FR")
class DbMultiverseXX_VE : DbMultiverse("xx-VE")
class DbMultiverseFR : DbMultiverse("fr", "fr")
class DbMultiverseJP : DbMultiverse("ja", "jp")
class DbMultiverseCN : DbMultiverse("zh", "cn")
class DbMultiverseES : DbMultiverse("es", "es")
class DbMultiverseIT : DbMultiverse("it", "it")
class DbMultiversePT : DbMultiverse("pt", "pt")
class DbMultiverseDE : DbMultiverse("de", "de")
class DbMultiversePL : DbMultiverse("pl", "pl")
class DbMultiverseNL : DbMultiverse("nl", "nl")
class DbMultiverseFR_PA : DbMultiverse("fr", "fr_PA")
class DbMultiverseTR_TR : DbMultiverse("tr", "tr_TR")
class DbMultiversePT_BR : DbMultiverse("pt-BR", "pt_BR")
class DbMultiverseHU_HU : DbMultiverse("hu", "hu_HU")
class DbMultiverseGA_ES : DbMultiverse("ga", "ga_ES")
class DbMultiverseCT_CT : DbMultiverse("ca", "ct_CT")
class DbMultiverseNO_NO : DbMultiverse("no", "no_NO")
class DbMultiverseRU_RU : DbMultiverse("ru", "ru_RU")
class DbMultiverseRO_RO : DbMultiverse("ro", "ro_RO")
class DbMultiverseEU_EH : DbMultiverse("eu", "eu_EH")
class DbMultiverseLT_LT : DbMultiverse("lt", "lt_LT")
class DbMultiverseHR_HR : DbMultiverse("hr", "hr_HR")
class DbMultiverseKR_KR : DbMultiverse("ko", "kr_KR")
class DbMultiverseFI_FI : DbMultiverse("fi", "fi_FI")
class DbMultiverseHE_HE : DbMultiverse("he", "he_HE")
class DbMultiverseBG_BG : DbMultiverse("bg", "bg_BG")
class DbMultiverseSV_SE : DbMultiverse("sv", "sv_SE")
class DbMultiverseGR_GR : DbMultiverse("el", "gr_GR")
class DbMultiverseES_CO : DbMultiverse("es-419", "es_CO")
class DbMultiverseAR_JO : DbMultiverse("ar", "ar_JO")
class DbMultiverseTL_PI : DbMultiverse("fil", "tl_PI")
class DbMultiverseLA_LA : DbMultiverse("la", "la_LA")
class DbMultiverseDA_DK : DbMultiverse("da", "da_DK")
class DbMultiverseCO_FR : DbMultiverse("co", "co_FR")
class DbMultiverseBR_FR : DbMultiverse("br", "br_FR")
class DbMultiverseXX_VE : DbMultiverse("vec", "xx_VE")

View File

@ -13,9 +13,11 @@ import org.jsoup.nodes.Document
import org.jsoup.nodes.Element
import rx.Observable
abstract class DbMultiverse(override val lang: String) : ParsedHttpSource() {
abstract class DbMultiverse(override val lang: String, private val internalLang: String) : ParsedHttpSource() {
override val name = "Dragon Ball Multiverse"
override val name =
if (internalLang.endsWith("_PA")) "Dragon Ball Multiverse Parody"
else "Dragon Ball Multiverse"
override val baseUrl = "https://www.dragonball-multiverse.com"
override val supportsLatest = false
@ -64,7 +66,7 @@ abstract class DbMultiverse(override val lang: String) : ParsedHttpSource() {
private fun createManga(document: Document?) = SManga.create().apply {
title = name
status = SManga.ONGOING
url = "/${lang.replace("-", "_")}/chapters.html"
url = "/$internalLang/chapters.html"
description = "Dragon Ball Multiverse (DBM) is a free online comic, made by a whole team of fans. It's our personal sequel to DBZ."
thumbnail_url = document?.select("div[ch=\"1\"] img")?.attr("abs:src")
}

View File

@ -1,3 +1,3 @@
package eu.kanade.tachiyomi.extension.all.dragonball_multiverse
class DbMultiverseEN : DbMultiverse("en")
class DbMultiverseEN : DbMultiverse("en", "en")