deserialize method
Deserializes the FML template elements, attributes and children
Implementation
@override
void deserialize(XmlElement xml) {
// deserialize
super.deserialize(xml);
// properties
ratio = Xml.get(node: xml, tag: 'ratio');
dividerColor = Xml.get(node: xml, tag: 'dividercolor');
dividerWidth = Xml.get(node: xml, tag: 'dividerwidth');
dividerHandleColor = Xml.get(node: xml, tag: 'dividerhandlecolor');
// remove and destroy all non-box children
if (children != null) {
var list = children!.where((child) => child is! BoxModel).cast<WidgetModel>();
for (var child in list) {
child.dispose();
}
children?.removeWhere((child) => list.contains(child));
}
}