Trolltech Home | Qtopia-interest Home | Recent Threads | All Threads | Author | Date
All threads index page 1

Qtopia-interest Archive, February 2008
[PATCH] Make neosuspend.cpp compilable on Qt/X11


Message 1 in thread

From 71ada555240172032c6e0b0ee6496d09c8e21651 Mon Sep 17 00:00:00 2001
From: Holger Freyther <zecke@xxxxxxxxxxx>
Date: Tue, 19 Feb 2008 15:08:38 +0100
Subject: [PATCH] Make the neosuspend.cpp compilable on X11:
     Guard the QWS usage with #ifdef Q_WS_QWS

---
 devices/ficgta01/server/neosuspend.cpp |    7 ++++++-
 1 files changed, 6 insertions(+), 1 deletions(-)

diff --git a/devices/ficgta01/server/neosuspend.cpp 
b/devices/ficgta01/server/neosuspend.cpp
index 13624e0..51a2232 100644
--- a/devices/ficgta01/server/neosuspend.cpp
+++ b/devices/ficgta01/server/neosuspend.cpp
@@ -19,7 +19,6 @@
 **
 ****************************************************************************/
 
-#include <qwindowsystem_qws.h>
 
 #include <QtopiaIpcAdaptor>
 #include <QtopiaIpcEnvelope>
@@ -33,6 +32,10 @@
 
 #include <qvaluespace.h>
 
+#ifdef Q_WS_QWS
+#include <qwindowsystem_qws.h>
+#endif
+
 class NeoSuspend : public SystemSuspendHandler
 {
 public:
@@ -96,7 +99,9 @@ bool NeoSuspend::wake()
     //processEvents to give Qt a chance to sync its internal timer with
     //the hw clock
     QCoreApplication::processEvents(QEventLoop::ExcludeUserInputEvents);
+#ifdef Q_WS_QWS
     QWSServer::screenSaverActivate( false );
+#endif
     {
         QtopiaIpcEnvelope("QPE/Card", "mtabChanged()" ); // might have 
changed while asleep
         QtopiaServiceRequest e("QtopiaPowerManager", "setBacklight(int)");
-- 
 [ signature omitted ]