[prev in list] [next in list] [prev in thread] [next in thread]
List: kde-commits
Subject: KDE/kdebase/workspace/systemsettings
From: Ben Cooksley <sourtooth () gmail ! com>
Date: 2009-05-19 20:14:23
Message-ID: 1242764063.912638.31221.nullmailer () svn ! kde ! org
[Download RAW message or body]
SVN commit 970241 by bcooksley:
Fix module view so the default and apply buttons activate again
M +0 -2 classic/ClassicMode.cpp
M +7 -2 core/ModuleView.cpp
M +1 -0 core/ModuleView.h
--- trunk/KDE/kdebase/workspace/systemsettings/classic/ClassicMode.cpp #970240:970241
@@ -27,7 +27,6 @@
#include <QStackedWidget>
#include <QAbstractItemModel>
-#include <KDebug>
#include <KDialog>
#include <KAboutData>
#include <KCModuleInfo>
@@ -166,7 +165,6 @@
void ClassicMode::moduleLoaded()
{
- kDebug();
d->stackedWidget->setCurrentWidget( d->moduleView );
}
--- trunk/KDE/kdebase/workspace/systemsettings/core/ModuleView.cpp #970240:970241
@@ -136,7 +136,7 @@
foreach ( KCModuleInfo *module, modules ) {
addModule(module);
}
- emit moduleChanged( false );
+ stateChanged();
}
void ModuleView::addModule( KCModuleInfo *module )
@@ -172,7 +172,7 @@
page->setIcon( KIcon( module->service()->icon() ) );
page->setHeader( module->service()->comment() );
// Allow it to signal properly
- connect( moduleProxy, SIGNAL(changed(bool)), this, SIGNAL(moduleChanged(bool)));
+ connect( moduleProxy, SIGNAL(changed(bool)), this, SLOT(stateChanged()));
// Set it to be shown and signal that
d->mPageWidget->addPage( page );
d->mPages.insert( page, moduleProxy );
@@ -291,6 +291,11 @@
}
d->mPageWidget->blockSignals(false);
// We need to get the state of the now active module
+ stateChanged();
+}
+
+void ModuleView::stateChanged()
+{
KCModuleProxy * activeModule = d->mPages.value( d->mPageWidget->currentPage() );
bool change = false;
if( activeModule ) {
--- trunk/KDE/kdebase/workspace/systemsettings/core/ModuleView.h #970240:970241
@@ -135,6 +135,7 @@
private Q_SLOTS:
void activeModuleChanged( KPageWidgetItem* current, KPageWidgetItem* previous);
void updateButtons();
+ void stateChanged();
Q_SIGNALS:
/**
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic