Vgperson - enable search (#3482)
This commit is contained in:
parent
1d606bca42
commit
e6e5819fd9
|
@ -5,7 +5,7 @@ ext {
|
|||
appName = 'Tachiyomi: vgperson'
|
||||
pkgNameSuffix = 'en.vgperson'
|
||||
extClass = '.Vgperson'
|
||||
extVersionCode = 3
|
||||
extVersionCode = 4
|
||||
libVersion = '1.2'
|
||||
}
|
||||
|
||||
|
|
|
@ -38,7 +38,7 @@ class Vgperson : ParsedHttpSource() {
|
|||
|
||||
override fun popularMangaSelector() = ".content a[href^=?m]"
|
||||
|
||||
override fun popularMangaNextPageSelector() = null
|
||||
override fun popularMangaNextPageSelector(): String? = null
|
||||
|
||||
override fun popularMangaRequest(page: Int) = GET(baseUrl, headers)
|
||||
|
||||
|
@ -48,7 +48,7 @@ class Vgperson : ParsedHttpSource() {
|
|||
thumbnail_url = getCover(title)
|
||||
}
|
||||
|
||||
override fun fetchMangaDetails(manga: SManga) =
|
||||
override fun fetchMangaDetails(manga: SManga): Observable<SManga> =
|
||||
client.newCall(mangaDetailsRequest(manga)).asObservableSuccess().map {
|
||||
mangaDetailsParse(it).apply {
|
||||
url = manga.url
|
||||
|
@ -100,8 +100,8 @@ class Vgperson : ParsedHttpSource() {
|
|||
override fun pageListParse(document: Document) =
|
||||
document.select("img").mapIndexed { i, img -> Page(i, "", img.attr("src")) }
|
||||
|
||||
override fun fetchSearchManga(page: Int, query: String, filters: FilterList):
|
||||
Observable<MangasPage> = Observable.empty()
|
||||
override fun fetchSearchManga(page: Int, query: String, filters: FilterList): Observable<MangasPage> = fetchPopularManga(1)
|
||||
.map { mp -> MangasPage(mp.mangas.filter { it.title.contains(query, ignoreCase = true) }, false) }
|
||||
|
||||
// get known manga covers from imgur
|
||||
private fun getCover(title: String) = when (title) {
|
||||
|
@ -113,7 +113,7 @@ class Vgperson : ParsedHttpSource() {
|
|||
|
||||
override fun latestUpdatesSelector() = ""
|
||||
|
||||
override fun latestUpdatesNextPageSelector() = null
|
||||
override fun latestUpdatesNextPageSelector(): String? = null
|
||||
|
||||
override fun latestUpdatesRequest(page: Int) =
|
||||
throw UnsupportedOperationException("This method should not be called!")
|
||||
|
@ -123,7 +123,7 @@ class Vgperson : ParsedHttpSource() {
|
|||
|
||||
override fun searchMangaSelector() = ""
|
||||
|
||||
override fun searchMangaNextPageSelector() = null
|
||||
override fun searchMangaNextPageSelector(): String? = null
|
||||
|
||||
override fun searchMangaRequest(page: Int, query: String, filters: FilterList) =
|
||||
throw UnsupportedOperationException("This method should not be called!")
|
||||
|
|
Loading…
Reference in New Issue