use the standard color and a * to indicate if a plan is fixed or not

This commit is contained in:
Sven Czarnian
2021-12-02 19:07:03 +01:00
parent c6159144bb
commit 0fc113cd2d

View File

@@ -458,8 +458,7 @@ void PlugIn::OnGetTagItem(EuroScopePlugIn::CFlightPlan flightPlan, EuroScopePlug
/* inbound expected, but not available */ /* inbound expected, but not available */
if (this->m_inbounds.cend() == it && (true == forced || true == planExpected)) { if (this->m_inbounds.cend() == it && (true == forced || true == planExpected)) {
std::strcpy(itemString, "??:??"); std::strcpy(itemString, "* ??:??");
*colorCode = EuroScopePlugIn::TAG_COLOR_INFORMATION;
} }
/* inbound is available */ /* inbound is available */
else if (this->m_inbounds.cend() != it) { else if (this->m_inbounds.cend() != it) {
@@ -468,14 +467,9 @@ void PlugIn::OnGetTagItem(EuroScopePlugIn::CFlightPlan flightPlan, EuroScopePlug
const auto seconds = std::abs(ttl) % 60; const auto seconds = std::abs(ttl) % 60;
std::stringstream stream; std::stringstream stream;
stream << std::setw(2) << std::setfill('0') << minutes << ":" stream << (true == it->second.fixedPlan() ? "" : "* ") << std::setw(2) << std::setfill('0') << minutes << ":"
<< std::setw(2) << std::setfill('0') << seconds; << std::setw(2) << std::setfill('0') << seconds;
std::strcpy(itemString, stream.str().c_str()); std::strcpy(itemString, stream.str().c_str());
if (false == it->second.fixedPlan())
*colorCode = EuroScopePlugIn::TAG_COLOR_INFORMATION;
else
*colorCode = EuroScopePlugIn::TAG_COLOR_DEFAULT;
} }
else { else {
gsl::at(tagString, 0) = '\0'; gsl::at(tagString, 0) = '\0';