Wear: fix DigitalStyle watchface

This commit is contained in:
Milos Kozak 2022-05-08 23:11:10 +02:00
parent 8139319430
commit e01647d496
19 changed files with 126 additions and 116 deletions

View file

@ -9,11 +9,15 @@
<option name="BLANK_LINES_AROUND_BLOCK_WHEN_BRANCHES" value="1" />
<option name="CODE_STYLE_DEFAULTS" value="KOTLIN_OFFICIAL" />
</JetCodeStyleSettings>
<XML>
<option name="XML_TEXT_WRAP" value="0" />
</XML>
<codeStyleSettings language="JAVA">
<option name="METHOD_ANNOTATION_WRAP" value="0" />
<option name="FIELD_ANNOTATION_WRAP" value="0" />
</codeStyleSettings>
<codeStyleSettings language="XML">
<option name="WRAP_ON_TYPING" value="0" />
<indentOptions>
<option name="CONTINUATION_INDENT_SIZE" value="4" />
</indentOptions>

View file

@ -158,11 +158,15 @@ class DateUtil @Inject constructor(private val context: Context) {
return DateTime(mills).toString(DateTimeFormat.forPattern(format))
}
fun dayNameString(): String = minuteString(now())
fun amPm(): String = amPm(now())
fun amPm(mills: Long): String =
DateTime(mills).toString(DateTimeFormat.forPattern("a"))
fun dayNameString(): String = dayNameString(now())
fun dayNameString(mills: Long): String =
DateTime(mills).toString(DateTimeFormat.forPattern("E"))
fun dayString(): String = minuteString(now())
fun dayString(): String = dayString(now())
fun dayString(mills: Long): String =
DateTime(mills).toString(DateTimeFormat.forPattern("dd"))

View file

