Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit c6f582d0 authored by tibbi's avatar tibbi
Browse files

add a config for storing the last used viewpager page

parent 4bee3181
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -6,7 +6,7 @@ buildscript {
        propMinSdkVersion = 16
        propTargetSdkVersion = propCompileSdkVersion
        propVersionCode = 1
        propVersionName = '3.13.17'
        propVersionName = '3.13.18'
        kotlin_version = '1.2.21'
        support_libs = '27.0.2'
    }
+4 −0
Original line number Diff line number Diff line
@@ -175,4 +175,8 @@ open class BaseConfig(val context: Context) {
    var preventPhoneFromSleeping: Boolean
        get() = prefs.getBoolean(PREVENT_PHONE_FROM_SLEEPING, true)
        set(preventPhoneFromSleeping) = prefs.edit().putBoolean(PREVENT_PHONE_FROM_SLEEPING, preventPhoneFromSleeping).apply()

    var lastUsedViewPagerPage: Int
        get() = prefs.getInt(LAST_USED_VIEW_PAGER_PAGE, 0)
        set(lastUsedViewPagerPage) = prefs.edit().putInt(LAST_USED_VIEW_PAGER_PAGE, lastUsedViewPagerPage).apply()
}
+1 −0
Original line number Diff line number Diff line
@@ -49,6 +49,7 @@ const val SKIP_DELETE_CONFIRMATION = "skip_delete_confirmation"
const val ENABLE_PULL_TO_REFRESH = "enable_pull_to_refresh"
const val SCROLL_HORIZONTALLY = "scroll_horizontally"
const val PREVENT_PHONE_FROM_SLEEPING = "prevent_phone_from_sleeping"
const val LAST_USED_VIEW_PAGER_PAGE = "last_used_view_pager_page"

// licenses
const val LICENSE_KOTLIN = 1