After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 309268 - "play" should play the selected song
"play" should play the selected song
Status: RESOLVED FIXED
Product: sound-juicer
Classification: Applications
Component: playing
2.11.x
Other Linux
: Normal normal
: ---
Assigned To: Sound Juicer Maintainers
Sound Juicer Maintainers
Depends on:
Blocks:
 
 
Reported: 2005-07-01 11:41 UTC by Sebastien Bacher
Modified: 2005-08-01 09:26 UTC
See Also:
GNOME target: 2.12.x
GNOME version: ---


Attachments
Patch against the CVS HEAD (1.54 KB, patch)
2005-07-03 15:22 UTC, Madhan Raj M
none Details | Review
Patch against the CVS HEAD (2.05 KB, patch)
2005-07-03 18:14 UTC, Madhan Raj M
none Details | Review
Patch against the CVS HEAD (4.01 KB, patch)
2005-07-04 15:19 UTC, Madhan Raj M
none Details | Review
Updated patch (3.49 KB, patch)
2005-07-04 15:46 UTC, Madhan Raj M
needs-work Details | Review
Latest patch against CVS HEAD (3.89 KB, patch)
2005-07-14 12:58 UTC, Madhan Raj M
none Details | Review
Patch against CVS HEAD (3.59 KB, patch)
2005-07-29 20:33 UTC, Madhan Raj M
none Details | Review
Patch against CVS head, as per Ross's comment (4.60 KB, patch)
2005-08-01 07:15 UTC, Madhan Raj M
none Details | Review

Description Sebastien Bacher 2005-07-01 11:41:23 UTC
with sound-juicer 2.11.3:

* select a song
* click on play

the first song starts playing, it should pick the selected one rather
Comment 1 Ross Burton 2005-07-01 11:53:27 UTC
I'll let you and Ronald battle this one out...
Comment 2 Ronald Bultje 2005-07-01 12:49:15 UTC
This should be 3-4 lines of code in play.c... I guess it's what you'd expect, so
yes, I should write those 3-4 lines of code. :).
Comment 3 Madhan Raj M 2005-07-03 14:59:40 UTC
Select a track and click on play. 
Suppose the selected track plays, what should be the behaviour when we click on
PAUSE, select another track and again click on play ?

Should the newly selected track play or the PAUSED track resume play ?
Should there be any STOP button to ensure that a song is stopped before moving
to next track?
Comment 4 Ronald Bultje 2005-07-03 15:21:22 UTC
No stop button. :).

As for behaviour, currently pause is a semi-hardware-pause and
semi-hardware-stop button, since it removes the title, for example (this is
visual feedback). When title is removed, I'd say select-new-and-play would play
the new one, whereas if the title would remain, i'd expect select-new to do
nothing and continue palying the old one.
Comment 5 Madhan Raj M 2005-07-03 15:22:27 UTC
Created attachment 48593 [details] [review]
Patch against the CVS HEAD

When a track is selected and Play is clicked, that track is played.
But still the above issue is yet to be decided.
Comment 6 Madhan Raj M 2005-07-03 18:14:45 UTC
Created attachment 48600 [details] [review]
Patch against the CVS HEAD

Whenever a track is selected and play button is clicked, the selected track is
played.

Thanks Ronald
Comment 7 Madhan Raj M 2005-07-04 15:19:58 UTC
Created attachment 48629 [details] [review]
Patch against the CVS HEAD
Comment 8 Madhan Raj M 2005-07-04 15:46:11 UTC
Created attachment 48630 [details] [review]
Updated patch
Comment 9 Madhan Raj M 2005-07-04 15:54:23 UTC
Ross:
While playing, when selection changes, should it play the new selection. ie
Should a single click start playing a selected track.

The current behaviour of this patch is:
1. Select a track, click on play. It plays the selected track.
2. While playing, when the selection changes, it does nothing. But when the row
is activated, the activated row is played. A Single click wont do anything.
3. While not playing, when selection changes, it is updated and when Play button
is clicked, the latest selection is played.
Comment 10 Ross Burton 2005-07-04 16:04:41 UTC
No, selecting a track whilst playing shouldn't switch to it.

If I press Pause and then Play again, does this patch carry on from where it
was, or start the current track again?
Comment 11 Madhan Raj M 2005-07-04 16:52:27 UTC
If i Pause and Play the current track, i'll resume play.

Also, if i Pause and change selection and come back to the old Paused track, and
click on Play, it will resume Play.
Comment 12 Madhan Raj M 2005-07-14 12:58:23 UTC
Created attachment 49165 [details] [review]
Latest patch against CVS HEAD

Slighter modifications.
Comment 13 Ronald Bultje 2005-07-27 12:01:36 UTC
Hi Madhan,

I've reorganised some of the code that you're touching here, to make your patch
(and similar behaviour) easier to implement. Only the .glade file changes and
the last chunk should now be needed to implement this feature. Can you update
the patch and test it, so we can apply?
Comment 14 Madhan Raj M 2005-07-29 20:33:26 UTC
Created attachment 49954 [details] [review]
Patch against CVS HEAD

The extra code sets the Stock Item (loud speaker) to the playing track and set
the title.
Comment 15 Ross Burton 2005-07-31 15:50:42 UTC
Small point, call gtk_tree_view_selection_set_mode in main() instead of on every
selection.
Comment 16 Madhan Raj M 2005-08-01 07:15:52 UTC
Created attachment 50051 [details] [review]
Patch against CVS head, as per Ross's comment
Comment 17 Ross Burton 2005-08-01 09:26:07 UTC
Committed, thanks