fossfreedom / rhythmweb

rhythmbox v2.9x/v3.x GTK3 port of the original rhythmweb GTK2 plugin created previously for rhythmbox v0.1x
GNU General Public License v3.0
23 stars 8 forks source link

Add playlist selection sidebar #19

Closed dinoboy197 closed 11 years ago

dinoboy197 commented 11 years ago

This is commit adds a toggleable lefthand playlist sidebar, which allows the user to select, view, and play the tracks included in any playlist predefined in Rhythmbox. It's a sizable commit, so please feel free to critique or suggest alternate implementations or changes.

The playlist sidebar is populated via AJAX, and updates regularly in case the user changes playlists in Rhythmbox. No edit capability is present, yet.

When a user clicks on a playlist, the tracks of the playlist are are loaded into the track listing, and then the user can double click on any of those tracks to start playing from that track in that playlist.

Whether the playlist sidebar is shown or hidden is remembered via a cookie, which prevents a jarring disappearance or appearance of the sidebar when the page performs it's standard full page refresh (maybe we won't need the full refresh in the future?)

I've also extracted the Javascript tap handler into it's own method so it can be reused.

fossfreedom commented 11 years ago

Issue 1: I've got one track in my play queue, none in "My Top Rated" and lots in "Recently Added"

On startup, it displays correctly my play queue. clicking toggle playlists and then clicking "Recently Added" displays all my recently added.

Clicking "Toggle Playlist" removes the playlists but leaves me with all in the "recently added" list - how do I get back to my play queue?

Issue 2: I click and highlight a track in the "recently added" playlist. I click "play" but it plays a track from my play queue. Seems like you need to double click to play the track in a playlist to play - the play button is just for the play queue?

Issue 3: Not sure the duration calculation is working - after playing a track from the playlist, the display isnt refreshed to display the next track.

dinoboy197 commented 11 years ago

I just am taking a look at these items now. I'll update when I make progress.

dinoboy197 commented 11 years ago

Issue 1: What are your thoughts regarding showing the play queue once you've selected a playlist? I agree that currently it's impossible to get back to the play queue unless you're playing tracks from a playlist and then the playlist ends. Would you rather see a "Play Queue" entry at the top of the playlist sidebar which can be clicked, or have some other button somewhere which de-selects the current playlist and loads the play queue tracks? I'm divided on the issue as in the Rhythmbox UI, the play queue isn't really in the playlist list - it's a separate entity.

Issue 2: I'm following Rhythmbox's default play button logic here: When a playlist is selected, no track is selected, and play queue is empty: clicking play plays from top of playlist. When a playlist is selected, no track is selected, and play queue has a song: clicking play plays from play queue. When a playlist is selected, a track is selected, and play queue is empty: clicking play plays selected song in selected playlist. When a playlist is selected, a track is selected, and play queue has a song: clicking play plays from play queue.

Note that actually two of the four of these are broken currently (I need to fix them). However, the issue that you mention (click a playlist, click an item in the playlist, play queue has a track in it, then click play) causes Rhythmbox to play from the play queue in the normal UI, so I think you're asking from different functionality from Rhythmbox itself. Is this really what you think Rhythmweb should do (behave differently from Rhythmbox in this case)?

Issue 3: I can't replicate this issue over here. Would you mind telling me the exact steps that you use to replicate, and if you're using a specific browser / platform?

Thanks for your comments! I'll make changes once I hear your opinions.

fossfreedom commented 11 years ago

Issue 1:

I see the potential of the changes - they are excellent.

I would probably rename " Toggle Playlists" to "Toggle Play-queues"

In that way you could/should have the play queue at the top of the list. It will also allow expandability later if other sources are added - I would add them to the list.

Issue 2 - yep - I can see the logic.

IMHO - the rhythmbox logic is wrong - from a web-interface point-of-view - its more logical to play from what you see.

I'm not worried - I'm happy to move this issue into another one and call it "an enhancement".

Issue 3 - nothing special - just ubuntu 12.04 and firefox. Double clicking any song from a playlist - plays that song.

Ok - if you leave the screen untouched then the next track title is correctly updated. I'll do some more testing later.

BTW - at the moment I'm devoting all my efforts on another plugin called "coverart-browser". Once I've stabilized and released the next version (end of oct) - I'll have more time to devote to rhythmweb. However - just shout if you need any help with all of this - I'll try my best to help where I can.

dinoboy197 commented 11 years ago

Made a few changes for issues 1 and 2. I also agree with you that when the Play button is clicked that the currently visible playlist (and track if one is selected) should play, even if there are tracks in the Play Queue. I've adjusted the web ui to behave accordingly.

Please do continue to test when you have time. I did see your coverart-browser and am checking it out as well!

fossfreedom commented 11 years ago

@dinoboy197 - cheers - looks and feels very nice.

Hey - if you have a little bit of time, do you mind testing out our coverart-browser plugin from the master branch?

git clone https://github.com/fossfreedom/coverart-browser -b master cd coverart-browser ./install.sh

We would love to get some feedback - any issues just raise them on the coverart github page