Bug 131734 - kded: Storage Media configuration not saved: Turning off Auto Action is not possible
Summary: kded: Storage Media configuration not saved: Turning off Auto Action is not p...
Status: RESOLVED UNMAINTAINED
Alias: None
Product: kio
Classification: Frameworks and Libraries
Component: media (show other bugs)
Version: unspecified
Platform: Fedora RPMs Linux
: NOR normal
Target Milestone: ---
Assignee: Kevin Ottens
URL:
Keywords:
: 145975 (view as bug list)
Depends on:
Blocks:
 
Reported: 2006-08-02 17:09 UTC by MartinG
Modified: 2009-02-27 19:41 UTC (History)
2 users (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments
Fix NotifierSettings::resetAutoAction() (609 bytes, patch)
2007-10-15 21:13 UTC, Jan Klötzke
Details

Note You need to log in before you can comment on or make changes to this bug.
Description MartinG 2006-08-02 17:09:46 UTC
Version:            (using KDE KDE 3.5.4)
Installed from:    Fedora RPMs
OS:                Linux

When configuring the KDE Media Manager using kcontrol, changes are not (always) saved. For example, for "Unmounted CD Writer" I have set "Open in New Window" as "Auto Action". Trying to turn this off by clicking "Toggle as Auto Action" and then choosing "Apply" does not work - the configuration is not saved (as seen when reopening the config window).

How to reproduce:
1) Open kcontrol -> "Peripherals" -> "Storage Media"
2) Scroll to any (non vital) medium in "Medium types:"
3) Enable "Auto Action" on something
4) Press "Apply"

5) Press some other component in kcontrol to exit "Storage Media" (for example "Peripherals)
6) Re-enter "Storage Media" and scroll to the same Mime Type
7) Disable the Auto Action and press Apply

Then, repeat 5) and 6) to see that the Auto Action is still active. It seems to be possible to "move" the Auto Action to for example "Do nothing", but not disable it.

Expected behaviour:
The configuration should be saved, and the kde notifier should just work ;)

This also happened in kde 3.5.3 (that is kdelibs-3.5.3-11.0.fc5.kde i think). I use the kde-redhat.sf.net yum repository with my FC5 installation, and installed kdelibs-3.5.4-1.0.fc5.kde (and the rest of the kde packages) from "kde-testing" and "kde-testing-all" to see if the problem was solved, but the problem remains.

I do not think this is specific to the packages in this repository.

I should mention that in "KDE Control Center"->"KDE Components"->"Service Manager" all KDED services and "Media Notifier Daemon" are active. Also, when plugging a USB pendrive or inserting a CF card, the notifier works just fine, my problem is that when I plug my external USB CD player, and insert a CDROM (or Audio CD, or blank cd) nothing happens. 

My guess is that this is related to the KDE Media Notifier, HAL, udev, fstab, fstab-sync or something in some way - it did work half a year ago or so (on Audio CDs I could choose "Rip with kaudiocreator").

Could it be related to the update of hal to version hal-0.5.7.1-2.fc5 ?

My current versions:
kdelibs-3.5.4-1.0.fc5.kde
hal-0.5.7.1-2.fc5
dbus-0.61-3.fc5.1
udev-084-13

By the way - where is the configuration for the kde media notofier supposed to be stored? I couldn't find anything in my ~/.kde/ folder.

I've googled quite alot, but could only find info for other distros (that use 'pmount' and 'kdebase-kio-plugins' which are not available for Fedora Core 5 AFAIK.)
Comment 1 MartinG 2006-08-02 19:27:21 UTC
It seems that I've got the service 'autofs' running - is this the service that takes care of "automounting" cdroms under FC5? In that case, I guess I need to configure these files:
# ll /etc/auto.*
-rwxr-xr-x 1 root root  558 jun 23 07:42 /etc/auto.smb
-rwxr-xr-x 1 root root 1292 jun 23 07:42 /etc/auto.net
-rw-r--r-- 1 root root  581 jun 23 07:42 /etc/auto.misc
-rw-r--r-- 1 root root  322 jun 23 07:42 /etc/auto.master

