Wear CWF Fix invalid keys for topOffset, leftOffset and rotationOffset steps

This commit is contained in:
Philoul 2023-10-24 17:00:54 +02:00
parent 5fd2db9706
commit 7b5d164239
2 changed files with 6 additions and 3 deletions

View file

@ -268,6 +268,9 @@ enum class JsonKeys(val key: String) {
DYNPREF("dynPref"), DYNPREF("dynPref"),
DYNPREFCOLOR("dynPrefColor"), DYNPREFCOLOR("dynPrefColor"),
PREFKEY("prefKey"), PREFKEY("prefKey"),
INVALIDTOPOFFSET("invalidTopOffset"),
INVALIDLEFTOFFSET("invalidLeftOffset"),
INVALIDROTATIONOFFSET("invalidRotationOffset"),
DEFAULT("default") DEFAULT("default")
} }

View file

@ -819,9 +819,9 @@ class CustomWatchface : BaseWatchFace() {
getColorSteps(dynColor, COLOR.key, INVALIDCOLOR.key) getColorSteps(dynColor, COLOR.key, INVALIDCOLOR.key)
getColorSteps(dynFontColor, FONTCOLOR.key, INVALIDFONTCOLOR.key) getColorSteps(dynFontColor, FONTCOLOR.key, INVALIDFONTCOLOR.key)
getIntSteps(dynTextSize, TEXTSIZE.key, INVALIDTEXTSIZE.key) getIntSteps(dynTextSize, TEXTSIZE.key, INVALIDTEXTSIZE.key)
getIntSteps(dynLeftOffset, LEFTOFFSET.key, INVALIDTEXTSIZE.key) getIntSteps(dynLeftOffset, LEFTOFFSET.key, INVALIDLEFTOFFSET.key)
getIntSteps(dynTopOffset, TOPOFFSET.key, INVALIDTEXTSIZE.key) getIntSteps(dynTopOffset, TOPOFFSET.key, INVALIDTOPOFFSET.key)
getIntSteps(dynRotationOffset, ROTATIONOFFSET.key, INVALIDTEXTSIZE.key) getIntSteps(dynRotationOffset, ROTATIONOFFSET.key, INVALIDROTATIONOFFSET.key)
} }
private fun getDrawableSteps(dynMap: MutableMap<Int, Drawable?>, key: String, invalidKey: String) { private fun getDrawableSteps(dynMap: MutableMap<Int, Drawable?>, key: String, invalidKey: String) {