summaryrefslogtreecommitdiff
authortille <tille>2002-10-19 15:33:05 (UTC)
committer tille <tille>2002-10-19 15:33:05 (UTC)
commit7a1c7fca5105427ff569f8219fb96873571a749a (patch) (side-by-side diff)
tree4c5620553e8647c72fb9a9f42eb069600f62e3ea
parent04d045931cb66c8ff13b1247e6a366ff77c36474 (diff)
downloadopie-7a1c7fca5105427ff569f8219fb96873571a749a.zip
opie-7a1c7fca5105427ff569f8219fb96873571a749a.tar.gz
opie-7a1c7fca5105427ff569f8219fb96873571a749a.tar.bz2
typo
Diffstat (more/less context) (ignore whitespace changes)
-rw-r--r--noncore/settings/netsystemtime/ntp.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/noncore/settings/netsystemtime/ntp.cpp b/noncore/settings/netsystemtime/ntp.cpp
index 9572993..fbd65a2 100644
--- a/noncore/settings/netsystemtime/ntp.cpp
+++ b/noncore/settings/netsystemtime/ntp.cpp
@@ -85,49 +85,49 @@ Ntp::~Ntp()
cfg.writeEntry( "minLookupDiff", SpinBoxMinLookupDelay->value() );
cfg.writeEntry( "ntpRefreshFreq", SpinBoxNtpDelay->value() );
}
bool Ntp::ntpDelayElapsed()
{
Config cfg("ntp",Config::User);
cfg.setGroup("lookups");
_lookupDiff = TimeConversion::toUTC(QDateTime::currentDateTime()) - cfg.readNumEntry("time",0);
return (_lookupDiff - (SpinBoxNtpDelay->value()*60)) > -60;
}
QString Ntp::getNtpServer()
{
return ComboNtpSrv->currentText();
}
void Ntp::slotRunNtp()
{
if ( !ntpDelayElapsed() )
{
switch (
QMessageBox::warning(this, tr("Run NTP?"),
tr("You asked for a delay of ")+SpinBoxNtpDelay->text()+tr(" minutes, but only ")+
- QString::number(_lookupDiff/60)+tr(" minutes elapsed since last loopup.")+
+ QString::number(_lookupDiff/60)+tr(" minutes elapsed since last lookup.")+
"<br>"+tr("Rerun NTP?"),
QMessageBox::Ok,QMessageBox::Cancel)
) {
case QMessageBox::Ok: break;
case QMessageBox::Cancel: return;
default: return;
}
}
TextLabelStartTime->setText(QDateTime::currentDateTime().toString());
ntpOutPut( tr("Running:")+"\nntpdate "+getNtpServer() );
ntpProcess->clearArguments();
*ntpProcess << "ntpdate" << getNtpServer();
bool ret = ntpProcess->start(OProcess::NotifyOnExit,OProcess::AllOutput);
if ( !ret ) {
qDebug("Error while executing ntpdate");
ntpOutPut( tr("Error while executing ntpdate"));
}
}
void Ntp::getNtpOutput(OProcess *proc, char *buffer, int buflen)
{
QString lineStr, lineStrOld;
lineStr = buffer;