Bug 158936

Summary: Cannot unmount devices inside the New Device Notifier
Product: [Unmaintained] plasma4 Reporter: András Manţia <amantia>
Component: widget-devicenotifierAssignee: Plasma Bugs List <plasma-bugs>
Status: RESOLVED FIXED    
Severity: wishlist CC: notmart, sverik, wstephenson
Priority: NOR    
Version: unspecified   
Target Milestone: ---   
Platform: unspecified   
OS: Linux   
Latest Commit: Version Fixed In:
Sentry Crash Report:
Attachments: change icon on successful unmount

Description András Manţia 2008-03-07 22:22:41 UTC
Version:            (using Devel)

KDE4 has the system wide issue that it is hard to find how to unmount devices (you can do it in Dolphin or a file dialog). The New Device Notifier would be a good place for this functionality, if it'd show the mounted devices as well, not just what was recently plugged. As of now, as soon as a device is mounted (well, only by clicking on it in the device notifier dialog, not if it is mounted e.g in Dolphin), it disappears from its list.
The proposal is:
- show there all user mountable devices, even if they are already mounted
- provide context menu to mount/unmount/eject
Comment 1 Marco Martin 2008-03-09 19:41:50 UTC
i propose this: add a second column right to the device entry with an eject icon if the device is mounted
Comment 2 Christopher Blauvelt 2008-03-09 20:02:39 UTC
+1

On 9 Mar 2008 18:41:51 -0000, Marco Martin <notmart@gmail.com> wrote:

[bugs.kde.org quoted mail]
+1<br><br><div class="gmail_quote">On 9 Mar 2008 18:41:51 -0000, Marco Martin &lt;<a href="mailto:notmart@gmail.com">notmart@gmail.com</a>&gt; wrote:<br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
------- You are receiving this mail because: -------<br>
You are the assignee for the bug, or are watching the assignee.<br>
<br>
<a href="http://bugs.kde.org/show_bug.cgi?id=158936" target="_blank">http://bugs.kde.org/show_bug.cgi?id=158936</a><br>
<br>
<br>
<br>
<br>
------- Additional Comments From notmart gmail com &nbsp;2008-03-09 19:41 -------<br>
i propose this: add a second column right to the device entry with an eject icon if the device is mounted<br>
_______________________________________________<br>
Panel-devel mailing list<br>
<a href="mailto:Panel-devel@kde.org">Panel-devel@kde.org</a><br>
<a href="https://mail.kde.org/mailman/listinfo/panel-devel" target="_blank">https://mail.kde.org/mailman/listinfo/panel-devel</a><br>
</blockquote></div><br>
Comment 3 András Manţia 2008-03-09 22:21:06 UTC
The problem is that it depends on the media type if it can be ejected or 
not... Do you eject a memory card? A floppy? An external hard drive?
You can certainly unmount it, but not always eject it.
Comment 4 Marco Martin 2008-03-10 15:31:18 UTC
well, an eject icon more or less ives the idea and it's already used in dolphin. and if someone will come up with a nice icon for unmount distinct from the eject one will of course be better (and very easy to implement once we have the general concept working)
Comment 5 Will Stephenson 2008-03-14 12:07:15 UTC
Also take care that memory cards or external hard drives may not be unmountable.

As an example, i've seen eeePCs with memory cards (card reader on the USB bus) that are 'permanently' mounted by fstab as root trigger the device notifier in KDE 3, although the user may not umount them.
Comment 6 Marco Martin 2008-03-14 12:07:52 UTC
SVN commit 785555 by mart:

adds an eject icon as a second column in the device notifier only for mounted devices: it makes more intuitive to unmount a gived external disk.
the look at the moment is:
http://www.notmart.org/misc/article_images/devicenotifier_eject.png
it's not the final one, the unification with kickoff menu aspect is in the works

BUG: 158936

 M  +91 -34    devicenotifier.cpp  
 M  +7 -0      devicenotifier.h  
 M  +55 -43    itemdelegate.cpp  
 M  +8 -2      itemdelegate.h  
 M  +13 -1     notifierview.cpp  
 M  +5 -2      notifierview.h  


WebSVN link: http://websvn.kde.org/?view=rev&revision=785555
Comment 7 Will Stephenson 2008-03-14 13:20:10 UTC
No error handling or checking if umount is actually possible?
Comment 8 Marco Martin 2008-03-14 19:40:34 UTC
damn, you're right...
now i reopened the review on http://mattr.info/r/285/
it still has problems but i hope should be ironed out quickly
Comment 9 Sven-Erik Petermann 2008-05-14 09:17:08 UTC
Does this fix also tell the user whether umount has finished its job and whether it was successful or not?
Comment 10 Marco Martin 2008-05-14 13:53:35 UTC
at the moment if the unmount fails an error message is shown, and if nothing happens means it was successful
maybe a passive popup when it's successful?
kinda fear that even this would be too annoying, hmm
i'll try to do a patch and see if it's terrible or not :)
Comment 11 András Manţia 2008-05-14 18:51:45 UTC
Please notify of successful unmount as well. Now the user does not know 
what has happened and will try to click again, which mounts the media...
Comment 12 Marco Martin 2008-05-17 20:10:17 UTC
Created attachment 24815 [details]
change icon on successful unmount

in this patch when a device is successfully unmounted the computer icon turns
into a kind of v (the one for ok buttons in dialogs, maybe there is a better
icon?) for two seconds, i think other things like popups would be too
intrusive.
don't know how intuitive/immediate it is, but i think it's the less annoying
way :)
Comment 13 Marco Martin 2008-05-19 23:28:01 UTC
SVN commit 810019 by mart:

little unobtrusive notification when a device is successfully unmounted
done with the change of the devicenotifier icon for two seconds.
CCBUG: 158936


 M  +16 -0     devicenotifier.cpp  
 M  +1 -0      devicenotifier.h  


WebSVN link: http://websvn.kde.org/?view=rev&revision=810019
Comment 14 Sven-Erik Petermann 2008-05-20 08:48:24 UTC
And if you happen to look out of the window for two seconds then you don't know the state of the device? I think the New Device Notifier should show these three states of a mountable device:
1. mounted
2. unmounting
3. unmounted
Comment 15 Marco Martin 2008-05-20 12:27:05 UTC
reopening the devices list it will show the device icon with the usual mounted overlay or not. it's needed to reopen, but of course there is not enough space to put info on multiple devices in the notifier icon :)