31 #include "conditionaledge.h" |
31 #include "conditionaledge.h" |
32 #include "comment.h" |
32 #include "comment.h" |
33 #include "empty.h" |
33 #include "empty.h" |
34 #include "circularprimitive.h" |
34 #include "circularprimitive.h" |
35 |
35 |
36 // List of all LDObjects |
36 static Uuid id_counter; |
37 QMap<qint32, LDObject*> g_allObjects; |
|
38 |
|
39 enum { MAX_LDOBJECT_IDS = (1 << 24) }; |
|
40 |
37 |
41 // ============================================================================= |
38 // ============================================================================= |
42 // LDObject constructors |
39 // LDObject constructors |
43 // |
40 // |
44 LDObject::LDObject() : |
41 LDObject::LDObject() : |
|
42 id {++id_counter}, |
45 m_isHidden {false} |
43 m_isHidden {false} |
46 { |
44 { |
47 m_randomColor = QColor::fromHsv (rand() % 360, rand() % 256, rand() % 96 + 128); |
45 m_randomColor = QColor::fromHsv (rand() % 360, rand() % 256, rand() % 96 + 128); |
48 } |
46 } |
49 |
47 |