summaryrefslogtreecommitdiff
authortille <tille>2002-10-31 21:15:33 (UTC)
committer tille <tille>2002-10-31 21:15:33 (UTC)
commit9453519728734e52aac9ea81a4ca3a867f013bda (patch) (unidiff)
treefc5a36cd1f01401f580a76d86fd087e0e41440cb
parent00a211621ea11ed73d803a3e52c09ce1e76864eb (diff)
downloadopie-9453519728734e52aac9ea81a4ca3a867f013bda.zip
opie-9453519728734e52aac9ea81a4ca3a867f013bda.tar.gz
opie-9453519728734e52aac9ea81a4ca3a867f013bda.tar.bz2
remove netsystemtime
Diffstat (more/less context) (ignore whitespace changes)
-rw-r--r--core/launcher/main.cpp7
1 files changed, 1 insertions, 6 deletions
diff --git a/core/launcher/main.cpp b/core/launcher/main.cpp
index 715239f..b517c7d 100644
--- a/core/launcher/main.cpp
+++ b/core/launcher/main.cpp
@@ -99,54 +99,49 @@ int initApplication( int argc, char ** argv )
99 QObject::connect( &a, SIGNAL(email()), d, SLOT(raiseEmail()) ); 99 QObject::connect( &a, SIGNAL(email()), d, SLOT(raiseEmail()) );
100 QObject::connect( &a, SIGNAL(power()), d, SLOT(togglePower()) ); 100 QObject::connect( &a, SIGNAL(power()), d, SLOT(togglePower()) );
101 QObject::connect( &a, SIGNAL(backlight()), d, SLOT(toggleLight()) ); 101 QObject::connect( &a, SIGNAL(backlight()), d, SLOT(toggleLight()) );
102 QObject::connect( &a, SIGNAL(symbol()), d, SLOT(toggleSymbolInput()) ); 102 QObject::connect( &a, SIGNAL(symbol()), d, SLOT(toggleSymbolInput()) );
103 QObject::connect( &a, SIGNAL(numLockStateToggle()), d, SLOT(toggleNumLockState()) ); 103 QObject::connect( &a, SIGNAL(numLockStateToggle()), d, SLOT(toggleNumLockState()) );
104 QObject::connect( &a, SIGNAL(capsLockStateToggle()), d, SLOT(toggleCapsLockState()) ); 104 QObject::connect( &a, SIGNAL(capsLockStateToggle()), d, SLOT(toggleCapsLockState()) );
105 QObject::connect( &a, SIGNAL(prepareForRestart()), d, SLOT(terminateServers()) ); 105 QObject::connect( &a, SIGNAL(prepareForRestart()), d, SLOT(terminateServers()) );
106 106
107 (void)new SysFileMonitor(d); 107 (void)new SysFileMonitor(d);
108 Network::createServer(d); 108 Network::createServer(d);
109 109
110#if defined(QT_QWS_CASSIOPEIA) || defined(QT_QWS_IPAQ) || defined(QT_QWS_EBX) 110#if defined(QT_QWS_CASSIOPEIA) || defined(QT_QWS_IPAQ) || defined(QT_QWS_EBX)
111 if ( !QFile::exists( "/etc/pointercal" ) ) { 111 if ( !QFile::exists( "/etc/pointercal" ) ) {
112 // Make sure calibration widget starts on top. 112 // Make sure calibration widget starts on top.
113 Calibrate *cal = new Calibrate; 113 Calibrate *cal = new Calibrate;
114 cal->exec(); 114 cal->exec();
115 delete cal; 115 delete cal;
116 } 116 }
117#endif 117#endif
118 118
119 d->show(); 119 d->show();
120 120
121 if ( QDate::currentDate ( ). year ( ) < 2000 ) { 121 if ( QDate::currentDate ( ). year ( ) < 2000 ) {
122 if ( QMessageBox::information ( 0, DesktopApplication::tr( "Information" ), DesktopApplication::tr( "<p>The system date doesn't seem to be valid.\n(%1)</p><p>Do you want to correct the clock ?</p>" ). arg( TimeString::dateString ( QDate::currentDate ( ))), QMessageBox::Yes, QMessageBox::No ) == QMessageBox::Yes ) { 122 if ( QMessageBox::information ( 0, DesktopApplication::tr( "Information" ), DesktopApplication::tr( "<p>The system date doesn't seem to be valid.\n(%1)</p><p>Do you want to correct the clock ?</p>" ). arg( TimeString::dateString ( QDate::currentDate ( ))), QMessageBox::Yes, QMessageBox::No ) == QMessageBox::Yes ) {
123 QCString app; 123 QCopEnvelope e ( "QPE/Application/systemtime", "setDocument(QString)" );
124 if ( QFile::exists ( QPEApplication::qpeDir ( ) + "/bin/netsystemtime" ))
125 app = "netsystemtime";
126 else
127 app = "systemtime";
128 QCopEnvelope e ( "QPE/Application/" + app, "setDocument(QString)" );
129 e << QString ( ); 124 e << QString ( );
130 } 125 }
131 } 126 }
132 127
133 int rv = a.exec(); 128 int rv = a.exec();
134 129
135 delete d; 130 delete d;
136 131
137 ODevice::inst ( )-> setSoftSuspend ( false ); 132 ODevice::inst ( )-> setSoftSuspend ( false );
138 133
139 return rv; 134 return rv;
140} 135}
141 136
142static const char *pidfile_path = "/var/run/opie.pid"; 137static const char *pidfile_path = "/var/run/opie.pid";
143 138
144void create_pidfile ( ) 139void create_pidfile ( )
145{ 140{
146 FILE *f; 141 FILE *f;
147 142
148 if (( f = ::fopen ( pidfile_path, "w" ))) { 143 if (( f = ::fopen ( pidfile_path, "w" ))) {
149 ::fprintf ( f, "%d", getpid ( )); 144 ::fprintf ( f, "%d", getpid ( ));
150 ::fclose ( f ); 145 ::fclose ( f );
151 } 146 }
152} 147}