diff options
| author | 2016-11-05 00:11:19 +0100 | |
|---|---|---|
| committer | 2016-11-05 00:11:19 +0100 | |
| commit | 3799c71dee9e8d73858c727873d550adc0649c64 (patch) | |
| tree | 87813e160bdbb3bad51b1a6c448bdeeaa475c2fc /booleancondition.cpp | |
| parent | d5876d9b88c2f695592338335308a32e584d86a4 (diff) | |
| parent | b977d3e2a2765f5b91ac7bf5c34ea8891969cda9 (diff) | |
| download | OneRoll-3799c71dee9e8d73858c727873d550adc0649c64.tar.gz OneRoll-3799c71dee9e8d73858c727873d550adc0649c64.zip | |
add filter node
Diffstat (limited to 'booleancondition.cpp')
| -rw-r--r-- | booleancondition.cpp | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/booleancondition.cpp b/booleancondition.cpp index 83076e0..585620a 100644 --- a/booleancondition.cpp +++ b/booleancondition.cpp @@ -58,6 +58,9 @@ qint64 BooleanCondition::hasValid(Die* b,bool recursive,bool unhighlight) const case LesserOrEqual: sum+= (value<=m_value)?1:0; break; + case Different: + sum+= (value!=m_value)?1:0; + break; } } if((unhighlight)&&(sum==0)) @@ -101,6 +104,9 @@ QString BooleanCondition::toString() case LesserOrEqual: str.append(QStringLiteral("<=")); break; + case Different: + str.append(QStringLiteral("!=")); + break; } return QStringLiteral("[%1%2]").arg(str).arg(m_value); } @@ -118,5 +124,7 @@ quint64 BooleanCondition::getValidRangeSize(quint64 faces) const return faces-(m_value-1); case LesserOrEqual: return m_value; + case Different: + return faces-1; } } |