Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCampbell Barton <ideasman42@gmail.com>2011-12-30 11:55:15 +0400
committerCampbell Barton <ideasman42@gmail.com>2011-12-30 11:55:15 +0400
commit6d965f4493871c9bd4550939b8263d0c509b7c41 (patch)
treeeb5fecdc3fc376d056d9e4ea7366c3a8e0dea8b7 /source/gameengine/Expressions
parentca629d5ccc65da456babba6c5bdbfa0de737ac7b (diff)
style edits for function declarations
Diffstat (limited to 'source/gameengine/Expressions')
-rw-r--r--source/gameengine/Expressions/InputParser.cpp18
-rw-r--r--source/gameengine/Expressions/Operator1Expr.cpp5
-rw-r--r--source/gameengine/Expressions/Operator2Expr.cpp11
-rw-r--r--source/gameengine/Expressions/PyObjectPlus.h3
-rw-r--r--source/gameengine/Expressions/Value.cpp3
5 files changed, 24 insertions, 16 deletions
diff --git a/source/gameengine/Expressions/InputParser.cpp b/source/gameengine/Expressions/InputParser.cpp
index 27f4f0b10cb..726fea795ba 100644
--- a/source/gameengine/Expressions/InputParser.cpp
+++ b/source/gameengine/Expressions/InputParser.cpp
@@ -346,7 +346,8 @@ void CParser::NextSym()
}
#if 0
-int CParser::MakeInt() {
+int CParser::MakeInt()
+{
// returns the integer representation of the value in the global
// variable const_as_string
// pre: const_as_string contains only numercal chars
@@ -354,7 +355,8 @@ int CParser::MakeInt() {
}
#endif
-STR_String CParser::Symbol2Str(int s) {
+STR_String CParser::Symbol2Str(int s)
+{
// returns a string representation of of symbol s,
// for use in Term when generating an error
switch(s) {
@@ -373,7 +375,8 @@ STR_String CParser::Symbol2Str(int s) {
}
}
-void CParser::Term(int s) {
+void CParser::Term(int s)
+{
// generates an error if the next symbol isn't the specified symbol s
// otherwise, skip the symbol
if(s == sym) NextSym();
@@ -387,7 +390,8 @@ void CParser::Term(int s) {
}
}
-int CParser::Priority(int optorkind) {
+int CParser::Priority(int optorkind)
+{
// returns the priority of an operator
// higher number means higher priority
switch(optorkind) {
@@ -409,7 +413,8 @@ int CParser::Priority(int optorkind) {
return 0; // should not happen
}
-CExpression *CParser::Ex(int i) {
+CExpression *CParser::Ex(int i)
+{
// parses an expression in the imput, starting at priority i, and
// returns an CExpression, containing the parsed input
CExpression *e1 = NULL, *e2 = NULL;
@@ -551,7 +556,8 @@ CExpression *CParser::Ex(int i) {
return e1;
}
-CExpression *CParser::Expr() {
+CExpression *CParser::Expr()
+{
// parses an expression in the imput, and
// returns an CExpression, containing the parsed input
return Ex(1);
diff --git a/source/gameengine/Expressions/Operator1Expr.cpp b/source/gameengine/Expressions/Operator1Expr.cpp
index 0ef35108233..4e93ee0cb09 100644
--- a/source/gameengine/Expressions/Operator1Expr.cpp
+++ b/source/gameengine/Expressions/Operator1Expr.cpp
@@ -98,10 +98,9 @@ bool COperator1Expr::IsInside(float x, float y, float z,bool bBorderInclude)
}
*/
-bool COperator1Expr::NeedsRecalculated() {
-
+bool COperator1Expr::NeedsRecalculated()
+{
return m_lhs->NeedsRecalculated();
-
}
CExpression* COperator1Expr::CheckLink(std::vector<CBrokenLinkInfo*>& brokenlinks) {
diff --git a/source/gameengine/Expressions/Operator2Expr.cpp b/source/gameengine/Expressions/Operator2Expr.cpp
index 7a012c4165c..11a509e59d0 100644
--- a/source/gameengine/Expressions/Operator2Expr.cpp
+++ b/source/gameengine/Expressions/Operator2Expr.cpp
@@ -168,17 +168,18 @@ bool COperator2Expr::IsInside(float x, float y, float z,bool bBorderInclude)
-bool COperator2Expr::IsRightInside(float x, float y, float z,bool bBorderInclude) {
-
+bool COperator2Expr::IsRightInside(float x, float y, float z,bool bBorderInclude)
+{
return m_rhs->IsInside(x,y,z,bBorderInclude) ;
-
}
-bool COperator2Expr::IsLeftInside(float x, float y, float z,bool bBorderInclude) {
+bool COperator2Expr::IsLeftInside(float x, float y, float z,bool bBorderInclude)
+{
return m_lhs->IsInside(x,y,z,bBorderInclude);
}
*/
-bool COperator2Expr::NeedsRecalculated() {
+bool COperator2Expr::NeedsRecalculated()
+{
// added some lines, just for debugging purposes, it could be a one-liner :)
//bool modleft
//bool modright;
diff --git a/source/gameengine/Expressions/PyObjectPlus.h b/source/gameengine/Expressions/PyObjectPlus.h
index 3e1c54b0cc7..b1072dd8336 100644
--- a/source/gameengine/Expressions/PyObjectPlus.h
+++ b/source/gameengine/Expressions/PyObjectPlus.h
@@ -54,7 +54,8 @@ extern "C" {
}
#endif
-static inline void Py_Fatal(const char *M) {
+static inline void Py_Fatal(const char *M)
+{
fprintf(stderr, "%s\n", M);
exit(-1);
};
diff --git a/source/gameengine/Expressions/Value.cpp b/source/gameengine/Expressions/Value.cpp
index 91fdbb0dabc..49150fc775f 100644
--- a/source/gameengine/Expressions/Value.cpp
+++ b/source/gameengine/Expressions/Value.cpp
@@ -530,7 +530,8 @@ PyAttributeDef CValue::Attributes[] = {
{ NULL } //Sentinel
};
-PyObject * CValue::pyattr_get_name(void * self_v, const KX_PYATTRIBUTE_DEF * attrdef) {
+PyObject * CValue::pyattr_get_name(void * self_v, const KX_PYATTRIBUTE_DEF * attrdef)
+{
CValue * self = static_cast<CValue *> (self_v);
return PyUnicode_From_STR_String(self->GetName());
}