summaryrefslogtreecommitdiff
path: root/core
Unidiff
Diffstat (limited to 'core') (more/less context) (show whitespace changes)
-rw-r--r--core/apps/calibrate/main.cpp3
-rw-r--r--core/opie-login/main.cpp3
2 files changed, 4 insertions, 2 deletions
diff --git a/core/apps/calibrate/main.cpp b/core/apps/calibrate/main.cpp
index 1c295eb..ec9b5ec 100644
--- a/core/apps/calibrate/main.cpp
+++ b/core/apps/calibrate/main.cpp
@@ -24,23 +24,24 @@
24#include <qpe/qpeapplication.h> 24#include <qpe/qpeapplication.h>
25 25
26#ifdef QWS 26#ifdef QWS
27#include <qwindowsystem_qws.h> 27#include <qwindowsystem_qws.h>
28#endif 28#endif
29 29
30int main( int argc, char ** argv ) 30int main( int argc, char ** argv )
31{ 31{
32 QPEApplication a( argc, argv ); 32 QPEApplication a( argc, argv );
33 int retval = 0; 33 int retval = 0;
34 34
35#ifdef QWS 35#ifdef QWS
36 if ( QWSServer::mouseHandler() ->inherits("QCalibratedMouseHandler") ) { 36 if ( QWSServer::mouseHandler() &&
37 QWSServer::mouseHandler() ->inherits("QCalibratedMouseHandler") ) {
37#endif 38#endif
38 // Make sure calibration widget starts on top. 39 // Make sure calibration widget starts on top.
39 Calibrate cal; 40 Calibrate cal;
40 a.setMainWidget(&cal); 41 a.setMainWidget(&cal);
41 a.showMainWidget(&cal); 42 a.showMainWidget(&cal);
42 return a.exec(); 43 return a.exec();
43#ifdef QWS 44#ifdef QWS
44 } 45 }
45#endif 46#endif
46} 47}
diff --git a/core/opie-login/main.cpp b/core/opie-login/main.cpp
index 7dcb5f6..2103216 100644
--- a/core/opie-login/main.cpp
+++ b/core/opie-login/main.cpp
@@ -331,25 +331,26 @@ namespace Opie { extern int force_appearance; } // HACK to get around the force
331int login_main ( int argc, char **argv, pid_t ppid ) 331int login_main ( int argc, char **argv, pid_t ppid )
332{ 332{
333 QWSServer::setDesktopBackground( QImage() ); 333 QWSServer::setDesktopBackground( QImage() );
334 LoginApplication *app = new LoginApplication ( argc, argv, ppid ); 334 LoginApplication *app = new LoginApplication ( argc, argv, ppid );
335 335
336 Opie::force_appearance = 0; 336 Opie::force_appearance = 0;
337 337
338 app-> setFont ( QFont ( "Helvetica", 10 )); 338 app-> setFont ( QFont ( "Helvetica", 10 ));
339 app-> setStyle ( new QPEStyle ( )); 339 app-> setStyle ( new QPEStyle ( ));
340 340
341 ODevice::inst ( )-> setSoftSuspend ( true ); 341 ODevice::inst ( )-> setSoftSuspend ( true );
342 342
343 if ( QWSServer::mouseHandler() ->inherits("QCalibratedMouseHandler") ) { 343 if ( QWSServer::mouseHandler() &&
344 QWSServer::mouseHandler() ->inherits("QCalibratedMouseHandler") ) {
344 if ( !QFile::exists ( "/etc/pointercal" )) { 345 if ( !QFile::exists ( "/etc/pointercal" )) {
345 // Make sure calibration widget starts on top. 346 // Make sure calibration widget starts on top.
346 Calibrate *cal = new Calibrate; 347 Calibrate *cal = new Calibrate;
347 cal-> exec ( ); 348 cal-> exec ( );
348 delete cal; 349 delete cal;
349 } 350 }
350 } 351 }
351 352
352 LoginScreenSaver *saver = new LoginScreenSaver; 353 LoginScreenSaver *saver = new LoginScreenSaver;
353 354
354 saver-> setIntervals ( ); 355 saver-> setIntervals ( );
355 QWSServer::setScreenSaver ( saver ); 356 QWSServer::setScreenSaver ( saver );