From d7981d8b16669368077d3937c1a9411491d34712 Mon Sep 17 00:00:00 2001 From: Shashank Pujari Date: Wed, 26 Aug 2020 10:51:50 +0530 Subject: [PATCH] MangaArabTeam source URL changed (#4206) * Update build.gradle * MangaArabTeam source URL changed * Add ShoujoHearts, fix some dates Co-authored-by: snakedoc83 --- src/all/madara/build.gradle | 2 +- .../extension/all/madara/MadaraFactory.kt | 21 +++++++++++++------ 2 files changed, 16 insertions(+), 7 deletions(-) diff --git a/src/all/madara/build.gradle b/src/all/madara/build.gradle index c97d14031..84767ea55 100644 --- a/src/all/madara/build.gradle +++ b/src/all/madara/build.gradle @@ -5,7 +5,7 @@ ext { extName = 'Madara (multiple sources)' pkgNameSuffix = "all.madara" extClass = '.MadaraFactory' - extVersionCode = 129 + extVersionCode = 130 libVersion = '1.2' containsNsfw = true } diff --git a/src/all/madara/src/eu/kanade/tachiyomi/extension/all/madara/MadaraFactory.kt b/src/all/madara/src/eu/kanade/tachiyomi/extension/all/madara/MadaraFactory.kt index 696765286..9a9b770e2 100644 --- a/src/all/madara/src/eu/kanade/tachiyomi/extension/all/madara/MadaraFactory.kt +++ b/src/all/madara/src/eu/kanade/tachiyomi/extension/all/madara/MadaraFactory.kt @@ -162,7 +162,8 @@ class MadaraFactory : SourceFactory { YaoiToshokan(), YokaiJump(), ZManga(), - ZinManga() + ZinManga(), + ShoujoHearts() // Removed by request of site owner // EarlyManga(), // MangaGecesi(), @@ -192,8 +193,8 @@ class TritiniaScans : Madara("TritiniaScans", "https://tritiniaman.ga", "en") { } class CopyPasteScan : Madara("CopyPasteScan", "https://copypastescan.xyz", "es") - -class FunList : Madara("FunList", "https://funlist.online", "en") + +class FunList : Madara("FunList", "https://funlist.online", "en") class Mangasushi : Madara("Mangasushi", "https://mangasushi.net", "en") @@ -645,7 +646,7 @@ class HunterFansub : Madara("Hunter Fansub", "https://hunterfansub.com", "es") { override val popularMangaUrlSelector = "div.post-title a:last-child" } -class MangaArabTeam : Madara("مانجا عرب تيم Manga Arab Team", "https://mangakm.com", "ar") { +class MangaArabTeam : Madara("مانجا عرب تيم Manga Arab Team", "https://mangaarabteam.com", "ar") { override fun imageRequest(page: Page): Request { return GET(page.imageUrl!!.replace("http:", "https:")) } @@ -693,7 +694,7 @@ class Toonily : Madara("Toonily", "https://toonily.com", "en") { ) } -class MangaKomi : Madara("MangaKomi", "https://mangakomi.com", "en", SimpleDateFormat("MM/dd/yyyy", Locale.US)) +class MangaKomi : Madara("MangaKomi", "https://mangakomi.com", "en") class Wakamics : Madara("Wakamics", "https://wakamics.com", "en") @@ -899,7 +900,7 @@ class DecadenceScans : Madara("Decadence Scans", "https://reader.decadencescans. class MangaRockTeam : Madara("Manga Rock Team", "https://mangarockteam.com", "en") -class MixedManga : Madara("Mixed Manga", "https://mixedmanga.com", "en") { +class MixedManga : Madara("Mixed Manga", "https://mixedmanga.com", "en", SimpleDateFormat("d MMM yyyy", Locale.US)) { override fun headersBuilder(): Headers.Builder = super.headersBuilder().add("Referer", baseUrl) } @@ -1265,3 +1266,11 @@ class ComicsValley : Madara("Comics Valley", "https://comicsvalley.com", "hi") class FriendlyTranslations : Madara("Friendly Translations", "https://friendlytranslationsscan.website", "en") class Wakascan : Madara("Wakascan", "https://wakascan.com", "fr") + +class ShoujoHearts : Madara("ShoujoHearts", "http://shoujohearts.com", "en") { + override fun popularMangaRequest(page: Int): Request = + POST("$baseUrl/reader/wp-admin/admin-ajax.php", formHeaders, formBuilder(page, true).build(), CacheControl.FORCE_NETWORK) + override fun latestUpdatesRequest(page: Int): Request = + POST("$baseUrl/reader/wp-admin/admin-ajax.php", formHeaders, formBuilder(page, false).build(), CacheControl.FORCE_NETWORK) + override fun searchPage(page: Int): String = "reader/page/$page/" +}