Add Now Playing to drawer
This commit is contained in:
parent
3243f320b1
commit
89ede8ff47
|
@ -248,6 +248,9 @@ public class SubsonicActivity extends AppCompatActivity implements OnItemSelecte
|
|||
case R.id.drawer_downloading:
|
||||
drawerItemSelected("Download");
|
||||
return true;
|
||||
case R.id.drawer_now_playing:
|
||||
drawerItemSelected("Now Playing");
|
||||
return true;
|
||||
case R.id.drawer_offline:
|
||||
toggleOffline();
|
||||
return true;
|
||||
|
|
|
@ -551,6 +551,8 @@ public class SubsonicFragmentActivity extends SubsonicActivity implements Downlo
|
|||
switch (fragmentType) {
|
||||
case "Playlist":
|
||||
return new SelectPlaylistFragment();
|
||||
case "Now Playing":
|
||||
return new NowPlayingFragment();
|
||||
case "Download":
|
||||
return new DownloadFragment();
|
||||
default:
|
||||
|
|
|
@ -128,7 +128,7 @@ public class NowPlayingFragment extends SubsonicFragment implements OnGestureLis
|
|||
startFlipped = true;
|
||||
}
|
||||
}
|
||||
primaryFragment = false;
|
||||
primaryFragment = true;
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
|
@ -14,6 +14,10 @@
|
|||
android:icon="?attr/drawerDownloading"
|
||||
android:title="@string/button_bar.downloading"
|
||||
android:visible="false" />
|
||||
<item
|
||||
android:id="@+id/drawer_now_playing"
|
||||
android:icon="?attr/drawerNowPlaying"
|
||||
android:title="@string/button_bar.now_playing" />
|
||||
</group>
|
||||
|
||||
<group android:checkableBehavior="single">
|
||||
|
|
|
@ -43,6 +43,7 @@
|
|||
<attr name="drawerLibrary" format="reference" />
|
||||
<attr name="drawerPlaylists" format="reference" />
|
||||
<attr name="drawerDownloading" format="reference" />
|
||||
<attr name="drawerNowPlaying" format="reference" />
|
||||
<attr name="drawerSettings" format="reference" />
|
||||
<attr name="actionbarThemeStyle" format="reference" />
|
||||
<attr name="actionbarTitleStyle" format="reference" />
|
||||
|
|
Loading…
Reference in New Issue