diff options
Diffstat (limited to 'project2/xmlPresenter.cpp')
-rw-r--r-- | project2/xmlPresenter.cpp | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/project2/xmlPresenter.cpp b/project2/xmlPresenter.cpp index af870eb..46b1ef1 100644 --- a/project2/xmlPresenter.cpp +++ b/project2/xmlPresenter.cpp @@ -1,4 +1,5 @@ #include "xmlPresenter.h" +#include "genericVisitor.h" XmlPresenter::~XmlPresenter() { @@ -36,15 +37,15 @@ XmlPresenter::pushSub(const Glib::ustring & name, const Glib::ustring & ns) cons } void -XmlPresenter::addAttr(const Glib::ustring & name, const Glib::ustring & ns, const Glib::ustring & value) const +XmlPresenter::addAttr(const Glib::ustring & name, const Glib::ustring & ns, const VariableType & value) const { - nodeStack.back()->set_attribute(name, value, ns); + LexicalCall<Glib::ustring, void>(boost::bind(&xmlpp::Element::set_attribute, nodeStack.back(), name, _1, ns), value); } void -XmlPresenter::setText(const Glib::ustring & value) const +XmlPresenter::setText(const VariableType & value) const { - nodeStack.back()->set_child_text(value); + LexicalCall<Glib::ustring, void>(boost::bind(&xmlpp::Element::set_child_text, nodeStack.back(), _1), value); } void |