diff --git a/multisrc/overrides/mangasproject/default/additional.gradle.kts b/multisrc/overrides/mangasproject/default/additional.gradle.kts new file mode 100644 index 000000000..10beb8157 --- /dev/null +++ b/multisrc/overrides/mangasproject/default/additional.gradle.kts @@ -0,0 +1,4 @@ + +dependencies { + implementation project(':lib-ratelimit') +} diff --git a/multisrc/overrides/mangasproject/leitornet/res/mipmap-hdpi/ic_launcher.png b/multisrc/overrides/mangasproject/leitornet/res/mipmap-hdpi/ic_launcher.png new file mode 100644 index 000000000..8675f0e18 Binary files /dev/null and b/multisrc/overrides/mangasproject/leitornet/res/mipmap-hdpi/ic_launcher.png differ diff --git a/multisrc/overrides/mangasproject/leitornet/res/mipmap-mdpi/ic_launcher.png b/multisrc/overrides/mangasproject/leitornet/res/mipmap-mdpi/ic_launcher.png new file mode 100644 index 000000000..3556bede0 Binary files /dev/null and b/multisrc/overrides/mangasproject/leitornet/res/mipmap-mdpi/ic_launcher.png differ diff --git a/multisrc/overrides/mangasproject/leitornet/res/mipmap-xhdpi/ic_launcher.png b/multisrc/overrides/mangasproject/leitornet/res/mipmap-xhdpi/ic_launcher.png new file mode 100644 index 000000000..48ded9aa3 Binary files /dev/null and b/multisrc/overrides/mangasproject/leitornet/res/mipmap-xhdpi/ic_launcher.png differ diff --git a/multisrc/overrides/mangasproject/leitornet/res/mipmap-xxhdpi/ic_launcher.png b/multisrc/overrides/mangasproject/leitornet/res/mipmap-xxhdpi/ic_launcher.png new file mode 100644 index 000000000..2a333c6ff Binary files /dev/null and b/multisrc/overrides/mangasproject/leitornet/res/mipmap-xxhdpi/ic_launcher.png differ diff --git a/multisrc/overrides/mangasproject/leitornet/res/mipmap-xxxhdpi/ic_launcher.png b/multisrc/overrides/mangasproject/leitornet/res/mipmap-xxxhdpi/ic_launcher.png new file mode 100644 index 000000000..5c87a277f Binary files /dev/null and b/multisrc/overrides/mangasproject/leitornet/res/mipmap-xxxhdpi/ic_launcher.png differ diff --git a/multisrc/overrides/mangasproject/leitornet/res/web_hi_res_512.png b/multisrc/overrides/mangasproject/leitornet/res/web_hi_res_512.png new file mode 100644 index 000000000..2f1790784 Binary files /dev/null and b/multisrc/overrides/mangasproject/leitornet/res/web_hi_res_512.png differ diff --git a/multisrc/overrides/mangasproject/leitornet/src/LeitorNet.kt b/multisrc/overrides/mangasproject/leitornet/src/LeitorNet.kt index 158c80d65..3892dc00d 100644 --- a/multisrc/overrides/mangasproject/leitornet/src/LeitorNet.kt +++ b/multisrc/overrides/mangasproject/leitornet/src/LeitorNet.kt @@ -1,26 +1,22 @@ 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.network.GET -import eu.kanade.tachiyomi.source.model.MangasPage import eu.kanade.tachiyomi.source.model.SChapter import okhttp3.Request import okhttp3.Response import okhttp3.OkHttpClient -import okhttp3.FormBody -import okhttp3.Headers -import okhttp3.HttpUrl 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 // did have mangas in their catalogue. Now they "only have webtoons" and // became a different website, but they still use the same structure. // Existing mangas and other titles in the library still work. override val id: Long = 2225174659569980836 - + override val client: OkHttpClient = network.cloudflareClient.newBuilder() .addInterceptor(RateLimitInterceptor(5, 1, TimeUnit.SECONDS)) .connectTimeout(1, TimeUnit.MINUTES) diff --git a/multisrc/overrides/mangasproject/mangalivre/res/mipmap-hdpi/ic_launcher.png b/multisrc/overrides/mangasproject/mangalivre/res/mipmap-hdpi/ic_launcher.png new file mode 100644 index 000000000..5a356a0cf Binary files /dev/null and b/multisrc/overrides/mangasproject/mangalivre/res/mipmap-hdpi/ic_launcher.png differ diff --git a/multisrc/overrides/mangasproject/mangalivre/res/mipmap-mdpi/ic_launcher.png b/multisrc/overrides/mangasproject/mangalivre/res/mipmap-mdpi/ic_launcher.png new file mode 100644 index 000000000..414a70899 Binary files /dev/null and b/multisrc/overrides/mangasproject/mangalivre/res/mipmap-mdpi/ic_launcher.png differ diff --git a/multisrc/overrides/mangasproject/mangalivre/res/mipmap-xhdpi/ic_launcher.png b/multisrc/overrides/mangasproject/mangalivre/res/mipmap-xhdpi/ic_launcher.png new file mode 100644 index 000000000..4a48b037f Binary files /dev/null and b/multisrc/overrides/mangasproject/mangalivre/res/mipmap-xhdpi/ic_launcher.png differ diff --git a/multisrc/overrides/mangasproject/mangalivre/res/mipmap-xxhdpi/ic_launcher.png b/multisrc/overrides/mangasproject/mangalivre/res/mipmap-xxhdpi/ic_launcher.png new file mode 100644 index 000000000..644fdc7e2 Binary files /dev/null and b/multisrc/overrides/mangasproject/mangalivre/res/mipmap-xxhdpi/ic_launcher.png differ diff --git a/multisrc/overrides/mangasproject/mangalivre/res/mipmap-xxxhdpi/ic_launcher.png b/multisrc/overrides/mangasproject/mangalivre/res/mipmap-xxxhdpi/ic_launcher.png new file mode 100644 index 000000000..6c8f3510c Binary files /dev/null and b/multisrc/overrides/mangasproject/mangalivre/res/mipmap-xxxhdpi/ic_launcher.png differ diff --git a/multisrc/overrides/mangasproject/mangalivre/res/web_hi_res_512.png b/multisrc/overrides/mangasproject/mangalivre/res/web_hi_res_512.png new file mode 100644 index 000000000..0f568046d Binary files /dev/null and b/multisrc/overrides/mangasproject/mangalivre/res/web_hi_res_512.png differ diff --git a/multisrc/overrides/mangasproject/mangalivre/src/MangaLivre.kt b/multisrc/overrides/mangasproject/mangalivre/src/MangaLivre.kt index b7f19e1a9..d0d738208 100644 --- a/multisrc/overrides/mangasproject/mangalivre/src/MangaLivre.kt +++ b/multisrc/overrides/mangasproject/mangalivre/src/MangaLivre.kt @@ -1,25 +1,21 @@ 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.network.GET import eu.kanade.tachiyomi.source.model.Filter import eu.kanade.tachiyomi.source.model.FilterList import eu.kanade.tachiyomi.source.model.MangasPage -import eu.kanade.tachiyomi.source.model.SChapter import okhttp3.Request import okhttp3.Response import okhttp3.OkHttpClient -import okhttp3.FormBody -import okhttp3.Headers -import okhttp3.HttpUrl 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. override val id: Long = 4762777556012432014 - + override val client: OkHttpClient = network.cloudflareClient.newBuilder() .addInterceptor(RateLimitInterceptor(5, 1, TimeUnit.SECONDS)) .connectTimeout(1, TimeUnit.MINUTES) diff --git a/multisrc/overrides/mangasproject/toonei/res/mipmap-hdpi/ic_launcher.png b/multisrc/overrides/mangasproject/toonei/res/mipmap-hdpi/ic_launcher.png new file mode 100644 index 000000000..8675f0e18 Binary files /dev/null and b/multisrc/overrides/mangasproject/toonei/res/mipmap-hdpi/ic_launcher.png differ diff --git a/multisrc/overrides/mangasproject/toonei/res/mipmap-mdpi/ic_launcher.png b/multisrc/overrides/mangasproject/toonei/res/mipmap-mdpi/ic_launcher.png new file mode 100644 index 000000000..3556bede0 Binary files /dev/null and b/multisrc/overrides/mangasproject/toonei/res/mipmap-mdpi/ic_launcher.png differ diff --git a/multisrc/overrides/mangasproject/toonei/res/mipmap-xhdpi/ic_launcher.png b/multisrc/overrides/mangasproject/toonei/res/mipmap-xhdpi/ic_launcher.png new file mode 100644 index 000000000..48ded9aa3 Binary files /dev/null and b/multisrc/overrides/mangasproject/toonei/res/mipmap-xhdpi/ic_launcher.png differ diff --git a/multisrc/overrides/mangasproject/toonei/res/mipmap-xxhdpi/ic_launcher.png b/multisrc/overrides/mangasproject/toonei/res/mipmap-xxhdpi/ic_launcher.png new file mode 100644 index 000000000..2a333c6ff Binary files /dev/null and b/multisrc/overrides/mangasproject/toonei/res/mipmap-xxhdpi/ic_launcher.png differ diff --git a/multisrc/overrides/mangasproject/toonei/res/mipmap-xxxhdpi/ic_launcher.png b/multisrc/overrides/mangasproject/toonei/res/mipmap-xxxhdpi/ic_launcher.png new file mode 100644 index 000000000..5c87a277f Binary files /dev/null and b/multisrc/overrides/mangasproject/toonei/res/mipmap-xxxhdpi/ic_launcher.png differ diff --git a/multisrc/overrides/mangasproject/toonei/res/web_hi_res_512.png b/multisrc/overrides/mangasproject/toonei/res/web_hi_res_512.png new file mode 100644 index 000000000..2f1790784 Binary files /dev/null and b/multisrc/overrides/mangasproject/toonei/res/web_hi_res_512.png differ diff --git a/multisrc/overrides/mangasproject/toonei/src/Toonei.kt b/multisrc/overrides/mangasproject/toonei/src/Toonei.kt index ac65ef849..1011829b2 100644 --- a/multisrc/overrides/mangasproject/toonei/src/Toonei.kt +++ b/multisrc/overrides/mangasproject/toonei/src/Toonei.kt @@ -1,18 +1,13 @@ package eu.kanade.tachiyomi.extension.pt.toonei +import eu.kanade.tachiyomi.lib.ratelimit.RateLimitInterceptor import eu.kanade.tachiyomi.multisrc.mangasproject.MangasProject import org.jsoup.nodes.Document -import okhttp3.Request -import okhttp3.Response import okhttp3.OkHttpClient -import okhttp3.FormBody -import okhttp3.Headers -import okhttp3.HttpUrl 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() .addInterceptor(RateLimitInterceptor(5, 1, TimeUnit.SECONDS)) .connectTimeout(1, TimeUnit.MINUTES) diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangasproject/MangasProject.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangasproject/MangasProject.kt index cb5f8f114..f5fe49cc8 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangasproject/MangasProject.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangasproject/MangasProject.kt @@ -34,12 +34,10 @@ abstract class MangasProject( override val lang: String ) : HttpSource() { - override val supportsLatest = true // Sometimes the site is slow. override val client: OkHttpClient = network.cloudflareClient.newBuilder() - //.addInterceptor(RateLimitInterceptor(5, 1, TimeUnit.SECONDS)) .connectTimeout(1, TimeUnit.MINUTES) .readTimeout(1, TimeUnit.MINUTES) .writeTimeout(1, TimeUnit.MINUTES) diff --git a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangasproject/MangasProjectGenerator.kt b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangasproject/MangasProjectGenerator.kt index 756f52e5a..afaf41c33 100644 --- a/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangasproject/MangasProjectGenerator.kt +++ b/multisrc/src/main/java/eu/kanade/tachiyomi/multisrc/mangasproject/MangasProjectGenerator.kt @@ -12,9 +12,9 @@ class MangasProjectGenerator : ThemeSourceGenerator { override val baseVersionCode: Int = 1 override val sources = listOf( - SingleLang("Leitor.net", "https://leitor.net", "pt-br", className = "LeitorNet"), - SingleLang("Mangá Livre", "https://mangalivre.net", "pt-br", className = "MangaLivre", isNsfw = true), - SingleLang("Toonei", "https://toonei.com", "pt-br"), + 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, overrideVersionCode = 1), + SingleLang("Toonei", "https://toonei.com", "pt-BR", isNsfw = true, overrideVersionCode = 1), ) companion object {