aboutsummaryrefslogtreecommitdiff
path: root/app/src/main/java
diff options
context:
space:
mode:
Diffstat (limited to 'app/src/main/java')
-rw-r--r--app/src/main/java/github/daneren2005/dsub/activity/SubsonicFragmentActivity.java12
1 files changed, 9 insertions, 3 deletions
diff --git a/app/src/main/java/github/daneren2005/dsub/activity/SubsonicFragmentActivity.java b/app/src/main/java/github/daneren2005/dsub/activity/SubsonicFragmentActivity.java
index f7ba429f..43bd15c7 100644
--- a/app/src/main/java/github/daneren2005/dsub/activity/SubsonicFragmentActivity.java
+++ b/app/src/main/java/github/daneren2005/dsub/activity/SubsonicFragmentActivity.java
@@ -597,6 +597,9 @@ public class SubsonicFragmentActivity extends SubsonicActivity {
DownloadFile current = downloadService.getCurrentPlaying();
PlayerState state = downloadService.getPlayerState();
if(current == currentPlaying && state == currentState) {
+ if(current == null && slideUpPanel.getPanelState() == SlidingUpPanelLayout.PanelState.COLLAPSED) {
+ slideUpPanel.setPanelState(SlidingUpPanelLayout.PanelState.HIDDEN);
+ }
return;
} else {
currentPlaying = current;
@@ -608,9 +611,12 @@ public class SubsonicFragmentActivity extends SubsonicActivity {
song = current.getSong();
trackView.setText(song.getTitle());
artistView.setText(song.getArtist());
- } else {
- trackView.setText(R.string.main_title);
- artistView.setText(R.string.main_artist);
+
+ if(slideUpPanel.getPanelState() == SlidingUpPanelLayout.PanelState.HIDDEN) {
+ slideUpPanel.setPanelState(SlidingUpPanelLayout.PanelState.COLLAPSED);
+ }
+ } else if(slideUpPanel.getPanelState() == SlidingUpPanelLayout.PanelState.COLLAPSED) {
+ slideUpPanel.setPanelState(SlidingUpPanelLayout.PanelState.HIDDEN);
}
if (coverArtView != null) {