Rockbox.org home
Downloads
Release release
Dev builds dev builds
Extras extras
themes themes
Documentation
Manual manual
Wiki wiki
Device Status device status
Support
Forums forums
Mailing lists mailing lists
IRC IRC
Development
Bugs bugs
Patches patches
Dev Guide dev guide
Search



Donate

Rockbox Technical Forums


Login with username, password and session length
Home Help Search Staff List Login Register
News:

Welcome to the Rockbox Technical Forums!

+  Rockbox Technical Forums
|-+  Rockbox General
| |-+  Rockbox General Discussion
| | |-+  Why does playlist insert replace the current playlist when stopped?
« previous next »
  • Print
Pages: [1] 2 3 ... 6

Author Topic: Why does playlist insert replace the current playlist when stopped?  (Read 25301 times)

Offline cc

  • Member
  • *
  • Posts: 51
Why does playlist insert replace the current playlist when stopped?
« on: September 30, 2007, 09:27:18 AM »

I was doing a patch for something else and I got to wondering why the current playlist gets replaced if you insert while stopped? What's the reasoning behind it?

I understand why you might want the option to do this (like you can while playing with "Play Next") but why make it the only choice?
Logged

Offline Llorean

  • Member
  • *
  • Posts: 12931
Re: Why does playlist insert replace the current playlist when stopped?
« Reply #1 on: September 30, 2007, 09:37:42 AM »
Why not, honestly? If you want to insert into an existing playlist, pause instead of stopping.
Logged

Offline nls

  • Developer
  • Member
  • *
  • Posts: 460
Re: Why does playlist insert replace the current playlist when stopped?
« Reply #2 on: September 30, 2007, 09:56:01 AM »
The reasoning behind it is that you do not have a current playlist when stopped. If you start playing without creating a new playlist rockbox will resume the old one.
Logged

Offline cc

  • Member
  • *
  • Posts: 51
Re: Why does playlist insert replace the current playlist when stopped?
« Reply #3 on: September 30, 2007, 10:19:54 AM »
Quote from: Llorean on September 30, 2007, 09:37:42 AM
Why not, honestly? If you want to insert into an existing playlist, pause instead of stopping.

Sure, I understand you can do that. But there is extra code in there specifically to remove the menu options that would give you the other choices, so I thought someone had a reason for not wanting to offer the other choices.
Logged

Offline cc

  • Member
  • *
  • Posts: 51
Re: Why does playlist insert replace the current playlist when stopped?
« Reply #4 on: September 30, 2007, 10:26:26 AM »
Quote from: nls on September 30, 2007, 09:56:01 AM
The reasoning behind it is that you do not have a current playlist when stopped. If you start playing without creating a new playlist rockbox will resume the old one.

The 'old one' isn't really old though, it is just the current_playlist that either does or doesn't get replaced when you do an insert. Unless I'm missing something, stopping playback doesn't do anything to the current_playlist.

Logged

Offline Llorean

  • Member
  • *
  • Posts: 12931
Re: Why does playlist insert replace the current playlist when stopped?
« Reply #5 on: September 30, 2007, 11:27:15 AM »
1) What "other choices" are removed? You simply asked about the "Insert" choice. Why exactly *doesn't* pausing work for you, and why should someone add an option to "Clear Playlist" since it's unnecessary as it stands? Right now, all inserting to a stopped playlist would add is the necessity for someone to manually clear a playlist without adding any new functionality, just hassle.

2) Please follow the posting guidelines. If you haven't read them, do so now, you will be expected to follow them in the future.
Logged

Offline cc

  • Member
  • *
  • Posts: 51
Re: Why does playlist insert replace the current playlist when stopped?
« Reply #6 on: September 30, 2007, 12:07:03 PM »
My apologies - I guess I should have posted in the UI section?

Quote from: Llorean on September 30, 2007, 11:27:15 AM
1) What "other choices" are removed? You simply asked about the "Insert" choice. Why exactly *doesn't* pausing work for you, and why should someone add an option to "Clear Playlist" since it's unnecessary as it stands? Right now, all inserting to a stopped playlist would add is the necessity for someone to manually clear a playlist without adding any new functionality, just hassle.

OK, here's where I'm coming from: there is already an option in when playing which clears the playlist before inserting ("Play Next"). I though it would be easier to understand if this option was shown when stopped instead of "Insert" (which does something else when playing).

After implementing that I wondered why not show the other items in the menu when stopped? Hence my question.

(I guess you know, but the playing/stopped menu is one structure with different things shown depending on whether audio is playing or not).
Logged

Offline Llorean

  • Member
  • *
  • Posts: 12931
Re: Why does playlist insert replace the current playlist when stopped?
« Reply #7 on: September 30, 2007, 06:38:23 PM »
"Play Next" and "Insert" would perform the same function when the playlist is empty. Whether it is physically empty or not, it is supposed to be conceptually empty when playback is stopped, therefor "Insert" is inserting into an empty playlist.

You still haven't answered the "What new functionality would this add, beyond requiring a user to have a new way manually clear the playlist"?

And no, the rules state that if you're not sure where to post something, put it in general discussion. It was the double post that was the problem. Did you actually go and read them carefully after I warned you, or did you just try to guess what was wrong?
Logged

Offline cc

  • Member
  • *
  • Posts: 51
Re: Why does playlist insert replace the current playlist when stopped?
« Reply #8 on: October 01, 2007, 02:33:17 AM »

I did read the guidelines, but I was not aware I had made a double post. I can't find it now - did you delete it?

