mirror of
https://github.com/SimpleMobileTools/Simple-Calendar.git
synced 2025-02-18 04:40:36 +01:00
style a couple more components
This commit is contained in:
parent
c771904361
commit
2ef1c73df1
@ -74,7 +74,8 @@ public class DayActivity extends SimpleActivity
|
|||||||
mDateTV.setText(date);
|
mDateTV.setText(date);
|
||||||
mToBeDeleted = new ArrayList<>();
|
mToBeDeleted = new ArrayList<>();
|
||||||
|
|
||||||
final int textColor = Utils.adjustAlpha(Color.BLACK, Constants.HIGH_ALPHA);
|
final int baseColor = mConfig.getIsDarkTheme() ? Color.WHITE : Color.BLACK;
|
||||||
|
final int textColor = Utils.adjustAlpha(baseColor, Constants.HIGH_ALPHA);
|
||||||
mLeftArrow.getDrawable().mutate().setColorFilter(textColor, PorterDuff.Mode.SRC_ATOP);
|
mLeftArrow.getDrawable().mutate().setColorFilter(textColor, PorterDuff.Mode.SRC_ATOP);
|
||||||
mRightArrow.getDrawable().mutate().setColorFilter(textColor, PorterDuff.Mode.SRC_ATOP);
|
mRightArrow.getDrawable().mutate().setColorFilter(textColor, PorterDuff.Mode.SRC_ATOP);
|
||||||
}
|
}
|
||||||
@ -114,7 +115,8 @@ public class DayActivity extends SimpleActivity
|
|||||||
|
|
||||||
@OnClick(R.id.top_text)
|
@OnClick(R.id.top_text)
|
||||||
public void pickDay() {
|
public void pickDay() {
|
||||||
final AlertDialog.Builder alertDialog = new AlertDialog.Builder(this, R.style.MyAlertDialog);
|
final int theme = mConfig.getIsDarkTheme() ? R.style.MyAlertDialog_Dark : R.style.MyAlertDialog;
|
||||||
|
final AlertDialog.Builder alertDialog = new AlertDialog.Builder(this, theme);
|
||||||
final View view = getLayoutInflater().inflate(R.layout.date_picker, null);
|
final View view = getLayoutInflater().inflate(R.layout.date_picker, null);
|
||||||
final DatePicker datePicker = (DatePicker) view.findViewById(R.id.date_picker);
|
final DatePicker datePicker = (DatePicker) view.findViewById(R.id.date_picker);
|
||||||
|
|
||||||
|
@ -176,7 +176,8 @@ public class MainActivity extends SimpleActivity implements Calendar {
|
|||||||
|
|
||||||
@OnClick(R.id.top_text)
|
@OnClick(R.id.top_text)
|
||||||
public void pickMonth() {
|
public void pickMonth() {
|
||||||
final AlertDialog.Builder alertDialog = new AlertDialog.Builder(this, R.style.MyAlertDialog);
|
final int theme = mConfig.getIsDarkTheme() ? R.style.MyAlertDialog_Dark : R.style.MyAlertDialog;
|
||||||
|
final AlertDialog.Builder alertDialog = new AlertDialog.Builder(this, theme);
|
||||||
final View view = getLayoutInflater().inflate(R.layout.date_picker, null);
|
final View view = getLayoutInflater().inflate(R.layout.date_picker, null);
|
||||||
final DatePicker datePicker = (DatePicker) view.findViewById(R.id.date_picker);
|
final DatePicker datePicker = (DatePicker) view.findViewById(R.id.date_picker);
|
||||||
hideDayPicker(datePicker);
|
hideDayPicker(datePicker);
|
||||||
|
@ -53,6 +53,8 @@
|
|||||||
|
|
||||||
<style name="MyAlertDialog" parent="Base.Theme.AppCompat.Light.Dialog.Alert"/>
|
<style name="MyAlertDialog" parent="Base.Theme.AppCompat.Light.Dialog.Alert"/>
|
||||||
|
|
||||||
|
<style name="MyAlertDialog.Dark" parent="Base.Theme.AppCompat.Dialog.Alert"/>
|
||||||
|
|
||||||
<style name="AppTheme.ActionBarStyle" parent="@style/Base.Widget.AppCompat.ActionBar">
|
<style name="AppTheme.ActionBarStyle" parent="@style/Base.Widget.AppCompat.ActionBar">
|
||||||
<item name="background">@color/colorPrimary</item>
|
<item name="background">@color/colorPrimary</item>
|
||||||
<item name="titleTextStyle">@style/AppTheme.ActionBar.TitleTextStyle</item>
|
<item name="titleTextStyle">@style/AppTheme.ActionBar.TitleTextStyle</item>
|
||||||
|
Loading…
x
Reference in New Issue
Block a user