Renamed the double page split methods

so they're not longing conflicting with upstream's page split
This commit is contained in:
Jays2Kings 2021-04-12 13:33:36 -04:00
parent 45c8bdafd3
commit 652c935062
3 changed files with 6 additions and 6 deletions

View File

@ -361,7 +361,7 @@ class PagerPageHolder(
.observeOn(AndroidSchedulers.mainThread())
.doOnNext { isAnimated ->
if (skipExtra) {
onPageSplit()
splitDoublePages()
}
if (!isAnimated) {
if (viewer.config.readerTheme >= 2) {
@ -715,9 +715,9 @@ class PagerPageHolder(
return ByteArrayInputStream(output.toByteArray())
}
private fun onPageSplit() {
private fun splitDoublePages() {
extraPage ?: return
viewer.onPageSplit(page)
viewer.splitDoublePages(page)
if (extraPage?.fullPage == true) {
extraPage = null
}

View File

@ -372,8 +372,8 @@ abstract class PagerViewer(val activity: ReaderActivity) : BaseViewer {
return true
}
fun onPageSplit(currentPage: ReaderPage) {
adapter.onPageSplit(currentPage)
fun splitDoublePages(currentPage: ReaderPage) {
adapter.splitDoublePages(currentPage)
}
/**

View File

@ -143,7 +143,7 @@ class PagerViewerAdapter(private val viewer: PagerViewer) : ViewPagerAdapter() {
return POSITION_NONE
}
fun onPageSplit(current: ReaderPage) {
fun splitDoublePages(current: ReaderPage) {
val oldCurrent = joinedItems.getOrNull(viewer.pager.currentItem)
setJoinedItems(
oldCurrent?.second == current ||