mirror of
https://github.com/SimpleMobileTools/Simple-Calendar.git
synced 2025-02-17 12:20:51 +01:00
add a white stroke around color pickers on widget config screens
This commit is contained in:
parent
898519de91
commit
48d452bd28
@ -18,6 +18,7 @@ import com.simplemobiletools.calendar.models.ListItem
|
|||||||
import com.simplemobiletools.calendar.models.ListSection
|
import com.simplemobiletools.calendar.models.ListSection
|
||||||
import com.simplemobiletools.commons.dialogs.ColorPickerDialog
|
import com.simplemobiletools.commons.dialogs.ColorPickerDialog
|
||||||
import com.simplemobiletools.commons.extensions.adjustAlpha
|
import com.simplemobiletools.commons.extensions.adjustAlpha
|
||||||
|
import com.simplemobiletools.commons.extensions.setFillWithStroke
|
||||||
import kotlinx.android.synthetic.main.widget_config_list.*
|
import kotlinx.android.synthetic.main.widget_config_list.*
|
||||||
import org.joda.time.DateTime
|
import org.joda.time.DateTime
|
||||||
import java.util.*
|
import java.util.*
|
||||||
@ -133,14 +134,14 @@ class WidgetListConfigureActivity : SimpleActivity() {
|
|||||||
private fun updateColors() {
|
private fun updateColors() {
|
||||||
mTextColor = mTextColorWithoutTransparency
|
mTextColor = mTextColorWithoutTransparency
|
||||||
mEventsAdapter?.updateTextColor(mTextColor)
|
mEventsAdapter?.updateTextColor(mTextColor)
|
||||||
config_text_color.setBackgroundColor(mTextColor)
|
config_text_color.setFillWithStroke(mTextColor, Color.BLACK)
|
||||||
config_save.setTextColor(mTextColor)
|
config_save.setTextColor(mTextColor)
|
||||||
}
|
}
|
||||||
|
|
||||||
private fun updateBgColor() {
|
private fun updateBgColor() {
|
||||||
mBgColor = mBgColorWithoutTransparency.adjustAlpha(mBgAlpha)
|
mBgColor = mBgColorWithoutTransparency.adjustAlpha(mBgAlpha)
|
||||||
config_events_list.setBackgroundColor(mBgColor)
|
config_events_list.setBackgroundColor(mBgColor)
|
||||||
config_bg_color.setBackgroundColor(mBgColor)
|
config_bg_color.setFillWithStroke(mBgColor, Color.BLACK)
|
||||||
config_save.setBackgroundColor(mBgColor)
|
config_save.setBackgroundColor(mBgColor)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -144,7 +144,7 @@ class WidgetMonthlyConfigureActivity : SimpleActivity(), MonthlyCalendar {
|
|||||||
top_left_arrow.applyColorFilter(mTextColor)
|
top_left_arrow.applyColorFilter(mTextColor)
|
||||||
top_right_arrow.applyColorFilter(mTextColor)
|
top_right_arrow.applyColorFilter(mTextColor)
|
||||||
top_value.setTextColor(mTextColor)
|
top_value.setTextColor(mTextColor)
|
||||||
config_text_color.setBackgroundColor(mTextColor)
|
config_text_color.setFillWithStroke(mTextColor, Color.BLACK)
|
||||||
config_save.setTextColor(mTextColor)
|
config_save.setTextColor(mTextColor)
|
||||||
updateLabels()
|
updateLabels()
|
||||||
}
|
}
|
||||||
@ -152,7 +152,7 @@ class WidgetMonthlyConfigureActivity : SimpleActivity(), MonthlyCalendar {
|
|||||||
private fun updateBgColor() {
|
private fun updateBgColor() {
|
||||||
mBgColor = mBgColorWithoutTransparency.adjustAlpha(mBgAlpha)
|
mBgColor = mBgColorWithoutTransparency.adjustAlpha(mBgAlpha)
|
||||||
config_calendar.setBackgroundColor(mBgColor)
|
config_calendar.setBackgroundColor(mBgColor)
|
||||||
config_bg_color.setBackgroundColor(mBgColor)
|
config_bg_color.setFillWithStroke(mBgColor, Color.BLACK)
|
||||||
config_save.setBackgroundColor(mBgColor)
|
config_save.setBackgroundColor(mBgColor)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -20,7 +20,7 @@
|
|||||||
android:paddingTop="@dimen/medium_margin"
|
android:paddingTop="@dimen/medium_margin"
|
||||||
app:layoutManager="com.simplemobiletools.commons.views.MyLinearLayoutManager"/>
|
app:layoutManager="com.simplemobiletools.commons.views.MyLinearLayoutManager"/>
|
||||||
|
|
||||||
<Button
|
<ImageView
|
||||||
android:id="@+id/config_bg_color"
|
android:id="@+id/config_bg_color"
|
||||||
android:layout_width="@dimen/widget_colorpicker_size"
|
android:layout_width="@dimen/widget_colorpicker_size"
|
||||||
android:layout_height="@dimen/widget_colorpicker_size"
|
android:layout_height="@dimen/widget_colorpicker_size"
|
||||||
@ -44,7 +44,7 @@
|
|||||||
android:paddingRight="@dimen/activity_margin"/>
|
android:paddingRight="@dimen/activity_margin"/>
|
||||||
</RelativeLayout>
|
</RelativeLayout>
|
||||||
|
|
||||||
<Button
|
<ImageView
|
||||||
android:id="@+id/config_text_color"
|
android:id="@+id/config_text_color"
|
||||||
android:layout_width="@dimen/widget_colorpicker_size"
|
android:layout_width="@dimen/widget_colorpicker_size"
|
||||||
android:layout_height="@dimen/widget_colorpicker_size"
|
android:layout_height="@dimen/widget_colorpicker_size"
|
||||||
|
@ -15,7 +15,7 @@
|
|||||||
android:layout_above="@+id/config_bg_color"
|
android:layout_above="@+id/config_bg_color"
|
||||||
android:layout_marginBottom="@dimen/activity_margin"/>
|
android:layout_marginBottom="@dimen/activity_margin"/>
|
||||||
|
|
||||||
<Button
|
<ImageView
|
||||||
android:id="@+id/config_bg_color"
|
android:id="@+id/config_bg_color"
|
||||||
android:layout_width="@dimen/widget_colorpicker_size"
|
android:layout_width="@dimen/widget_colorpicker_size"
|
||||||
android:layout_height="@dimen/widget_colorpicker_size"
|
android:layout_height="@dimen/widget_colorpicker_size"
|
||||||
@ -39,7 +39,7 @@
|
|||||||
android:paddingRight="@dimen/activity_margin"/>
|
android:paddingRight="@dimen/activity_margin"/>
|
||||||
</RelativeLayout>
|
</RelativeLayout>
|
||||||
|
|
||||||
<Button
|
<ImageView
|
||||||
android:id="@+id/config_text_color"
|
android:id="@+id/config_text_color"
|
||||||
android:layout_width="@dimen/widget_colorpicker_size"
|
android:layout_width="@dimen/widget_colorpicker_size"
|
||||||
android:layout_height="@dimen/widget_colorpicker_size"
|
android:layout_height="@dimen/widget_colorpicker_size"
|
||||||
|
Loading…
x
Reference in New Issue
Block a user