summaryrefslogtreecommitdiffstats
path: root/ksmserver/shutdown.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'ksmserver/shutdown.cpp')
-rw-r--r--ksmserver/shutdown.cpp17
1 files changed, 12 insertions, 5 deletions
diff --git a/ksmserver/shutdown.cpp b/ksmserver/shutdown.cpp
index 537790407..0dda6598c 100644
--- a/ksmserver/shutdown.cpp
+++ b/ksmserver/shutdown.cpp
@@ -338,9 +338,10 @@ void KSMServer::shutdown( TDEApplication::ShutdownConfirm confirm,
void KSMServer::logoutTimed( int sdtype, int sdmode, TQString bootOption )
{
- int confirmDelay;
+ int confirmDelay = 0;
TDEConfig* config = TDEGlobal::config();
+ config->reparseConfiguration(); // config may have changed in the KControl module
config->setGroup( "General" );
if ( sdtype == TDEApplication::ShutdownTypeHalt ) {
@@ -350,14 +351,20 @@ void KSMServer::logoutTimed( int sdtype, int sdmode, TQString bootOption )
confirmDelay = config->readNumEntry( "confirmRebootDelay", 31 );
}
else {
- confirmDelay = config->readNumEntry( "confirmLogoutDelay", 31 );
+ if(config->readBoolEntry("confirmLogout", true)) {
+ confirmDelay = config->readNumEntry( "confirmLogoutDelay", 31 );
+ }
}
bool result = true;
- if (confirmDelay) {
- KSMShutdownFeedback::start(); // make the screen gray
+ if (confirmDelay > 0) {
+ if(config->readBoolEntry("doFancyLogout", true)) {
+ KSMShutdownFeedback::start(); // make the screen gray
+ }
result = KSMDelayedMessageBox::showTicker( (TDEApplication::ShutdownType)sdtype, bootOption, confirmDelay );
- KSMShutdownFeedback::stop(); // make the screen become normal again
+ if(config->readBoolEntry("doFancyLogout", true)) {
+ KSMShutdownFeedback::stop(); // make the screen become normal again
+ }
}
if ( result )