Skip to content

Commit 1522b88

Browse files
committed
Fix issue where CSV from computer with another locale could not be played
1 parent ddb33c1 commit 1522b88

4 files changed

Lines changed: 6 additions & 5 deletions

File tree

src/CsvPlayer.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -399,7 +399,7 @@ void CsvPlayer::updateData()
399399
// No error, calculate difference & schedule update
400400
if (!error)
401401
{
402-
auto format = "yyyy/MMM/dd/ HH:mm:ss::zzz";
402+
auto format = "yyyy/MM/dd/ HH:mm:ss::zzz";
403403
auto currDateTime = QDateTime::fromString(currTime, format);
404404
auto nextDateTime = QDateTime::fromString(nextTime, format);
405405
auto msecsToNextF = currDateTime.msecsTo(nextDateTime);

src/Export.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -249,7 +249,7 @@ void Export::writeValues()
249249

250250
// Prepend current time
251251
titles.prepend("RX Date/Time");
252-
values.prepend(dateTime.toString("yyyy/MMM/dd/ HH:mm:ss::zzz"));
252+
values.prepend(dateTime.toString("yyyy/MM/dd/ HH:mm:ss::zzz"));
253253

254254
// File not open, create it & add cell titles
255255
if (!isOpen() && exportEnabled())
@@ -333,5 +333,5 @@ void Export::updateValues()
333333

334334
// Update JSON list
335335
m_jsonList.append(
336-
qMakePair<QDateTime, QJsonObject>(QDateTime::currentDateTime(), json));
336+
qMakePair<QDateTime, QJsonObject>(QDateTime::currentDateTimeUtc(), json));
337337
}

src/SerialManager.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,8 @@ static QString SAFE_STRING(const QByteArray &data)
6565
else if (code == 127)
6666
hexString.append(" DEL ");
6767

68-
else if (code > 127) {
68+
else if (code > 127)
69+
{
6970
auto hexByte = QString::number(code, 16);
7071
while (hexByte.length() < 4)
7172
hexByte.prepend("0");

src/Translator.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -128,7 +128,7 @@ QString Translator::welcomeConsoleText() const
128128
*/
129129
QStringList Translator::availableLanguages() const
130130
{
131-
return QStringList { "English", "Español", "简体中文", "Deutsch"};
131+
return QStringList { "English", "Español", "简体中文", "Deutsch" };
132132
}
133133

134134
/**

0 commit comments

Comments
 (0)