author | zecke <zecke> | 2004-03-14 16:01:52 (UTC) |
---|---|---|
committer | zecke <zecke> | 2004-03-14 16:01:52 (UTC) |
commit | f12af18557c8f376f0c6c30e80a85737ff6c592e (patch) (side-by-side diff) | |
tree | d60806f34f4ff6af82491579e80c9ef72cd4071e /noncore/settings/netsystemtime | |
parent | 13aeeabab5f2a6262b33de83cc9559a49365e325 (diff) | |
download | opie-f12af18557c8f376f0c6c30e80a85737ff6c592e.zip opie-f12af18557c8f376f0c6c30e80a85737ff6c592e.tar.gz opie-f12af18557c8f376f0c6c30e80a85737ff6c592e.tar.bz2 |
Make use of ODP
Diffstat (limited to 'noncore/settings/netsystemtime') (more/less context) (ignore whitespace changes)
-rw-r--r-- | noncore/settings/netsystemtime/main.cpp | 1 | ||||
-rw-r--r-- | noncore/settings/netsystemtime/mainwindow.cpp | 6 | ||||
-rw-r--r-- | noncore/settings/netsystemtime/mainwindow.h | 9 |
3 files changed, 9 insertions, 7 deletions
diff --git a/noncore/settings/netsystemtime/main.cpp b/noncore/settings/netsystemtime/main.cpp index 4a2d17c..dbcdc17 100644 --- a/noncore/settings/netsystemtime/main.cpp +++ b/noncore/settings/netsystemtime/main.cpp @@ -25,9 +25,10 @@ Boston, MA 02111-1307, USA. */ #include "mainwindow.h" #include <opie2/oapplicationfactory.h> +using namespace Opie::Core; OPIE_EXPORT_APP( OApplicationFactory<MainWindow> ) diff --git a/noncore/settings/netsystemtime/mainwindow.cpp b/noncore/settings/netsystemtime/mainwindow.cpp index c995d6e..ba96f33 100644 --- a/noncore/settings/netsystemtime/mainwindow.cpp +++ b/noncore/settings/netsystemtime/mainwindow.cpp @@ -43,16 +43,18 @@ #endif #include <qlayout.h> #include <qmessagebox.h> #include <qsocket.h> #include <qstring.h> #include <qtimer.h> +using namespace Opie::Ui; +using namespace Opie::Core; MainWindow::MainWindow( QWidget *parent , const char *name, bool modal, WFlags f ) : QDialog( 0x0, 0x0, TRUE, 0 ) { setCaption( tr( "SystemTime" ) ); QVBoxLayout *layout = new QVBoxLayout( this ); layout->setMargin( 2 ); layout->setSpacing( 4 ); @@ -183,19 +185,19 @@ void MainWindow::runNTP() QString output = tr( "Running:\nntpdate " ); output.append( srv ); ntpTab->addNtpOutput( output ); } if ( !ntpProcess ) { ntpProcess = new OProcess(); - connect( ntpProcess, SIGNAL(receivedStdout(OProcess*,char*,int)), + connect( ntpProcess, SIGNAL(receivedStdout(Opie::Core::OProcess*,char*,int)), this, SLOT(slotNtpOutput(OProcess*,char*,int)) ); - connect( ntpProcess, SIGNAL(processExited(OProcess*)), + connect( ntpProcess, SIGNAL(processExited(Opie::Core::OProcess*)), this, SLOT(slotNtpFinished(OProcess*)) ); } else ntpProcess->clearArguments(); *ntpProcess << "ntpdate" << srv; bool ret = ntpProcess->start( OProcess::NotifyOnExit, OProcess::AllOutput ); diff --git a/noncore/settings/netsystemtime/mainwindow.h b/noncore/settings/netsystemtime/mainwindow.h index d4a9713..8701803 100644 --- a/noncore/settings/netsystemtime/mainwindow.h +++ b/noncore/settings/netsystemtime/mainwindow.h @@ -35,17 +35,16 @@ #include <opie2/otabwidget.h> class TimeTabWidget; class FormatTabWidget; class SettingsTabWidget; class NTPTabWidget; class PredictTabWidget; -using Opie::OTabWidget; class QDateTime; class QSocket; class QTimer; class MainWindow : public QDialog { Q_OBJECT @@ -55,28 +54,28 @@ public: ~MainWindow(); static QString appName() { return QString::fromLatin1("systemtime"); } protected: void accept(); void reject(); private: - OTabWidget *mainWidget; + Opie::Ui::OTabWidget *mainWidget; TimeTabWidget *timeTab; FormatTabWidget *formatTab; SettingsTabWidget *settingsTab; NTPTabWidget *ntpTab; PredictTabWidget *predictTab; bool ntpTabEnabled; bool predictTabEnabled; - OProcess *ntpProcess; + Opie::Core::OProcess *ntpProcess; QTimer *ntpTimer; QSocket *ntpSock; int ntpDelay; bool ntpInteractive; QString ntpOutput; int _lookupDiff; void runNTP(); @@ -85,15 +84,15 @@ private: private slots: void slotSetTime( const QDateTime & ); void slotQCopReceive( const QCString &, const QByteArray & ); void slotDisplayNTPTab( bool ); void slotDisplayPredictTab( bool ); void slotGetNTPTime(); void slotTimerGetNTPTime(); void slotProbeNTPServer(); - void slotNtpOutput( OProcess *, char *, int ); - void slotNtpFinished( OProcess* ); + void slotNtpOutput( Opie::Core::OProcess *, char *, int ); + void slotNtpFinished( Opie::Core::OProcess* ); void slotNTPDelayChanged( int ); void slotCheckNtp( int ); }; #endif |