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 337157 - Rate song via notification area icon context menu
Rate song via notification area icon context menu
Status: RESOLVED FIXED
Product: banshee
Classification: Other
Component: User Interface
git master
Other All
: Normal enhancement
: 0.13.x
Assigned To: Banshee Maintainers
Banshee Maintainers
: 440861 (view as bug list)
Depends on: 338057
Blocks:
 
 
Reported: 2006-04-04 10:00 UTC by François Tissandier
Modified: 2007-05-25 05:23 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
patch to enable the rating of songs through the NotificationAreaIcon (7.85 KB, patch)
2006-04-17 19:50 UTC, Pepijn van de Geer
needs-work Details | Review
patch to make the ratingmenu a widget (7.75 KB, patch)
2007-04-21 12:12 UTC, Pepijn van de Geer
needs-work Details | Review
patch to make the ratingmenu a widget (7.75 KB, patch)
2007-04-21 12:14 UTC, Pepijn van de Geer
none Details | Review
patch to make the ratingmenu a widget (7.75 KB, patch)
2007-04-21 12:17 UTC, Pepijn van de Geer
none Details | Review
Patch to add ratingmenu to popup (4.39 KB, patch)
2007-04-21 12:28 UTC, Pepijn van de Geer
needs-work Details | Review
Inline Menu Rating (16.10 KB, patch)
2007-04-23 23:23 UTC, Aaron Bockover
none Details | Review
Screenshot of inline rating (17.90 KB, image/png)
2007-04-23 23:29 UTC, Aaron Bockover
  Details
Second Iteration of Inline Rating (18.32 KB, patch)
2007-04-24 01:18 UTC, Aaron Bockover
none Details | Review
Screencast of inline rating (623.84 KB, application/ogg)
2007-04-24 01:20 UTC, Aaron Bockover
  Details
Add the new RatingMenuItem to contextmenu (3.28 KB, patch)
2007-04-24 11:25 UTC, Pepijn van de Geer
committed Details | Review

Description François Tissandier 2006-04-04 10:00:40 UTC
Currently, you need to see the main window of Banshee to rate a song. Typically
I do something else on the computer while listening to music, and I want to rate
some songs from time to time. 

What I think would be very convenient is a plugin to add the rating stuff in the
right-clic menu of the icon:

Play
Previous
Next
--------
Rate it!
--------
....

Then when you move your mouse about the "rate it" item, it displays a drop down
menu on the right, with the 5 ratings, or maybe with empty stars and you click
to fill them. 


Other solution, even less clics: 
integrate the rating in the info popup, with the empty clicable stars. BUt it
would require to be able to interact with the popup.
Comment 1 François Tissandier 2006-04-06 21:10:29 UTC
Another idea for the same functionality:

if you want to rate a song from the main window, you have to right click. If the rating column is displayed, it would seem logical to click on the stars to give the rating, or modifying it. Several other softwares are doing this. You see empty stars, if you click on the first one, it's rating 1, if you click on the second, it's rating 2, etc.. .
Comment 2 Paul Cutler 2006-04-07 00:54:30 UTC
You may want to check out Music Applet, http://web.ics.purdue.edu/~kuliniew/music-applet/ , an applet for the GNOME panel, that adds Banshee music control and rating control.  Banshee support was just recently added.
Comment 3 François Tissandier 2006-04-07 07:37:30 UTC
Music Applet is what I was thinking about. But the pop-up looks quite poor compared to the one from Banshee, don't you think? A mix of the two would be a nice solution maybe.
Comment 4 Ruben Vermeersch 2006-04-10 19:27:48 UTC
Moving to the User Interface component.
Comment 5 Pepijn van de Geer 2006-04-17 19:50:11 UTC
Created attachment 63736 [details] [review]
patch to enable the rating of songs through the NotificationAreaIcon

This patch enables the rating of songs as described in the first post. It adds a ratings menu. In contrast to the ratings menu in the playlistview this rates the current song, not the selected songs. The menu is only available when there is a current song (paused or playing) that is from the library or from a playlist.
I would apreciate it if someone would take a look at it. It's my first attempt at C# and Banshee programming, so there might be some stupid mistakes in there. 
Having sad that, it works properly for me. 

The only known problem is that the playlistview isn't always upated when you rate a song. But it is supposed te be used with the Banshee screen out of sight. 

It would be nice to add someway of telling how the song is currently rated. Maybe disabling that rating from the menu?

ps. It changes the Makefile.am to ad star.png as a resource. I don't know if this is the proper way.
Comment 6 François Tissandier 2006-04-17 21:15:54 UTC
>It would be nice to add someway of telling how the song is currently rated.
Maybe disabling that rating from the menu?

Or show it in the popup window? 
Comment 7 Aaron Bockover 2006-06-21 05:50:08 UTC
I'd really like to see the rating menu abstracted into its own widget so there's no duplication. 

Also, the star.png resource is available from the entry assembly and does not need to be included in the plugin assembly.

Replace Gdk.Pixbuf.LoadFromResource("star.png") with new Gdk.Pixbuf(System.Reflection.Assembly.GetEntryAssembly(), "star.png").

Sound reasonable?
Comment 8 Josiah Ritchie - flickerfly 2007-02-23 18:11:18 UTC
What info is still needed on this enhancement? It's been NEEDINFO for over 6 months without change, but I know I'd really like to have it available still. :-)

