mirror of
https://github.com/openmoh/openmohaa.git
synced 2025-04-28 21:57:57 +03:00
Mark getter methods as const for ScriptThreadLabel
This commit is contained in:
parent
7b97ad6e2f
commit
9c811c2318
2 changed files with 16 additions and 16 deletions
|
@ -866,7 +866,7 @@ ScriptThreadLabel::ScriptThreadLabel()
|
|||
m_Label = STRING_EMPTY;
|
||||
}
|
||||
|
||||
ScriptThread *ScriptThreadLabel::Create(Listener *listener)
|
||||
ScriptThread *ScriptThreadLabel::Create(Listener *listener) const
|
||||
{
|
||||
ScriptClass *scriptClass;
|
||||
ScriptThread *thread;
|
||||
|
@ -896,7 +896,7 @@ ScriptThread *ScriptThreadLabel::Create(Listener *listener)
|
|||
return thread;
|
||||
}
|
||||
|
||||
void ScriptThreadLabel::Execute(Listener *listener)
|
||||
void ScriptThreadLabel::Execute(Listener *listener) const
|
||||
{
|
||||
if (!m_Script) {
|
||||
return;
|
||||
|
@ -909,7 +909,7 @@ void ScriptThreadLabel::Execute(Listener *listener)
|
|||
}
|
||||
}
|
||||
|
||||
void ScriptThreadLabel::Execute(Listener *listener, Event& ev)
|
||||
void ScriptThreadLabel::Execute(Listener *listener, Event& ev) const
|
||||
{
|
||||
if (!m_Script) {
|
||||
return;
|
||||
|
@ -922,12 +922,12 @@ void ScriptThreadLabel::Execute(Listener *listener, Event& ev)
|
|||
}
|
||||
}
|
||||
|
||||
void ScriptThreadLabel::Execute(Listener *listener, Event *ev)
|
||||
void ScriptThreadLabel::Execute(Listener *listener, Event *ev) const
|
||||
{
|
||||
Execute(listener, *ev);
|
||||
}
|
||||
|
||||
void ScriptThreadLabel::Execute(Listener *pSelf, const SafePtr<Listener>& listener, const SafePtr<Listener>& param)
|
||||
void ScriptThreadLabel::Execute(Listener *pSelf, const SafePtr<Listener>& listener, const SafePtr<Listener>& param) const
|
||||
{
|
||||
if (!m_Script) {
|
||||
return;
|
||||
|
@ -1214,7 +1214,7 @@ bool ScriptThreadLabel::TrySetScript(const_str label)
|
|||
return true;
|
||||
}
|
||||
|
||||
void ScriptThreadLabel::GetScriptValue(ScriptVariable *var)
|
||||
void ScriptThreadLabel::GetScriptValue(ScriptVariable *var) const
|
||||
{
|
||||
if (!m_Script) {
|
||||
var->Clear();
|
||||
|
@ -1228,12 +1228,12 @@ void ScriptThreadLabel::GetScriptValue(ScriptVariable *var)
|
|||
var->setConstArrayValue(var_array, 2);
|
||||
}
|
||||
|
||||
bool ScriptThreadLabel::IsSet(void)
|
||||
bool ScriptThreadLabel::IsSet(void) const
|
||||
{
|
||||
return m_Script != NULL;
|
||||
}
|
||||
|
||||
bool ScriptThreadLabel::IsFile(const_str filename)
|
||||
bool ScriptThreadLabel::IsFile(const_str filename) const
|
||||
{
|
||||
return m_Script && m_Script->ConstFilename() == filename && m_Label == STRING_EMPTY;
|
||||
}
|
||||
|
|
|
@ -169,11 +169,11 @@ private:
|
|||
public:
|
||||
ScriptThreadLabel();
|
||||
|
||||
ScriptThread *Create(Listener *listener);
|
||||
void Execute(Listener *listener = NULL);
|
||||
void Execute(Listener *listener, Event& ev);
|
||||
void Execute(Listener *listener, Event *ev);
|
||||
void Execute(Listener *pSelf, const SafePtr<Listener>& listener, const SafePtr<Listener>& param);
|
||||
ScriptThread *Create(Listener *listener) const;
|
||||
void Execute(Listener *listener = NULL) const;
|
||||
void Execute(Listener *listener, Event& ev) const;
|
||||
void Execute(Listener *listener, Event *ev) const;
|
||||
void Execute(Listener *pSelf, const SafePtr<Listener>& listener, const SafePtr<Listener>& param) const;
|
||||
|
||||
void Clear();
|
||||
void Set(const char *label);
|
||||
|
@ -188,10 +188,10 @@ public:
|
|||
bool TrySetScript(const_str label);
|
||||
bool TrySetScript(const char *label);
|
||||
|
||||
bool IsSet(void);
|
||||
bool IsFile(const_str filename);
|
||||
bool IsSet(void) const;
|
||||
bool IsFile(const_str filename) const;
|
||||
|
||||
void GetScriptValue(ScriptVariable *var);
|
||||
void GetScriptValue(ScriptVariable *var) const;
|
||||
|
||||
void Archive(Archiver& arc);
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue