18 default: |
18 default: |
19 return Object::getProperty(property); |
19 return Object::getProperty(property); |
20 } |
20 } |
21 } |
21 } |
22 |
22 |
23 auto ldraw::ErrorLine::setProperty( |
23 void ldraw::ErrorLine::setProperty(SetPropertyResult* result, const PropertyKeyValue& pair) |
24 Property property, |
|
25 const QVariant& value) |
|
26 -> SetPropertyResult |
|
27 { |
24 { |
28 switch (property) |
25 LDRAW_OBJECT_HANDLE_SET_PROPERTY(Text, {this->text = value;}); |
29 { |
26 LDRAW_OBJECT_HANDLE_SET_PROPERTY(ErrorMessage, {this->message = value;}); |
30 case Property::Text: |
27 BaseClass::setProperty(result, pair); |
31 this->text = value.toString(); |
|
32 return SetPropertyResult::Success; |
|
33 case Property::ErrorMessage: |
|
34 this->message = value.toString(); |
|
35 return SetPropertyResult::Success; |
|
36 default: |
|
37 return Object::setProperty(property, value); |
|
38 } |
|
39 } |
28 } |
40 |
29 |
41 QString ldraw::ErrorLine::textRepresentation() const |
30 QString ldraw::ErrorLine::textRepresentation() const |
42 { |
31 { |
43 return this->text; |
32 return this->text; |