summaryrefslogtreecommitdiff
Side-by-side diff
Diffstat (more/less context) (ignore whitespace changes)
-rw-r--r--noncore/settings/netsystemtime/ntp.cpp3
1 files changed, 1 insertions, 2 deletions
diff --git a/noncore/settings/netsystemtime/ntp.cpp b/noncore/settings/netsystemtime/ntp.cpp
index bcbf7a1..b2f5332 100644
--- a/noncore/settings/netsystemtime/ntp.cpp
+++ b/noncore/settings/netsystemtime/ntp.cpp
@@ -245,38 +245,37 @@ void Ntp::slotCheckNtp(int i)
TextLabelMainPredTime->hide();
ButtonSetTime->setText( tr("Get time from network") );
connect( ButtonSetTime, SIGNAL(clicked()), SLOT(slotRunNtp()) );
if ( ntpDelayElapsed() )
{
slotRunNtp();
disconnect(ntpTimer, SIGNAL( timeout() ), this, SLOT(slotProbeNtpServer()) );
connect(ntpTimer, SIGNAL( timeout() ), SLOT(slotRunNtp()) );
}else{
disconnect(ntpTimer, SIGNAL( timeout() ), this, SLOT(slotRunNtp()) );
connect(ntpTimer, SIGNAL( timeout() ), SLOT(slotProbeNtpServer()) );
}
}else{
preditctTime();
ButtonSetTime->setText( tr("Set predicted time") );
if (i>0)ntpOutPut(tr("Could not connect to server ")+getNtpServer());
connect( ButtonSetTime, SIGNAL(clicked()), SLOT(setPredictTime()) );
connect( ntpTimer, SIGNAL( timeout() ), SLOT(slotProbeNtpServer()) );
}
// ntpTimer->start(SpinBoxNtpDelay->value()*1000*60);
}
void Ntp::slotProbeNtpServer()
{
- if ( ntpDelayElapsed() )
- ntpSock->connectToHost( getNtpServer() ,123);
+ ntpSock->connectToHost( getNtpServer() ,123);
}
void Ntp::slotNtpDelayChanged(int delay)
{
ntpTimer->changeInterval( delay*1000*60 );
}
void Ntp::ntpOutPut(QString out)
{
MultiLineEditntpOutPut->append(out);
MultiLineEditntpOutPut->setCursorPosition(MultiLineEditntpOutPut->numLines() + 1,0,FALSE);
}