diff options
author | Ima Mechanique <ima.mechanique@secondlife.com> | 2014-03-06 16:11:59 +0000 |
---|---|---|
committer | Ima Mechanique <ima.mechanique@secondlife.com> | 2014-03-06 16:11:59 +0000 |
commit | a2c084849f6c977c4c1c3151e0762c0137d34d0d (patch) | |
tree | 3b0b238256c4cc3972e3723d5ef134ed4a26b241 | |
parent | c8b0484034d69aa38afba14e6965f69cf8c8da24 (diff) |
storm-1831: Fixing constants not getting highlighted. Fixing ratation constant treated as string. Adding logging of unrecognised token groups.
-rwxr-xr-x | indra/llui/llkeywords.cpp | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/indra/llui/llkeywords.cpp b/indra/llui/llkeywords.cpp index c5e8f76a73..6a349f3916 100755 --- a/indra/llui/llkeywords.cpp +++ b/indra/llui/llkeywords.cpp @@ -197,7 +197,7 @@ LLColor4 LLKeywords::getColorGroup(const std::string key_in) { ColourGroup = "SyntaxLslConstantKey"; } - else if (key_in == "constants-string") + else if (key_in == "constants-rotation") { ColourGroup = "SyntaxLslConstantRotation"; } @@ -249,6 +249,10 @@ LLColor4 LLKeywords::getColorGroup(const std::string key_in) { ColourGroup = "SyntaxLslComment2Sided"; } + else + { + LL_WARNS("SyntaxLSL") << "Color key '" << key_in << "' not recognised!" << LL_ENDL; + } return LLUIColorTable::instance().getColor(ColourGroup); } @@ -334,7 +338,6 @@ void LLKeywords::processTokensGroup(LLSD& Tokens, const std::string Group) { if (outerIt->second.isMap()) { - Color = ColorGroup; mAttributes.clear(); LLSD arguments = LLSD (); LLSD::map_iterator innerIt = outerIt->second.beginMap(); @@ -360,7 +363,7 @@ void LLKeywords::processTokensGroup(LLSD& Tokens, const std::string Group) std::string tooltip = ""; if (token_type == LLKeywordToken::TT_CONSTANT) { - Color = getColorGroup(Group + "-" + getAttribute("type")); + ColorGroup = getColorGroup(Group + "-" + getAttribute("type")); tooltip = "Type: " + getAttribute("type") + ", Value: " + getAttribute("value"); } else if (token_type == LLKeywordToken::TT_EVENT) |