From cec5731da8c49542b06cbd831ba35a2b7ed7fd5d Mon Sep 17 00:00:00 2001 From: gouldtj Date: Mon, 30 Jan 2006 05:10:24 +0000 Subject: [PATCH] r10781@tres: ted | 2006-01-26 23:18:34 -0800 Some modifications, getting basic menu merging working --- src/extension/effect.cpp | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/src/extension/effect.cpp b/src/extension/effect.cpp index 5a43cd74c..43bd81830 100644 --- a/src/extension/effect.cpp +++ b/src/extension/effect.cpp @@ -30,9 +30,14 @@ Effect::Effect (Inkscape::XML::Node * in_repr, Implementation::Implementation * find_effects_list(inkscape_get_menus(INKSCAPE)); if (_effects_list != NULL) { + unsigned start_pos = _effects_list->position(); + _menu_node = sp_repr_new("verb"); _menu_node->setAttribute("verb-id", this->get_id(), false); _effects_list->parent()->appendChild(_menu_node); + + _menu_node->setPosition(start_pos + 1); + Inkscape::GC::release(_menu_node); } /*else { printf("Effect %s not added\n", get_name()); @@ -137,7 +142,7 @@ Effect::find_effects_list (Inkscape::XML::Node * menustruct) child != NULL; child = child->next()) { if (!strcmp(child->name(), EFFECTS_LIST)) { - _effects_list = menustruct; + _effects_list = child; return true; } Inkscape::XML::Node * firstchild = child->firstChild(); -- 2.30.2