Fix typo in var name

This commit is contained in:
Sebastian Kügler 2013-03-28 01:50:19 +01:00
parent b19f4fe01d
commit 2ac12c5fe6
3 changed files with 12 additions and 10 deletions

View File

@ -120,6 +120,7 @@ ConfigModel::ConfigModel(QObject *parent)
roleNames[PluginNameRole] = "pluginName";
setRoleNames(roleNames);
qDebug() << " XXX loaded QALM";
}
ConfigModel::~ConfigModel()

View File

@ -35,7 +35,7 @@
//////////////////////////////ContainmentConfigView
ContainmentConfigView::ContainmentConfigView(ContainmentInterface *interface, QWindow *parent)
: ConfigView(interface, parent),
m_contianmentInterface(interface),
m_containmentInterface(interface),
m_wallpaperConfigModel(0),
m_currentWallpaperConfig(0)
{
@ -68,6 +68,7 @@ ConfigModel *ContainmentConfigView::wallpaperConfigModel()
foreach (const QString &package, packages) {
pkg.setPath(package);
ConfigCategory *cat = new ConfigCategory(m_wallpaperConfigModel);
qDebug() << "newed ConfigCategory";
cat->setName(pkg.metadata().name());
cat->setIcon(pkg.metadata().icon());
cat->setSource(pkg.filePath("ui", "config.qml"));
@ -95,13 +96,13 @@ void ContainmentConfigView::setCurrentWallpaper(const QString &wallpaper)
return;
}
if (m_contianmentInterface->containment()->wallpaper() == wallpaper) {
if (m_containmentInterface->containment()->wallpaper() == wallpaper) {
delete m_currentWallpaperConfig;
if (m_contianmentInterface->wallpaperInterface()) {
m_currentWallpaperConfig = m_contianmentInterface->wallpaperInterface()->configuration();
if (m_containmentInterface->wallpaperInterface()) {
m_currentWallpaperConfig = m_containmentInterface->wallpaperInterface()->configuration();
}
} else {
if (m_contianmentInterface->containment()->wallpaper() != m_currentWallpaper) {
if (m_containmentInterface->containment()->wallpaper() != m_currentWallpaper) {
delete m_currentWallpaperConfig;
}
@ -110,7 +111,7 @@ void ContainmentConfigView::setCurrentWallpaper(const QString &wallpaper)
pkg.setDefaultPackageRoot("plasma/wallpapers");
pkg.setPath(wallpaper);
QFile file(pkg.filePath("config", "main.xml"));
KConfigGroup cfg = m_contianmentInterface->containment()->config();
KConfigGroup cfg = m_containmentInterface->containment()->config();
cfg = KConfigGroup(&cfg, "Wallpaper");
m_currentWallpaperConfig = new ConfigPropertyMap(new Plasma::ConfigLoader(&cfg, &file), this);
}
@ -122,11 +123,11 @@ void ContainmentConfigView::setCurrentWallpaper(const QString &wallpaper)
void ContainmentConfigView::applyWallpaper()
{
m_contianmentInterface->containment()->setWallpaper(m_currentWallpaper);
m_containmentInterface->containment()->setWallpaper(m_currentWallpaper);
if (m_currentWallpaperConfig != m_contianmentInterface->wallpaperInterface()->configuration()) {
if (m_currentWallpaperConfig != m_containmentInterface->wallpaperInterface()->configuration()) {
delete m_currentWallpaperConfig;
m_currentWallpaperConfig = m_contianmentInterface->wallpaperInterface()->configuration();
m_currentWallpaperConfig = m_containmentInterface->wallpaperInterface()->configuration();
emit wallpaperConfigurationChanged();
}
}

View File

@ -51,7 +51,7 @@ Q_SIGNALS:
void wallpaperConfigurationChanged();
private:
ContainmentInterface *m_contianmentInterface;
ContainmentInterface *m_containmentInterface;
ConfigModel *m_wallpaperConfigModel;
QString m_currentWallpaper;
ConfigPropertyMap *m_currentWallpaperConfig;