roaming user patches
Helge Deller
deller at gmx.de
Tue Nov 25 17:15:26 GMT 2003
The attached patch fixes two outstanding bugs
regarding roaming user support in kfind and kdesktop/minicli.
Patch is tested - Ok to commit ?
-------------- next part --------------
Index: kfind/kftabdlg.cpp
===================================================================
RCS file: /home/kde/kdebase/kfind/kftabdlg.cpp,v
retrieving revision 1.116
diff -u -p -r1.116 kftabdlg.cpp
--- kfind/kftabdlg.cpp 29 Oct 2003 18:33:34 -0000 1.116
+++ kfind/kftabdlg.cpp 25 Nov 2003 17:12:34 -0000
@@ -378,7 +378,7 @@ void KfindTabWidget::setURL( const KURL
KConfig *conf = KGlobal::config();
conf->setGroup("History");
m_url = url;
- QStringList sl = conf->readListEntry("Directories", ',');
+ QStringList sl = conf->readPathListEntry("Directories");
dirBox->clear(); // make sure there is no old Stuff in there
if(!sl.isEmpty()) {
@@ -456,13 +456,13 @@ void KfindTabWidget::loadHistory()
// Load pattern history
KConfig *conf = KGlobal::config();
conf->setGroup("History");
- QStringList sl = conf->readListEntry("Patterns", ',');
+ QStringList sl = conf->readListEntry("Patterns");
if(!sl.isEmpty())
nameBox->insertStringList(sl);
else
nameBox->insertItem("*");
- sl = conf->readListEntry("Directories", ',');
+ sl = conf->readPathListEntry("Directories");
if(!sl.isEmpty()) {
dirBox->insertStringList(sl);
// If the _searchPath already exists in the list we do not
@@ -848,7 +848,7 @@ static void save_pattern(QComboBox *obj,
KConfig *conf = KGlobal::config();
conf->setGroup(group);
- conf->writeEntry(entry, sl, ',');
+ conf->writePathEntry(entry, sl);
}
#include "kftabdlg.moc"
Index: kdesktop/minicli.cpp
===================================================================
RCS file: /home/kde/kdebase/kdesktop/minicli.cpp,v
retrieving revision 1.166
diff -u -p -r1.166 minicli.cpp
--- kdesktop/minicli.cpp 8 Nov 2003 17:20:25 -0000 1.166
+++ kdesktop/minicli.cpp 25 Nov 2003 17:12:35 -0000
@@ -181,9 +181,9 @@ void Minicli::loadConfig()
KConfig *config = KGlobal::config();
config->setGroup("MiniCli");
- QStringList histList = config->readListEntry("History");
+ QStringList histList = config->readPathListEntry("History");
int maxHistory = config->readNumEntry("HistoryLength", 50);
- m_terminalAppList = config->readListEntry("TerminalApps");
+ m_terminalAppList = config->readPathListEntry("TerminalApps");
if (m_terminalAppList.isEmpty())
m_terminalAppList << "ls"; // Default
@@ -232,8 +232,8 @@ void Minicli::saveConfig()
{
KConfig *config = KGlobal::config();
config->setGroup("MiniCli");
- config->writeEntry( "History", m_dlg->cbCommand->historyItems() );
- config->writeEntry( "TerminalApps", m_terminalAppList );
+ config->writePathEntry( "History", m_dlg->cbCommand->historyItems() );
+ config->writePathEntry( "TerminalApps", m_terminalAppList );
config->writePathEntry( "CompletionItems", m_dlg->cbCommand->completionObject()->items() );
config->writeEntry( "CompletionMode", (int) m_dlg->cbCommand->completionMode() );
config->sync();
More information about the kde-core-devel
mailing list