From 943c09096f11827470b9cd3e311329ac422aaf20 Mon Sep 17 00:00:00 2001 From: andyq Date: Thu, 17 Oct 2002 22:49:03 +0000 Subject: Read/Write out to config file whether a destination is set to linkToRoot --- (limited to 'noncore/settings/aqpkg/datamgr.cpp') diff --git a/noncore/settings/aqpkg/datamgr.cpp b/noncore/settings/aqpkg/datamgr.cpp index d929c39..089c3e3 100644 --- a/noncore/settings/aqpkg/datamgr.cpp +++ b/noncore/settings/aqpkg/datamgr.cpp @@ -18,6 +18,10 @@ #include using namespace std; +#ifdef QWS +#include +#endif + #include #include "datamgr.h" @@ -70,6 +74,11 @@ void DataManager :: loadServers() serverList.push_back( Server( LOCAL_SERVER, "" ) ); serverList.push_back( Server( LOCAL_IPKGS, "" ) ); +#ifdef QWS + Config cfg( "aqpkg" ); + cfg.setGroup( "destinations" ); +#endif + // Read file from /etc/ipkg.conf QString ipkg_conf = IPKG_CONF; FILE *fp; @@ -112,6 +121,14 @@ void DataManager :: loadServers() char path[50]; sscanf( lineStr, "%*[^ ] %s %s", alias, path ); Destination d( alias, path ); + bool linkToRoot = true; +#ifdef QWS + QString key = alias; + key += "_linkToRoot"; + linkToRoot = cfg.readBoolEntry( key, true ); +#endif + d.linkToRoot( linkToRoot ); + destList.push_back( d ); } } -- cgit v0.9.0.2