I tried to enable the auto.misc file in /etc/auto.master:
    /misc /etc/auto.misc --timeout=60

where in the auto.misc file I've got:
    cd -fstype=iso9660,ro,nosuid,nodev :/dev/cdrom

but that didn't seem to help. Shutting down the autofs service didn't change anything either.

Sorry for beeing slightly off topic with this, but getting a notification on cdrom insertion is what I want to get working again...

Btw. I forgot to mention that manually mounting the cdrom manually ("mount /mnt/cdrom") works when I've put in my /etc/fstab:
  /dev/scd0               /mnt/cdrom              auto ro,noauto,users    0 0

Comment 2 MartinG 2006-08-05 14:28:01 UTC
Apparently this also happens in Gnome see https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=201400
Comment 3 Greg Lepore 2007-01-19 22:00:26 UTC
I have also run into this bug.  Kubuntu Edgy.  If it helps, I set the auto action on during the pop-up for the media, rather than through Control Center.
Comment 4 Sean Hodges 2007-01-20 12:01:25 UTC
I can confirm this bug as well (Kubuntu Edgy, running KDE 3.5.5) . If I have set the auto-action for a media device, I cannot disable that auto-action, I can only move it to another application using the Storage Media utility.

My workaround at present is:

1. Create a temporary application entry called "temp" and attach it to the devices that have auto-start flags set.

2. Set this application to be the auto-start for each of these media devices.

3. Remove the "temp" application, effectively removing the auto-start flag as well.

Hope this helps someone

Sean
Comment 5 Greg Lepore 2007-01-20 14:42:51 UTC
Sean,

Ahh, excellent workaround!  Thanks.

Sean Hodges wrote:
[bugs.kde.org quoted mail]
Comment 6 jeberger 2007-07-04 20:45:37 UTC
I confirm the problem on Mandriva 2007.1

Another way to work around it is to edit the file ~/.kde/share/config/medianotifierrc There should be a line for each defined auto-action. Remove the line you don't want and save the file.
Comment 7 Gokdeniz Karadag 2007-08-03 17:04:33 UTC
This also happens on gentoo, kde version 3.5.5

Editing ~/.kde/share/config/medianotifierrc manually is a "working" workaround.
Comment 8 Bram Schoenmakers 2007-08-04 13:40:56 UTC
*** Bug 145975 has been marked as a duplicate of this bug. ***
Comment 9 Jan Klötzke 2007-10-15 21:11:46 UTC
Confirmed on KDE 3.5.7 from svn.

The attached notifiersettings.patch solves the bug. It applies against kdebase package from KDE 3.5.7.

The problem is caused by NotifierSettings::resetAutoAction() which removes the mimetype entry from then "m_autoMimetypesMap" map. Consequently ::save() doesn't know the mimetype anymore and does not remove the entry from the config file. Fix: set map entry to 0L -> ::save() removes the entry from config file.
Comment 10 Jan Klötzke 2007-10-15 21:13:21 UTC
Created attachment 21824 [details]
Fix NotifierSettings::resetAutoAction()
Comment 11 MartinG 2008-01-12 12:48:44 UTC
This bug is still around in kdelibs-3.5.8-19.fc8. Jan Klötzke's patch seems like an easy fix, could anyone implement it?
Comment 12 Paul Worrall 2008-07-21 22:50:43 UTC
Link to the Kubuntu bug report: https://bugs.launchpad.net/kdebase/+bug/56043
Comment 13 David Palacio 2008-11-27 20:03:11 UTC
*** This bug has been confirmed by popular vote. ***
Comment 14 Kevin Ottens 2009-02-27 19:41:56 UTC
This component is gone in KDE4.