Quote from: Llorean on September 30, 2007, 06:38:23 PM
"Play Next" and "Insert" would perform the same function when the playlist is empty. Whether it is physically empty or not, it is supposed to be conceptually empty when playback is stopped, therefor "Insert" is inserting into an empty playlist.

This had not occurred to me. Maybe it is just me, but it does not seem logical to think the  playlist is empty while stopped when pressing play  starts right from where you left off  :)

Quote from: Llorean on September 30, 2007, 06:38:23 PM
You still haven't answered the "What new functionality would this add, beyond requiring a user to have a new way manually clear the playlist"?

The new 'functionality' would be an easier to understand interface - the playlist menu would always be the same independent of whether playback was stopped or not, and there would be no need to explain in the manual the different functionality of the menu (and particularly the insert function) has depending on the play/stop.

Also, there would be less code because there would be no need to have different code for these two cases.

This would not involve "a new way to clear the playlist", it would just use "Play Next".
Logged

Offline Llorean

  • Member
  • *
  • Posts: 12931
Re: Why does playlist insert replace the current playlist when stopped?
« Reply #9 on: October 01, 2007, 02:55:18 AM »
Then what would be the point of even HAVING a stop function, if the playlist will always act exactly as if it were paused?

Play Next does NOT interrupt the current song, so to clear the playlist you'd have to stop, "Play Next", then resume, then hit next.
Logged

Offline cc

  • Member
  • *
  • Posts: 51
Re: Why does playlist insert replace the current playlist when stopped?
« Reply #10 on: October 01, 2007, 03:45:43 AM »
Quote from: Llorean on October 01, 2007, 02:55:18 AM
Play Next does NOT interrupt the current song, so to clear the playlist you'd have to stop, "Play Next", then resume, then hit next.

Ah, this is what I had missed. I understand now.

Logged

Offline fml2

  • Member
  • *
  • Posts: 157
Re: Why does playlist insert replace the current playlist when stopped?
« Reply #11 on: October 01, 2007, 01:10:07 PM »
The fact that after a STOP it's still possible to resume the playback means to me that the playlist still exists. That's why I'd also assume that Insert would work as cc suggested.

The difference between STOP ans PAUSE would be that after STOP you go to the file (or db) browser, while after PAUSE you're still in the WPS.

To clear the current playlist, you can either explicitly clear it (is there an option for this) or select a song thus implicitly creating a new playlist.
Logged

Offline DefineByte

  • Member
  • *
  • Posts: 104
Re: Why does playlist insert replace the current playlist when stopped?
« Reply #12 on: October 01, 2007, 03:37:30 PM »
I find the current behaviour strange too.
Logged

Offline Llorean

  • Member
  • *
  • Posts: 12931
Re: Why does playlist insert replace the current playlist when stopped?
« Reply #13 on: October 01, 2007, 10:23:24 PM »
There is no option currently for explicitly clearing a playlist.

And "Selecting a song" won't work for inserting a single song into an empty playlist, meaning you HAVE to introduce a clear operation and make it more of a hassle for playing a single song than it is now.

Play can be thought of as "reloading" the previous playlist, if you need a term that is more semantically applicable. Does thinking of it this way solve your problems?

It's not that the playlist doesn't EXIST, it's that it ISN'T ACTIVE. If you Pause, the playlist is still active, but playback is not happening. If you Stop, then the playlist is no longer active at all, meaning that if you insert a song it's inserted into a blank playlist, and if you resume/reload, then it can attempt to start playing the previous playlist from where you were, necessitating a rebuffer. Stopping playback conceptually empties the audio buffer, necessary for certain things to happen. It really is STOP, and this is very different from PAUSE.

I think that if you actually think about what's going on, the behaviour will make more sense. Another solution would be to take away the Resume Stopped Playlist function? Would that solve the conceptual difficulty for you?
Logged

Offline fml2

  • Member
  • *
  • Posts: 157
Re: Why does playlist insert replace the current playlist when stopped?
« Reply #14 on: October 02, 2007, 04:07:23 AM »
Quote from: Llorean on October 01, 2007, 10:23:24 PM
There is no option currently for explicitly clearing a playlist.

OK

Quote
And "Selecting a song" won't work for inserting a single song into an empty playlist, meaning you HAVE to introduce a clear operation and make it more of a hassle for playing a single song than it is now.

You could do that by selecting "Play next". IIUC, "Play next" works as follows: if there is current song, it's retained (queued). The rest of the list is erased. The selected song is inserted into the list. If you're in PAUSE, there is current song, and it will play to the end. If you're in STOP, there is no current song, so the list will contain just the inserted song.

Quote
Play can be thought of as "reloading" the previous playlist, if you need a term that is more semantically applicable. Does thinking of it this way solve your problems?

I'd rather think of it other way: a playlist never disappears, even after STOP or having reached its end. It can only be replaced by another list. Then we don't have to introduce the 'active' category at all.

Quote
I think that if you actually think about what's going on, the behaviour will make more sense.

The main thing is you can predict the results of your next action. If you can do that, even the most unlogical behaviour is OK. But to learn that behaviour is harder if there are many special cases.
Logged

  • Print
Pages: [1] 2 3 ... 6
« previous next »
+  Rockbox Technical Forums
|-+  Rockbox General
| |-+  Rockbox General Discussion
| | |-+  Why does playlist insert replace the current playlist when stopped?
 

  • SMF 2.0.17 | SMF © 2019, Simple Machines
  • Rockbox Privacy Policy
  • XHTML
  • RSS
  • WAP2

Page created in 0.145 seconds with 22 queries.