add clearApplets() method to Corona, as discussed on panel-devel.
svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=698001
This commit is contained in:
parent
b4a001e6e1
commit
c89bd8f0bf
@ -191,8 +191,7 @@ void Corona::saveApplets() const
|
||||
|
||||
void Corona::loadApplets(const QString& config)
|
||||
{
|
||||
qDeleteAll(d->applets);
|
||||
d->applets.clear();
|
||||
clearApplets();
|
||||
|
||||
KConfig appletConfig(config, KConfig::OnlyLocal);
|
||||
foreach (const QString& group, appletConfig.groupList()) {
|
||||
@ -207,6 +206,12 @@ void Corona::loadApplets()
|
||||
loadApplets("plasma-appletsrc");
|
||||
}
|
||||
|
||||
void Corona::clearApplets()
|
||||
{
|
||||
qDeleteAll(d->applets);
|
||||
d->applets.clear();
|
||||
}
|
||||
|
||||
Applet* Corona::addApplet(const QString& name, const QStringList& args, uint id, const QRectF& geometry)
|
||||
{
|
||||
Applet* applet = Applet::loadApplet(name, id, args);
|
||||
|
Loading…
Reference in New Issue
Block a user