Remove all use of add_child() from xmlpp.
[dcpomatic.git] / src / lib / kdm_recipient.cc
index 671e9797c24cbfb40e2b9bdf509538d2cf1dc391..c33eb1b9fa962fcd0e308af21d4770aad10c08dc 100644 (file)
@@ -39,14 +39,14 @@ KDMRecipient::KDMRecipient (cxml::ConstNodePtr node)
 void
 KDMRecipient::as_xml (xmlpp::Element* parent) const
 {
-       parent->add_child("Name")->add_child_text(name);
+       cxml::add_text_child(parent, "Name", name);
        if (recipient) {
-               parent->add_child("Recipient")->add_child_text(recipient->certificate(true));
+               cxml::add_text_child(parent, "Recipient", recipient->certificate(true));
        }
        if (recipient_file) {
-               parent->add_child("RecipientFile")->add_child_text(*recipient_file);
+               cxml::add_text_child(parent, "RecipientFile", *recipient_file);
        }
 
-       parent->add_child("Notes")->add_child_text(notes);
+       cxml::add_text_child(parent, "Notes", notes);
 }