remove deprecated version of loadLayout
This commit is contained in:
parent
5f92b0d44f
commit
38004e0f9c
19
corona.cpp
19
corona.cpp
@ -273,8 +273,8 @@ void Corona::loadLayout(const QString &configName)
|
||||
d->configName = configName;
|
||||
}
|
||||
|
||||
KSharedConfigPtr conf = config();
|
||||
d->importLayout(*conf, false);
|
||||
KConfigGroup conf(config(), QString());
|
||||
d->importLayout(conf, false);
|
||||
}
|
||||
|
||||
QList<Plasma::Containment *> Corona::importLayout(const KConfigGroup &conf)
|
||||
@ -282,13 +282,6 @@ QList<Plasma::Containment *> Corona::importLayout(const KConfigGroup &conf)
|
||||
return d->importLayout(conf, true);
|
||||
}
|
||||
|
||||
#ifndef KDE_NO_DEPRECATED
|
||||
QList<Plasma::Containment *> Corona::importLayout(const KConfigBase &conf)
|
||||
{
|
||||
return d->importLayout(conf, true);
|
||||
}
|
||||
#endif
|
||||
|
||||
Containment *Corona::containmentForScreen(int screen, int desktop) const
|
||||
{
|
||||
foreach (Containment *containment, d->containments) {
|
||||
@ -985,12 +978,10 @@ Containment *CoronaPrivate::addContainment(const QString &name, const QVariantLi
|
||||
return containment;
|
||||
}
|
||||
|
||||
QList<Plasma::Containment *> CoronaPrivate::importLayout(const KConfigBase &conf, bool mergeConfig)
|
||||
QList<Plasma::Containment *> CoronaPrivate::importLayout(const KConfigGroup &conf, bool mergeConfig)
|
||||
{
|
||||
if (const KConfigGroup *group = dynamic_cast<const KConfigGroup *>(&conf)) {
|
||||
if (!group->isValid()) {
|
||||
return QList<Containment *>();
|
||||
}
|
||||
if (!conf.isValid()) {
|
||||
return QList<Containment *>();
|
||||
}
|
||||
|
||||
QList<Plasma::Containment *> newContainments;
|
||||
|
14
corona.h
14
corona.h
@ -275,20 +275,6 @@ public:
|
||||
*/
|
||||
AbstractDialogManager *dialogManager();
|
||||
|
||||
/**
|
||||
* Imports an applet layout from a config file. The results will be added to the
|
||||
* current set of Containments.
|
||||
* @deprecated Use the 4.6 version that takes a KConfigGroup
|
||||
*
|
||||
* @param config the name of the config file to load from,
|
||||
* or the default config file if QString()
|
||||
* @return the list of containments that were loaded
|
||||
* @since 4.5
|
||||
*/
|
||||
#ifndef KDE_NO_DEPRECATED
|
||||
KDE_DEPRECATED QList<Plasma::Containment *> importLayout(const KConfigBase &config);
|
||||
#endif
|
||||
|
||||
/**
|
||||
* Returns the name of the preferred plugin to be used as containment toolboxes.
|
||||
* CustomContainments and CustomPanelContainments can still override it as their liking. It's also not guaranteed that the plugin will actually exist.
|
||||
|
@ -46,7 +46,7 @@ public:
|
||||
void syncConfig();
|
||||
Containment *addContainment(const QString &name, const QVariantList &args, uint id, bool delayedInit);
|
||||
void offscreenWidgetDestroyed(QObject *);
|
||||
QList<Plasma::Containment *> importLayout(const KConfigBase &conf, bool mergeConfig);
|
||||
QList<Plasma::Containment *> importLayout(const KConfigGroup &conf, bool mergeConfig);
|
||||
|
||||
static bool s_positioningContainments;
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user