implement component comparison
authorTimo Savola <tsavola@movial.fi>
Sat, 5 Apr 2008 23:33:06 +0000 (02:33 +0300)
committerTimo Savola <tsavola@movial.fi>
Sat, 5 Apr 2008 23:33:06 +0000 (02:33 +0300)
matrix/config.py

index 40b139b..41f8b50 100644 (file)
@@ -64,6 +64,9 @@ class Component(object):
 
                components[name] = self
 
+       def __cmp__(self, other):
+               return cmp(self.name, other.name)
+
        def get_active_tag(self):
                global board