diff options
author | Scott Kennedy <skennedy@google.com> | 2015-02-28 18:12:39 -0800 |
---|---|---|
committer | Scott Kennedy <skennedy@google.com> | 2015-03-02 11:11:22 -0800 |
commit | a09b3c940e98b8606a16a94b48b6d0121d9d3635 (patch) | |
tree | 4c4c3838cba13dad2ae459197483872ba546a8ee | |
parent | 70ca047b61c72f1670d52d16d8d0deb341277f38 (diff) | |
download | datetimepicker-a09b3c940e98b8606a16a94b48b6d0121d9d3635.tar.gz |
Remove the "white" color and use Android's
Change-Id: I3b05f376db201e441759400c6341eb1e53ffbc60
-rw-r--r-- | res/drawable-land-v19/done_background_color.xml | 4 | ||||
-rw-r--r-- | res/drawable-land/done_background_color.xml | 4 | ||||
-rw-r--r-- | res/layout-land/date_picker_dialog.xml | 4 | ||||
-rw-r--r-- | res/layout-land/time_picker_dialog.xml | 2 | ||||
-rw-r--r-- | res/layout-sw600dp-land/date_picker_dialog.xml | 4 | ||||
-rw-r--r-- | res/layout/date_picker_header_view.xml | 2 | ||||
-rw-r--r-- | res/layout/date_picker_selected_date.xml | 4 | ||||
-rw-r--r-- | res/layout/time_header_label.xml | 2 | ||||
-rw-r--r-- | res/layout/time_picker_dialog.xml | 2 | ||||
-rw-r--r-- | res/values/colors.xml | 3 | ||||
-rw-r--r-- | src/com/android/datetimepicker/date/MonthView.java | 2 | ||||
-rw-r--r-- | src/com/android/datetimepicker/time/AmPmCirclesView.java | 6 | ||||
-rw-r--r-- | src/com/android/datetimepicker/time/CircleView.java | 4 | ||||
-rw-r--r-- | src/com/android/datetimepicker/time/RadialTextsView.java | 2 | ||||
-rw-r--r-- | src/com/android/datetimepicker/time/TimePickerDialog.java | 5 |
15 files changed, 25 insertions, 25 deletions
diff --git a/res/drawable-land-v19/done_background_color.xml b/res/drawable-land-v19/done_background_color.xml index b4da4c4..5966359 100644 --- a/res/drawable-land-v19/done_background_color.xml +++ b/res/drawable-land-v19/done_background_color.xml @@ -21,5 +21,5 @@ <item android:state_pressed="true" android:drawable="@color/neutral_pressed" /> - <item android:drawable="@color/white" /> -</selector>
\ No newline at end of file + <item android:drawable="@android:color/white" /> +</selector> diff --git a/res/drawable-land/done_background_color.xml b/res/drawable-land/done_background_color.xml index b2acf46..6cfc2f3 100644 --- a/res/drawable-land/done_background_color.xml +++ b/res/drawable-land/done_background_color.xml @@ -21,5 +21,5 @@ <item android:state_pressed="true" android:drawable="@color/blue" /> - <item android:drawable="@color/white" /> -</selector>
\ No newline at end of file + <item android:drawable="@android:color/white" /> +</selector> diff --git a/res/layout-land/date_picker_dialog.xml b/res/layout-land/date_picker_dialog.xml index 99b882f..6ba8b67 100644 --- a/res/layout-land/date_picker_dialog.xml +++ b/res/layout-land/date_picker_dialog.xml @@ -24,7 +24,7 @@ android:layout_width="wrap_content" android:layout_height="match_parent" android:layout_gravity="center" - android:background="@color/white" + android:background="@android:color/white" android:orientation="vertical" > <LinearLayout @@ -48,4 +48,4 @@ <include layout="@layout/date_picker_view_animator" /> -</LinearLayout>
\ No newline at end of file +</LinearLayout> diff --git a/res/layout-land/time_picker_dialog.xml b/res/layout-land/time_picker_dialog.xml index ed167af..e3a88cc 100644 --- a/res/layout-land/time_picker_dialog.xml +++ b/res/layout-land/time_picker_dialog.xml @@ -33,7 +33,7 @@ android:layout_width="match_parent" android:layout_height="0dip" android:layout_weight="1" - android:background="@color/white" > + android:background="@android:color/white" > <include layout="@layout/time_header_label" android:layout_width="match_parent" diff --git a/res/layout-sw600dp-land/date_picker_dialog.xml b/res/layout-sw600dp-land/date_picker_dialog.xml index 99b882f..6ba8b67 100644 --- a/res/layout-sw600dp-land/date_picker_dialog.xml +++ b/res/layout-sw600dp-land/date_picker_dialog.xml @@ -24,7 +24,7 @@ android:layout_width="wrap_content" android:layout_height="match_parent" android:layout_gravity="center" - android:background="@color/white" + android:background="@android:color/white" android:orientation="vertical" > <LinearLayout @@ -48,4 +48,4 @@ <include layout="@layout/date_picker_view_animator" /> -</LinearLayout>
\ No newline at end of file +</LinearLayout> diff --git a/res/layout/date_picker_header_view.xml b/res/layout/date_picker_header_view.xml index 5fd73cc..08e70ed 100644 --- a/res/layout/date_picker_header_view.xml +++ b/res/layout/date_picker_header_view.xml @@ -21,6 +21,6 @@ android:background="@color/calendar_header" android:gravity="center" android:includeFontPadding="false" - android:textColor="@color/white" + android:textColor="@android:color/white" android:textSize="@dimen/date_picker_header_text_size" android:importantForAccessibility="no" /> diff --git a/res/layout/date_picker_selected_date.xml b/res/layout/date_picker_selected_date.xml index 2118ce1..757b4d1 100644 --- a/res/layout/date_picker_selected_date.xml +++ b/res/layout/date_picker_selected_date.xml @@ -20,7 +20,7 @@ android:layout_width="@dimen/date_picker_component_width" android:layout_height="0dip" android:layout_weight="1" - android:background="@color/white" + android:background="@android:color/white" android:gravity="center" android:orientation="vertical" > @@ -67,4 +67,4 @@ android:textColor="@color/date_picker_selector" android:textSize="@dimen/selected_date_year_size" /> -</LinearLayout>
\ No newline at end of file +</LinearLayout> diff --git a/res/layout/time_header_label.xml b/res/layout/time_header_label.xml index 56776ad..4299980 100644 --- a/res/layout/time_header_label.xml +++ b/res/layout/time_header_label.xml @@ -19,7 +19,7 @@ android:layout_width="match_parent" android:layout_height="match_parent" android:layout_gravity="center" - android:background="@color/white" > + android:background="@android:color/white" > <View android:id="@+id/center_view" android:layout_width="1dp" diff --git a/res/layout/time_picker_dialog.xml b/res/layout/time_picker_dialog.xml index 24b18c9..6d69af2 100644 --- a/res/layout/time_picker_dialog.xml +++ b/res/layout/time_picker_dialog.xml @@ -24,7 +24,7 @@ android:id="@+id/time_display_background" android:layout_width="match_parent" android:layout_height="wrap_content" - android:background="@color/white" > + android:background="@android:color/white" > <include layout="@layout/time_header_label" android:layout_width="match_parent" diff --git a/res/values/colors.xml b/res/values/colors.xml index 0a5eb15..82804d4 100644 --- a/res/values/colors.xml +++ b/res/values/colors.xml @@ -16,7 +16,6 @@ --> <resources> - <color name="white">#ffffff</color> <color name="circle_background">#f2f2f2</color> <color name="line_background">#cccccc</color> <color name="ampm_text_color">#8c8c8c</color> @@ -45,4 +44,4 @@ <color name="done_text_color_dark_normal">#ffffff</color> <color name="done_text_color_dark_disabled">#888888</color> <color name="done_disabled_dark">#bfbfbf</color> -</resources>
\ No newline at end of file +</resources> diff --git a/src/com/android/datetimepicker/date/MonthView.java b/src/com/android/datetimepicker/date/MonthView.java index e4d1f09..00711f3 100644 --- a/src/com/android/datetimepicker/date/MonthView.java +++ b/src/com/android/datetimepicker/date/MonthView.java @@ -204,7 +204,7 @@ public abstract class MonthView extends View { mDayTextColor = res.getColor(R.color.date_picker_text_normal); mTodayNumberColor = res.getColor(R.color.blue); mDisabledDayTextColor = res.getColor(R.color.date_picker_text_disabled); - mMonthTitleColor = res.getColor(R.color.white); + mMonthTitleColor = res.getColor(android.R.color.white); mMonthTitleBGColor = res.getColor(R.color.circle_background); mStringBuilder = new StringBuilder(50); diff --git a/src/com/android/datetimepicker/time/AmPmCirclesView.java b/src/com/android/datetimepicker/time/AmPmCirclesView.java index c62aebf..902abd9 100644 --- a/src/com/android/datetimepicker/time/AmPmCirclesView.java +++ b/src/com/android/datetimepicker/time/AmPmCirclesView.java @@ -74,7 +74,7 @@ public class AmPmCirclesView extends View { } Resources res = context.getResources(); - mUnselectedColor = res.getColor(R.color.white); + mUnselectedColor = res.getColor(android.R.color.white); mSelectedColor = res.getColor(R.color.blue); mAmPmTextColor = res.getColor(R.color.ampm_text_color); mSelectedAlpha = SELECTED_ALPHA; @@ -103,10 +103,10 @@ public class AmPmCirclesView extends View { if (themeDark) { mUnselectedColor = res.getColor(R.color.dark_gray); mSelectedColor = res.getColor(R.color.red); - mAmPmTextColor = res.getColor(R.color.white); + mAmPmTextColor = res.getColor(android.R.color.white); mSelectedAlpha = SELECTED_ALPHA_THEME_DARK; } else { - mUnselectedColor = res.getColor(R.color.white); + mUnselectedColor = res.getColor(android.R.color.white); mSelectedColor = res.getColor(R.color.blue); mAmPmTextColor = res.getColor(R.color.ampm_text_color); mSelectedAlpha = SELECTED_ALPHA; diff --git a/src/com/android/datetimepicker/time/CircleView.java b/src/com/android/datetimepicker/time/CircleView.java index 549db42..1dd4eea 100644 --- a/src/com/android/datetimepicker/time/CircleView.java +++ b/src/com/android/datetimepicker/time/CircleView.java @@ -48,7 +48,7 @@ public class CircleView extends View { super(context); Resources res = context.getResources(); - mCircleColor = res.getColor(R.color.white); + mCircleColor = res.getColor(android.R.color.white); mDotColor = res.getColor(R.color.numbers_text_color); mPaint.setAntiAlias(true); @@ -82,7 +82,7 @@ public class CircleView extends View { mCircleColor = res.getColor(R.color.dark_gray); mDotColor = res.getColor(R.color.light_gray); } else { - mCircleColor = res.getColor(R.color.white); + mCircleColor = res.getColor(android.R.color.white); mDotColor = res.getColor(R.color.numbers_text_color); } } diff --git a/src/com/android/datetimepicker/time/RadialTextsView.java b/src/com/android/datetimepicker/time/RadialTextsView.java index 9acc8c5..684e8f5 100644 --- a/src/com/android/datetimepicker/time/RadialTextsView.java +++ b/src/com/android/datetimepicker/time/RadialTextsView.java @@ -147,7 +147,7 @@ public class RadialTextsView extends View { Resources res = context.getResources(); int textColor; if (themeDark) { - textColor = res.getColor(R.color.white); + textColor = res.getColor(android.R.color.white); } else { textColor = res.getColor(R.color.numbers_text_color); } diff --git a/src/com/android/datetimepicker/time/TimePickerDialog.java b/src/com/android/datetimepicker/time/TimePickerDialog.java index feb9a8a..c7661ad 100644 --- a/src/com/android/datetimepicker/time/TimePickerDialog.java +++ b/src/com/android/datetimepicker/time/TimePickerDialog.java @@ -201,7 +201,8 @@ public class TimePickerDialog extends DialogFragment implements OnValueSelectedL mMinutePickerDescription = res.getString(R.string.minute_picker_description); mSelectMinutes = res.getString(R.string.select_minutes); mSelectedColor = res.getColor(mThemeDark? R.color.red : R.color.blue); - mUnselectedColor = res.getColor(mThemeDark? R.color.white : R.color.numbers_text_color); + mUnselectedColor = + res.getColor(mThemeDark? android.R.color.white : R.color.numbers_text_color); mHourView = (TextView) view.findViewById(R.id.hours); mHourView.setOnKeyListener(keyboardListener); @@ -314,7 +315,7 @@ public class TimePickerDialog extends DialogFragment implements OnValueSelectedL // Set the theme at the end so that the initialize()s above don't counteract the theme. mTimePicker.setTheme(getActivity().getApplicationContext(), mThemeDark); // Prepare some colors to use. - int white = res.getColor(R.color.white); + int white = res.getColor(android.R.color.white); int circleBackground = res.getColor(R.color.circle_background); int line = res.getColor(R.color.line_background); int timeDisplay = res.getColor(R.color.numbers_text_color); |