[Issue 15102] Unified function to remove files/directories

via Digitalmars-d-bugs digitalmars-d-bugs at puremagic.com
Thu Oct 15 13:11:44 PDT 2015


https://issues.dlang.org/show_bug.cgi?id=15102

--- Comment #6 from Jacob Carlborg <doob at me.com> ---
(In reply to Vladimir Panteleev from comment #5)
> (In reply to Jacob Carlborg from comment #4)
> > BTW, in a GUI it's the same operation for all there cases.
> 
> Not at all, unless it's a very poor GUI.

I said "same operation", i.e. clicking on the same menu item/button.

> A good file manager will display to the user the type of object the user is
> about to delete for confirmation. Additionally, if the directory is not
> empty, an additional (or more noticeable) confirmation should be displayed.

On OS X, both Finder and Path Finder behave like this:

If a file, empty directory or non-empty directory is put in the trash no
confirmation are required. When the trash is emptied there's a generic
confirmation, regardless of the content.

For something that would bypass the trash, i.e. removing from a network drive,
a confirmation is required. But the it's the same message for all three cases.

For Debian with MATE, Debian with Gnome and Windows 10, it's the same as well.

> You still haven't provided a good use case.

The only reason why you might want to have separate functions is because of
performance reasons. But that's no reason why there can't be a unified
function.

--


More information about the Digitalmars-d-bugs mailing list