Ref T298, better string handling/messages

This commit is contained in:
Klaus Basan
2018-08-07 19:45:30 +02:00
parent d310c9c843
commit 68607a3cb8
5 changed files with 51 additions and 50 deletions

View File

@@ -863,10 +863,12 @@ namespace BlackMisc
const int score = model.calculateScore(remoteModel, preferColorLiveries, log ? &subMsgs : nullptr);
if (ignoreZeroScores && score < 1) { continue; }
CMatchingUtils::addLogDetailsToList(log, remoteModel.getCallsign(), QString("--- Calculating #%1 '%2'---").arg(c++).arg(model.getModelStringAndDbKey()));
static const QString bMsg("--- Calculating #%1 '%2'---");
static const QString eMsg("--- End calculating #%1 ---");
CMatchingUtils::addLogDetailsToList(log, remoteModel.getCallsign(), bMsg.arg(c).arg(model.getModelStringAndDbKey()));
if (log) { log->push_back(subMsgs); }
CMatchingUtils::addLogDetailsToList(log, remoteModel.getCallsign(), QString("--- End calculating #%1 ---").arg(c));
CMatchingUtils::addLogDetailsToList(log, remoteModel.getCallsign(), eMsg.arg(c));
c++;
scoreMap.insertMulti(score, model);
}
CMatchingUtils::addLogDetailsToList(log, remoteModel.getCallsign(), QStringLiteral("--- End scoring ---"));