diff options
| author | 2016-03-22 19:27:45 +0100 | |
|---|---|---|
| committer | 2016-03-22 19:27:45 +0100 | |
| commit | d466a529fe2ed5c09c2353c67c82df5c83d831cf (patch) | |
| tree | 6807e3729cf4eff1c750e5de04113af4809059bb /node | |
| parent | 37320ce7aa23c52f950a97c756a2d9c618467d1d (diff) | |
| download | OneRoll-d466a529fe2ed5c09c2353c67c82df5c83d831cf.tar.gz OneRoll-d466a529fe2ed5c09c2353c67c82df5c83d831cf.zip | |
fix cpp check
Diffstat (limited to 'node')
| -rw-r--r-- | node/executionnode.cpp | 2 | ||||
| -rw-r--r-- | node/listsetrollnode.cpp | 2 | ||||
| -rw-r--r-- | node/listsetrollnode.h | 2 | ||||
| -rw-r--r-- | node/mergenode.cpp | 26 | ||||
| -rw-r--r-- | node/scalaroperatornode.h | 4 |
5 files changed, 18 insertions, 18 deletions
diff --git a/node/executionnode.cpp b/node/executionnode.cpp index c1dec73..d2f291b 100644 --- a/node/executionnode.cpp +++ b/node/executionnode.cpp @@ -3,7 +3,7 @@ #include <QUuid> ExecutionNode::ExecutionNode() - : m_nextNode(NULL),m_result(NULL),m_previousNode(NULL),m_id(QString("\"%1\"").arg(QUuid::createUuid().toString())) + : m_previousNode(NULL),m_result(NULL),m_nextNode(NULL),m_errors(QMap<ExecutionNode::DICE_ERROR_CODE,QString>()),m_id(QString("\"%1\"").arg(QUuid::createUuid().toString())) { } diff --git a/node/listsetrollnode.cpp b/node/listsetrollnode.cpp index 9f15d36..7674720 100644 --- a/node/listsetrollnode.cpp +++ b/node/listsetrollnode.cpp @@ -35,7 +35,7 @@ ListSetRollNode::~ListSetRollNode() } } -QStringList ListSetRollNode::getList() +QStringList ListSetRollNode::getList() const { return m_values; } diff --git a/node/listsetrollnode.h b/node/listsetrollnode.h index 5f381f5..05e7ea4 100644 --- a/node/listsetrollnode.h +++ b/node/listsetrollnode.h @@ -39,7 +39,7 @@ public: virtual void run(ExecutionNode* previous = NULL); virtual QString toString(bool)const; virtual qint64 getPriority() const; - QStringList getList(); + QStringList getList() const; void setListValue(QStringList); void setUnique(bool ); diff --git a/node/mergenode.cpp b/node/mergenode.cpp index 5145bc8..7f3bec0 100644 --- a/node/mergenode.cpp +++ b/node/mergenode.cpp @@ -32,26 +32,26 @@ void MergeNode::run(ExecutionNode* previous) if(NULL!=previous) { m_result->setPrevious(previous->getResult()); - } - Result* tmpResult = previous->getResult(); - while(NULL!=tmpResult) - { - DiceResult* dice = dynamic_cast<DiceResult*>(tmpResult); - if(NULL!=dice) + + Result* tmpResult = previous->getResult(); + while(NULL!=tmpResult) { - ///@todo improve here to set homogeneous while is really - m_diceResult->setHomogeneous(false); - foreach(Die* die, dice->getResultList()) + DiceResult* dice = dynamic_cast<DiceResult*>(tmpResult); + if(NULL!=dice) { - if(!m_diceResult->getResultList().contains(die)) + ///@todo improve here to set homogeneous while is really + m_diceResult->setHomogeneous(false); + foreach(Die* die, dice->getResultList()) { - m_diceResult->getResultList().append(die); + if(!m_diceResult->getResultList().contains(die)) + { + m_diceResult->getResultList().append(die); + } } } + tmpResult = tmpResult->getPrevious(); } - tmpResult = tmpResult->getPrevious(); } - if(NULL!=m_nextNode) { m_nextNode->run(this); diff --git a/node/scalaroperatornode.h b/node/scalaroperatornode.h index 06f121b..fccc5e5 100644 --- a/node/scalaroperatornode.h +++ b/node/scalaroperatornode.h @@ -62,9 +62,9 @@ private: static qint64 multiple(qint64,qint64); private: - ArithmeticOperator m_arithmeticOperator; - ScalarResult* m_scalarResult; ExecutionNode* m_internalNode; + ScalarResult* m_scalarResult; + ArithmeticOperator m_arithmeticOperator; }; #endif // SCALAROPERATORNODE_H |