aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/node/dicerollernode.cpp
diff options
context:
space:
mode:
authorRenaud G <renaud@rolisteam.org>2017-10-27 22:19:20 +0200
committerRenaud G <renaud@rolisteam.org>2017-10-29 03:30:46 +0100
commitf053853e87624a045438bacd4dd1494e91ae381f (patch)
treecbf98ae65d48f4158c3af73be6bd0a1fb9417335 /node/dicerollernode.cpp
parenta543a6ca8ddc2826a4433044ed1a040acbbf36a3 (diff)
downloadOneRoll-f053853e87624a045438bacd4dd1494e91ae381f.tar.gz
OneRoll-f053853e87624a045438bacd4dd1494e91ae381f.zip
-c++11 update about for and nullptr.
Diffstat (limited to 'node/dicerollernode.cpp')
-rw-r--r--node/dicerollernode.cpp12
1 files changed, 5 insertions, 7 deletions
diff --git a/node/dicerollernode.cpp b/node/dicerollernode.cpp
index 89ba24d..25b9d5a 100644
--- a/node/dicerollernode.cpp
+++ b/node/dicerollernode.cpp
@@ -17,10 +17,10 @@ DiceRollerNode::DiceRollerNode(qint64 max,qint64 min)
void DiceRollerNode::run(ExecutionNode* previous)
{
m_previousNode = previous;
- if(NULL!=previous)
+ if(nullptr!=previous)
{
Result* result=previous->getResult();
- if(NULL!=result)
+ if(nullptr!=result)
{
m_diceCount = result->getResult(Result::SCALAR).toReal();
m_result->setPrevious(result);
@@ -40,7 +40,7 @@ void DiceRollerNode::run(ExecutionNode* previous)
//qDebug() << die->getValue() << "value";
m_diceResult->insertResult(die);
}
- if(NULL!=m_nextNode)
+ if(nullptr!=m_nextNode)
{
m_nextNode->run(this);
}
@@ -66,18 +66,16 @@ QString DiceRollerNode::toString(bool wl) const
qint64 DiceRollerNode::getPriority() const
{
qint64 priority=4;
-// if(NULL!=m_nextNode)
+// if(nullptr!=m_nextNode)
// {
// priority = m_nextNode->getPriority();
// }
-
-
return priority;
}
ExecutionNode* DiceRollerNode::getCopy() const
{
DiceRollerNode* node = new DiceRollerNode(m_max,m_min);
- if(NULL!=m_nextNode)
+ if(nullptr!=m_nextNode)
{
node->setNextNode(m_nextNode->getCopy());
}