index c8644fef962ef2b3af6adddb79be4791f2d50f19..515b49360d20f1705764328647d8d57632cfe857 100644 (file)
--- a/src/dialogs/xml-tree.cpp
+++ b/src/dialogs/xml-tree.cpp
if (GTK_CTREE_ROW(node)->parent == new_parent &&
GTK_CTREE_ROW(node)->sibling == new_sibling)
{
- sp_document_done(current_document, SP_VERB_DIALOG_XML_EDITOR,
+ SPDocumentUndo::done(current_document, SP_VERB_DIALOG_XML_EDITOR,
_("Drag XML subtree"));
} else {
- sp_document_cancel(current_document);
+ SPDocumentUndo::cancel(current_document);
}
}
set_tree_select(new_repr);
set_dt_select(new_repr);
- sp_document_done(current_document, SP_VERB_DIALOG_XML_EDITOR,
+ SPDocumentUndo::done(current_document, SP_VERB_DIALOG_XML_EDITOR,
_("Create new element node"));
}
Inkscape::XML::Node *text = xml_doc->createTextNode("");
selected_repr->appendChild(text);
- sp_document_done(current_document, SP_VERB_DIALOG_XML_EDITOR,
+ SPDocumentUndo::done(current_document, SP_VERB_DIALOG_XML_EDITOR,
_("Create new text node"));
set_tree_select(text);
Inkscape::XML::Node *dup = selected_repr->duplicate(parent->document());
parent->addChild(dup, selected_repr);
- sp_document_done(current_document, SP_VERB_DIALOG_XML_EDITOR,
+ SPDocumentUndo::done(current_document, SP_VERB_DIALOG_XML_EDITOR,
_("Duplicate node"));
GtkCTreeNode *node = sp_xmlview_tree_get_repr_node(SP_XMLVIEW_TREE(tree), dup);
g_assert(selected_repr != NULL);
sp_repr_unparent(selected_repr);
- sp_document_done(current_document, SP_VERB_DIALOG_XML_EDITOR,
+ SPDocumentUndo::done(current_document, SP_VERB_DIALOG_XML_EDITOR,
Q_("nodeAsInXMLinHistoryDialog|Delete node"));
}
updated->updateRepr();
}
- sp_document_done(current_document, SP_VERB_DIALOG_XML_EDITOR,
+ SPDocumentUndo::done(current_document, SP_VERB_DIALOG_XML_EDITOR,
_("Delete attribute"));
}
updated->updateRepr();
}
- sp_document_done(current_document, SP_VERB_DIALOG_XML_EDITOR,
+ SPDocumentUndo::done(current_document, SP_VERB_DIALOG_XML_EDITOR,
_("Change attribute"));
/* TODO: actually, the row won't have been created yet. why? */
parent->changeOrder(selected_repr, ref);
- sp_document_done(current_document, SP_VERB_DIALOG_XML_EDITOR,
+ SPDocumentUndo::done(current_document, SP_VERB_DIALOG_XML_EDITOR,
_("Raise node"));
set_tree_select(selected_repr);
parent->changeOrder(selected_repr, selected_repr->next());
- sp_document_done(current_document, SP_VERB_DIALOG_XML_EDITOR,
+ SPDocumentUndo::done(current_document, SP_VERB_DIALOG_XML_EDITOR,
_("Lower node"));
set_tree_select(selected_repr);
parent->removeChild(repr);
prev->addChild(repr, ref);
- sp_document_done(current_document, SP_VERB_DIALOG_XML_EDITOR,
+ SPDocumentUndo::done(current_document, SP_VERB_DIALOG_XML_EDITOR,
_("Indent node"));
set_tree_select(repr);
set_dt_select(repr);
parent->removeChild(repr);
grandparent->addChild(repr, parent);
- sp_document_done(current_document, SP_VERB_DIALOG_XML_EDITOR,
+ SPDocumentUndo::done(current_document, SP_VERB_DIALOG_XML_EDITOR,
_("Unindent node"));
set_tree_select(repr);
set_dt_select(repr);