diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/catalogue/CatalogueAdapter.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/catalogue/CatalogueAdapter.kt index ca78228789..2c9ac946c4 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/catalogue/CatalogueAdapter.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/catalogue/CatalogueAdapter.kt @@ -13,7 +13,7 @@ import eu.kanade.tachiyomi.util.system.getResourceColor class CatalogueAdapter(val controller: CatalogueController) : FlexibleAdapter>(null, controller, true) { - val cardBackground = controller.activity!!.getResourceColor(R.attr.background_card) + val cardBackground = controller.activity!!.getResourceColor(R.attr.colorSurface) init { setDisplayHeadersAtStartUp(true) diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/extension/ExtensionAdapter.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/extension/ExtensionAdapter.kt index f8b1f56715..7c071dbd74 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/extension/ExtensionAdapter.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/extension/ExtensionAdapter.kt @@ -13,7 +13,7 @@ import eu.kanade.tachiyomi.util.system.getResourceColor class ExtensionAdapter(val controller: ExtensionController) : FlexibleAdapter>(null, controller, true) { - val cardBackground = controller.activity!!.getResourceColor(R.attr.background_card) + val cardBackground = controller.activity!!.getResourceColor(R.attr.colorSurface) init { setDisplayHeadersAtStartUp(true) diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/migration/SourceAdapter.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/migration/SourceAdapter.kt index 8aa6ed7574..22af8dd0f5 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/migration/SourceAdapter.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/migration/SourceAdapter.kt @@ -13,7 +13,7 @@ import eu.kanade.tachiyomi.util.system.getResourceColor class SourceAdapter(val controller: MigrationController) : FlexibleAdapter>(null, controller, true) { - val cardBackground = controller.activity!!.getResourceColor(R.attr.background_card) + val cardBackground = controller.activity!!.getResourceColor(R.attr.colorSurface) private var items: List>? = null diff --git a/app/src/main/java/eu/kanade/tachiyomi/widget/preference/LoginDialogPreference.kt b/app/src/main/java/eu/kanade/tachiyomi/widget/preference/LoginDialogPreference.kt index 5abb672e10..c3e836ca86 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/widget/preference/LoginDialogPreference.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/widget/preference/LoginDialogPreference.kt @@ -50,7 +50,7 @@ abstract class LoginDialogPreference(private val usernameLabel: String? = null, } if (!usernameLabel.isNullOrEmpty()) { - username_label.text = usernameLabel + username_label.hint = usernameLabel } login.setMode(ActionProcessButton.Mode.ENDLESS) diff --git a/app/src/main/java/eu/kanade/tachiyomi/widget/preference/SwitchPreferenceCategory.kt b/app/src/main/java/eu/kanade/tachiyomi/widget/preference/SwitchPreferenceCategory.kt index e5f7595811..92ee4f096d 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/widget/preference/SwitchPreferenceCategory.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/widget/preference/SwitchPreferenceCategory.kt @@ -1,9 +1,7 @@ package eu.kanade.tachiyomi.widget.preference -import android.annotation.TargetApi import android.content.Context import android.content.res.TypedArray -import android.os.Build.VERSION_CODES.ICE_CREAM_SANDWICH import android.util.AttributeSet import android.view.View import android.widget.Checkable @@ -41,7 +39,6 @@ class SwitchPreferenceCategory @JvmOverloads constructor( syncSwitchView(switchView) } - @TargetApi(ICE_CREAM_SANDWICH) private fun syncSwitchView(view: View) { if (view is Checkable) { val isChecked = view.isChecked diff --git a/app/src/main/java/eu/kanade/tachiyomi/widget/preference/TrackLoginDialog.kt b/app/src/main/java/eu/kanade/tachiyomi/widget/preference/TrackLoginDialog.kt index 0dacbfe83d..75dbf10c82 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/widget/preference/TrackLoginDialog.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/widget/preference/TrackLoginDialog.kt @@ -35,7 +35,7 @@ class TrackLoginDialog(usernameLabel: String? = null, bundle: Bundle? = null) : requestSubscription?.unsubscribe() v?.apply { - if (username.text.isEmpty() || password.text.isEmpty()) + if (username.text.isNullOrEmpty() || password.text.isNullOrEmpty()) return login.progress = 1 diff --git a/app/src/main/res/drawable/bottom_nav_item_selector.xml b/app/src/main/res/drawable/bottom_nav_item_selector.xml deleted file mode 100644 index a4b1bce02b..0000000000 --- a/app/src/main/res/drawable/bottom_nav_item_selector.xml +++ /dev/null @@ -1,8 +0,0 @@ - - - - - - - - diff --git a/app/src/main/res/drawable/button_bg_transparent.xml b/app/src/main/res/drawable/button_bg_transparent.xml index 84577aa474..d7924bf403 100644 --- a/app/src/main/res/drawable/button_bg_transparent.xml +++ b/app/src/main/res/drawable/button_bg_transparent.xml @@ -3,7 +3,7 @@ - + @@ -15,12 +15,12 @@ - - + + - + - \ No newline at end of file + diff --git a/app/src/main/res/drawable/line_divider_dark.xml b/app/src/main/res/drawable/line_divider.xml similarity index 77% rename from app/src/main/res/drawable/line_divider_dark.xml rename to app/src/main/res/drawable/line_divider.xml index 3d8da577ae..454cad4bdd 100644 --- a/app/src/main/res/drawable/line_divider_dark.xml +++ b/app/src/main/res/drawable/line_divider.xml @@ -6,6 +6,6 @@ android:width="1dp" android:height="1dp" /> - + - \ No newline at end of file + diff --git a/app/src/main/res/drawable/line_divider_light.xml b/app/src/main/res/drawable/line_divider_light.xml deleted file mode 100644 index eca76daba5..0000000000 --- a/app/src/main/res/drawable/line_divider_light.xml +++ /dev/null @@ -1,11 +0,0 @@ - - - - - - - - \ No newline at end of file diff --git a/app/src/main/res/drawable/list_item_selector_dark.xml b/app/src/main/res/drawable/list_item_selector.xml similarity index 60% rename from app/src/main/res/drawable/list_item_selector_dark.xml rename to app/src/main/res/drawable/list_item_selector.xml index 5b08a69f78..1e25926654 100644 --- a/app/src/main/res/drawable/list_item_selector_dark.xml +++ b/app/src/main/res/drawable/list_item_selector.xml @@ -1,18 +1,18 @@ + android:color="?attr/rippleColor"> - + - + - + diff --git a/app/src/main/res/drawable/list_item_selector_amoled.xml b/app/src/main/res/drawable/list_item_selector_amoled.xml deleted file mode 100644 index f3a9c3e06f..0000000000 --- a/app/src/main/res/drawable/list_item_selector_amoled.xml +++ /dev/null @@ -1,19 +0,0 @@ - - - - - - - - - - - - - - - - - - diff --git a/app/src/main/res/drawable/list_item_selector_light.xml b/app/src/main/res/drawable/list_item_selector_light.xml deleted file mode 100644 index 3fa9224b93..0000000000 --- a/app/src/main/res/drawable/list_item_selector_light.xml +++ /dev/null @@ -1,19 +0,0 @@ - - - - - - - - - - - - - - - - - - diff --git a/app/src/main/res/drawable/sc_book_48dp.xml b/app/src/main/res/drawable/sc_book_48dp.xml index 35c7a7c2ff..cea55b9a22 100644 --- a/app/src/main/res/drawable/sc_book_48dp.xml +++ b/app/src/main/res/drawable/sc_book_48dp.xml @@ -6,7 +6,7 @@ android:viewportWidth="48"> - \ No newline at end of file + diff --git a/app/src/main/res/drawable/sc_explore_48dp.xml b/app/src/main/res/drawable/sc_explore_48dp.xml index 1489806c88..911db2d81a 100644 --- a/app/src/main/res/drawable/sc_explore_48dp.xml +++ b/app/src/main/res/drawable/sc_explore_48dp.xml @@ -6,7 +6,7 @@ android:viewportWidth="48"> - \ No newline at end of file + diff --git a/app/src/main/res/drawable/sc_history_48dp.xml b/app/src/main/res/drawable/sc_history_48dp.xml index 9a1d531c9b..76d656f30c 100644 --- a/app/src/main/res/drawable/sc_history_48dp.xml +++ b/app/src/main/res/drawable/sc_history_48dp.xml @@ -6,7 +6,7 @@ android:viewportWidth="48"> diff --git a/app/src/main/res/layout/catalogue_global_search_controller_card_item.xml b/app/src/main/res/layout/catalogue_global_search_controller_card_item.xml index f78bb13f46..d15b5b91ef 100644 --- a/app/src/main/res/layout/catalogue_global_search_controller_card_item.xml +++ b/app/src/main/res/layout/catalogue_global_search_controller_card_item.xml @@ -4,7 +4,7 @@ xmlns:tools="http://schemas.android.com/tools" android:layout_width="wrap_content" android:layout_height="wrap_content" - android:background="?attr/selectable_list_drawable" + android:background="@drawable/list_item_selector" android:orientation="vertical" android:paddingStart="4dp" android:paddingTop="8dp" diff --git a/app/src/main/res/layout/catalogue_grid_item.xml b/app/src/main/res/layout/catalogue_grid_item.xml index 630d1cee07..bbdf1e8c22 100644 --- a/app/src/main/res/layout/catalogue_grid_item.xml +++ b/app/src/main/res/layout/catalogue_grid_item.xml @@ -16,8 +16,8 @@ android:id="@+id/thumbnail" android:layout_width="match_parent" android:layout_height="match_parent" - android:background="?android:attr/colorBackground" - tools:background="?android:attr/colorBackground" + android:background="?attr/colorSurface" + tools:background="?attr/colorSurface" tools:ignore="ContentDescription" tools:src="@mipmap/ic_launcher" /> diff --git a/app/src/main/res/layout/catalogue_list_item.xml b/app/src/main/res/layout/catalogue_list_item.xml index 66d717b8f5..cdf5fe2ba9 100644 --- a/app/src/main/res/layout/catalogue_list_item.xml +++ b/app/src/main/res/layout/catalogue_list_item.xml @@ -5,7 +5,7 @@ android:layout_width="match_parent" android:layout_height="@dimen/material_component_lists_single_line_with_avatar_height" android:layout_gravity="center_vertical" - android:background="?attr/selectable_list_drawable" + android:background="@drawable/list_item_selector" tools:layout_editor_absoluteX="0dp" tools:layout_editor_absoluteY="25dp"> diff --git a/app/src/main/res/layout/catalogue_main_controller_card_item.xml b/app/src/main/res/layout/catalogue_main_controller_card_item.xml index 672abf30c1..35f66ce137 100644 --- a/app/src/main/res/layout/catalogue_main_controller_card_item.xml +++ b/app/src/main/res/layout/catalogue_main_controller_card_item.xml @@ -9,7 +9,7 @@ android:id="@+id/card" android:layout_width="match_parent" android:layout_height="@dimen/material_component_lists_two_line_height" - android:background="?attr/selectable_list_drawable"> + android:background="@drawable/list_item_selector"> + android:background="@drawable/list_item_selector"> diff --git a/app/src/main/res/layout/download_custom_amount.xml b/app/src/main/res/layout/download_custom_amount.xml index 7e41e7dc6b..b4368204ed 100644 --- a/app/src/main/res/layout/download_custom_amount.xml +++ b/app/src/main/res/layout/download_custom_amount.xml @@ -10,7 +10,7 @@ android:id="@+id/btn_decrease_10" android:layout_width="wrap_content" android:layout_height="match_parent" - android:background="?selectable_list_drawable" + android:background="@drawable/list_item_selector" android:padding="8dp" android:tint="?colorAccent" app:srcCompat="@drawable/ic_chevron_left_double_black_24dp" /> @@ -19,7 +19,7 @@ android:id="@+id/btn_decrease" android:layout_width="wrap_content" android:layout_height="match_parent" - android:background="?selectable_list_drawable" + android:background="@drawable/list_item_selector" android:padding="8dp" android:tint="?colorAccent" app:srcCompat="@drawable/ic_chevron_left_black_24dp" /> @@ -37,7 +37,7 @@ android:id="@+id/btn_increase" android:layout_width="wrap_content" android:layout_height="match_parent" - android:background="?selectable_list_drawable" + android:background="@drawable/list_item_selector" android:padding="8dp" android:tint="?colorAccent" app:srcCompat="@drawable/ic_chevron_right_black_24dp" /> @@ -46,7 +46,7 @@ android:id="@+id/btn_increase_10" android:layout_width="wrap_content" android:layout_height="match_parent" - android:background="?selectable_list_drawable" + android:background="@drawable/list_item_selector" android:padding="8dp" android:tint="?colorAccent" app:srcCompat="@drawable/ic_chevron_right_double_black_24dp" /> diff --git a/app/src/main/res/layout/extension_card_item.xml b/app/src/main/res/layout/extension_card_item.xml index 0370cd1a07..beebc90c09 100644 --- a/app/src/main/res/layout/extension_card_item.xml +++ b/app/src/main/res/layout/extension_card_item.xml @@ -9,7 +9,7 @@ android:id="@+id/card" android:layout_width="match_parent" android:layout_height="64dp" - android:background="?attr/selectable_list_drawable"> + android:background="@drawable/list_item_selector"> diff --git a/app/src/main/res/layout/main_activity.xml b/app/src/main/res/layout/main_activity.xml index 5ebd768f13..c7820fced5 100644 --- a/app/src/main/res/layout/main_activity.xml +++ b/app/src/main/res/layout/main_activity.xml @@ -25,11 +25,10 @@ @@ -44,12 +43,11 @@ diff --git a/app/src/main/res/layout/navigation_view_text.xml b/app/src/main/res/layout/navigation_view_text.xml index 23432d98d5..87bbc27768 100644 --- a/app/src/main/res/layout/navigation_view_text.xml +++ b/app/src/main/res/layout/navigation_view_text.xml @@ -1,7 +1,7 @@ + android:background="?android:attr/divider" /> - + android:hint="@string/username"> - + - + + + android:hint="@string/password"> - + + + - - - @@ -31,7 +31,7 @@ app:layout_constraintStart_toEndOf="@id/general_prefs" app:layout_constraintTop_toTopOf="@id/general_prefs" /> - - - - - - - - - - - @@ -249,20 +242,19 @@ app:layout_constraintStart_toStartOf="parent" app:layout_constraintTop_toBottomOf="@id/end_general_preferences" /> - - diff --git a/app/src/main/res/layout/track_item.xml b/app/src/main/res/layout/track_item.xml index da7d9d1b17..673e20d8d1 100644 --- a/app/src/main/res/layout/track_item.xml +++ b/app/src/main/res/layout/track_item.xml @@ -51,7 +51,7 @@ android:id="@+id/status_container" android:layout_width="match_parent" android:layout_height="wrap_content" - android:background="?attr/selectable_list_drawable" + android:background="@drawable/list_item_selector" android:clickable="true" android:focusable="true" android:orientation="horizontal" @@ -104,7 +104,7 @@ android:layout_width="0dp" android:layout_height="wrap_content" android:layout_weight="1" - android:background="?attr/selectable_list_drawable" + android:background="@drawable/list_item_selector" android:clickable="true" android:focusable="true" android:orientation="horizontal" @@ -132,7 +132,7 @@ android:layout_width="0dp" android:layout_height="wrap_content" android:layout_weight="1" - android:background="?attr/selectable_list_drawable" + android:background="@drawable/list_item_selector" android:clickable="true" android:focusable="true" android:orientation="horizontal" diff --git a/app/src/main/res/layout/track_search_dialog.xml b/app/src/main/res/layout/track_search_dialog.xml index c6aff5cf93..c2ecc59ad1 100644 --- a/app/src/main/res/layout/track_search_dialog.xml +++ b/app/src/main/res/layout/track_search_dialog.xml @@ -42,7 +42,7 @@ android:dividerHeight="10dp" android:footerDividersEnabled="true" android:headerDividersEnabled="true" - android:listSelector="?attr/selectable_list_drawable" + android:listSelector="@drawable/list_item_selector" android:paddingTop="4dp" android:paddingBottom="4dp" android:scrollbars="none" diff --git a/app/src/main/res/layout/track_search_item.xml b/app/src/main/res/layout/track_search_item.xml index ec9d87e6ba..916dc5e29d 100644 --- a/app/src/main/res/layout/track_search_item.xml +++ b/app/src/main/res/layout/track_search_item.xml @@ -2,7 +2,6 @@ @@ -10,7 +9,7 @@ android:id="@+id/linearLayout" android:layout_width="match_parent" android:layout_height="216dp" - android:background="?attr/selectable_list_drawable" + android:background="@drawable/list_item_selector" android:orientation="horizontal"> + android:background="@drawable/list_item_selector"> - - - - - diff --git a/app/src/main/res/values/colors.xml b/app/src/main/res/values/colors.xml index 53d3d89dcf..ad5c6cecd0 100644 --- a/app/src/main/res/values/colors.xml +++ b/app/src/main/res/values/colors.xml @@ -3,6 +3,7 @@ #54759E #435E7E + #212121 #1C1C1D @@ -17,12 +18,9 @@ @color/md_black_1000_38 @color/md_black_1000_12 @color/md_black_1000_12 - @color/md_grey_50 @color/md_white_1000 - @color/md_blue_A400_38 - @color/md_black_1000_54 #3399FF @@ -31,14 +29,9 @@ @color/md_white_1000_50 @android:color/transparent @color/md_white_1000_20- - - @color/md_black_1000 - @color/md_grey_900 @color/colorDarkPrimaryDark @color/colorDarkPrimary - @color/md_blue_A200_50 - @color/md_white_1000_54 @color/colorDarkPrimary diff --git a/app/src/main/res/values/styles.xml b/app/src/main/res/values/styles.xml index f268632c10..cc379cf2e2 100644 --- a/app/src/main/res/values/styles.xml +++ b/app/src/main/res/values/styles.xml @@ -4,38 +4,36 @@ - - - - - + + - - - @@ -125,7 +123,7 @@ @@ -185,26 +182,30 @@ - - - - - @@ -212,7 +213,7 @@ - @@ -234,7 +235,7 @@ @style/ThemeOverlay.AppCompat.Dark.ActionBar - + - diff --git a/app/src/main/res/values/themes.xml b/app/src/main/res/values/themes.xml index 0ad8b28da9..8282c4aa64 100644 --- a/app/src/main/res/values/themes.xml +++ b/app/src/main/res/values/themes.xml @@ -9,38 +9,48 @@ - @@ -55,20 +65,28 @@ - -