mirror of
https://github.com/aniyomiorg/aniyomi.git
synced 2024-11-28 09:15:12 +03:00
Add dev flavor. Bugfix in reader
This commit is contained in:
parent
6020cd011d
commit
c437f1473c
2 changed files with 8 additions and 2 deletions
|
@ -44,6 +44,7 @@ android {
|
||||||
buildConfigField "String", "COMMIT_COUNT", "\"${getCommitCount()}\""
|
buildConfigField "String", "COMMIT_COUNT", "\"${getCommitCount()}\""
|
||||||
buildConfigField "String", "COMMIT_SHA", "\"${getGitSha()}\""
|
buildConfigField "String", "COMMIT_SHA", "\"${getGitSha()}\""
|
||||||
buildConfigField "String", "BUILD_TIME", "\"${getBuildTime()}\""
|
buildConfigField "String", "BUILD_TIME", "\"${getBuildTime()}\""
|
||||||
|
buildConfigField "boolean", "INCLUDE_UPDATER", "false"
|
||||||
|
|
||||||
vectorDrawables.useSupportLibrary = true
|
vectorDrawables.useSupportLibrary = true
|
||||||
|
|
||||||
|
@ -70,9 +71,11 @@ android {
|
||||||
standard {
|
standard {
|
||||||
buildConfigField "boolean", "INCLUDE_UPDATER", "true"
|
buildConfigField "boolean", "INCLUDE_UPDATER", "true"
|
||||||
}
|
}
|
||||||
|
|
||||||
fdroid {
|
fdroid {
|
||||||
buildConfigField "boolean", "INCLUDE_UPDATER", "false"
|
}
|
||||||
|
dev {
|
||||||
|
minSdkVersion 21
|
||||||
|
resConfigs "en", "xxhdpi"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -230,7 +230,10 @@ abstract class PagerReader : BaseReader() {
|
||||||
*/
|
*/
|
||||||
protected fun setPagesOnAdapter() {
|
protected fun setPagesOnAdapter() {
|
||||||
if (pages.isNotEmpty()) {
|
if (pages.isNotEmpty()) {
|
||||||
|
// Prevent a wrong active page when changing chapters with the navigation buttons.
|
||||||
|
val currPage = currentPage
|
||||||
adapter.pages = pages
|
adapter.pages = pages
|
||||||
|
currentPage = currPage
|
||||||
if (currentPage == pager.currentItem) {
|
if (currentPage == pager.currentItem) {
|
||||||
onPageChanged(currentPage)
|
onPageChanged(currentPage)
|
||||||
} else {
|
} else {
|
||||||
|
|
Loading…
Reference in a new issue