From 332041e13b05f7e982eb43b0ab3fd96fdfff7a71 Mon Sep 17 00:00:00 2001 From: Onuray Sahin Date: Thu, 2 Jul 2020 19:29:45 +0300 Subject: [PATCH] Move some of colors from attrs.xml to colors_riotx.xml --- .../features/widgets/webview/WidgetWebView.kt | 2 +- vector/src/main/res/layout/activity_login.xml | 2 +- .../src/main/res/layout/activity_progress.xml | 2 +- .../res/layout/activity_vector_settings.xml | 2 +- ...constraint_set_composer_layout_compact.xml | 6 +++--- ...onstraint_set_composer_layout_expanded.xml | 6 +++--- .../main/res/layout/fragment_room_widget.xml | 2 +- .../main/res/layout/merge_composer_layout.xml | 6 +++--- .../res/layout/merge_overlay_waiting_view.xml | 2 +- vector/src/main/res/values/attrs.xml | 6 ------ vector/src/main/res/values/colors_riotx.xml | 19 +++++++++++++++++++ vector/src/main/res/values/theme_black.xml | 4 ++-- vector/src/main/res/values/theme_dark.xml | 6 +++--- vector/src/main/res/values/theme_light.xml | 6 +++--- vector/src/main/res/values/theme_status.xml | 6 +++--- 15 files changed, 45 insertions(+), 32 deletions(-) diff --git a/vector/src/main/java/im/vector/riotx/features/widgets/webview/WidgetWebView.kt b/vector/src/main/java/im/vector/riotx/features/widgets/webview/WidgetWebView.kt index 6b5ade06c4..8fb1f63e65 100644 --- a/vector/src/main/java/im/vector/riotx/features/widgets/webview/WidgetWebView.kt +++ b/vector/src/main/java/im/vector/riotx/features/widgets/webview/WidgetWebView.kt @@ -32,7 +32,7 @@ import im.vector.riotx.features.webview.WebViewEventListener @SuppressLint("NewApi") fun WebView.setupForWidget(webViewEventListener: WebViewEventListener) { // xml value seems ignored - setBackgroundColor(ThemeUtils.getColor(context, R.attr.vctr_bottom_nav_background_color)) + setBackgroundColor(ThemeUtils.getColor(context, R.attr.riotx_bottom_nav_background_color)) // clear caches clearHistory() diff --git a/vector/src/main/res/layout/activity_login.xml b/vector/src/main/res/layout/activity_login.xml index 0add6040a7..9b10f4f391 100644 --- a/vector/src/main/res/layout/activity_login.xml +++ b/vector/src/main/res/layout/activity_login.xml @@ -26,7 +26,7 @@ android:id="@+id/loginTouchArea" android:layout_width="0dp" android:layout_height="0dp" - android:background="?vctr_waiting_background_color" + android:background="?riotx_waiting_background_color" android:clickable="true" app:layout_constraintBottom_toBottomOf="parent" app:layout_constraintEnd_toEndOf="parent" diff --git a/vector/src/main/res/layout/activity_progress.xml b/vector/src/main/res/layout/activity_progress.xml index 5942160525..fe5623f235 100644 --- a/vector/src/main/res/layout/activity_progress.xml +++ b/vector/src/main/res/layout/activity_progress.xml @@ -2,7 +2,7 @@ + android:background="?attr/riotx_waiting_background_color"> diff --git a/vector/src/main/res/layout/constraint_set_composer_layout_compact.xml b/vector/src/main/res/layout/constraint_set_composer_layout_compact.xml index 4607f28f34..a2bf24551d 100644 --- a/vector/src/main/res/layout/constraint_set_composer_layout_compact.xml +++ b/vector/src/main/res/layout/constraint_set_composer_layout_compact.xml @@ -13,7 +13,7 @@ android:id="@+id/related_message_backround" android:layout_width="0dp" android:layout_height="0dp" - android:background="?vctr_bottom_nav_background_color" + android:background="?riotx_bottom_nav_background_color" app:layout_constraintBottom_toTopOf="parent" app:layout_constraintEnd_toEndOf="parent" app:layout_constraintStart_toStartOf="parent" @@ -23,7 +23,7 @@ android:id="@+id/related_message_background_top_separator" android:layout_width="0dp" android:layout_height="0dp" - android:background="?vctr_bottom_nav_background_border_color" + android:background="?riotx_bottom_nav_background_border_color" app:layout_constraintBottom_toTopOf="parent" app:layout_constraintEnd_toEndOf="parent" app:layout_constraintStart_toStartOf="parent" /> @@ -32,7 +32,7 @@ android:id="@+id/related_message_background_bottom_separator" android:layout_width="0dp" android:layout_height="1dp" - android:background="?vctr_bottom_nav_background_border_color" + android:background="?riotx_bottom_nav_background_border_color" app:layout_constraintEnd_toEndOf="parent" app:layout_constraintStart_toStartOf="parent" app:layout_constraintTop_toTopOf="parent" /> diff --git a/vector/src/main/res/layout/constraint_set_composer_layout_expanded.xml b/vector/src/main/res/layout/constraint_set_composer_layout_expanded.xml index 17b350542a..f72404339d 100644 --- a/vector/src/main/res/layout/constraint_set_composer_layout_expanded.xml +++ b/vector/src/main/res/layout/constraint_set_composer_layout_expanded.xml @@ -13,7 +13,7 @@ android:id="@+id/related_message_backround" android:layout_width="match_parent" android:layout_height="0dp" - android:background="?vctr_bottom_nav_background_color" + android:background="?riotx_bottom_nav_background_color" app:layout_constraintBottom_toBottomOf="@id/composer_preview_barrier" app:layout_constraintTop_toTopOf="parent" /> @@ -21,7 +21,7 @@ android:id="@+id/related_message_background_top_separator" android:layout_width="0dp" android:layout_height="1dp" - android:background="?vctr_bottom_nav_background_border_color" + android:background="?riotx_bottom_nav_background_border_color" app:layout_constraintEnd_toEndOf="@id/related_message_backround" app:layout_constraintStart_toStartOf="@+id/related_message_backround" app:layout_constraintTop_toTopOf="@id/related_message_backround" /> @@ -30,7 +30,7 @@ android:id="@+id/related_message_background_bottom_separator" android:layout_width="0dp" android:layout_height="1dp" - android:background="?vctr_bottom_nav_background_border_color" + android:background="?riotx_bottom_nav_background_border_color" app:layout_constraintBottom_toBottomOf="@id/related_message_backround" app:layout_constraintEnd_toEndOf="@id/related_message_backround" app:layout_constraintStart_toStartOf="@+id/related_message_backround" /> diff --git a/vector/src/main/res/layout/fragment_room_widget.xml b/vector/src/main/res/layout/fragment_room_widget.xml index 4c1e5bb4a3..f336f6b6e9 100644 --- a/vector/src/main/res/layout/fragment_room_widget.xml +++ b/vector/src/main/res/layout/fragment_room_widget.xml @@ -25,7 +25,7 @@ android:layout_width="match_parent" android:layout_height="wrap_content" android:layout_alignParentTop="true" - android:background="?vctr_bottom_nav_background_color" + android:background="?riotx_bottom_nav_background_color" android:orientation="horizontal" android:padding="16dp" android:visibility="gone" diff --git a/vector/src/main/res/layout/merge_composer_layout.xml b/vector/src/main/res/layout/merge_composer_layout.xml index b0c733c349..237d3956c3 100644 --- a/vector/src/main/res/layout/merge_composer_layout.xml +++ b/vector/src/main/res/layout/merge_composer_layout.xml @@ -15,21 +15,21 @@ android:id="@+id/related_message_backround" android:layout_width="0dp" android:layout_height="0dp" - android:background="?vctr_bottom_nav_background_color" + android:background="?riotx_bottom_nav_background_color" tools:ignore="MissingConstraints" /> - - - - - - diff --git a/vector/src/main/res/values/colors_riotx.xml b/vector/src/main/res/values/colors_riotx.xml index 348deb57bb..ce99b3a0b1 100644 --- a/vector/src/main/res/values/colors_riotx.xml +++ b/vector/src/main/res/values/colors_riotx.xml @@ -185,6 +185,25 @@ #E3E8F0 #E3E8F0 + + #FFF3F8FD + @color/primary_color_dark + @color/primary_color_black + @color/riot_primary_background_color_status + + + ##AAAAAAAA + #55555555 + #FF15171b + FFE9EDF1 + + + #FFE9EDF1 + #FF15171b + #AAAAAAAA + + + #FFF8E3 diff --git a/vector/src/main/res/values/theme_black.xml b/vector/src/main/res/values/theme_black.xml index 33f04771c1..87d41b8da1 100644 --- a/vector/src/main/res/values/theme_black.xml +++ b/vector/src/main/res/values/theme_black.xml @@ -85,8 +85,8 @@ @color/riot_primary_background_color_black - @color/primary_color_black - #FF15171b + @color/riotx_bottom_nav_background_color_black + @color/riotx_bottom_nav_background_border_color_black @drawable/direct_chat_circle_black diff --git a/vector/src/main/res/values/theme_dark.xml b/vector/src/main/res/values/theme_dark.xml index b4002b409c..2cf29005a6 100644 --- a/vector/src/main/res/values/theme_dark.xml +++ b/vector/src/main/res/values/theme_dark.xml @@ -67,11 +67,11 @@ ?colorAccent - @color/primary_color_dark - #FF15171b + @color/riotx_bottom_nav_background_color_dark + @color/riotx_bottom_nav_background_border_color_dark - #55555555 + @color/riotx_waiting_background_color_dark diff --git a/vector/src/main/res/values/theme_light.xml b/vector/src/main/res/values/theme_light.xml index 3d6a338321..0bad238794 100644 --- a/vector/src/main/res/values/theme_light.xml +++ b/vector/src/main/res/values/theme_light.xml @@ -66,11 +66,11 @@ ?colorAccent - #FFF3F8FD - #FFE9EDF1 + @color/riotx_bottom_nav_background_color_light + @color/riotx_bottom_nav_background_border_color_light - #AAAAAAAA + @color/riotx_waiting_background_color_light diff --git a/vector/src/main/res/values/theme_status.xml b/vector/src/main/res/values/theme_status.xml index 7607ce30e9..ed260ccfeb 100644 --- a/vector/src/main/res/values/theme_status.xml +++ b/vector/src/main/res/values/theme_status.xml @@ -21,12 +21,12 @@ @color/riot_primary_background_color_status - @color/riot_primary_background_color_status + @color/riotx_bottom_nav_background_color_status - #FFE9EDF1 + @color/riotx_bottom_nav_background_border_color_status - #AAAAAAAA + @color/riotx_waiting_background_color_status #FFFFFFFF