Remove some state from the library view

This commit is contained in:
len
2016-12-04 23:58:46 +01:00
parent 3d2a98451b
commit 30b4c6e755
3 changed files with 15 additions and 39 deletions

View File

@@ -13,6 +13,8 @@ import java.io.File
fun <T> Preference<T>.getOrDefault(): T = get() ?: defaultValue()!!
fun Preference<Boolean>.invert(): Boolean = getOrDefault().let { set(!it); !it }
class PreferencesHelper(context: Context) {
val keys = PreferenceKeys(context)