mirror of
https://github.com/swift-project/pilotclient.git
synced 2026-04-02 15:15:50 +08:00
Simplify (remove duplicate spaces) text messages
This commit is contained in:
@@ -264,10 +264,10 @@ namespace BlackCore
|
||||
CLogMessage(this).validationError("Incorrect message");
|
||||
return false;
|
||||
}
|
||||
QString receiver = parser.part(1).trimmed(); // receiver
|
||||
|
||||
// set receiver
|
||||
CSimulatedAircraft ownAircraft(this->getIContextOwnAircraft()->getOwnAircraft());
|
||||
const QString receiver = parser.part(1).trimmed(); // receiver
|
||||
const CSimulatedAircraft ownAircraft(this->getIContextOwnAircraft()->getOwnAircraft());
|
||||
if (ownAircraft.getCallsign().isEmpty())
|
||||
{
|
||||
CLogMessage(this).validationError("No own callsign");
|
||||
|
||||
@@ -1108,7 +1108,7 @@ namespace BlackCore
|
||||
// Wait maximum 3 seconds for the reply and release as text message after
|
||||
if (pendingQuery.m_queryTime.secsTo(QDateTime::currentDateTimeUtc()) > 3)
|
||||
{
|
||||
QString atisMessage(pendingQuery.m_atisMessage.join(QChar::LineFeed));
|
||||
const QString atisMessage(pendingQuery.m_atisMessage.join(QChar::LineFeed));
|
||||
CTextMessage tm(atisMessage, sender, receiver);
|
||||
tm.setCurrentUtcTime();
|
||||
consolidateTextMessage(tm);
|
||||
|
||||
Reference in New Issue
Block a user