Also, would this be a good candidate for gnome-love?
Comment 9 Jason Switzer 2007-04-17 04:39:54 UTC
I think this feature is crucial to using the rating system. This patch has been sitting here for over a year and is still marked NEEDINFO. What info is still needed exactly?
Comment 10 Pepijn van de Geer 2007-04-17 07:08:45 UTC
The patch is marked needs-work.
I'll try to change the patch according to Aarons comments. Perhaps this weekend. Maybe we can get it into 0.13.
Comment 11 Pepijn van de Geer 2007-04-21 12:12:51 UTC
Created attachment 86730 [details] [review]
patch to make the ratingmenu a widget

Here's my second attempt. This patch makes the ratingmenu a widget, so it can be reused in the notification area plugin.
Comment 12 Pepijn van de Geer 2007-04-21 12:14:06 UTC
Created attachment 86731 [details] [review]
patch to make the ratingmenu a widget

Here's my second attempt. This patch makes the ratingmenu a widget, so it can be reused in the notification area plugin.
Comment 13 Pepijn van de Geer 2007-04-21 12:17:37 UTC
Created attachment 86732 [details] [review]
patch to make the ratingmenu a widget

Here's my second attempt. This patch makes the ratingmenu a widget, so it can be reused in the notification area plugin.
Comment 14 Pepijn van de Geer 2007-04-21 12:28:42 UTC
Created attachment 86734 [details] [review]
Patch to add ratingmenu to popup

And this adds the ratingmenu to the popup.

ps. Sorry for spamming bugzilla. Don't know what happend. Can someone delete the double entries?
Comment 15 Aaron Bockover 2007-04-23 19:09:26 UTC
Hi Pepijn:

Thanks for the work on the patch. A few quick administrative and cosmetic issues:

a) Please ensure you are using spaces and not tabs, I notice there is a mix in your patches. Ensure you conform to the style rules set forth and used by the project in HACKING

b) For the sake of review and commit, it would be nice to have a single patch

c) Please write a ChangeLog entry, included in the patch or just as a comment to the bug - you know best what changed in the patch

Because this has been open for so long and you're working on it, I'd like to commit ASAP. However, I have a separate idea for rating via menu where we actually would reuse the "inline" widget that is available in the track editor. It would be slick, eliminate the sub menu, and would take up less space, but it will probably be a significant chunk of work, so I'd rather just get this version in first.
Comment 16 Aaron Bockover 2007-04-23 23:23:50 UTC
Created attachment 86882 [details] [review]
Inline Menu Rating

This patch adds inline rating support to the song view menu. It reuses the RatingEntry widget in an "embedded" mode, wrapped by a custom MenuItem widget, RatingMenuItem. This widget is reusable and can go into the notification area popup menu (not addressed by this patch though).

Thoughts on the behavior? I like the inline rating, eliminating the clunky submenu, but maybe it's not as clear as it needs to be. I'd appreciate some testing and feedback.
Comment 17 Aaron Bockover 2007-04-23 23:29:03 UTC
Created attachment 86884 [details]
Screenshot of inline rating

Just a screenshot showing off how it looks in the menu.
Comment 18 Ruben Vermeersch 2007-04-24 01:04:20 UTC
(In reply to comment #17)
> Created an attachment (id=86884) [edit]
> Screenshot of inline rating

Ultrahot! That is all I have to say about it :-)
Comment 19 Aaron Bockover 2007-04-24 01:18:08 UTC
Created attachment 86889 [details] [review]
Second Iteration of Inline Rating

This is the second version, it addresses the following issues:

a) Show a label "Rating"
b) Be keyboard friendly
   - Draw the selected/highlighted menu item background to indicate focus
   - Respond to keyboard events (all that the entry supports except up/down)
c) A few bug fixes in the rating entry code, not necessarily related to the menu inlining
Comment 20 Aaron Bockover 2007-04-24 01:20:29 UTC
Created attachment 86890 [details]
Screencast of inline rating

The screencast shows the new themeing/highlighting and interaction via keyboard (note placement of cursor when rating changes).
Comment 21 Pepijn van de Geer 2007-04-24 09:47:39 UTC
Looks great, I like it. There's two things I noticed though:

First the RatingEntry doesn't show the current rating. But looking at the FIXME you already knew that. I think this is issue is also related to bugs #398498 and  #411994. (The second one also suggests a solution.)

My second issue might just be personal taste, but it feels strange you have to "cancel" the popup to set the rating. Maybe clicking on the word "rating" (or anywhere but the stars) can accept your changes and make the menu disappear? 
Comment 22 Pepijn van de Geer 2007-04-24 11:25:58 UTC
Created attachment 86916 [details] [review]
Add the new RatingMenuItem to contextmenu

* src/Plugins/Banshee.Plugins.NotificationAreaIcon/NotificationAreaIconPlugin.cs:
Add new RatingMenuItem to notification area icon context menu (BGO #337157)

This patch adds the new RatingMenuItem to the notification area icon context menu.
There is one minor bug with this code: In the odd case you set the rating of a currently playing song in the mainwindow and then open the notification area icon context menu the rating isn't updated. There doesn't seem to be a PlayerEngineEvent for when the rating is changed.
Comment 23 Aaron Bockover 2007-05-25 02:36:04 UTC
*** Bug 440861 has been marked as a duplicate of this bug. ***
Comment 24 Aaron Bockover 2007-05-25 03:17:27 UTC
Pepijn: I've committed your latest patch with a few minor modifications. When you set the rating on the PlayerEngineCore.CurrentTrack, making a subsequent call to PlayerEngineCore.TrackInfoUpdate() is (somewhat unfortunately) necessary - this will allow the main GUI to refresh and depict the changes. Also, if there is no CurrentTrack, I prefer to have the rating item hidden, not insensitive. Finally, I removed the separator.

Thanks!
Comment 25 Andrew Conkling 2007-05-25 05:23:45 UTC
Sorry to jump in here, but I just wanted to chime in and say that this is pretty sexy. :)