summaryrefslogtreecommitdiff
path: root/app/src/main/java/de/danoeh/antennapod/view
diff options
context:
space:
mode:
authorByteHamster <info@bytehamster.com>2021-04-15 21:44:02 +0200
committerByteHamster <info@bytehamster.com>2021-04-21 23:05:42 +0200
commitbd7793ffd49a914ced95f82b3ea7633972eb738a (patch)
tree234c031ee6022dc0ca36657eebf3e36fe9ed3960 /app/src/main/java/de/danoeh/antennapod/view
parentd51e9c7625e0cf1d72c17e908312b7dd42363622 (diff)
downloadAntennaPod-bd7793ffd49a914ced95f82b3ea7633972eb738a.zip
Deleted duplicate resources
Diffstat (limited to 'app/src/main/java/de/danoeh/antennapod/view')
-rw-r--r--app/src/main/java/de/danoeh/antennapod/view/EmptyViewHandler.java9
-rw-r--r--app/src/main/java/de/danoeh/antennapod/view/PlayButton.java6
2 files changed, 5 insertions, 10 deletions
diff --git a/app/src/main/java/de/danoeh/antennapod/view/EmptyViewHandler.java b/app/src/main/java/de/danoeh/antennapod/view/EmptyViewHandler.java
index d4bf44aa5..ce8f08511 100644
--- a/app/src/main/java/de/danoeh/antennapod/view/EmptyViewHandler.java
+++ b/app/src/main/java/de/danoeh/antennapod/view/EmptyViewHandler.java
@@ -6,7 +6,7 @@ import android.view.Gravity;
import android.widget.AbsListView;
import android.widget.FrameLayout;
import android.widget.ListAdapter;
-import androidx.annotation.AttrRes;
+import androidx.annotation.DrawableRes;
import androidx.recyclerview.widget.RecyclerView;
import android.view.View;
import android.view.ViewGroup;
@@ -15,7 +15,6 @@ import android.widget.RelativeLayout;
import android.widget.TextView;
import de.danoeh.antennapod.R;
-import de.danoeh.antennapod.ui.common.ThemeUtils;
public class EmptyViewHandler {
private boolean layoutAdded = false;
@@ -23,7 +22,6 @@ public class EmptyViewHandler {
private ListAdapter listAdapter;
private RecyclerView.Adapter<?> recyclerAdapter;
- private final Context context;
private final View emptyView;
private final TextView tvTitle;
private final TextView tvMessage;
@@ -31,7 +29,6 @@ public class EmptyViewHandler {
public EmptyViewHandler(Context context) {
emptyView = View.inflate(context, R.layout.empty_view_layout, null);
- this.context = context;
tvTitle = emptyView.findViewById(R.id.emptyViewTitle);
tvMessage = emptyView.findViewById(R.id.emptyViewMessage);
ivIcon = emptyView.findViewById(R.id.emptyViewIcon);
@@ -49,8 +46,8 @@ public class EmptyViewHandler {
tvMessage.setText(message);
}
- public void setIcon(@AttrRes int iconAttr) {
- ivIcon.setImageResource(ThemeUtils.getDrawableFromAttr(context, iconAttr));
+ public void setIcon(@DrawableRes int icon) {
+ ivIcon.setImageResource(icon);
ivIcon.setVisibility(View.VISIBLE);
}
diff --git a/app/src/main/java/de/danoeh/antennapod/view/PlayButton.java b/app/src/main/java/de/danoeh/antennapod/view/PlayButton.java
index 691a15ca2..04b277fb4 100644
--- a/app/src/main/java/de/danoeh/antennapod/view/PlayButton.java
+++ b/app/src/main/java/de/danoeh/antennapod/view/PlayButton.java
@@ -7,7 +7,6 @@ import androidx.annotation.Nullable;
import androidx.appcompat.widget.AppCompatImageButton;
import androidx.vectordrawable.graphics.drawable.AnimatedVectorDrawableCompat;
import de.danoeh.antennapod.R;
-import de.danoeh.antennapod.ui.common.ThemeUtils;
public class PlayButton extends AppCompatImageButton {
private boolean isShowPlay = true;
@@ -34,10 +33,9 @@ public class PlayButton extends AppCompatImageButton {
this.isShowPlay = showPlay;
setContentDescription(getContext().getString(showPlay ? R.string.play_label : R.string.pause_label));
if (isVideoScreen) {
- setImageResource(showPlay ? R.drawable.ic_av_play_white_80dp : R.drawable.ic_av_pause_white_80dp);
+ setImageResource(showPlay ? R.drawable.ic_play_video_white : R.drawable.ic_pause_video_white);
} else if (!isShown()) {
- setImageResource(ThemeUtils.getDrawableFromAttr(getContext(),
- showPlay ? R.attr.av_play : R.attr.av_pause));
+ setImageResource(showPlay ? R.drawable.ic_play_48dp : R.drawable.ic_pause);
} else if (showPlay) {
AnimatedVectorDrawableCompat drawable = AnimatedVectorDrawableCompat.create(
getContext(), R.drawable.ic_animate_pause_play);