From 1948d55d5da404c47ef5a390e14e0e0c54e3fe36 Mon Sep 17 00:00:00 2001 From: AntsyLich <59261191+AntsyLich@users.noreply.github.com> Date: Sun, 28 Aug 2022 04:10:16 +0600 Subject: [PATCH] Long strip split fixes (#7875) * Fix image width in `splitStrip` * Fix reader switch isn't in md3 --- app/src/main/java/eu/kanade/tachiyomi/util/system/ImageUtil.kt | 2 +- app/src/main/res/layout/reader_webtoon_settings.xml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/app/src/main/java/eu/kanade/tachiyomi/util/system/ImageUtil.kt b/app/src/main/java/eu/kanade/tachiyomi/util/system/ImageUtil.kt index bf4c120bed..e9332e3d13 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/util/system/ImageUtil.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/util/system/ImageUtil.kt @@ -282,7 +282,7 @@ object ImageUtil { val options = extractImageOptions(imageStream).apply { inJustDecodeBounds = false } - val region = Rect(0, splitData.topOffset, splitData.outputImageHeight, splitData.bottomOffset) + val region = Rect(0, splitData.topOffset, options.outWidth, splitData.bottomOffset) try { val splitBitmap = bitmapRegionDecoder.decodeRegion(region, options) diff --git a/app/src/main/res/layout/reader_webtoon_settings.xml b/app/src/main/res/layout/reader_webtoon_settings.xml index b80b1991fa..ff0ddb7669 100644 --- a/app/src/main/res/layout/reader_webtoon_settings.xml +++ b/app/src/main/res/layout/reader_webtoon_settings.xml @@ -66,7 +66,7 @@ android:visibility="gone" tools:visibility="visible" /> -