]> ruin.nu Git - germs.git/blobdiff - src/reverseaction.h
Basic implementation of threaded sorting
[germs.git] / src / reverseaction.h
index e0857803518b2d4aa5acaa72f0c7cfe89f41bf4f..267aeaa84bdc11cdec6dcadce0ecc114b4d10782 100644 (file)
@@ -63,6 +63,14 @@ class ReverseAction : public SortActionImpl{
                        return false;
                }
 
+               virtual bool operator<(const SortActionImpl& sa) const{
+                       if (const ReverseAction* psa = dynamic_cast<const ReverseAction*>(&sa)){
+                               if (_i < psa->_i || (_i == psa->_i && _j < psa->_j))
+                                       return true;
+                       }
+                       return false;
+               }
+
                /**
                 * Gives a string representation of the action, for output
                 */