config ui of applets should work again
This commit is contained in:
parent
e7ca00e534
commit
4feb02c329
@ -109,7 +109,7 @@ void PlasmoidPackage::initPackage(Package *package)
|
||||
package->setServicePrefix("plasma-applet-");
|
||||
package->setDefaultPackageRoot("plasma/plasmoids/");
|
||||
|
||||
package->addFileDefinition("configmodel", "ui/config.qml", i18n("Configuration UI pages model"));
|
||||
package->addFileDefinition("configmodel", "config/config.qml", i18n("Configuration UI pages model"));
|
||||
package->addFileDefinition("mainconfigxml", "config/main.xml", i18n("Configuration XML file"));
|
||||
}
|
||||
|
||||
|
@ -99,13 +99,13 @@ void ContainmentConfigView::setCurrentWallpaper(const QString &wallpaper)
|
||||
return;
|
||||
}
|
||||
|
||||
if (m_containment->containment()->wallpaper() == wallpaper) {
|
||||
if (m_containment->wallpaper() == wallpaper) {
|
||||
delete m_currentWallpaperConfig;
|
||||
if (m_containment->wallpaperInterface()) {
|
||||
m_currentWallpaperConfig = m_containment->wallpaperInterface()->configuration();
|
||||
}
|
||||
} else {
|
||||
if (m_containment->containment()->wallpaper() != m_currentWallpaper) {
|
||||
if (m_containment->wallpaper() != m_currentWallpaper) {
|
||||
delete m_currentWallpaperConfig;
|
||||
}
|
||||
|
||||
@ -114,7 +114,7 @@ void ContainmentConfigView::setCurrentWallpaper(const QString &wallpaper)
|
||||
pkg.setDefaultPackageRoot("plasma/wallpapers");
|
||||
pkg.setPath(wallpaper);
|
||||
QFile file(pkg.filePath("config", "main.xml"));
|
||||
KConfigGroup cfg = m_containment->containment()->config();
|
||||
KConfigGroup cfg = m_containment->config();
|
||||
cfg = KConfigGroup(&cfg, "Wallpaper");
|
||||
m_currentWallpaperConfig = new ConfigPropertyMap(new Plasma::ConfigLoader(&cfg, &file), this);
|
||||
}*/
|
||||
@ -126,9 +126,9 @@ void ContainmentConfigView::setCurrentWallpaper(const QString &wallpaper)
|
||||
|
||||
void ContainmentConfigView::applyWallpaper()
|
||||
{
|
||||
/*m_containment->containment()->setWallpaper(m_currentWallpaper);
|
||||
m_containment->setWallpaper(m_currentWallpaper);
|
||||
|
||||
if (m_currentWallpaperConfig != m_containment->wallpaperInterface()->configuration()) {
|
||||
/*if (m_currentWallpaperConfig != m_containment->wallpaperInterface()->configuration()) {
|
||||
delete m_currentWallpaperConfig;
|
||||
m_currentWallpaperConfig = m_containment->wallpaperInterface()->configuration();
|
||||
emit wallpaperConfigurationChanged();
|
||||
|
@ -315,7 +315,6 @@ void DesktopCorona::showConfigurationInterface(Plasma::Applet *applet)
|
||||
return;
|
||||
}
|
||||
|
||||
if (!m_configView) {
|
||||
Plasma::Containment *cont = qobject_cast<Plasma::Containment *>(applet);
|
||||
|
||||
if (cont) {
|
||||
@ -324,7 +323,6 @@ void DesktopCorona::showConfigurationInterface(Plasma::Applet *applet)
|
||||
m_configView = new ConfigView(applet);
|
||||
}
|
||||
m_configView.data()->init();
|
||||
}
|
||||
|
||||
m_configView.data()->show();
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user