diff options
author | Timothy Pearson <kb9vqf@pearsoncomputing.net> | 2012-11-19 17:14:29 -0600 |
---|---|---|
committer | Slávek Banko <slavek.banko@axis.cz> | 2012-11-20 05:01:13 +0100 |
commit | 5eb1e8bfcf94ceb6c23ccf7d341daf5aebaa59a4 (patch) | |
tree | 824ba2f3e1cc92c7d7a3ffb5ac48008004ae2842 | |
parent | 339bb1ff189da09bdeb512e6eb9beb03b212b9c5 (diff) | |
download | tdebase-5eb1e8bfcf94ceb6c23ccf7d341daf5aebaa59a4.tar.gz tdebase-5eb1e8bfcf94ceb6c23ccf7d341daf5aebaa59a4.zip |
Attempt to work around issue described in Bug 1288
(cherry picked from commit 4de72a5ddd70b37c4e077c53dd60d1a8e4da7466)
-rw-r--r-- | kdesktop/lock/lockprocess.cc | 15 |
1 files changed, 13 insertions, 2 deletions
diff --git a/kdesktop/lock/lockprocess.cc b/kdesktop/lock/lockprocess.cc index ab8af7596..73feba2c0 100644 --- a/kdesktop/lock/lockprocess.cc +++ b/kdesktop/lock/lockprocess.cc @@ -58,6 +58,7 @@ #include <tqimage.h> #include <tqregexp.h> #include <tqpainter.h> +#include <tqeventloop.h> #include <tqdatetime.h> @@ -1303,9 +1304,19 @@ bool LockProcess::startSaver() connect( mEnsureScreenHiddenTimer, TQT_SIGNAL(timeout()), this, TQT_SLOT(slotForcePaintBackground()) ); mEnsureScreenHiddenTimer->start(DESKTOP_WALLPAPER_OBTAIN_TIMEOUT_MS, true); } - + + int exitTimer = 0; while ((backingPixmap.isNull()) && (mEnsureScreenHiddenTimer->isActive())) { - kapp->processEvents(); + kapp->eventLoop()->processEvents(TQEventLoop::ExcludeUserInput); + + // HACK + // Work around an issue with the underlying system whereby the TQTimer sometimes fails to time out! + // This issue was reported in Bug #1288 + usleep(100); + exitTimer++; + if (exitTimer > (DESKTOP_WALLPAPER_OBTAIN_TIMEOUT_MS*10)) { + break; + } } } } |