Minor cleanup.
This commit is contained in:
@@ -38,8 +38,6 @@
|
|||||||
|
|
||||||
#include <fstream>
|
#include <fstream>
|
||||||
#include <boost/tokenizer.hpp>
|
#include <boost/tokenizer.hpp>
|
||||||
#include <boost/bind.hpp>
|
|
||||||
//#include <boost/spirit/include/qi.hpp>
|
|
||||||
#include <boost/spirit/include/classic_core.hpp>
|
#include <boost/spirit/include/classic_core.hpp>
|
||||||
|
|
||||||
#include "lluicolor.h"
|
#include "lluicolor.h"
|
||||||
@@ -679,7 +677,7 @@ LLXUIParser::LLXUIParser()
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
LLTrace::BlockTimerStatHandle FTM_PARSE_XUI("XUI Parsing");
|
static LLTrace::BlockTimerStatHandle FTM_PARSE_XUI("XUI Parsing");
|
||||||
const LLXMLNodePtr DUMMY_NODE = new LLXMLNode();
|
const LLXMLNodePtr DUMMY_NODE = new LLXMLNode();
|
||||||
|
|
||||||
void LLXUIParser::readXUI(LLXMLNodePtr node, LLInitParam::BaseBlock& block, const std::string& filename, bool silent)
|
void LLXUIParser::readXUI(LLXMLNodePtr node, LLInitParam::BaseBlock& block, const std::string& filename, bool silent)
|
||||||
@@ -759,7 +757,7 @@ bool LLXUIParser::readXUIImpl(LLXMLNodePtr nodep, LLInitParam::BaseBlock& block)
|
|||||||
// and if not, treat as a child element of the current node
|
// and if not, treat as a child element of the current node
|
||||||
// e.g. <button><rect left="10"/></button> will interpret <rect> as "button.rect"
|
// e.g. <button><rect left="10"/></button> will interpret <rect> as "button.rect"
|
||||||
// since there is no widget named "rect"
|
// since there is no widget named "rect"
|
||||||
if (child_name.find(".") == std::string::npos)
|
if (child_name.find('.') == std::string::npos)
|
||||||
{
|
{
|
||||||
mNameStack.push_back(std::make_pair(child_name, true));
|
mNameStack.push_back(std::make_pair(child_name, true));
|
||||||
num_tokens_pushed++;
|
num_tokens_pushed++;
|
||||||
@@ -1366,7 +1364,9 @@ struct ScopedFile
|
|||||||
};
|
};
|
||||||
LLSimpleXUIParser::LLSimpleXUIParser(LLSimpleXUIParser::element_start_callback_t element_cb)
|
LLSimpleXUIParser::LLSimpleXUIParser(LLSimpleXUIParser::element_start_callback_t element_cb)
|
||||||
: Parser(sSimpleXUIReadFuncs, sSimpleXUIWriteFuncs, sSimpleXUIInspectFuncs),
|
: Parser(sSimpleXUIReadFuncs, sSimpleXUIWriteFuncs, sSimpleXUIInspectFuncs),
|
||||||
|
mParser(nullptr),
|
||||||
mCurReadDepth(0),
|
mCurReadDepth(0),
|
||||||
|
mCurAttributeValueBegin(nullptr),
|
||||||
mElementCB(element_cb)
|
mElementCB(element_cb)
|
||||||
{
|
{
|
||||||
if (sSimpleXUIReadFuncs.empty())
|
if (sSimpleXUIReadFuncs.empty())
|
||||||
@@ -1500,7 +1500,7 @@ void LLSimpleXUIParser::startElement(const char *name, const char **atts)
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{ // compound attribute
|
{ // compound attribute
|
||||||
if (child_name.find(".") == std::string::npos)
|
if (child_name.find('.') == std::string::npos)
|
||||||
{
|
{
|
||||||
mNameStack.push_back(std::make_pair(child_name, true));
|
mNameStack.push_back(std::make_pair(child_name, true));
|
||||||
num_tokens_pushed++;
|
num_tokens_pushed++;
|
||||||
|
|||||||
@@ -31,10 +31,6 @@
|
|||||||
#include "llregistry.h"
|
#include "llregistry.h"
|
||||||
#include "llxmlnode.h"
|
#include "llxmlnode.h"
|
||||||
|
|
||||||
#ifndef BOOST_FUNCTION_HPP_INCLUDED
|
|
||||||
#include <boost/function.hpp>
|
|
||||||
#define BOOST_FUNCTION_HPP_INCLUDED
|
|
||||||
#endif
|
|
||||||
#include <iosfwd>
|
#include <iosfwd>
|
||||||
#include <stack>
|
#include <stack>
|
||||||
#include <set>
|
#include <set>
|
||||||
@@ -63,7 +59,7 @@ public:
|
|||||||
void writeXSD(const std::string& name, LLXMLNodePtr node, const LLInitParam::BaseBlock& block, const std::string& xml_namespace);
|
void writeXSD(const std::string& name, LLXMLNodePtr node, const LLInitParam::BaseBlock& block, const std::string& xml_namespace);
|
||||||
|
|
||||||
/*virtual*/ std::string getCurrentElementName() { return LLStringUtil::null; }
|
/*virtual*/ std::string getCurrentElementName() { return LLStringUtil::null; }
|
||||||
|
/*virtual*/ std::string getCurrentFileName() { return LLStringUtil::null; }
|
||||||
LLXSDWriter();
|
LLXSDWriter();
|
||||||
~LLXSDWriter();
|
~LLXSDWriter();
|
||||||
|
|
||||||
@@ -101,6 +97,7 @@ public:
|
|||||||
typedef LLInitParam::Parser::name_stack_t name_stack_t;
|
typedef LLInitParam::Parser::name_stack_t name_stack_t;
|
||||||
|
|
||||||
/*virtual*/ std::string getCurrentElementName();
|
/*virtual*/ std::string getCurrentElementName();
|
||||||
|
/*virtual*/ std::string getCurrentFileName() { return mCurFileName; }
|
||||||
/*virtual*/ void parserWarning(const std::string& message);
|
/*virtual*/ void parserWarning(const std::string& message);
|
||||||
/*virtual*/ void parserError(const std::string& message);
|
/*virtual*/ void parserError(const std::string& message);
|
||||||
|
|
||||||
@@ -199,10 +196,11 @@ public:
|
|||||||
typedef LLInitParam::Parser::name_stack_t name_stack_t;
|
typedef LLInitParam::Parser::name_stack_t name_stack_t;
|
||||||
typedef LLInitParam::BaseBlock* (*element_start_callback_t)(LLSimpleXUIParser&, const char* block_name);
|
typedef LLInitParam::BaseBlock* (*element_start_callback_t)(LLSimpleXUIParser&, const char* block_name);
|
||||||
|
|
||||||
LLSimpleXUIParser(element_start_callback_t element_cb = NULL);
|
LLSimpleXUIParser(element_start_callback_t element_cb = nullptr);
|
||||||
virtual ~LLSimpleXUIParser();
|
virtual ~LLSimpleXUIParser();
|
||||||
|
|
||||||
/*virtual*/ std::string getCurrentElementName();
|
/*virtual*/ std::string getCurrentElementName();
|
||||||
|
/*virtual*/ std::string getCurrentFileName() { return mCurFileName; }
|
||||||
/*virtual*/ void parserWarning(const std::string& message);
|
/*virtual*/ void parserWarning(const std::string& message);
|
||||||
/*virtual*/ void parserError(const std::string& message);
|
/*virtual*/ void parserError(const std::string& message);
|
||||||
|
|
||||||
|
|||||||
@@ -722,6 +722,7 @@ void settings_setup_listeners()
|
|||||||
gSavedSettings.getControl("RenderAutoMaskAlphaNonDeferred")->getSignal()->connect(boost::bind(&handleResetVertexBuffersChanged, _2));
|
gSavedSettings.getControl("RenderAutoMaskAlphaNonDeferred")->getSignal()->connect(boost::bind(&handleResetVertexBuffersChanged, _2));
|
||||||
gSavedSettings.getControl("SHUseRMSEAutoMask")->getSignal()->connect(boost::bind(&handleResetVertexBuffersChanged, _2));
|
gSavedSettings.getControl("SHUseRMSEAutoMask")->getSignal()->connect(boost::bind(&handleResetVertexBuffersChanged, _2));
|
||||||
gSavedSettings.getControl("SHAutoMaskMaxRMSE")->getSignal()->connect(boost::bind(&handleResetVertexBuffersChanged, _2));
|
gSavedSettings.getControl("SHAutoMaskMaxRMSE")->getSignal()->connect(boost::bind(&handleResetVertexBuffersChanged, _2));
|
||||||
|
gSavedSettings.getControl("SHAutoMaskMaxMid")->getSignal()->connect(boost::bind(&handleResetVertexBuffersChanged, _2));
|
||||||
gSavedSettings.getControl("SHAltBatching")->getSignal()->connect(boost::bind(&handleResetVertexBuffersChanged, _2));
|
gSavedSettings.getControl("SHAltBatching")->getSignal()->connect(boost::bind(&handleResetVertexBuffersChanged, _2));
|
||||||
gSavedSettings.getControl("RenderObjectBump")->getSignal()->connect(boost::bind(&handleResetVertexBuffersChanged, _2));
|
gSavedSettings.getControl("RenderObjectBump")->getSignal()->connect(boost::bind(&handleResetVertexBuffersChanged, _2));
|
||||||
gSavedSettings.getControl("RenderMaxVBOSize")->getSignal()->connect(boost::bind(&handleResetVertexBuffersChanged, _2));
|
gSavedSettings.getControl("RenderMaxVBOSize")->getSignal()->connect(boost::bind(&handleResetVertexBuffersChanged, _2));
|
||||||
|
|||||||
Reference in New Issue
Block a user