mirror of
https://github.com/SimpleMobileTools/Simple-Clock.git
synced 2025-02-22 14:47:38 +01:00
add a toggle for setting Sunday as the first day
This commit is contained in:
parent
d91895f336
commit
68ee5a40c6
@ -24,6 +24,7 @@ class SettingsActivity : SimpleActivity() {
|
|||||||
setupUseEnglish()
|
setupUseEnglish()
|
||||||
setupAvoidWhatsNew()
|
setupAvoidWhatsNew()
|
||||||
setupPreventPhoneFromSleeping()
|
setupPreventPhoneFromSleeping()
|
||||||
|
setupSundayFirst()
|
||||||
setupShowSeconds()
|
setupShowSeconds()
|
||||||
setupDisplayOtherTimeZones()
|
setupDisplayOtherTimeZones()
|
||||||
setupAlarmMaxReminder()
|
setupAlarmMaxReminder()
|
||||||
@ -75,6 +76,14 @@ class SettingsActivity : SimpleActivity() {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private fun setupSundayFirst() {
|
||||||
|
settings_sunday_first.isChecked = config.isSundayFirst
|
||||||
|
settings_sunday_first_holder.setOnClickListener {
|
||||||
|
settings_sunday_first.toggle()
|
||||||
|
config.isSundayFirst = settings_sunday_first.isChecked
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
private fun setupShowSeconds() {
|
private fun setupShowSeconds() {
|
||||||
settings_show_seconds.isChecked = config.showSeconds
|
settings_show_seconds.isChecked = config.showSeconds
|
||||||
settings_show_seconds_holder.setOnClickListener {
|
settings_show_seconds_holder.setOnClickListener {
|
||||||
|
@ -102,6 +102,29 @@
|
|||||||
|
|
||||||
</RelativeLayout>
|
</RelativeLayout>
|
||||||
|
|
||||||
|
<RelativeLayout
|
||||||
|
android:id="@+id/settings_sunday_first_holder"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginTop="@dimen/medium_margin"
|
||||||
|
android:background="?attr/selectableItemBackground"
|
||||||
|
android:paddingBottom="@dimen/activity_margin"
|
||||||
|
android:paddingLeft="@dimen/normal_margin"
|
||||||
|
android:paddingRight="@dimen/normal_margin"
|
||||||
|
android:paddingTop="@dimen/activity_margin">
|
||||||
|
|
||||||
|
<com.simplemobiletools.commons.views.MySwitchCompat
|
||||||
|
android:id="@+id/settings_sunday_first"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:background="@null"
|
||||||
|
android:clickable="false"
|
||||||
|
android:paddingLeft="@dimen/medium_margin"
|
||||||
|
android:paddingStart="@dimen/medium_margin"
|
||||||
|
android:text="@string/sunday_first"/>
|
||||||
|
|
||||||
|
</RelativeLayout>
|
||||||
|
|
||||||
<View
|
<View
|
||||||
android:id="@+id/clock_tab_divider"
|
android:id="@+id/clock_tab_divider"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
|
Loading…
x
Reference in New Issue
Block a user