Update Config.kt

This commit is contained in:
Tibor Kaputa 2021-11-23 12:28:28 +01:00 committed by GitHub
parent 6363d8d511
commit 3a70d1ab40
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 3 deletions

View File

@ -230,9 +230,7 @@ class Config(context: Context) : BaseConfig(context) {
get() = prefs.getBoolean(HIGHLIGHT_WEEKENDS, false) get() = prefs.getBoolean(HIGHLIGHT_WEEKENDS, false)
set(highlightWeekends) = prefs.edit().putBoolean(HIGHLIGHT_WEEKENDS, highlightWeekends).apply() set(highlightWeekends) = prefs.edit().putBoolean(HIGHLIGHT_WEEKENDS, highlightWeekends).apply()
val defaultHighlightWeekendsColor = context.resources.getColor(R.color.red_text)
var highlightWeekendsColor: Int var highlightWeekendsColor: Int
get() = prefs.getInt(HIGHLIGHT_WEEKENDS_COLOR, defaultHighlightWeekendsColor) get() = prefs.getInt(HIGHLIGHT_WEEKENDS_COLOR, context.resources.getColor(R.color.red_text))
set(highlightWeekendsColor) = prefs.edit().putInt(HIGHLIGHT_WEEKENDS_COLOR, highlightWeekendsColor).apply() set(highlightWeekendsColor) = prefs.edit().putInt(HIGHLIGHT_WEEKENDS_COLOR, highlightWeekendsColor).apply()
} }