summaryrefslogtreecommitdiff
Side-by-side diff
Diffstat (more/less context) (ignore whitespace changes)
-rw-r--r--core/launcher/desktop.cpp35
1 files changed, 17 insertions, 18 deletions
diff --git a/core/launcher/desktop.cpp b/core/launcher/desktop.cpp
index 552c7c3..fb10602 100644
--- a/core/launcher/desktop.cpp
+++ b/core/launcher/desktop.cpp
@@ -201,7 +201,7 @@ bool DesktopApplication::qwsEventFilter( QWSEvent *e )
will not send multiple repeats if user holds key
i.e. one shot
-
+
*/
- if (!keyRegisterList.isEmpty()) {
+ if (!keyRegisterList.isEmpty()) {
KeyRegisterList::Iterator it;
for( it = keyRegisterList.begin(); it != keyRegisterList.end(); ++it ) {
@@ -251,5 +251,5 @@ bool DesktopApplication::qwsEventFilter( QWSEvent *e )
return TRUE;
}
-// This was used for the iPAQ PowerButton
+// This was used for the iPAQ PowerButton
// See main.cpp for new KeyboardFilter
//
@@ -560,13 +560,12 @@ void Desktop::execAutoStart() {
Config cfg( "autostart" );
cfg.setGroup( "AutoStart" );
- appName = cfg.readEntry("Apps", "");
- delay = (cfg.readEntry("Delay", "0" )).toInt();
+ appName = cfg.readEntry( "Apps", "" );
+ delay = ( cfg.readEntry( "Delay", "0" ) ).toInt();
// If the time between suspend and resume was longer then the
// value saved as delay, start the app
- if ( suspendTime.secsTo(now) >= (delay*60) ) {
- QCopEnvelope e("QPE/System", "execute(QString)");
- e << QString(appName);
- } //else {
- //}
+ if ( suspendTime.secsTo( now ) >= ( delay * 60 ) && !appName.isEmpty() ) {
+ QCopEnvelope e( "QPE/System", "execute(QString)" );
+ e << QString( appName );
+ }
}
@@ -608,8 +607,8 @@ void Desktop::togglePower()
static bool excllock = false;
-
+
if ( excllock )
return;
-
+
excllock = true;
@@ -639,7 +638,7 @@ void Desktop::togglePower()
//qcopBridge->closeOpenConnections();
//qDebug("called togglePower()!!!!!!");
-
+
qApp-> processEvents ( );
-
+
excllock = false;
}
@@ -701,10 +700,10 @@ void DesktopApplication::shutdown( ShutdownImpl::Type t )
case ShutdownImpl::TerminateDesktop:
prepareForTermination(FALSE);
-
+
// This is a workaround for a Qt bug
// clipboard applet has to stop its poll timer, or Qt/E
- // will hang on quit() right before it emits aboutToQuit()
+ // will hang on quit() right before it emits aboutToQuit()
emit aboutToQuit ( );
-
+
quit();
break;
@@ -799,5 +798,5 @@ bool Desktop::eventFilter( QObject *, QEvent *ev )
if ( ke-> key ( ) == Qt::Key_F11 ) { // menu key
QWidget *active = qApp-> activeWindow ( );
-
+
if ( active && active-> isPopup ( ))
active->close();