From 794a084b6b71f7a5f9773bf5190dea4f40456814 Mon Sep 17 00:00:00 2001 From: Oleguer Llopart Date: Sun, 12 Jan 2025 15:42:26 +0100 Subject: [PATCH] Upd: scripts/reading.js --- scripts/reading.js | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/scripts/reading.js b/scripts/reading.js index b3a92832..edae7202 100644 --- a/scripts/reading.js +++ b/scripts/reading.js @@ -1137,7 +1137,7 @@ function calculateRealReadingDirection(index) } //Go to a specific comic index -function goToIndex(index, animation = true, nextPrevious = false, end = false, direction = 0) +function goToIndex(index, animation = true, nextPrevious = false, end = false) { let animationDurationS = ((animation) ? _config.readingViewSpeed : 0); let animationDurationMS = animationDurationS * 1000; @@ -1257,8 +1257,6 @@ function goToIndex(index, animation = true, nextPrevious = false, end = false, d let largerImage = returnLargerImage(eIndex-1); let scrollTop = (largerImage.top - rect.top) + content.scrollTop; - console.log(largerImage.top, rect.top); - let scrollSum = 0; if((readingViewIs('scroll') && (_config.readingViewAdjustToWidth || _config.readingWebtoon)) && pageVisibilityIndex !== false) @@ -1277,8 +1275,6 @@ function goToIndex(index, animation = true, nextPrevious = false, end = false, d } } - console.log(content.scrollTop, scrollTop, scrollSum); - clearTimeout(disableOnScrollST); disableOnScroll(true); @@ -1384,7 +1380,7 @@ function goNext() } else if(nextIndex <= indexNum || ((readingViewIs('scroll') && (_config.readingViewAdjustToWidth || _config.readingWebtoon)) && currentPageVisibility < maxPageVisibility)) { - goToIndex(nextIndex, true, true, false, 1); + goToIndex(nextIndex, true, true); music.soundEffect.page(); } else if(currentIndex == indexNum && dom.nextComic() && (!_config.readingManga || readingViewIs('scroll'))) @@ -1412,7 +1408,7 @@ function goPrevious() } else if(previousIndex > 0 || ((readingViewIs('scroll') && (_config.readingViewAdjustToWidth || _config.readingWebtoon)) && currentPageVisibility > 0)) { - goToIndex(previousIndex, true, true, false, -1); + goToIndex(previousIndex, true, true); music.soundEffect.page(); } else if(previousIndex == 0 && dom.previousComic() && (!_config.readingManga || readingViewIs('scroll')))