summaryrefslogtreecommitdiff
path: root/core/opie-login/main.cpp
Side-by-side diff
Diffstat (limited to 'core/opie-login/main.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r--core/opie-login/main.cpp13
1 files changed, 5 insertions, 8 deletions
diff --git a/core/opie-login/main.cpp b/core/opie-login/main.cpp
index 718009a..df9451d 100644
--- a/core/opie-login/main.cpp
+++ b/core/opie-login/main.cpp
@@ -18,12 +18,14 @@
#include <qwindowsystem_qws.h>
#include <qfile.h>
#include "loginwindowimpl.h"
#include "calibrate.h"
+using namespace Opie;
+
int login_main ( int argc, char **argv );
void sigusr1 ( int sig );
void exit_closelog ( );
@@ -87,20 +89,20 @@ public:
m_lcd_status = true;
m_backlight_bright = -1;
m_backlight_forcedoff = false;
// Make sure the LCD is in fact on, (if opie was killed while the LCD is off it would still be off)
- ODevice::inst ( ) -> setDisplayStatus ( true );
+ ODevice::inst ( )-> setDisplayStatus ( true );
}
void restore()
{
if ( !m_lcd_status ) // We must have turned it off
ODevice::inst ( ) -> setDisplayStatus ( true );
- setBacklight ( -1 );
+ setBacklight ( -3 );
}
bool save( int level )
{
switch ( level ) {
case 0:
if ( backlight() > 1 )
@@ -186,31 +188,26 @@ int login_main ( int argc, char **argv )
app. setFont ( QFont ( "Helvetica", 10 ));
app. setStyle ( new QPEStyle ( ));
ODevice::inst ( )-> setSoftSuspend ( true );
- {
- QCopEnvelope e("QPE/System", "setBacklight(int)" );
- e << -3; // Forced on
- }
-
#if defined(QT_QWS_CASSIOPEIA) || defined(QT_QWS_IPAQ) || defined(QT_QWS_EBX)
if ( !QFile::exists ( "/etc/pointercal" )) {
// Make sure calibration widget starts on top.
Calibrate *cal = new Calibrate;
cal-> exec ( );
delete cal;
}
#endif
-
LoginScreenSaver *saver = new LoginScreenSaver;
saver-> setIntervals ( );
QWSServer::setScreenSaver ( saver );
+ saver-> restore ( );
LoginWindowImpl *lw = new LoginWindowImpl ( );
app. setMainWidget ( lw );
lw-> setGeometry ( 0, 0, app. desktop ( )-> width ( ), app. desktop ( )-> height ( ));
lw-> show ( );