summaryrefslogtreecommitdiff
path: root/indra/newview
diff options
context:
space:
mode:
Diffstat (limited to 'indra/newview')
-rwxr-xr-xindra/newview/app_settings/keywords_lsl_default.xml2
-rwxr-xr-xindra/newview/llpreviewscript.cpp4
-rwxr-xr-xindra/newview/llpreviewscript.h2
-rw-r--r--indra/newview/llscripteditor.cpp2
-rw-r--r--indra/newview/llsyntaxid.cpp38
-rw-r--r--indra/newview/llsyntaxid.h24
6 files changed, 25 insertions, 47 deletions
diff --git a/indra/newview/app_settings/keywords_lsl_default.xml b/indra/newview/app_settings/keywords_lsl_default.xml
index 53a89f0f09..02823136ee 100755
--- a/indra/newview/app_settings/keywords_lsl_default.xml
+++ b/indra/newview/app_settings/keywords_lsl_default.xml
@@ -21,7 +21,7 @@
<key>for</key>
<map>
<key>tooltip</key>
- <string>for loop\nfor (&lt;initialiser&gt;; &lt;condition&gt;; &lt;post-iteration-statement&gt;)\n{ ...\n}</string>
+ <string>for loop\nfor (&lt;initializer&gt;; &lt;condition&gt;; &lt;post-iteration-statement&gt;)\n{ ...\n}</string>
</map>
<key>if</key>
<map>
diff --git a/indra/newview/llpreviewscript.cpp b/indra/newview/llpreviewscript.cpp
index fae4aeb7bc..73dc19dd81 100755
--- a/indra/newview/llpreviewscript.cpp
+++ b/indra/newview/llpreviewscript.cpp
@@ -412,7 +412,7 @@ BOOL LLScriptEdCore::postBuild()
LLSyntaxIdLSL::getInstance()->addFileFetchedCallback(boost::bind(&LLScriptEdCore::processKeywords, this));
// Intialise keyword highlighting for the current simulator's version of LSL
- LLSyntaxIdLSL::getInstance()->initialise();
+ LLSyntaxIdLSL::getInstance()->initialize();
if (LLSyntaxIdLSL::getInstance()->isDifferentVersion())
{
@@ -440,7 +440,7 @@ void LLScriptEdCore::updateKeywords()
void LLScriptEdCore::processLoaded()
{
- LLSyntaxIdLSL::getInstance()->initialise();
+ LLSyntaxIdLSL::getInstance()->initialize();
if (LLSyntaxIdLSL::getInstance()->isLoaded())
{
processKeywords();
diff --git a/indra/newview/llpreviewscript.h b/indra/newview/llpreviewscript.h
index 966c149d3d..69a72325fc 100755
--- a/indra/newview/llpreviewscript.h
+++ b/indra/newview/llpreviewscript.h
@@ -77,7 +77,7 @@ protected:
public:
~LLScriptEdCore();
- void initialiseKeywords();
+ void initializeKeywords();
void initMenu();
void processKeywords();
void processLoaded();
diff --git a/indra/newview/llscripteditor.cpp b/indra/newview/llscripteditor.cpp
index 5d87f7ba0c..869368e72c 100644
--- a/indra/newview/llscripteditor.cpp
+++ b/indra/newview/llscripteditor.cpp
@@ -46,7 +46,7 @@ LLScriptEditor::LLScriptEditor(const Params& p)
void LLScriptEditor::initKeywords()
{
- mKeywords.initialise(LLSyntaxIdLSL::getInstance()->getKeywordsXML());
+ mKeywords.initialize(LLSyntaxIdLSL::getInstance()->getKeywordsXML());
}
static LLFastTimer::DeclareTimer FTM_SYNTAX_HIGHLIGHTING("Syntax Highlighting");
diff --git a/indra/newview/llsyntaxid.cpp b/indra/newview/llsyntaxid.cpp
index 3f726fa8b5..3582ac024d 100644
--- a/indra/newview/llsyntaxid.cpp
+++ b/indra/newview/llsyntaxid.cpp
@@ -70,7 +70,7 @@ void fetchKeywordsFileResponder::result(const LLSD& content_ref)
<< "Supported verson of syntax file." << LL_ENDL;
LLSyntaxIdLSL::setKeywordsXml(content_ref);
- LLSyntaxIdLSL::sInitialised = true;
+ LLSyntaxIdLSL::sInitialized = true;
LLSyntaxIdLSL::sLoaded = true;
LLSyntaxIdLSL::sLoadFailed = false;
@@ -117,12 +117,12 @@ const std::string LLSyntaxIdLSL::CAPABILITY_NAME = "LSLSyntax";
const std::string LLSyntaxIdLSL::FILENAME_DEFAULT = "keywords_lsl_default.xml";
const std::string LLSyntaxIdLSL::SIMULATOR_FEATURE = "LSLSyntaxId";
-bool LLSyntaxIdLSL::sInitialised;
+bool LLSyntaxIdLSL::sInitialized;
LLSD LLSyntaxIdLSL::sKeywordsXml;
bool LLSyntaxIdLSL::sLoaded;
bool LLSyntaxIdLSL::sLoadFailed;
bool LLSyntaxIdLSL::sVersionChanged;
-LLSyntaxIdLSL::file_fetched_signal_t LLSyntaxIdLSL::sFileFetchedSignal;
+LLSyntaxIdLSL::file_fetched_signal_t LLSyntaxIdLSL::sFileFetchedSignal;
/**
* @brief LLSyntaxIdLSL constructor
@@ -207,7 +207,7 @@ bool LLSyntaxIdLSL::checkSyntaxIdChanged()
}
else
{
- if ( mSyntaxIdCurrent.isNull() && isInitialised())
+ if ( mSyntaxIdCurrent.isNull() && isInitialized())
{
LL_INFOS("SyntaxLSL")
<< "It does not have LSLSyntaxId capability, remaining with default keywords file!"
@@ -255,9 +255,9 @@ void LLSyntaxIdLSL::fetchKeywordsFile()
//-----------------------------------------------------------------------------
-// initialise
+// initialize
//-----------------------------------------------------------------------------
-void LLSyntaxIdLSL::initialise()
+void LLSyntaxIdLSL::initialize()
{
mFileNameNew = mFileNameCurrent;
mSyntaxIdNew = mSyntaxIdCurrent;
@@ -309,7 +309,7 @@ void LLSyntaxIdLSL::initialise()
loadDefaultKeywordsIntoLLSD();
}
}
- else if (!isInitialised())
+ else if (!isInitialized())
{
loadDefaultKeywordsIntoLLSD();
}
@@ -355,8 +355,7 @@ bool LLSyntaxIdLSL::isSupportedVersion(const LLSD& content)
//-----------------------------------------------------------------------------
void LLSyntaxIdLSL::loadDefaultKeywordsIntoLLSD()
{
- LL_INFOS("SyntaxLSL")
- << "LSLSyntaxId is null so we will use the default file!" << LL_ENDL;
+ LL_INFOS("SyntaxLSL") << "LSLSyntaxId is null so we will use the default file!" << LL_ENDL;
mSyntaxIdNew = LLUUID();
buildFullFileSpec();
loadKeywordsIntoLLSD();
@@ -373,9 +372,7 @@ void LLSyntaxIdLSL::loadDefaultKeywordsIntoLLSD()
*/
void LLSyntaxIdLSL::loadKeywordsIntoLLSD()
{
- LL_INFOS("SyntaxLSL")
- << "Trying to open cached or default keyword file ;-)"
- << LL_ENDL;
+ LL_INFOS("SyntaxLSL") << "Trying to open cached or default keyword file" << LL_ENDL;
// Is this the right thing to do, or should we leave the old content
// even if it isn't entirely accurate anymore?
@@ -389,9 +386,7 @@ void LLSyntaxIdLSL::loadKeywordsIntoLLSD()
sLoaded = (bool)LLSDSerialize::fromXML(content, file);
if (!sLoaded)
{
- LL_WARNS("SyntaxLSL")
- << "Unable to deserialise file: "
- << mFullFileSpec << LL_ENDL;
+ LL_WARNS("SyntaxLSL") << "Unable to deserialise file: " << mFullFileSpec << LL_ENDL;
}
else
{
@@ -399,15 +394,13 @@ void LLSyntaxIdLSL::loadKeywordsIntoLLSD()
{
sKeywordsXml = content;
sLoaded = true;
- sInitialised = true;
- LL_INFOS("SyntaxLSL")
- << "Deserialised file: " << mFullFileSpec << LL_ENDL;
+ sInitialized = true;
+ LL_INFOS("SyntaxLSL") << "Deserialised file: " << mFullFileSpec << LL_ENDL;
}
else
{
sLoaded = false;
- LL_WARNS("SyntaxLSL")
- << "Unknown or unsupported version of syntax file." << LL_ENDL;
+ LL_WARNS("SyntaxLSL") << "Unknown or unsupported version of syntax file." << LL_ENDL;
}
}
}
@@ -422,8 +415,3 @@ boost::signals2::connection LLSyntaxIdLSL::addFileFetchedCallback(const file_fet
{
return sFileFetchedSignal.connect(cb);
}
-
-void LLSyntaxIdLSL::removeFileFetchedCallback(boost::signals2::connection callback)
-{
- sFileFetchedSignal.disconnect(callback);
-}
diff --git a/indra/newview/llsyntaxid.h b/indra/newview/llsyntaxid.h
index 75cfc45380..b68f3f4237 100644
--- a/indra/newview/llsyntaxid.h
+++ b/indra/newview/llsyntaxid.h
@@ -36,23 +36,18 @@
#include "llsingleton.h"
#include "llviewerregion.h"
-
-/**
- * @file llsyntaxid.h
- * @brief Tracks the file needed to decorate the current sim's version of LSL.
- */
-class LLSyntaxIdLSL: public LLSingleton<LLSyntaxIdLSL>
+class LLSyntaxIdLSL : public LLSingleton<LLSyntaxIdLSL>
{
friend class fetchKeywordsFileResponder;
public:
typedef boost::signals2::signal<void()> file_fetched_signal_t;
- static const std::string CAPABILITY_NAME;
- static const std::string FILENAME_DEFAULT;
- static const std::string SIMULATOR_FEATURE;
+ static const std::string CAPABILITY_NAME;
+ static const std::string FILENAME_DEFAULT;
+ static const std::string SIMULATOR_FEATURE;
protected:
- static bool sInitialised;
+ static bool sInitialized;
static LLSD sKeywordsXml;
static bool sLoaded;
static bool sLoadFailed;
@@ -85,16 +80,15 @@ public:
LLSD getKeywordsXML() const { return sKeywordsXml; }
LLUUID getSyntaxId() const { return mSyntaxIdCurrent; }
bool isDifferentVersion() const { return sVersionChanged; }
- bool isInitialised() const { return sInitialised; }
+ bool isInitialized() const { return sInitialized; }
- void initialise();
+ void initialize();
bool isLoaded() { return sLoaded; }
static bool isSupportedVersion(const LLSD& content);
static void setKeywordsXml(const LLSD& content) { sKeywordsXml = content; }
boost::signals2::connection addFileFetchedCallback(const file_fetched_signal_t::slot_type& cb);
- void removeFileFetchedCallback(boost::signals2::connection callback);
protected:
@@ -110,10 +104,6 @@ protected:
};
-/**
- * @file llsyntaxid.h
- * @brief Handles responses for the LSLSyntax capability's get call. Is a friend of LLSyntaxIdLSL
- */
class fetchKeywordsFileResponder : public LLHTTPClient::Responder
{
public: