Skip to content

Commit

Permalink
QT6.8: Migration from QDateTime constructor Qt::UTC to QTimeZone::utc()
Browse files Browse the repository at this point in the history
  • Loading branch information
foldynl committed Dec 11, 2024
1 parent ac4ef96 commit b42f8dc
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions logformat/AdiFormat.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -470,8 +470,8 @@ void AdiFormat::contactFields2SQLRecord(QMap<QString, QVariant> &contact, QSqlRe
time_on = time_off;
}

QDateTime start_time(date_on, time_on, Qt::UTC);
QDateTime end_time(date_off, time_off, Qt::UTC);
QDateTime start_time(date_on, time_on, QTimeZone::utc());
QDateTime end_time(date_off, time_off, QTimeZone::utc());

if ( end_time < start_time )
{
Expand Down
2 changes: 1 addition & 1 deletion ui/NewContactWidget.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1593,7 +1593,7 @@ void NewContactWidget::saveContact()
if ( !isQSOTimeStarted() )
updateTime();

QDateTime start = QDateTime(ui->dateEdit->date(), ui->timeOnEdit->time(), Qt::UTC);
QDateTime start = QDateTime(ui->dateEdit->date(), ui->timeOnEdit->time(), QTimeZone::utc());
QDateTime end = ( isManualEnterMode ) ? start.addSecs(QTime(0,0).secsTo(ui->qsoDurationEdit->time()))
: timeOff;

Expand Down

0 comments on commit b42f8dc

Please sign in to comment.