X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=src%2FInstrumentation%2FNavDisplay.cxx;h=30be600fdf838d5aee7fc2591b3acd224d730b2f;hb=0b9adf8854398461333eba43df18fa2f5c8231a1;hp=9c84efd4d05336f80f5abc698d1c4af9cfad21f4;hpb=caf0138ab35b03bbe7bf367ff2222d0a31be3157;p=flightgear.git diff --git a/src/Instrumentation/NavDisplay.cxx b/src/Instrumentation/NavDisplay.cxx index 9c84efd4d..30be600fd 100644 --- a/src/Instrumentation/NavDisplay.cxx +++ b/src/Instrumentation/NavDisplay.cxx @@ -861,7 +861,7 @@ void NavDisplay::addSymbolToScene(SymbolInstance* sym) addLine(sym->pos, sym->endPos, def->lineColor); } - if (!def->hasText) { + if (!def->hasText || !def->textEnabled) { return; } @@ -1114,21 +1114,6 @@ bool NavDisplay::anyRuleForType(const string& type) const return false; } -bool NavDisplay::anyRuleMatches(const string& type, const string_set& states) const -{ - BOOST_FOREACH(SymbolRule* r, _rules) { - if (!r->enabled || (r->type != type)) { - continue; - } - - if (r->matches(states)) { - return true; - } - } // of rules iteration - - return false; -} - void NavDisplay::findRules(const string& type, const string_set& states, SymbolRuleVector& rules) { BOOST_FOREACH(SymbolRule* candidate, _rules) { @@ -1152,6 +1137,7 @@ bool NavDisplay::isPositionedShown(FGPositioned* pos) void NavDisplay::isPositionedShownInner(FGPositioned* pos, SymbolRuleVector& rules) { string type = FGPositioned::nameForType(pos->type()); + boost::to_lower(type); if (!anyRuleForType(type)) { return; // not diplayed at all, we're done }