Fix wrong language in multisrc MangasProject (#6463)
* Fix wrong language in multisrc MangasProject. * Fix lib-ratelimit import error and add custom icons.
|
@ -0,0 +1,4 @@
|
||||||
|
|
||||||
|
dependencies {
|
||||||
|
implementation project(':lib-ratelimit')
|
||||||
|
}
|
After Width: | Height: | Size: 3.5 KiB |
After Width: | Height: | Size: 2.0 KiB |
After Width: | Height: | Size: 4.7 KiB |
After Width: | Height: | Size: 8.5 KiB |
After Width: | Height: | Size: 13 KiB |
After Width: | Height: | Size: 68 KiB |
|
@ -1,26 +1,22 @@
|
||||||
package eu.kanade.tachiyomi.extension.pt.leitornet
|
package eu.kanade.tachiyomi.extension.pt.leitornet
|
||||||
|
|
||||||
|
import eu.kanade.tachiyomi.lib.ratelimit.RateLimitInterceptor
|
||||||
import eu.kanade.tachiyomi.multisrc.mangasproject.MangasProject
|
import eu.kanade.tachiyomi.multisrc.mangasproject.MangasProject
|
||||||
import eu.kanade.tachiyomi.network.GET
|
import eu.kanade.tachiyomi.network.GET
|
||||||
import eu.kanade.tachiyomi.source.model.MangasPage
|
|
||||||
import eu.kanade.tachiyomi.source.model.SChapter
|
import eu.kanade.tachiyomi.source.model.SChapter
|
||||||
import okhttp3.Request
|
import okhttp3.Request
|
||||||
import okhttp3.Response
|
import okhttp3.Response
|
||||||
import okhttp3.OkHttpClient
|
import okhttp3.OkHttpClient
|
||||||
import okhttp3.FormBody
|
|
||||||
import okhttp3.Headers
|
|
||||||
import okhttp3.HttpUrl
|
|
||||||
import java.util.concurrent.TimeUnit
|
import java.util.concurrent.TimeUnit
|
||||||
import eu.kanade.tachiyomi.lib.ratelimit.RateLimitInterceptor
|
|
||||||
|
|
||||||
class LeitorNet : MangasProject("Leitor.net", "https://leitor.net", "pt-br") {
|
class LeitorNet : MangasProject("Leitor.net", "https://leitor.net", "pt-BR") {
|
||||||
|
|
||||||
// Use the old generated id when the source did have the name "mangásPROJECT" and
|
// Use the old generated id when the source did have the name "mangásPROJECT" and
|
||||||
// did have mangas in their catalogue. Now they "only have webtoons" and
|
// did have mangas in their catalogue. Now they "only have webtoons" and
|
||||||
// became a different website, but they still use the same structure.
|
// became a different website, but they still use the same structure.
|
||||||
// Existing mangas and other titles in the library still work.
|
// Existing mangas and other titles in the library still work.
|
||||||
override val id: Long = 2225174659569980836
|
override val id: Long = 2225174659569980836
|
||||||
|
|
||||||
override val client: OkHttpClient = network.cloudflareClient.newBuilder()
|
override val client: OkHttpClient = network.cloudflareClient.newBuilder()
|
||||||
.addInterceptor(RateLimitInterceptor(5, 1, TimeUnit.SECONDS))
|
.addInterceptor(RateLimitInterceptor(5, 1, TimeUnit.SECONDS))
|
||||||
.connectTimeout(1, TimeUnit.MINUTES)
|
.connectTimeout(1, TimeUnit.MINUTES)
|
||||||
|
|
After Width: | Height: | Size: 3.2 KiB |
After Width: | Height: | Size: 1.8 KiB |
After Width: | Height: | Size: 4.5 KiB |
After Width: | Height: | Size: 8.3 KiB |
After Width: | Height: | Size: 13 KiB |
After Width: | Height: | Size: 69 KiB |
|
@ -1,25 +1,21 @@
|
||||||
package eu.kanade.tachiyomi.extension.pt.mangalivre
|
package eu.kanade.tachiyomi.extension.pt.mangalivre
|
||||||
|
|
||||||
|
import eu.kanade.tachiyomi.lib.ratelimit.RateLimitInterceptor
|
||||||
import eu.kanade.tachiyomi.multisrc.mangasproject.MangasProject
|
import eu.kanade.tachiyomi.multisrc.mangasproject.MangasProject
|
||||||
import eu.kanade.tachiyomi.network.GET
|
import eu.kanade.tachiyomi.network.GET
|
||||||
import eu.kanade.tachiyomi.source.model.Filter
|
import eu.kanade.tachiyomi.source.model.Filter
|
||||||
import eu.kanade.tachiyomi.source.model.FilterList
|
import eu.kanade.tachiyomi.source.model.FilterList
|
||||||
import eu.kanade.tachiyomi.source.model.MangasPage
|
import eu.kanade.tachiyomi.source.model.MangasPage
|
||||||
import eu.kanade.tachiyomi.source.model.SChapter
|
|
||||||
import okhttp3.Request
|
import okhttp3.Request
|
||||||
import okhttp3.Response
|
import okhttp3.Response
|
||||||
import okhttp3.OkHttpClient
|
import okhttp3.OkHttpClient
|
||||||
import okhttp3.FormBody
|
|
||||||
import okhttp3.Headers
|
|
||||||
import okhttp3.HttpUrl
|
|
||||||
import java.util.concurrent.TimeUnit
|
import java.util.concurrent.TimeUnit
|
||||||
import eu.kanade.tachiyomi.lib.ratelimit.RateLimitInterceptor
|
|
||||||
|
|
||||||
class MangaLivre : MangasProject("Mangá Livre", "https://mangalivre.net", "pt-br") {
|
class MangaLivre : MangasProject("Mangá Livre", "https://mangalivre.net", "pt-BR") {
|
||||||
|
|
||||||
// Hardcode the id because the language wasn't specific.
|
// Hardcode the id because the language wasn't specific.
|
||||||
override val id: Long = 4762777556012432014
|
override val id: Long = 4762777556012432014
|
||||||
|
|
||||||
override val client: OkHttpClient = network.cloudflareClient.newBuilder()
|
override val client: OkHttpClient = network.cloudflareClient.newBuilder()
|
||||||
.addInterceptor(RateLimitInterceptor(5, 1, TimeUnit.SECONDS))
|
.addInterceptor(RateLimitInterceptor(5, 1, TimeUnit.SECONDS))
|
||||||
.connectTimeout(1, TimeUnit.MINUTES)
|
.connectTimeout(1, TimeUnit.MINUTES)
|
||||||
|
|
After Width: | Height: | Size: 3.5 KiB |
After Width: | Height: | Size: 2.0 KiB |
After Width: | Height: | Size: 4.7 KiB |
After Width: | Height: | Size: 8.5 KiB |
After Width: | Height: | Size: 13 KiB |
After Width: | Height: | Size: 68 KiB |
|
@ -1,18 +1,13 @@
|
||||||
package eu.kanade.tachiyomi.extension.pt.toonei
|
package eu.kanade.tachiyomi.extension.pt.toonei
|
||||||
|
|
||||||
|
import eu.kanade.tachiyomi.lib.ratelimit.RateLimitInterceptor
|
||||||
import eu.kanade.tachiyomi.multisrc.mangasproject.MangasProject
|
import eu.kanade.tachiyomi.multisrc.mangasproject.MangasProject
|
||||||
import org.jsoup.nodes.Document
|
import org.jsoup.nodes.Document
|
||||||
import okhttp3.Request
|
|
||||||
import okhttp3.Response
|
|
||||||
import okhttp3.OkHttpClient
|
import okhttp3.OkHttpClient
|
||||||
import okhttp3.FormBody
|
|
||||||
import okhttp3.Headers
|
|
||||||
import okhttp3.HttpUrl
|
|
||||||
import java.util.concurrent.TimeUnit
|
import java.util.concurrent.TimeUnit
|
||||||
import eu.kanade.tachiyomi.lib.ratelimit.RateLimitInterceptor
|
|
||||||
|
|
||||||
class Toonei : MangasProject("Toonei", "https://toonei.com", "pt-br") {
|
class Toonei : MangasProject("Toonei", "https://toonei.com", "pt-BR") {
|
||||||
|
|
||||||
override val client: OkHttpClient = network.cloudflareClient.newBuilder()
|
override val client: OkHttpClient = network.cloudflareClient.newBuilder()
|
||||||
.addInterceptor(RateLimitInterceptor(5, 1, TimeUnit.SECONDS))
|
.addInterceptor(RateLimitInterceptor(5, 1, TimeUnit.SECONDS))
|
||||||
.connectTimeout(1, TimeUnit.MINUTES)
|
.connectTimeout(1, TimeUnit.MINUTES)
|
||||||
|
|
|
@ -34,12 +34,10 @@ abstract class MangasProject(
|
||||||
override val lang: String
|
override val lang: String
|
||||||
) : HttpSource() {
|
) : HttpSource() {
|
||||||
|
|
||||||
|
|
||||||
override val supportsLatest = true
|
override val supportsLatest = true
|
||||||
|
|
||||||
// Sometimes the site is slow.
|
// Sometimes the site is slow.
|
||||||
override val client: OkHttpClient = network.cloudflareClient.newBuilder()
|
override val client: OkHttpClient = network.cloudflareClient.newBuilder()
|
||||||
//.addInterceptor(RateLimitInterceptor(5, 1, TimeUnit.SECONDS))
|
|
||||||
.connectTimeout(1, TimeUnit.MINUTES)
|
.connectTimeout(1, TimeUnit.MINUTES)
|
||||||
.readTimeout(1, TimeUnit.MINUTES)
|
.readTimeout(1, TimeUnit.MINUTES)
|
||||||
.writeTimeout(1, TimeUnit.MINUTES)
|
.writeTimeout(1, TimeUnit.MINUTES)
|
||||||
|
|
|
@ -12,9 +12,9 @@ class MangasProjectGenerator : ThemeSourceGenerator {
|
||||||
override val baseVersionCode: Int = 1
|
override val baseVersionCode: Int = 1
|
||||||
|
|
||||||
override val sources = listOf(
|
override val sources = listOf(
|
||||||
SingleLang("Leitor.net", "https://leitor.net", "pt-br", className = "LeitorNet"),
|
SingleLang("Leitor.net", "https://leitor.net", "pt-BR", className = "LeitorNet", isNsfw = true, overrideVersionCode = 1),
|
||||||
SingleLang("Mangá Livre", "https://mangalivre.net", "pt-br", className = "MangaLivre", isNsfw = true),
|
SingleLang("Mangá Livre", "https://mangalivre.net", "pt-BR", className = "MangaLivre", isNsfw = true, overrideVersionCode = 1),
|
||||||
SingleLang("Toonei", "https://toonei.com", "pt-br"),
|
SingleLang("Toonei", "https://toonei.com", "pt-BR", isNsfw = true, overrideVersionCode = 1),
|
||||||
)
|
)
|
||||||
|
|
||||||
companion object {
|
companion object {
|
||||||
|
|