summaryrefslogtreecommitdiffabout
path: root/microkde/kresources/configpage.cpp
authorzautrix <zautrix>2005-01-18 23:10:44 (UTC)
committer zautrix <zautrix>2005-01-18 23:10:44 (UTC)
commitc626089f47244d0c0a9ba73bcd12f42927acb28f (patch) (side-by-side diff)
tree2f0ca8591dab470ed3ddd6c2af860c2a8081db97 /microkde/kresources/configpage.cpp
parentbfb2947510c52f9c6b35c35786490f261adf30e3 (diff)
downloadkdepimpi-c626089f47244d0c0a9ba73bcd12f42927acb28f.zip
kdepimpi-c626089f47244d0c0a9ba73bcd12f42927acb28f.tar.gz
kdepimpi-c626089f47244d0c0a9ba73bcd12f42927acb28f.tar.bz2
fix
Diffstat (limited to 'microkde/kresources/configpage.cpp') (more/less context) (show whitespace changes)
-rw-r--r--microkde/kresources/configpage.cpp7
1 files changed, 2 insertions, 5 deletions
diff --git a/microkde/kresources/configpage.cpp b/microkde/kresources/configpage.cpp
index 533be51..011e47e 100644
--- a/microkde/kresources/configpage.cpp
+++ b/microkde/kresources/configpage.cpp
@@ -436,98 +436,95 @@ void ConfigPage::slotStandard()
ConfigViewItem *configItem = static_cast<ConfigViewItem*>( it );
if ( configItem->standard() )
configItem->setStandard( false );
it = it->itemBelow();
}
item->setStandard( true );
mCurrentManager->setStandardResource( item->resource() );
emit changed( true );
}
void ConfigPage::slotSelectionChanged()
{
bool state = ( mListView->currentItem() != 0 );
mRemoveButton->setEnabled( state );
mEditButton->setEnabled( state );
mStandardButton->setEnabled( state );
}
void ConfigPage::resourceAdded( Resource* resource )
{
qDebug("ConfigPage::resourceAdded : %s", resource->resourceName().latin1());
- kdDebug(5650) << "ConfigPage::resourceAdded( " << resource->resourceName() << " )" << endl;
ConfigViewItem *item = new ConfigViewItem( mListView, resource );
// FIXME: this sucks. This should be in the config file,
// or application-dependent, in which case it's always Off
item->setOn( false );
mLastItem = item;
emit changed( true );
}
void ConfigPage::resourceModified( Resource* resource )
{
qDebug("ConfigPage::resourceModified : %s", resource->resourceName().latin1());
- kdDebug(5650) << "ConfigPage::resourceModified( " << resource->resourceName() << " )" << endl;
}
void ConfigPage::resourceDeleted( Resource* resource )
{
qDebug("ConfigPage::resourceDeleted : %s", resource->resourceName().latin1());
- kdDebug(5650) << "ConfigPage::resourceDeleted( " << resource->resourceName() << " )" << endl;
}
void ConfigPage::slotItemClicked( QListViewItem *item )
{
ConfigViewItem *configItem = static_cast<ConfigViewItem *>( item );
if ( !configItem ) return;
if ( configItem->standard() && !configItem->isOn() ) {
KMessageBox::sorry( this, i18n( "You cannot deactivate the<br>standard resource. Choose<br>another standard resource first." ) );
configItem->setOn( true );
return;
}
if ( configItem->isOn() != configItem->resource()->isActive() ) {
emit changed( true );
}
}
void ConfigPage::saveResourceSettings()
{
- qDebug("ConfigPage::saveResourceSettings() begin");
+ //qDebug("ConfigPage::saveResourceSettings() begin");
if ( mCurrentManager ) {
QListViewItem *item = mListView->firstChild();
while ( item ) {
ConfigViewItem *configItem = static_cast<ConfigViewItem*>( item );
// check if standard resource
if ( configItem->standard() && !configItem->readOnly() &&
configItem->isOn() ) {
mCurrentManager->setStandardResource( configItem->resource() );
}
// check if active or passive resource
configItem->resource()->setActive( configItem->isOn() );
item = item->nextSibling();
}
mCurrentManager->writeConfig( mCurrentConfig );
if ( !mCurrentManager->standardResource() )
KMessageBox::sorry( this, i18n( "There is no valid standard resource!<br>Please select one which is neither read-only nor inactive." ) );
}
- qDebug("ConfigPage::saveResourceSettings() end");
+ //qDebug("ConfigPage::saveResourceSettings() end");
}
//US #include "configpage.moc"