@ -43,8 +43,6 @@ import info.nightscout.shared.logging.LTag
import info.nightscout.shared.sharedPreferences.SP
import info.nightscout.shared.weardata.EventData
import info.nightscout.shared.weardata.EventData.ActionResendData
import info.nightscout.shared.weardata.EventData.SingleBg
import info.nightscout.shared.weardata.EventData.TreatmentData
import io.reactivex.rxjava3.disposables.CompositeDisposable
import io.reactivex.rxjava3.kotlin.plusAssign
import lecho.lib.hellocharts.view.LineChartView
@ -73,8 +71,8 @@ abstract class BaseWatchFace : WatchFace() {
protected val singleBg get() = rawData.singleBg
protected val status get() = rawData.status
protected val treatmentData get() = rawData.treatmentData
protected val graphData get() = rawData.graphData
private val treatmentData get() = rawData.treatmentData
private val graphData get() = rawData.graphData
// Layout
@LayoutRes abstract fun layoutResource(): Int
@ -98,6 +96,7 @@ abstract class BaseWatchFace : WatchFace() {
var mCOB2: TextView? = null
var mBgi: TextView? = null
var mLoop: TextView? = null
var mTimePeriod: TextView? = null
var mDay: TextView? = null
var mDayName: TextView? = null
var mMonth: TextView? = null
@ -245,7 +244,7 @@ abstract class BaseWatchFace : WatchFace() {
}
private fun setupBatteryReceiver() {
val setting = sp.getString("simplify_ui", "off")
val setting = sp.getString(R.string.key_simplify_ui, "off")
if ((setting == "charging" || setting == "ambient_charging") && batteryReceiver == null) {
val intentBatteryFilter = IntentFilter()
intentBatteryFilter.addAction(BatteryManager.ACTION_CHARGING)
@ -296,6 +295,7 @@ abstract class BaseWatchFace : WatchFace() {
mDay = layoutView?.findViewById(R.id.day)
mDayName = layoutView?.findViewById(R.id.dayname)
mMonth = layoutView?.findViewById(R.id.month)
mTimePeriod = layoutView?.findViewById(R.id.timePeriod)
mDate = layoutView?.findViewById(R.id.date_time)
mLoop = layoutView?.findViewById(R.id.loop)
mSgv = layoutView?.findViewById(R.id.sgv)
@ -383,7 +383,7 @@ abstract class BaseWatchFace : WatchFace() {
mDirectionPaint.color = getBgColour(singleBg.sgvLevel)
val sSvg = singleBg.sgvString
val svgWidth = mSvgPaint.measureText(sSvg)
val sDirection = " " + singleBg.sgvString + "\uFE0E"
val sDirection = " " + singleBg.slopeArrow + "\uFE0E"
val directionWidth = mDirectionPaint.measureText(sDirection)
val xSvg = xHalf - (svgWidth + directionWidth) / 2
canvas.drawText(sSvg, xSvg, yThird + mYOffset, mSvgPaint)
@ -420,7 +420,7 @@ abstract class BaseWatchFace : WatchFace() {
@Suppress("DEPRECATION")
private fun checkVibrateHourly(oldTime: WatchFaceTime, newTime: WatchFaceTime) {
val hourlyVibratePref = sp.getBoolean("vibrate_Hourly", false)
val hourlyVibratePref = sp.getBoolean(R.string.key_vibrate_hourly, false)
if (hourlyVibratePref && layoutSet && newTime.hasHourChanged(oldTime)) {
aapsLogger.info(LTag.WEAR, "hourlyVibratePref", "true --> $newTime")
val vibrator = getSystemService(VIBRATOR_SERVICE) as Vibrator
@ -435,8 +435,8 @@ abstract class BaseWatchFace : WatchFace() {
mSgv?.text = singleBg.sgvString
mSgv?.visibility = sp.getBoolean(R.string.key_show_bg, true).toVisibilityKeepSpace()
strikeThroughSgvIfNeeded()
mDirection?.text = "${singleBg.sgvString}\uFE0E"
mDirection?.visibility = sp.getBoolean("show_direction", true).toVisibility()
mDirection?.text = "${singleBg.slopeArrow}\uFE0E"
mDirection?.visibility = sp.getBoolean(R.string.key_show_direction, true).toVisibility()
mDelta?.text = singleBg.delta
mDelta?.visibility = sp.getBoolean(R.string.key_show_delta, true).toVisibility()
mAvgDelta?.text = singleBg.avgDelta
@ -444,23 +444,23 @@ abstract class BaseWatchFace : WatchFace() {
mCOB1?.visibility = sp.getBoolean(R.string.key_show_cob, true).toVisibility()
mCOB2?.text = status.cob
mCOB2?.visibility = sp.getBoolean(R.string.key_show_cob, true).toVisibility()
mIOB1?.visibility = sp.getBoolean("show_iob", true).toVisibility()
mIOB2?.visibility = sp.getBoolean("show_iob", true).toVisibility()
mIOB1?.text = if (sp.getBoolean("show_iob", true)) status.iobSum else getString(R.string.activity_IOB)
mIOB2?.text = if (sp.getBoolean("show_iob", true)) status.iobDetail else status.iobSum
mIOB1?.visibility = sp.getBoolean(R.string.key_show_iob, true).toVisibility()
mIOB2?.visibility = sp.getBoolean(R.string.key_show_iob, true).toVisibility()
mIOB1?.text = if (sp.getBoolean(R.string.key_show_iob, true)) status.iobSum else getString(R.string.activity_IOB)
mIOB2?.text = if (sp.getBoolean(R.string.key_show_iob, true)) status.iobDetail else status.iobSum
mTimestamp?.visibility = sp.getBoolean(R.string.key_show_ago, true).toVisibility()
mTimestamp?.text = readingAge(if (isAAPSv2 != null) true else sp.getBoolean(R.string.key_show_external_status, true))
mUploaderBattery?.visibility = sp.getBoolean("show_uploader_battery", true).toVisibility()
mUploaderBattery?.visibility = sp.getBoolean(R.string.key_show_uploader_battery, true).toVisibility()
mUploaderBattery?.text =
when {
isAAPSv2 != null -> status.battery + "%"
sp.getBoolean(R.string.key_show_external_status, true) -> "U: ${status.battery}%"
else -> "Uploader: ${status.battery}%"
}
mRigBattery?.visibility = sp.getBoolean("show_rig_battery", false).toVisibility()
mRigBattery?.visibility = sp.getBoolean(R.string.key_show_rig_battery, false).toVisibility()
mRigBattery?.text = status.rigBattery
mBasalRate?.text = status.currentBasal
mBasalRate?.visibility = sp.getBoolean("show_temp_basal", true).toVisibility()
mBasalRate?.visibility = sp.getBoolean(R.string.key_show_temp_basal, true).toVisibility()
mBgi?.text = status.bgi
mBgi?.visibility = status.showBgi.toVisibility()
mStatus?.text = status.externalStatus
@ -499,13 +499,15 @@ abstract class BaseWatchFace : WatchFace() {
mDayName?.text = dateUtil.dayNameString()
mDay?.text = dateUtil.dayString()
mMonth?.text = dateUtil.monthString()
mTimePeriod?.visibility = android.text.format.DateFormat.is24HourFormat(this).not().toVisibility()
mTimePeriod?.text = dateUtil.amPm()
}
private fun setColor() {
dividerMatchesBg = sp.getBoolean("match_divider", false)
dividerMatchesBg = sp.getBoolean(R.string.key_match_divider, false)
when {
lowResMode -> setColorLowRes()
sp.getBoolean("dark", true) -> setColorDark()
sp.getBoolean(R.string.key_dark, true) -> setColorDark()
else -> setColorBright()
}
}
@ -537,7 +539,7 @@ abstract class BaseWatchFace : WatchFace() {
private val isSimpleUi: Boolean
get() {
val simplify = sp.getString("simplify_ui", "off")
val simplify = sp.getString(R.string.key_simplify_ui, "off")
return if (simplify == "off") false
else if ((simplify == "ambient" || simplify == "ambient_charging") && currentWatchMode == WatchMode.AMBIENT) true
else (simplify == "charging" || simplify == "ambient_charging") && isCharging

View file

@ -276,35 +276,15 @@ class CircleWatchface : WatchFace() {
// defining color for dark and bright
private val lowColor: Int
get() = if (sp.getBoolean("dark", true)) {
Color.argb(255, 255, 120, 120)
} else {
Color.argb(255, 255, 80, 80)
}
get() = if (sp.getBoolean(R.string.key_dark, true)) Color.argb(255, 255, 120, 120) else Color.argb(255, 255, 80, 80)
private val inRangeColor: Int
get() = if (sp.getBoolean("dark", true)) {
Color.argb(255, 120, 255, 120)
} else {
Color.argb(255, 0, 240, 0)
}
get() = if (sp.getBoolean(R.string.key_dark, true)) Color.argb(255, 120, 255, 120) else Color.argb(255, 0, 240, 0)
private val highColor: Int
get() = if (sp.getBoolean("dark", true)) {
Color.argb(255, 255, 255, 120)
} else {
Color.argb(255, 255, 200, 0)
}
get() = if (sp.getBoolean(R.string.key_dark, true)) Color.argb(255, 255, 255, 120) else Color.argb(255, 255, 200, 0)
private val backgroundColor: Int
get() = if (sp.getBoolean("dark", true)) {
Color.BLACK
} else {
Color.WHITE
}
get() = if (sp.getBoolean(R.string.key_dark, true)) Color.BLACK else Color.WHITE
val textColor: Int
get() = if (sp.getBoolean("dark", true)) {
Color.WHITE
} else {
Color.BLACK
}
get() = if (sp.getBoolean(R.string.key_dark, true)) Color.WHITE else Color.BLACK
private fun drawOtherStuff(canvas: Canvas) {
aapsLogger.debug(LTag.WEAR, "start onDrawOtherStuff. bgDataList.size(): " + bgDataList.size)
@ -388,7 +368,7 @@ class CircleWatchface : WatchFace() {
private fun addReadingSoft(canvas: Canvas, entry: SingleBg) {
aapsLogger.debug(LTag.WEAR, "addReadingSoft")
var color = Color.LTGRAY
if (sp.getBoolean("dark", true)) {
if (sp.getBoolean(R.string.key_dark, true)) {
color = Color.DKGRAY
}
val offsetMultiplier = (displaySize.x / 2f - PADDING) / 12f
@ -403,7 +383,7 @@ class CircleWatchface : WatchFace() {
aapsLogger.debug(LTag.WEAR, "addReading")
var color = Color.LTGRAY
var indicatorColor = Color.DKGRAY
if (sp.getBoolean("dark", true)) {
if (sp.getBoolean(R.string.key_dark, true)) {
color = Color.DKGRAY
indicatorColor = Color.LTGRAY
}

View file

@ -67,13 +67,10 @@ class DigitalStyleWatchface : BaseWatchFace() {
val mShapesElements = layoutView?.findViewById<LinearLayout>(R.id.shapes_elements)
if (mShapesElements != null) {
val displayFormatType = if (mShapesElements.contentDescription.toString().startsWith("round")) "round" else "rect"
val displayStyle = sp.getString("digitalstyle_frameStyle", "full")
val displayFrameColor = sp.getString("digitalstyle_frameColor", "red")
val displayFrameColorSaturation = sp.getString(
"digitalstyle_frameColorSaturation",
"500"
)
val displayFrameColorOpacity = sp.getString("digitalstyle_frameColorOpacity", "1")
val displayStyle = sp.getString(R.string.key_digital_style_frame_style, "full")
val displayFrameColor = sp.getString(R.string.key_digital_style_frame_color, "red")
val displayFrameColorSaturation = sp.getString(R.string.key_digital_style_frame_color_saturation, "500")
val displayFrameColorOpacity = sp.getString(R.string.key_digital_style_frame_color_opacity, "1")
// Load image with shapes
val styleDrawableName = "digitalstyle_bg_" + displayStyle + "_" + displayFormatType

View file

@ -185,7 +185,7 @@ class SteampunkWatchface : BaseWatchFace() {
}
//if both batteries are shown, make them smaller.
if (sp.getBoolean("show_uploader_battery", true) && sp.getBoolean("show_rig_battery", false)) {
if (sp.getBoolean(R.string.key_show_uploader_battery, true) && sp.getBoolean(R.string.key_show_rig_battery, false)) {
mUploaderBattery?.textSize = fontSmall
mRigBattery?.textSize = fontSmall
} else {

View file

@ -6,7 +6,6 @@
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="@color/black"
tools:context=".watchfaces.DigitalStyleWatchface"
tools:deviceIds="wear_square">
<!-- background-image with shapes elements-->
@ -279,7 +278,7 @@
<LinearLayout
android:layout_width="match_parent"
android:layout_height="0dp"
android:layout_marginStart="9dp"
android:layout_marginLeft="9dp"
android:layout_weight="1"
android:orientation="vertical">
@ -369,7 +368,7 @@
android:id="@+id/month"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="5dp"
android:layout_marginLeft="5dp"
android:fontFamily="@font/roboto_condensed_regular"
android:text="MMM"
android:textAllCaps="true"
@ -418,8 +417,7 @@
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="left"
android:layout_marginStart="6sp"
android:layout_marginTop="-2sp"
android:layout_marginLeft="6sp"
android:layout_marginBottom="-8sp"
android:fontFamily="@font/roboto_condensed_bold"
android:text="MI"
@ -427,18 +425,28 @@
android:textSize="26sp"
android:textStyle="bold" />
<!-- 12h period AM / PM-->
<TextView
android:id="@+id/timePeriod"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="bottom"
android:layout_marginLeft="8sp"
android:fontFamily="@font/roboto_condensed_bold"
android:text="AM"
android:textColor="@color/light_grey"
android:textSize="10sp"
android:textStyle="bold" />
</LinearLayout>
</LinearLayout>
</LinearLayout>
<!-- right side 1/2 height - bottom halft -->
<LinearLayout
android:layout_width="match_parent"
android:layout_height="0dp"
android:layout_marginStart="7dp"
android:layout_marginEnd="7dp"
android:layout_marginLeft="7dp"
android:layout_marginRight="7dp"
android:layout_weight="1"
android:baselineAligned="false"
android:gravity="left|top"

View file

@ -6,7 +6,6 @@
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="@color/black"
tools:context=".watchfaces.DigitalStyleWatchface"
tools:deviceIds="wear_round">
<!-- background-image with shapes elements-->
@ -280,7 +279,7 @@
<LinearLayout
android:layout_width="match_parent"
android:layout_height="0dp"
android:layout_marginStart="9dp"
android:layout_marginLeft="9dp"
android:layout_weight="1"
android:orientation="vertical">
@ -370,7 +369,7 @@
android:id="@+id/month"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="5dp"
android:layout_marginLeft="5dp"
android:fontFamily="@font/roboto_condensed_regular"
android:text="MMM"
android:textAllCaps="true"
@ -395,7 +394,7 @@
<!-- hour -->
<TextView
android:id="@+id/hour"
android:layout_width="wrap_content"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_gravity="left"
android:fontFamily="@font/roboto_condensed_bold"
@ -418,8 +417,7 @@
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="left"
android:layout_marginStart="6sp"
android:layout_marginTop="-2sp"
android:layout_marginLeft="6sp"
android:layout_marginBottom="-8sp"
android:fontFamily="@font/roboto_condensed_bold"
android:text="MI"
@ -427,18 +425,28 @@
android:textSize="26sp"
android:textStyle="bold" />
<!-- 12h period AM / PM -->
<TextView
android:id="@+id/timePeriod"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginLeft="8sp"
android:fontFamily="@font/roboto_condensed_bold"
android:gravity="top"
android:text="AM"
android:textColor="@color/light_grey"
android:textSize="10sp"
android:textStyle="bold" />
</LinearLayout>
</LinearLayout>
</LinearLayout>
<!-- right side 1/2 height - bottom halft -->
<LinearLayout
android:layout_width="match_parent"
android:layout_height="0dp"
android:layout_marginStart="7dp"
android:layout_marginEnd="7dp"
android:layout_marginLeft="7dp"
android:layout_marginRight="7dp"
android:layout_weight="1"
android:baselineAligned="false"
android:gravity="left|top"

View file

@ -207,5 +207,18 @@
<string name="key_show_delta" translatable="false">showDelta</string>
<string name="key_show_avg_delta" translatable="false">showAvgDelta</string>
<string name="key_show_ring_history" translatable="false">showRingHistory</string>
<string name="key_digital_style_frame_style" translatable="false">digital_style_frame_style</string>
<string name="key_digital_style_frame_color" translatable="false">digital_style_frame_color</string>
<string name="key_digital_style_frame_color_saturation" translatable="false">digital_style_frame_color_saturation</string>
<string name="key_digital_style_frame_color_opacity" translatable="false">digital_style_frame_color_opacity</string>
<string name="key_show_direction" translatable="false">show_direction</string>
<string name="key_show_iob" translatable="false">show_iob</string>
<string name="key_show_uploader_battery" translatable="false">show_uploader_battery</string>
<string name="key_show_rig_battery" translatable="false">show_rig_battery</string>
<string name="key_show_temp_basal" translatable="false">show_temp_basal</string>
<string name="key_vibrate_hourly" translatable="false">vibrate_hourly</string>
<string name="key_match_divider" translatable="false">match_divider</string>
<string name="key_simplify_ui" translatable="false">simplify_ui</string>
<string name="key_dark" translatable="false">dark</string>
</resources>

View file

@ -4,7 +4,7 @@
<CheckBoxPreference
android:defaultValue="true"
android:key="show_iob"
android:key="@string/key_show_iob"
android:summary="Show insulin on board."
android:title="@string/pref_show_iob"
app:wear_iconOff="@drawable/settings_off"
@ -43,7 +43,7 @@
app:wear_iconOn="@drawable/settings_on" />
<CheckBoxPreference
android:defaultValue="true"
android:key="show_direction"
android:key="@string/key_show_direction"
android:summary="Show direction arrow"
android:title="@string/pref_show_direction_arrow"
app:wear_iconOff="@drawable/settings_off"
@ -59,21 +59,21 @@
<CheckBoxPreference
android:defaultValue="true"
android:key="show_uploader_battery"
android:key="@string/key_show_uploader_battery"
android:title="@string/pref_show_phone_battery"
app:wear_iconOff="@drawable/settings_off"
app:wear_iconOn="@drawable/settings_on" />
<CheckBoxPreference
android:defaultValue="false"
android:key="show_rig_battery"
android:key="@string/key_show_rig_battery"
android:title="@string/pref_show_rig_battery"
app:wear_iconOff="@drawable/settings_off"
app:wear_iconOn="@drawable/settings_on" />
<CheckBoxPreference
android:defaultValue="true"
android:key="show_temp_basal"
android:key="@string/key_show_temp_basal"
android:title="@string/pref_show_basal_rate"
app:wear_iconOff="@drawable/settings_off"
app:wear_iconOn="@drawable/settings_on" />

View file

@ -4,15 +4,14 @@
<CheckBoxPreference
android:defaultValue="true"
android:key="dark"
android:summary="Dark theme"
android:key="@string/key_dark"
android:title="@string/pref_dark"
app:wear_iconOff="@drawable/settings_off"
app:wear_iconOn="@drawable/settings_on" />
<CheckBoxPreference
android:defaultValue="false"
android:key="vibrate_Hourly"
android:key="@string/key_vibrate_hourly"
android:title="@string/pref_vibrate_hourly"
app:wear_iconOff="@drawable/settings_off"
app:wear_iconOn="@drawable/settings_on" />

View file

@ -4,8 +4,7 @@
<CheckBoxPreference
android:defaultValue="true"
android:key="dark"
android:summary="Dark theme"
android:key="@string/key_dark"
android:title="@string/pref_dark"
app:wear_iconOff="@drawable/settings_off"
app:wear_iconOn="@drawable/settings_on" />
@ -44,7 +43,7 @@
<CheckBoxPreference
android:defaultValue="false"
android:key="vibrate_Hourly"
android:key="@string/key_vibrate_hourly"
android:title="@string/pref_vibrate_hourly"
app:wear_iconOff="@drawable/settings_off"
app:wear_iconOn="@drawable/settings_on" />

View file

@ -4,7 +4,7 @@
<CheckBoxPreference
android:defaultValue="false"
android:key="vibrate_Hourly"
android:key="@string/key_vibrate_hourly"
android:title="@string/pref_vibrate_hourly"
app:wear_iconOff="@drawable/settings_off"
app:wear_iconOn="@drawable/settings_on" />
@ -13,7 +13,7 @@
android:defaultValue="off"
android:entries="@array/watchface_simplify_ui_name"
android:entryValues="@array/watchface_simplify_ui_values"
android:key="simplify_ui"
android:key="@string/key_simplify_ui"
android:summary="@string/pref_simplify_ui_sum"
android:title="@string/pref_simplify_ui" />

View file

@ -6,27 +6,27 @@
android:defaultValue="full"
android:entries="@array/digitalstyle_styles_name"
android:entryValues="@array/digitalstyle_styles_values"
android:key="digitalstyle_frameStyle"
android:key="@string/key_digital_style_frame_style"
android:title="@string/digitalstyle_pref_your_style" />
<ListPreference
android:defaultValue="red"
android:entries="@array/digitalstyle_color_name"
android:entryValues="@array/digitalstyle_color_values"
android:key="digitalstyle_frameColor"
android:key="@string/key_digital_style_frame_color"
android:title="@string/digitalstyle_pref_your_color" />
<ListPreference
android:defaultValue="700"
android:entries="@array/digitalstyle_color_saturation"
android:entryValues="@array/digitalstyle_color_saturation"
android:key="digitalstyle_frameColorSaturation"
android:key="@string/key_digital_style_frame_color_saturation"
android:title="@string/digitalstyle_pref_your_color_saturation" />
<ListPreference
android:defaultValue="1"
android:entries="@array/digitalstyle_color_opacity_name"
android:entryValues="@array/digitalstyle_color_opacity_value"
android:key="digitalstyle_frameColorOpacity"
android:key="@string/key_digital_style_frame_color_opacity"
android:title="@string/digitalstyle_pref_your_color_opacity" />
<CheckBoxPreference
@ -45,7 +45,7 @@
<CheckBoxPreference
android:defaultValue="false"
android:key="vibrate_Hourly"
android:key="@string/key_vibrate_hourly"
android:title="@string/pref_vibrate_hourly"
app:wear_iconOff="@drawable/settings_off"
app:wear_iconOn="@drawable/settings_on" />
@ -54,7 +54,7 @@
android:defaultValue="off"
android:entries="@array/watchface_simplify_ui_name"
android:entryValues="@array/watchface_simplify_ui_values"
android:key="simplify_ui"
android:key="@string/key_simplify_ui"
android:summary="@string/pref_simplify_ui_sum"
android:title="@string/pref_simplify_ui" />

View file

@ -4,15 +4,14 @@
<CheckBoxPreference
android:defaultValue="true"
android:key="dark"
android:summary="Dark theme"
android:key="@string/key_dark"
android:title="@string/pref_dark"
app:wear_iconOff="@drawable/settings_off"
app:wear_iconOn="@drawable/settings_on" />
<CheckBoxPreference
android:defaultValue="false"
android:key="match_divider"
android:key="@string/key_match_divider"
android:summary="Status bar divider background matches watchface background"
android:title="@string/pref_matching_divider"
app:wear_iconOff="@drawable/settings_off"
@ -20,7 +19,7 @@
<CheckBoxPreference
android:defaultValue="false"
android:key="vibrate_Hourly"
android:key="@string/key_vibrate_hourly"
android:title="@string/pref_vibrate_hourly"
app:wear_iconOff="@drawable/settings_off"
app:wear_iconOn="@drawable/settings_on" />
@ -29,7 +28,7 @@
android:defaultValue="off"
android:entries="@array/watchface_simplify_ui_name"
android:entryValues="@array/watchface_simplify_ui_values"
android:key="simplify_ui"
android:key="@string/key_simplify_ui"
android:summary="@string/pref_simplify_ui_sum"
android:title="@string/pref_simplify_ui" />

View file

@ -4,15 +4,14 @@
<CheckBoxPreference
android:defaultValue="true"
android:key="dark"
android:summary="Dark theme"
android:key="@string/key_dark"
android:title="@string/pref_dark"
app:wear_iconOff="@drawable/settings_off"
app:wear_iconOn="@drawable/settings_on" />
<CheckBoxPreference
android:defaultValue="false"
android:key="match_divider"
android:key="@string/key_match_divider"
android:summary="Status bar divider background matches watchface background"
android:title="@string/pref_matching_divider"
app:wear_iconOff="@drawable/settings_off"
@ -27,7 +26,7 @@
<CheckBoxPreference
android:defaultValue="false"
android:key="vibrate_Hourly"
android:key="@string/key_vibrate_hourly"
android:title="@string/pref_vibrate_hourly"
app:wear_iconOff="@drawable/settings_off"
app:wear_iconOn="@drawable/settings_on" />
@ -36,7 +35,7 @@
android:defaultValue="off"
android:entries="@array/watchface_simplify_ui_name"
android:entryValues="@array/watchface_simplify_ui_values"
android:key="simplify_ui"
android:key="@string/key_simplify_ui"
android:summary="@string/pref_simplify_ui_sum"
android:title="@string/pref_simplify_ui" />

View file

@ -4,15 +4,14 @@
<CheckBoxPreference
android:defaultValue="true"
android:key="dark"
android:summary="Dark theme"
android:key="@string/key_dark"
android:title="@string/pref_dark"
app:wear_iconOff="@drawable/settings_off"
app:wear_iconOn="@drawable/settings_on" />
<CheckBoxPreference
android:defaultValue="false"
android:key="match_divider"
android:key="@string/key_match_divider"
android:summary="Status bar divider background matches watchface background"
android:title="@string/pref_matching_divider"
app:wear_iconOff="@drawable/settings_off"
@ -20,7 +19,7 @@
<CheckBoxPreference
android:defaultValue="false"
android:key="vibrate_Hourly"
android:key="@string/key_vibrate_hourly"
android:title="@string/pref_vibrate_hourly"
app:wear_iconOff="@drawable/settings_off"
app:wear_iconOn="@drawable/settings_on" />
@ -29,7 +28,7 @@
android:defaultValue="off"
android:entries="@array/watchface_simplify_ui_name"
android:entryValues="@array/watchface_simplify_ui_values"
android:key="simplify_ui"
android:key="@string/key_simplify_ui"
android:summary="@string/pref_simplify_ui_sum"
android:title="@string/pref_simplify_ui" />

View file

@ -4,15 +4,14 @@
<CheckBoxPreference
android:defaultValue="true"
android:key="dark"
android:summary="Dark theme"
android:key="@string/key_dark"
android:title="@string/pref_dark"
app:wear_iconOff="@drawable/settings_off"
app:wear_iconOn="@drawable/settings_on" />
<CheckBoxPreference
android:defaultValue="false"
android:key="vibrate_Hourly"
android:key="@string/key_vibrate_hourly"
android:title="@string/pref_vibrate_hourly"
app:wear_iconOff="@drawable/settings_off"
app:wear_iconOn="@drawable/settings_on" />

View file

@ -12,7 +12,7 @@
<CheckBoxPreference
android:defaultValue="false"
android:key="vibrate_Hourly"
android:key="@string/key_vibrate_hourly"
android:title="@string/pref_vibrate_hourly"
app:wear_iconOff="@drawable/settings_off"
app:wear_iconOn="@drawable/settings_on" />
@ -21,7 +21,7 @@
android:defaultValue="off"
android:entries="@array/watchface_simplify_ui_name"
android:entryValues="@array/watchface_simplify_ui_values"
android:key="simplify_ui"
android:key="@string/key_simplify_ui"
android:summary="@string/pref_simplify_ui_sum"
android:title="@string/pref_simplify_ui" />