1 #include "metacommand.h" |
1 #include "metacommand.h" |
2 |
2 |
3 linetypes::MetaCommand::MetaCommand(QStringView text) : |
3 ldraw::MetaCommand::MetaCommand(QStringView text) : |
4 Object{}, |
4 Object{}, |
5 storedText{text.toString()} {} |
5 storedText{text.toString()} {} |
6 |
6 |
7 QVariant linetypes::MetaCommand::getProperty(Property property) const |
7 QVariant ldraw::MetaCommand::getProperty(Property property) const |
8 { |
8 { |
9 switch (property) |
9 switch (property) |
10 { |
10 { |
11 case Property::Text: |
11 case Property::Text: |
12 return storedText; |
12 return storedText; |
13 default: |
13 default: |
14 return Object::getProperty(property); |
14 return Object::getProperty(property); |
15 } |
15 } |
16 } |
16 } |
17 |
17 |
18 auto linetypes::MetaCommand::setProperty(Property property, const QVariant& value) |
18 auto ldraw::MetaCommand::setProperty(Property property, const QVariant& value) |
19 -> SetPropertyResult |
19 -> SetPropertyResult |
20 { |
20 { |
21 switch (property) |
21 switch (property) |
22 { |
22 { |
23 case Property::Text: |
23 case Property::Text: |