diff options
author | David Faure <faure@kde.org> | 2014-03-16 23:30:59 +0100 |
---|---|---|
committer | David Faure <faure@kde.org> | 2014-03-23 23:00:03 +0100 |
commit | c1980dbc51c9aa2770d09850e69529ea2211924b (patch) | |
tree | 2bbccf3cdebbd6d1149eb1ae615c832570cfa000 /src/core/kcoreconfigskeleton.cpp | |
parent | 41ccd7bcd61c478a4243165b1df0c48e2ecad0df (diff) | |
download | kconfig-c1980dbc51c9aa2770d09850e69529ea2211924b.tar.gz kconfig-c1980dbc51c9aa2770d09850e69529ea2211924b.tar.bz2 |
Add KCoreConfigSkeleton::read() which doesn't call reparseConfiguration.
Call it from generated singletons, since the constructor creates
a KConfig from a filename, which already loads from disk.
This removes the need for using DelayedParsing.
REVIEW: 116845
Diffstat (limited to 'src/core/kcoreconfigskeleton.cpp')
-rw-r--r-- | src/core/kcoreconfigskeleton.cpp | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/src/core/kcoreconfigskeleton.cpp b/src/core/kcoreconfigskeleton.cpp index 0c1a96fa..0a9b0dfe 100644 --- a/src/core/kcoreconfigskeleton.cpp +++ b/src/core/kcoreconfigskeleton.cpp @@ -986,7 +986,7 @@ KCoreConfigSkeleton::KCoreConfigSkeleton(const QString &configname, QObject *par { //qDebug() << "Creating KCoreConfigSkeleton (" << (void *)this << ")"; - d->mConfig = KSharedConfig::openConfig(configname, KConfig::FullConfig | KConfig::DelayedParsing); + d->mConfig = KSharedConfig::openConfig(configname, KConfig::FullConfig); } KCoreConfigSkeleton::KCoreConfigSkeleton(KSharedConfig::Ptr pConfig, QObject *parent) @@ -1065,6 +1065,11 @@ void KCoreConfigSkeleton::readConfig() { // qDebug(); d->mConfig->reparseConfiguration(); + read(); +} + +void KCoreConfigSkeleton::read() +{ KConfigSkeletonItem::List::ConstIterator it; for (it = d->mItems.constBegin(); it != d->mItems.constEnd(); ++it) { (*it)->readConfig(d->mConfig.data()); |