From 0031ed83eb212cbbc79269742eb72a8c204911f1 Mon Sep 17 00:00:00 2001 From: Bryan Owens Date: Sun, 1 May 2016 16:31:47 -0500 Subject: Themes: Expose and separate values for themes Change-Id: Ifeff7fa28707de84af3c40f910787092f56c65b5 Signed-off-by: Bryan Owens --- res/layout/activity_album_detail.xml | 10 +++++----- res/layout/activity_artist_detail.xml | 2 +- res/layout/activity_base.xml | 6 +++--- res/layout/app_msg.xml | 2 +- res/layout/app_widget_large.xml | 2 +- res/layout/app_widget_large_alternate.xml | 2 +- res/layout/app_widget_small.xml | 2 +- res/layout/artist_detail_album.xml | 4 ++-- res/layout/artist_detail_header.xml | 6 +++--- res/layout/grid_items_normal.xml | 4 ++-- res/layout/header_bar.xml | 2 +- res/layout/list_base_padding.xml | 2 +- res/layout/list_item_top_tracks.xml | 2 +- res/layout/main_album_flow.xml | 2 +- res/layout/main_playback_controls.xml | 10 +++++----- res/layout/playlist_detail_header.xml | 4 ++-- res/values/colors.xml | 25 +++++++++++++++++++++++++ res/values/dimens.xml | 4 ++++ res/values/styles.xml | 4 ++++ 19 files changed, 64 insertions(+), 31 deletions(-) diff --git a/res/layout/activity_album_detail.xml b/res/layout/activity_album_detail.xml index 3838784..b92066f 100644 --- a/res/layout/activity_album_detail.xml +++ b/res/layout/activity_album_detail.xml @@ -1,7 +1,7 @@ + android:background="@color/activity_album_detail_background_color" > + android:textColor="@color/album_detail_title_text_color" /> + android:textColor="@color/album_detail_song_count_and_year_text_color" /> @@ -79,7 +79,7 @@ android:layout_toRightOf="@id/duration_icon" android:singleLine="true" android:textSize="@dimen/text_size_micro" - android:textColor="@color/default_text_color" + android:textColor="@color/album_detail_duration_text_color" android:layout_marginTop="4dp" /> diff --git a/res/layout/activity_artist_detail.xml b/res/layout/activity_artist_detail.xml index 79f0098..1670794 100644 --- a/res/layout/activity_artist_detail.xml +++ b/res/layout/activity_artist_detail.xml @@ -1,7 +1,7 @@ + android:background="@color/activity_artist_detail_background_color" > diff --git a/res/layout/activity_base.xml b/res/layout/activity_base.xml index 8426ffa..031223e 100644 --- a/res/layout/activity_base.xml +++ b/res/layout/activity_base.xml @@ -35,8 +35,8 @@ android:id="@+id/toolbar" android:layout_width="match_parent" android:layout_height="?android:attr/actionBarSize" - android:theme="@android:style/ThemeOverlay.Material.Dark.ActionBar" - android:popupTheme="@android:style/Theme.Material.Light" + android:theme="@style/ToolBarTheme" + android:popupTheme="@style/ToolBarPopupTheme" android:elevation="@dimen/action_bar_elevation" /> diff --git a/res/layout/app_widget_large.xml b/res/layout/app_widget_large.xml index c4ea525..7ecc900 100644 --- a/res/layout/app_widget_large.xml +++ b/res/layout/app_widget_large.xml @@ -21,7 +21,7 @@ android:layout_height="@dimen/app_widget_large_min_height" android:columnCount="2" android:rowCount="2" - android:background="@color/black" + android:background="@color/widget_background_color" tools:ignore="ContentDescription" > diff --git a/res/layout/app_widget_small.xml b/res/layout/app_widget_small.xml index f6810a7..cb7cd6c 100644 --- a/res/layout/app_widget_small.xml +++ b/res/layout/app_widget_small.xml @@ -21,7 +21,7 @@ android:layout_height="match_parent" android:columnCount="2" android:rowCount="2" - android:background="@color/black" + android:background="@color/widget_background_color" android:gravity="top" android:padding="@dimen/app_widget_padding" tools:ignore="NestedWeights" > diff --git a/res/layout/artist_detail_album.xml b/res/layout/artist_detail_album.xml index 48733de..4433f9e 100644 --- a/res/layout/artist_detail_album.xml +++ b/res/layout/artist_detail_album.xml @@ -65,7 +65,7 @@ android:textSize="@dimen/text_size_micro" android:layout_width="match_parent" android:layout_height="wrap_content" - android:textColor="@color/cardOne" /> + android:textColor="@color/artist_detail_album_title_text_color" /> + android:textColor="@color/artist_detail_album_year_text_color" /> diff --git a/res/layout/artist_detail_header.xml b/res/layout/artist_detail_header.xml index 25cf202..3bdff8d 100644 --- a/res/layout/artist_detail_header.xml +++ b/res/layout/artist_detail_header.xml @@ -1,7 +1,7 @@ + android:background="@color/artist_detail_header_background_color" > @@ -36,7 +36,7 @@ android:layout_below="@id/albums" android:gravity="bottom" android:textAllCaps="true" - android:textColor="@color/list_item_header_text_color" + android:textColor="@color/artist_detail_header_songs_label_text_color" android:textSize="@dimen/text_size_medium" android:text="@string/header_all_songs" /> diff --git a/res/layout/grid_items_normal.xml b/res/layout/grid_items_normal.xml index fee88c1..3c1b0dd 100644 --- a/res/layout/grid_items_normal.xml +++ b/res/layout/grid_items_normal.xml @@ -47,7 +47,7 @@ @@ -55,7 +55,7 @@ diff --git a/res/layout/header_bar.xml b/res/layout/header_bar.xml index 4e66b13..97731fe 100644 --- a/res/layout/header_bar.xml +++ b/res/layout/header_bar.xml @@ -23,7 +23,7 @@ android:paddingStart="@dimen/drag_and_drop_width" android:background="@color/header_action_bar_color" android:elevation="@dimen/action_bar_elevation" - android:theme="@android:style/ThemeOverlay.Material.Dark.ActionBar"> + android:theme="@style/ToolBarTheme"> + android:background="@color/list_base_container_background_color"> diff --git a/res/layout/list_item_top_tracks.xml b/res/layout/list_item_top_tracks.xml index 8988de7..1f74e46 100644 --- a/res/layout/list_item_top_tracks.xml +++ b/res/layout/list_item_top_tracks.xml @@ -49,7 +49,7 @@ android:layout_gravity="center" android:textStyle="bold" android:textSize="@dimen/text_size_small" - android:textColor="@color/white" /> + android:textColor="@color/position_number_color" /> diff --git a/res/layout/main_album_flow.xml b/res/layout/main_album_flow.xml index 109c782..d2e7cde 100644 --- a/res/layout/main_album_flow.xml +++ b/res/layout/main_album_flow.xml @@ -45,7 +45,7 @@ android:paddingTop="6dp" android:paddingBottom="6dp" android:background="@color/lyrics_background_color" - android:textColor="@color/white" + android:textColor="@color/audio_player_lyrics_text_color" android:textSize="@dimen/text_size_small" android:alpha="0.0"/> \ No newline at end of file diff --git a/res/layout/main_playback_controls.xml b/res/layout/main_playback_controls.xml index cee200f..09f934a 100644 --- a/res/layout/main_playback_controls.xml +++ b/res/layout/main_playback_controls.xml @@ -20,9 +20,9 @@ xmlns:card_view="http://schemas.android.com/apk/res-auto" android:layout_width="fill_parent" android:layout_height="fill_parent" - card_view:cardCornerRadius="2dp" - card_view:contentPadding="8dp" - card_view:cardElevation="4dp" + card_view:cardCornerRadius="@dimen/audio_player_controls_card_corner_radius" + card_view:contentPadding="@dimen/audio_player_controls_card_content_padding" + card_view:cardElevation="@dimen/audio_player_controls_card_elevation" card_view:cardUseCompatPadding="true" card_view:cardBackgroundColor="@color/semitransparent_black" > @@ -104,7 +104,7 @@ android:layout_centerVertical="true" android:paddingRight="@dimen/audio_player_time_text_padding" android:gravity="right|center_vertical" - android:textColor="@color/white" + android:textColor="@color/audio_player_total_time_color" android:textSize="@dimen/audio_player_time_text_size" android:textStyle="bold"/> diff --git a/res/layout/playlist_detail_header.xml b/res/layout/playlist_detail_header.xml index 6b7c95a..8456cac 100644 --- a/res/layout/playlist_detail_header.xml +++ b/res/layout/playlist_detail_header.xml @@ -50,7 +50,7 @@ android:layout_width="wrap_content" android:layout_height="wrap_content" android:paddingRight="16dp" - android:textColor="@color/white" + android:textColor="@color/number_of_songs_text_color" android:textSize="@dimen/text_size_micro" /> diff --git a/res/values/colors.xml b/res/values/colors.xml index 481e8b3..2c905e6 100644 --- a/res/values/colors.xml +++ b/res/values/colors.xml @@ -143,4 +143,29 @@ #bffafafa + + + @color/black + @color/white + @color/background_color + @color/background_color + @color/background_color + @color/background_color + @color/default_text_color + @color/default_text_color + @color/default_text_color + @color/default_text_color + ?android:textColorPrimaryInverse + @color/cardOne + @color/cardTwo + @color/list_item_header_text_color + @color/list_item_header_text_color + @color/cardOne + @color/cardTwo + @color/white + @color/white + @color/white + @color/white + @color/white + @color/white diff --git a/res/values/dimens.xml b/res/values/dimens.xml index dbbf5e8..80f7a85 100644 --- a/res/values/dimens.xml +++ b/res/values/dimens.xml @@ -215,4 +215,8 @@ 12sp 10sp + + 2dp + 8dp + 4dp diff --git a/res/values/styles.xml b/res/values/styles.xml index 93acfd1..b942e5e 100644 --- a/res/values/styles.xml +++ b/res/values/styles.xml @@ -191,4 +191,8 @@ @color/tab_text_color @dimen/tab_text_size + +