mirror of
https://github.com/f4exb/sdrangel.git
synced 2026-06-05 07:24:44 -04:00
Windows: MSVC2017: changes in sdrbase (1)
This commit is contained in:
@@ -39,24 +39,24 @@ void CommandOutputDialog::refresh()
|
||||
ui->commandText->setText(m_command.getLastProcessCommandLine());
|
||||
ui->processPid->setText(QString("%1").arg(m_command.getLastProcessPid()));
|
||||
|
||||
if (m_command.getLastProcessStartTimestamp().tv_sec == 0) {
|
||||
if (m_command.getLastProcessStartTimestamp() == 0) {
|
||||
ui->startTime->setText(("..."));
|
||||
}
|
||||
else
|
||||
{
|
||||
struct timeval tv = m_command.getLastProcessStartTimestamp();
|
||||
QDateTime dt = QDateTime::fromMSecsSinceEpoch(tv.tv_sec * 1000LL + tv.tv_usec / 1000LL);
|
||||
clock_t tv = m_command.getLastProcessStartTimestamp();
|
||||
QDateTime dt = QDateTime::fromMSecsSinceEpoch((tv * 1000LL) / CLOCKS_PER_SEC);
|
||||
QString dateStr = dt.toString("yyyy-MM-dd HH:mm:ss.zzz");
|
||||
ui->startTime->setText(dateStr);
|
||||
}
|
||||
|
||||
if (m_command.getLastProcessFinishTimestamp().tv_sec == 0) {
|
||||
if (m_command.getLastProcessFinishTimestamp() == 0) {
|
||||
ui->endTime->setText(("..."));
|
||||
}
|
||||
else
|
||||
{
|
||||
struct timeval tv = m_command.getLastProcessFinishTimestamp();
|
||||
QDateTime dt = QDateTime::fromMSecsSinceEpoch(tv.tv_sec * 1000LL + tv.tv_usec / 1000LL);
|
||||
clock_t tv = m_command.getLastProcessFinishTimestamp();
|
||||
QDateTime dt = QDateTime::fromMSecsSinceEpoch((tv * 1000LL) / CLOCKS_PER_SEC);
|
||||
QString dateStr = dt.toString("yyyy-MM-dd HH:mm:ss.zzz");
|
||||
ui->endTime->setText(dateStr);
|
||||
}
|
||||
@@ -64,7 +64,7 @@ void CommandOutputDialog::refresh()
|
||||
ui->runningState->setChecked(m_command.getLastProcessState() == QProcess::Running);
|
||||
QProcess::ProcessError processError;
|
||||
|
||||
if (m_command.getLastProcessStartTimestamp().tv_sec == 0) // not started
|
||||
if (m_command.getLastProcessStartTimestamp() == 0) // not started
|
||||
{
|
||||
ui->errorText->setText("...");
|
||||
ui->exitCode->setText("-");
|
||||
|
||||
Reference in New Issue
Block a user