mirror of
https://github.com/null2264/yokai.git
synced 2025-06-21 10:44:42 +00:00
fix: Paged reading mode failing if "Smart Background" is enabled
This commit is contained in:
parent
f4a0264cf0
commit
179680b0d4
1 changed files with 10 additions and 9 deletions
|
@ -504,18 +504,19 @@ class PagerPageHolder(
|
|||
}
|
||||
// if the user switches to automatic when pages are already cached, the bg needs to be loaded
|
||||
else {
|
||||
setImage(actualSource, false, imageConfig)
|
||||
|
||||
val background =
|
||||
try {
|
||||
pageView?.background = setBG(actualSource.inputStream())
|
||||
setBG(actualSource.peek().inputStream())
|
||||
} catch (e: Exception) {
|
||||
Timber.e(e.localizedMessage)
|
||||
pageView?.background = ColorDrawable(Color.WHITE)
|
||||
} finally {
|
||||
ColorDrawable(Color.WHITE)
|
||||
}
|
||||
setImage(actualSource, false, imageConfig)
|
||||
|
||||
pageView?.background = background
|
||||
page.bg = pageView?.background
|
||||
page.bgType = bgType
|
||||
}
|
||||
}
|
||||
} else {
|
||||
setImage(actualSource, false, imageConfig)
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue