Skip to content

Commit 488d615

Browse files
committed
Add tasks section in settings
Moved "Allow creating tasks" setting from general section to tasks
1 parent 2084259 commit 488d615

2 files changed

Lines changed: 35 additions & 16 deletions

File tree

app/src/main/kotlin/com/simplemobiletools/calendar/pro/activities/SettingsActivity.kt

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -103,6 +103,7 @@ class SettingsActivity : SimpleActivity() {
103103
settings_event_lists_label,
104104
settings_widgets_label,
105105
settings_events_label,
106+
settings_tasks_label,
106107
settings_migrating_label
107108
).forEach {
108109
it.setTextColor(getProperPrimaryColor())
@@ -119,6 +120,7 @@ class SettingsActivity : SimpleActivity() {
119120
settings_event_lists_holder,
120121
settings_widgets_holder,
121122
settings_events_holder,
123+
settings_tasks_holder,
122124
settings_migrating_holder
123125
).forEach {
124126
it.background.applyColorFilter(getProperBackgroundColor().getContrastColor())

app/src/main/res/layout/activity_settings.xml

Lines changed: 33 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -138,22 +138,6 @@
138138

139139
</RelativeLayout>
140140

141-
<RelativeLayout
142-
android:id="@+id/settings_allow_creating_tasks_holder"
143-
style="@style/SettingsHolderCheckboxStyle"
144-
android:layout_width="match_parent"
145-
android:layout_height="wrap_content"
146-
android:background="@drawable/ripple_background">
147-
148-
<com.simplemobiletools.commons.views.MyAppCompatCheckbox
149-
android:id="@+id/settings_allow_creating_tasks"
150-
style="@style/SettingsCheckboxStyle"
151-
android:layout_width="match_parent"
152-
android:layout_height="wrap_content"
153-
android:text="@string/allow_creating_tasks" />
154-
155-
</RelativeLayout>
156-
157141
<RelativeLayout
158142
android:id="@+id/settings_sunday_first_holder"
159143
style="@style/SettingsHolderCheckboxStyle"
@@ -942,6 +926,39 @@
942926
</RelativeLayout>
943927
</LinearLayout>
944928

929+
<TextView
930+
android:id="@+id/settings_tasks_label"
931+
style="@style/SettingsSectionLabelStyle"
932+
android:layout_width="match_parent"
933+
android:layout_height="wrap_content"
934+
android:text="@string/tasks" />
935+
936+
<LinearLayout
937+
android:id="@+id/settings_tasks_holder"
938+
android:layout_width="match_parent"
939+
android:layout_height="wrap_content"
940+
android:layout_margin="@dimen/medium_margin"
941+
android:background="@drawable/section_holder_stroke"
942+
android:orientation="vertical">
943+
944+
<RelativeLayout
945+
android:id="@+id/settings_allow_creating_tasks_holder"
946+
style="@style/SettingsHolderCheckboxStyle"
947+
android:layout_width="match_parent"
948+
android:layout_height="wrap_content"
949+
android:background="@drawable/ripple_all_corners">
950+
951+
<com.simplemobiletools.commons.views.MyAppCompatCheckbox
952+
android:id="@+id/settings_allow_creating_tasks"
953+
style="@style/SettingsCheckboxStyle"
954+
android:layout_width="match_parent"
955+
android:layout_height="wrap_content"
956+
android:text="@string/allow_creating_tasks" />
957+
958+
</RelativeLayout>
959+
960+
</LinearLayout>
961+
945962
<TextView
946963
android:id="@+id/settings_migrating_label"
947964
style="@style/SettingsSectionLabelStyle"

0 commit comments

Comments
 (0)