summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--app/src/main/assets/licenses.xml12
-rw-r--r--app/src/main/java/de/danoeh/antennapod/dialog/AuthenticationDialog.java2
-rw-r--r--app/src/main/java/de/danoeh/antennapod/dialog/EpisodesApplyActionFragment.java2
-rw-r--r--app/src/main/java/de/danoeh/antennapod/fragment/DownloadLogFragment.java2
-rw-r--r--app/src/main/java/de/danoeh/antennapod/preferences/NumberPickerPreference.java2
-rw-r--r--app/src/main/res/layout/feed_item_list_fragment.xml3
-rw-r--r--app/src/main/res/layout/feedinfo.xml3
-rw-r--r--app/src/main/res/layout/quick_feed_discovery.xml4
-rw-r--r--app/src/main/res/layout/searchlist_item_feed.xml1
-rw-r--r--app/src/main/res/layout/subscription_item.xml6
-rw-r--r--core/build.gradle1
-rw-r--r--core/src/main/res/values-v21/styles.xml17
-rw-r--r--core/src/main/res/values-v23/styles.xml19
-rw-r--r--core/src/main/res/values/colors.xml4
-rw-r--r--core/src/main/res/values/styles.xml93
15 files changed, 88 insertions, 83 deletions
diff --git a/app/src/main/assets/licenses.xml b/app/src/main/assets/licenses.xml
index c69f692cf..4f0255182 100644
--- a/app/src/main/assets/licenses.xml
+++ b/app/src/main/assets/licenses.xml
@@ -13,6 +13,12 @@
license="Apache 2.0"
licenseText="LICENSE_APACHE-2.0.txt" />
<library
+ name="Android Jetpack"
+ author="Google"
+ website="https://developer.android.com/jetpack"
+ license="Apache 2.0"
+ licenseText="LICENSE_APACHE-2.0.txt" />
+ <library
name="Apache Commons"
author="The Apache Software Foundation"
website="http://commons.apache.org/"
@@ -67,6 +73,12 @@
license="SIL Open Font, Version 1.1"
licenseText="LICENSE_SIL.txt" />
<library
+ name="Material Components"
+ author="Google"
+ website="https://github.com/material-components/material-components-android"
+ license="Apache 2.0"
+ licenseText="LICENSE_APACHE-2.0.txt" />
+ <library
name="OkHttp"
author="Square"
website="https://github.com/square/okhttp"
diff --git a/app/src/main/java/de/danoeh/antennapod/dialog/AuthenticationDialog.java b/app/src/main/java/de/danoeh/antennapod/dialog/AuthenticationDialog.java
index fb2f92742..39d321f18 100644
--- a/app/src/main/java/de/danoeh/antennapod/dialog/AuthenticationDialog.java
+++ b/app/src/main/java/de/danoeh/antennapod/dialog/AuthenticationDialog.java
@@ -1,9 +1,9 @@
package de.danoeh.antennapod.dialog;
-import android.app.AlertDialog;
import android.content.Context;
import android.view.View;
import android.widget.EditText;
+import androidx.appcompat.app.AlertDialog;
import de.danoeh.antennapod.R;
/**
diff --git a/app/src/main/java/de/danoeh/antennapod/dialog/EpisodesApplyActionFragment.java b/app/src/main/java/de/danoeh/antennapod/dialog/EpisodesApplyActionFragment.java
index 9198c7a3e..fe588e4da 100644
--- a/app/src/main/java/de/danoeh/antennapod/dialog/EpisodesApplyActionFragment.java
+++ b/app/src/main/java/de/danoeh/antennapod/dialog/EpisodesApplyActionFragment.java
@@ -1,6 +1,5 @@
package de.danoeh.antennapod.dialog;
-import android.app.AlertDialog;
import android.content.res.TypedArray;
import android.graphics.drawable.Drawable;
import android.os.Bundle;
@@ -17,6 +16,7 @@ import androidx.annotation.IdRes;
import androidx.annotation.NonNull;
import androidx.annotation.PluralsRes;
import androidx.annotation.StringRes;
+import androidx.appcompat.app.AlertDialog;
import androidx.appcompat.app.AppCompatActivity;
import androidx.appcompat.widget.Toolbar;
import androidx.collection.ArrayMap;
diff --git a/app/src/main/java/de/danoeh/antennapod/fragment/DownloadLogFragment.java b/app/src/main/java/de/danoeh/antennapod/fragment/DownloadLogFragment.java
index a2fea9f24..312e3cb62 100644
--- a/app/src/main/java/de/danoeh/antennapod/fragment/DownloadLogFragment.java
+++ b/app/src/main/java/de/danoeh/antennapod/fragment/DownloadLogFragment.java
@@ -1,9 +1,9 @@
package de.danoeh.antennapod.fragment;
-import android.app.AlertDialog;
import android.app.Dialog;
import android.content.res.TypedArray;
import android.os.Bundle;
+import androidx.appcompat.app.AlertDialog;
import androidx.fragment.app.ListFragment;
import androidx.core.view.MenuItemCompat;
import android.util.Log;
diff --git a/app/src/main/java/de/danoeh/antennapod/preferences/NumberPickerPreference.java b/app/src/main/java/de/danoeh/antennapod/preferences/NumberPickerPreference.java
index a58986241..484d56e96 100644
--- a/app/src/main/java/de/danoeh/antennapod/preferences/NumberPickerPreference.java
+++ b/app/src/main/java/de/danoeh/antennapod/preferences/NumberPickerPreference.java
@@ -1,7 +1,7 @@
package de.danoeh.antennapod.preferences;
-import android.app.AlertDialog;
import android.content.Context;
+import androidx.appcompat.app.AlertDialog;
import androidx.preference.Preference;
import android.text.InputFilter;
import android.util.AttributeSet;
diff --git a/app/src/main/res/layout/feed_item_list_fragment.xml b/app/src/main/res/layout/feed_item_list_fragment.xml
index 38496dd4f..d6c7409a8 100644
--- a/app/src/main/res/layout/feed_item_list_fragment.xml
+++ b/app/src/main/res/layout/feed_item_list_fragment.xml
@@ -14,7 +14,8 @@
android:id="@+id/collapsing_toolbar"
android:layout_width="match_parent"
android:layout_height="match_parent"
- app:contentScrim="?attr/colorPrimary"
+ android:background="?android:attr/windowBackground"
+ app:contentScrim="?android:attr/windowBackground"
app:scrimAnimationDuration="200"
app:layout_scrollFlags="scroll|exitUntilCollapsed">
diff --git a/app/src/main/res/layout/feedinfo.xml b/app/src/main/res/layout/feedinfo.xml
index d2e077be1..fa6aac251 100644
--- a/app/src/main/res/layout/feedinfo.xml
+++ b/app/src/main/res/layout/feedinfo.xml
@@ -14,7 +14,8 @@
android:id="@+id/collapsing_toolbar"
android:layout_width="match_parent"
android:layout_height="match_parent"
- app:contentScrim="?attr/colorPrimary"
+ android:background="?android:attr/windowBackground"
+ app:contentScrim="?android:attr/windowBackground"
app:scrimAnimationDuration="200"
app:layout_scrollFlags="scroll|exitUntilCollapsed">
diff --git a/app/src/main/res/layout/quick_feed_discovery.xml b/app/src/main/res/layout/quick_feed_discovery.xml
index 78a59c7eb..a274fcdc7 100644
--- a/app/src/main/res/layout/quick_feed_discovery.xml
+++ b/app/src/main/res/layout/quick_feed_discovery.xml
@@ -25,8 +25,8 @@
android:minHeight="0dp"
android:minWidth="0dp"
android:text="@string/discover_more"
- android:id="@+id/discover_more"
- style="?android:attr/buttonBarButtonStyle"/>
+ style="@style/Widget.MaterialComponents.Button.TextButton"
+ android:id="@+id/discover_more"/>
</LinearLayout>
<RelativeLayout
diff --git a/app/src/main/res/layout/searchlist_item_feed.xml b/app/src/main/res/layout/searchlist_item_feed.xml
index f5e76801e..607a3197f 100644
--- a/app/src/main/res/layout/searchlist_item_feed.xml
+++ b/app/src/main/res/layout/searchlist_item_feed.xml
@@ -14,6 +14,7 @@
android:elevation="4dp"
android:outlineProvider="bounds"
android:foreground="?android:attr/selectableItemBackground"
+ android:background="?android:attr/windowBackground"
squareImageView:direction="height" />
</LinearLayout>
diff --git a/app/src/main/res/layout/subscription_item.xml b/app/src/main/res/layout/subscription_item.xml
index 43c3d99fa..a01b6d070 100644
--- a/app/src/main/res/layout/subscription_item.xml
+++ b/app/src/main/res/layout/subscription_item.xml
@@ -11,7 +11,7 @@
android:id="@+id/imgvCover"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
- android:scaleType="centerCrop"
+ android:scaleType="fitCenter"
tools:src="@mipmap/ic_launcher_round"
squareImageView:direction="width"/>
@@ -37,9 +37,9 @@
android:layout_alignParentRight="true"
android:layout_alignParentEnd="true"
android:layout_alignParentTop="true"
- app:backgroundColor="?attr/colorAccent"
+ app:backgroundColor="?attr/colorSecondary"
app:corner="rightTop"
app:primaryText="Test"
- app:primaryTextColor="@color/white"
+ app:primaryTextColor="?attr/colorOnSecondary"
app:primaryTextSize="12sp" />
</RelativeLayout>
diff --git a/core/build.gradle b/core/build.gradle
index 8b450a620..8c1c8a5f7 100644
--- a/core/build.gradle
+++ b/core/build.gradle
@@ -61,6 +61,7 @@ dependencies {
annotationProcessor "androidx.annotation:annotation:1.1.0"
implementation "androidx.work:work-runtime:$workManagerVersion"
implementation "androidx.media:media:1.1.0"
+ implementation 'com.google.android.material:material:1.1.0'
implementation "org.apache.commons:commons-lang3:$commonslangVersion"
implementation "commons-io:commons-io:$commonsioVersion"
implementation "org.jsoup:jsoup:$jsoupVersion"
diff --git a/core/src/main/res/values-v21/styles.xml b/core/src/main/res/values-v21/styles.xml
index 9f74da348..996b16f5e 100644
--- a/core/src/main/res/values-v21/styles.xml
+++ b/core/src/main/res/values-v21/styles.xml
@@ -2,25 +2,16 @@
<resources>
<style name="Theme.AntennaPod.Light" parent="Theme.Base.AntennaPod.Light">
<item name="android:windowContentTransitions">true</item>
+ <!-- To make icons visible -->
+ <item name="android:statusBarColor">@color/grey600</item>
</style>
<style name="Theme.AntennaPod.Dark" parent="Theme.Base.AntennaPod.Dark">
<item name="android:windowContentTransitions">true</item>
+ <item name="android:statusBarColor">@color/background_darktheme</item>
</style>
<style name="Theme.AntennaPod.TrueBlack" parent="Theme.Base.AntennaPod.TrueBlack">
- <item name="android:windowContentTransitions">true</item>
- <item name="android:navigationBarColor">@color/black</item>
- <item name="android:colorAccent">@color/white</item>
- <item name="android:colorPrimary">@color/black</item>
- <item name="android:colorPrimaryDark">@color/black</item>
- </style>
-
- <style name="Theme.AntennaPod.TrueBlack.NoTitle" parent="Theme.Base.AntennaPod.TrueBlack.NoTitle">
- <item name="android:navigationBarColor">@color/black</item>
- <item name="android:colorAccent">@color/white</item>
- <item name="android:colorPrimary">@color/black</item>
- <item name="android:colorPrimaryDark">@color/black</item>
+ <item name="android:statusBarColor">@color/black</item>
</style>
-
</resources> \ No newline at end of file
diff --git a/core/src/main/res/values-v23/styles.xml b/core/src/main/res/values-v23/styles.xml
index 5cd274e68..fd339a071 100644
--- a/core/src/main/res/values-v23/styles.xml
+++ b/core/src/main/res/values-v23/styles.xml
@@ -1,13 +1,18 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>
-
- <style name="Theme.AntennaPod.Light.NoTitle" parent="Theme.Base.AntennaPod.Light.NoTitle">
+ <style name="Theme.AntennaPod.Light" parent="Theme.Base.AntennaPod.Light">
+ <item name="android:windowContentTransitions">true</item>
+ <item name="android:statusBarColor">@color/background_light</item>
<item name="android:windowLightStatusBar">true</item>
- <item name="colorPrimaryDark">@color/primary_light</item>
</style>
- <style name="Theme.AntennaPod.Light" parent="Theme.Base.AntennaPod.Light">
- <item name="android:windowLightStatusBar">true</item>
- <item name="colorPrimaryDark">@color/primary_light</item>
+ <style name="Theme.AntennaPod.Dark" parent="Theme.Base.AntennaPod.Dark">
+ <item name="android:windowContentTransitions">true</item>
+ <item name="android:statusBarColor">@color/background_darktheme</item>
+ <item name="android:windowLightStatusBar">false</item>
+ </style>
+
+ <style name="Theme.AntennaPod.TrueBlack" parent="Theme.Base.AntennaPod.TrueBlack">
+ <item name="android:statusBarColor">@color/black</item>
</style>
-</resources>
+</resources> \ No newline at end of file
diff --git a/core/src/main/res/values/colors.xml b/core/src/main/res/values/colors.xml
index 0937e37e2..c553f2e14 100644
--- a/core/src/main/res/values/colors.xml
+++ b/core/src/main/res/values/colors.xml
@@ -12,8 +12,8 @@
<color name="feed_image_bg">#50000000</color>
<!-- Theme colors -->
- <color name="primary_light">#FFFFFF</color>
- <color name="primary_darktheme">#303030</color>
+ <color name="background_light">#FFFFFF</color>
+ <color name="background_darktheme">#303030</color>
<color name="highlight_light">#DDDDDD</color>
<color name="highlight_dark">#414141</color>
<color name="highlight_trueblack">#414141</color>
diff --git a/core/src/main/res/values/styles.xml b/core/src/main/res/values/styles.xml
index 3cac01d71..6f275361b 100644
--- a/core/src/main/res/values/styles.xml
+++ b/core/src/main/res/values/styles.xml
@@ -5,12 +5,20 @@
<!-- Room for API dependent attributes -->
</style>
- <style name="Theme.Base.AntennaPod.Light" parent="Theme.AppCompat.Light">
- <item name="colorPrimary">@color/primary_light</item>
+ <style name="Theme.Base.AntennaPod.Light" parent="Theme.MaterialComponents.Light">
+ <item name="colorPrimary">@color/accent_light</item>
<item name="colorAccent">@color/accent_light</item>
+ <item name="colorSecondary">@color/accent_light</item>
+ <item name="colorOnSecondary">@color/white</item>
<item name="progressBarTheme">@style/ProgressBarLight</item>
- <item name="buttonStyle">@style/Widget.AntennaPod.Button</item>
- <item name="android:windowBackground">@color/primary_light</item>
+ <item name="colorPrimaryDark">@color/accent_light</item>
+ <item name="android:windowBackground">@color/background_light</item>
+ <item name="actionBarStyle">@style/Widget.AntennaPod.ActionBar.Light</item>
+ <item name="master_switch_background">@color/master_switch_background_light</item>
+ <item name="currently_playing_background">@color/highlight_light</item>
+ <item name="action_icon_color">@color/black</item>
+ <item name="drawer_activated_color">@color/highlight_light</item>
+
<item name="storage">@drawable/ic_storage_black</item>
<item name="ic_network">@drawable/ic_network_black</item>
<item name="statistics">@drawable/ic_statistics_black</item>
@@ -38,7 +46,6 @@
<item name="stat_playlist">@drawable/ic_playlist_black</item>
<item name="type_video">@drawable/ic_videocam_black_24dp</item>
<item name="dragview_background">@drawable/ic_drag_lighttheme</item>
- <item name="drawer_activated_color">@color/highlight_light</item>
<item name="ic_history">@drawable/ic_history_black</item>
<item name="ic_folder">@drawable/ic_folder_black</item>
<item name="ic_settings_playback">@drawable/ic_av_play_black_24dp</item>
@@ -62,10 +69,6 @@
<item name="batch_edit_fab_icon">@drawable/ic_fab_edit_white</item>
<item name="ic_key">@drawable/ic_key_black</item>
<item name="ic_volume_adaption">@drawable/ic_volume_adaption_black</item>
- <item name="master_switch_background">@color/master_switch_background_light</item>
- <item name="currently_playing_background">@color/highlight_light</item>
- <item name="preferenceTheme">@style/PreferenceThemeOverlay.v14.Material</item>
- <item name="action_icon_color">@color/black</item>
<item name="scrollbar_thumb">@drawable/scrollbar_thumb_light</item>
</style>
@@ -73,14 +76,21 @@
<!-- Room for API dependent attributes -->
</style>
- <style name="Theme.Base.AntennaPod.Dark" parent="Theme.AppCompat">
+ <style name="Theme.Base.AntennaPod.Dark" parent="Theme.MaterialComponents">
<item name="colorAccent">@color/accent_dark</item>
- <item name="colorPrimary">@color/primary_darktheme</item>
- <item name="colorPrimaryDark">@color/primary_darktheme</item>
- <item name="android:windowBackground">@color/primary_darktheme</item>
+ <item name="colorSecondary">@color/accent_dark</item>
+ <item name="colorOnSecondary">@color/black</item>
+ <item name="colorPrimary">@color/accent_dark</item>
+ <item name="colorPrimaryDark">@color/background_darktheme</item>
+ <item name="android:windowBackground">@color/background_darktheme</item>
+ <item name="actionBarStyle">@style/Widget.AntennaPod.ActionBar.Dark</item>
<item name="colorControlNormal">@color/white</item>
- <item name="buttonStyle">@style/Widget.AntennaPod.Button</item>
<item name="progressBarTheme">@style/ProgressBarDark</item>
+ <item name="drawer_activated_color">@color/highlight_dark</item>
+ <item name="master_switch_background">@color/master_switch_background_dark</item>
+ <item name="currently_playing_background">@color/highlight_dark</item>
+ <item name="action_icon_color">@color/white</item>
+
<item name="storage">@drawable/ic_storage_white</item>
<item name="ic_network">@drawable/ic_network_white</item>
<item name="statistics">@drawable/ic_statistics_white</item>
@@ -108,7 +118,6 @@
<item name="stat_playlist">@drawable/ic_playlist_white</item>
<item name="type_video">@drawable/ic_videocam_white_24dp</item>
<item name="dragview_background">@drawable/ic_drag_darktheme</item>
- <item name="drawer_activated_color">@color/highlight_dark</item>
<item name="ic_history">@drawable/ic_history_white</item>
<item name="ic_folder">@drawable/ic_folder_white</item>
<item name="ic_settings_playback">@drawable/ic_av_play_white_24dp</item>
@@ -132,10 +141,6 @@
<item name="batch_edit_fab_icon">@drawable/ic_fab_edit_white</item>
<item name="ic_key">@drawable/ic_key_white</item>
<item name="ic_volume_adaption">@drawable/ic_volume_adaption_white</item>
- <item name="master_switch_background">@color/master_switch_background_dark</item>
- <item name="currently_playing_background">@color/highlight_dark</item>
- <item name="preferenceTheme">@style/PreferenceThemeOverlay.v14.Material</item>
- <item name="action_icon_color">@color/white</item>
<item name="scrollbar_thumb">@drawable/scrollbar_thumb_dark</item>
</style>
@@ -143,44 +148,30 @@
<!-- Room for API dependent attributes -->
</style>
- <style name="Theme.Base.AntennaPod.TrueBlack" parent="Theme.Base.AntennaPod.Dark">
- <item name="batch_edit_fab_icon">@drawable/ic_fab_edit_black</item>
+ <style name="Theme.Base.AntennaPod.TrueBlack" parent="Theme.AntennaPod.Dark">
+ <item name="colorPrimaryDark">@color/black</item>
+ <item name="actionBarStyle">@style/Widget.AntennaPod.ActionBar.Black</item>
<item name="drawer_activated_color">@color/highlight_trueblack</item>
<item name="android:textColorPrimary">@color/white</item>
<item name="android:color">@color/white</item>
<item name="android:colorBackground">@color/black</item>
<item name="android:windowBackground">@color/black</item>
<item name="android:actionBarStyle">@color/black</item>
- <item name="colorPrimary">@color/black</item>
- <item name="colorPrimaryDark">@color/black</item>
</style>
-
- <style name="Theme.AntennaPod.Light.NoTitle" parent="Theme.Base.AntennaPod.Light.NoTitle">
- <!-- Room for API dependent attributes -->
- </style>
-
- <style name="Theme.Base.AntennaPod.Light.NoTitle" parent="Theme.Base.AntennaPod.Light">
+ <style name="Theme.AntennaPod.Light.NoTitle" parent="Theme.AntennaPod.Light">
<item name="windowActionBar">false</item>
<item name="windowNoTitle">true</item>
<item name="windowActionModeOverlay">true</item>
</style>
- <style name="Theme.AntennaPod.Dark.NoTitle" parent="Theme.Base.AntennaPod.Dark.NoTitle">
- <!-- Room for API dependent attributes -->
- </style>
-
- <style name="Theme.Base.AntennaPod.Dark.NoTitle" parent="Theme.Base.AntennaPod.Dark">
+ <style name="Theme.AntennaPod.Dark.NoTitle" parent="Theme.AntennaPod.Dark">
<item name="windowActionBar">false</item>
<item name="windowNoTitle">true</item>
<item name="windowActionModeOverlay">true</item>
</style>
- <style name="Theme.AntennaPod.TrueBlack.NoTitle" parent="Theme.Base.AntennaPod.TrueBlack.NoTitle">
- <!-- Room for API dependent attributes -->
- </style>
-
- <style name="Theme.Base.AntennaPod.TrueBlack.NoTitle" parent="Theme.Base.AntennaPod.TrueBlack">
+ <style name="Theme.AntennaPod.TrueBlack.NoTitle" parent="Theme.AntennaPod.TrueBlack">
<item name="windowActionBar">false</item>
<item name="windowNoTitle">true</item>
<item name="windowActionModeOverlay">true</item>
@@ -208,7 +199,7 @@
<item name="android:fitsSystemWindows">true</item>
</style>
- <style name="Theme.AntennaPod.TrueBlack.Translucent" parent="Theme.Base.AntennaPod.TrueBlack">
+ <style name="Theme.AntennaPod.TrueBlack.Translucent" parent="Theme.AntennaPod.TrueBlack">
<item name="android:windowIsTranslucent">true</item>
<item name="android:windowBackground">@android:color/transparent</item>
<item name="android:background">@android:color/transparent</item>
@@ -224,11 +215,7 @@
<item name="android:windowExitAnimation">@android:anim/fade_out</item>
</style>
- <style name="Theme.AntennaPod.Splash" parent="Theme.Base.AntennaPod.Splash">
- <!-- Room for API dependent attributes -->
- </style>
-
- <style name="Theme.Base.AntennaPod.Splash" parent="Theme.AppCompat.NoActionBar">
+ <style name="Theme.AntennaPod.Splash" parent="Theme.MaterialComponents.NoActionBar">
<item name="android:windowBackground">@drawable/bg_splash</item>
<item name="colorPrimary">@color/ic_launcher_background</item>
<item name="colorPrimaryDark">@color/ic_launcher_background</item>
@@ -271,11 +258,6 @@
<item name="android:textAllCaps">true</item>
</style>
- <style name="Widget.AntennaPod.Button" parent="Widget.AppCompat.Button.Colored">
- <item name="colorButtonNormal">?attr/colorAccent</item>
- <item name="textAllCaps">false</item>
- </style>
-
<style name="BigBlurryBackground">
<item name="android:scaleType">centerCrop</item>
<!-- <item name="android:tint">@color/image_readability_tint</item> -->
@@ -303,4 +285,15 @@
<item name="fastScrollVerticalTrackDrawable">@drawable/scrollbar_track</item>
</style>
+ <style name="Widget.AntennaPod.ActionBar.Light" parent="Widget.MaterialComponents.Light.ActionBar.Solid">
+ <item name="background">@color/background_light</item>
+ </style>
+
+ <style name="Widget.AntennaPod.ActionBar.Dark" parent="Widget.MaterialComponents.Light.ActionBar.Solid">
+ <item name="background">@color/background_darktheme</item>
+ </style>
+
+ <style name="Widget.AntennaPod.ActionBar.Black" parent="Widget.MaterialComponents.Light.ActionBar.Solid">
+ <item name="background">@color/black</item>
+ </style>
</resources>