Version: (using KDE 4.2.4) OS: Linux Installed from: Unspecified Linux Some applications use a KDirOperator (Amarok, KDevelop, Kate) and want to restore settings after application restart or session management. To do this, KDirOperator provides the functions readConfig() and writeConfig(). writeConfig() correctly saves the content to the given KConfigGroup, but readConfig() simply does not restore the settings (view mode (icons, detailed, ...), show hidden files, ...?). Amarok fixes this by manually reading the config values and applying the settings via the KDirOperator api again, see: http://websvn.kde.org/trunk/extragear/multimedia/amarok/src/browsers/filebrowser/FileBrowser.cpp?r1=905136&r2=905135&pathrev=905136 Either there is a bug in readConfig(), or it's a misunderstanding or misuse atm...
Created attachment 35133 [details] unit test Finally I figured out that it was probably a kate issue due to wrong order of execution of the member functions. The restoring of the config options does work now. Attached is a unit test that makes sure the right view mode is created after readConfig(). (this probably means the report is invalid)
SVN commit 1023790 by dfaure: Add unittest from Dominik Haumann for readConfig() restoring the right view mode. CCBUG: 199306 M +20 -0 kdiroperatortest.cpp WebSVN link: http://websvn.kde.org/?view=rev&revision=1023790
OK, now what? Is there still a bug or can we close this?
Unit test applied by David -> close as INVALID, as there was no real bug.