Use XMLNode::set_property in PBD::PropertyTemplate<T> class
authorTim Mayberry <mojofunk@gmail.com>
Fri, 26 Aug 2016 12:31:45 +0000 (22:31 +1000)
committerTim Mayberry <mojofunk@gmail.com>
Tue, 18 Apr 2017 23:36:48 +0000 (09:36 +1000)
libs/pbd/pbd/properties.h

index a424b718e811d9f0af5bc92334ac35dbe7a69292..d176c266cbf7aa80b999aa0a640909bc7e756443 100644 (file)
@@ -116,7 +116,7 @@ public:
        }
 
        void get_value (XMLNode & node) const {
-                node.add_property (property_name(), to_string (_current));
+               node.set_property (property_name (), _current);
        }
 
 
@@ -139,8 +139,8 @@ public:
 
        void get_changes_as_xml (XMLNode* history_node) const {
                XMLNode* node = history_node->add_child (property_name());
-                node->add_property ("from", to_string (_old));
-                node->add_property ("to", to_string (_current));
+               node->set_property ("from", _old);
+               node->set_property ("to", _current);
        }
 
        void get_changes_as_properties (PropertyList& changes, Command *) const {