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 164220 - Implement trash support for the playlist
Implement trash support for the playlist
Status: RESOLVED WONTFIX
Product: totem
Classification: Core
Component: general
unspecified
Other Linux
: Normal enhancement
: ---
Assigned To: General Totem maintainer(s)
General Totem maintainer(s)
Depends on:
Blocks:
 
 
Reported: 2005-01-16 02:51 UTC by Bastien Nocera
Modified: 2013-03-12 23:04 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Attempt - doesn't work (1.95 KB, patch)
2008-01-20 17:39 UTC, Patrick Hulin
needs-work Details | Review

Description Bastien Nocera 2005-01-16 02:51:20 UTC
We should be able to DND entries from the playlist to the trash to delete them.
http://primates.ximian.com/~federico/news-2004-04.html#x-delete-me
Comment 1 Reinout van Schouwen 2005-12-27 22:29:46 UTC
In the mean time, can we have an Edit>Clear item + a context menu option 'Clear'?

Currently when you want to clear the playlist, you have to remove the tracks one by one (click track, click -, click next track, click - etc.) unless you happen to be part of the elite group that knows about shift/ctrl multiple selection methods.
Comment 2 Bastien Nocera 2007-01-05 12:10:33 UTC
bug #309902 added the "Remove" context menu item.

Now it just needs a "Clear Playlist" menu item in the Edit menu. I moved this to bug #393111
Comment 3 Patrick Hulin 2008-01-13 05:19:20 UTC
So all I have to do is add a handler for the GtkWidget::drag_data_delete signal, right?
Comment 4 Reinout van Schouwen 2008-01-13 12:10:33 UTC
As long as the playlist can be restored from the Trash again.
Comment 5 Bastien Nocera 2008-01-14 14:44:25 UTC
(In reply to comment #4)
> As long as the playlist can be restored from the Trash again.

Why would you want to do that?
Comment 6 Reinout van Schouwen 2008-01-14 16:34:32 UTC
(In reply to comment #5)

> Why would you want to do that?

Simply because it's part of the semantics of the Trash functionality, that anything you put in, can be gotten out again, unless you empty the Trash. 

It would be a confusing user experience if objects you put in the Trash sometimes simply disappear, and other times still exist.
Comment 7 Patrick Hulin 2008-01-14 16:43:09 UTC
Besides the difficulty (impossibility?) to code, that's not really an expectation I have as a user.
Comment 8 Matthew Paul Thomas (mpt) 2008-01-14 17:13:11 UTC
The reason you don't have that expectation is that no other applications do it *yet*, Nautilus included. Once Nautilus implements it (bug 41850), there will be UI for other applications to hook restore functions into.

In the meantime, I think it would be sufficient for dragging an item from a playlist to the Trash to delete it from the playlist and create a symlink to it in the Trash. Conversely, dragging a symlink to an item (whether it be in the Trash, or anywhere else) into a playlist should add the item to the playlist.
Comment 9 Patrick Hulin 2008-01-20 17:39:55 UTC
Created attachment 103268 [details] [review]
Attempt - doesn't work

Can someone look at my patch and help me figure out why it doesn't work? Nothing happens when I drag something from playlist->trash.
Comment 10 Bastien Nocera 2008-01-21 10:58:49 UTC
(In reply to comment #8)
> The reason you don't have that expectation is that no other applications do it
> *yet*, Nautilus included. Once Nautilus implements it (bug 41850), there will
> be UI for other applications to hook restore functions into.

I don't think we're expected to be able to restore the data from the trash and into the application without human intervention.

> In the meantime, I think it would be sufficient for dragging an item from a
> playlist to the Trash to delete it from the playlist and create a symlink to it
> in the Trash. Conversely, dragging a symlink to an item (whether it be in the
> Trash, or anywhere else) into a playlist should add the item to the playlist.

You're right actually, and this should create a partial playlist file in the Trash, that re-added to Totem, would restore it.

See:
http://developer.apple.com/documentation/UserExperience/Conceptual/OSXHIGuidelines/XHIGDragDrop/chapter_13_section_6.html#//apple_ref/doc/uid/TP30000364-TPXREF34

"
Dragging items to the Trash results in moving the item from the source to the Trash. For example, dragging a text selection from a word-processing application and dropping it on the Trash icon (or in the Trash window) results in the text being deleted from the application and a clipping containing that text being created inside the Trash. Note that the item is moved, although it is dragged between two containers. This exception to the rules described earlier is appropriate because the user can undo the operation by dragging the clipping out of the Trash back to its original source; it is consistent with the principle of preventing accidental data loss.

It is important to preserve the Trash’s container property; do not simply delete the source without creating a clipping or other item in the Trash.
"
Comment 11 Bastien Nocera 2008-01-21 11:02:14 UTC
(In reply to comment #9)
> Created an attachment (id=103268) [edit]
> Attempt - doesn't work
> 
> Can someone look at my patch and help me figure out why it doesn't work?
> Nothing happens when I drag something from playlist->trash.

FYI, I have no idea how this is supposed to work, and it probably would need some trial and error. You could try disabling the internal treeview drag'n'drop (reordering the entries), and might have more luck then.
Comment 12 Bastien Nocera 2013-03-08 14:24:58 UTC
We don't have a visible trash in the shell UI anymore.
Comment 13 Reinout van Schouwen 2013-03-12 22:58:58 UTC
(In reply to comment #12)
> We don't have a visible trash in the shell UI anymore.

There is one in Nautilus. Also, in Classic mode, Nautilus still draws icons on the desktop. Is the mere fact that the main gnome-shell UI doesn't expose Trash by default, enough reason to WONTFIX this?!
Comment 14 Bastien Nocera 2013-03-12 23:04:02 UTC
(In reply to comment #13)
> (In reply to comment #12)
> > We don't have a visible trash in the shell UI anymore.
> 
> There is one in Nautilus. Also, in Classic mode, Nautilus still draws icons on
> the desktop. Is the mere fact that the main gnome-shell UI doesn't expose Trash
> by default, enough reason to WONTFIX this?!

Yes. The trash doesn't appear in the default UI (the non-classic mode), either on the desktop, or in a panel.

Given that the last patch is 5 years old and this bug has been opened (by me) 8 years ago, I don't think that it's useful to keep opened when I (or any of the other Totem developers) have no intention on fixing it.