From: Krzysztof KosiƄski Date: Fri, 22 Jan 2010 10:54:17 +0000 (+0100) Subject: Fix some of the LPE issues. X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=d197ea621bc433ab5875a8a9ab1e9d834b187db0;p=inkscape.git Fix some of the LPE issues. --- diff --git a/src/live_effects/parameter/path.cpp b/src/live_effects/parameter/path.cpp index 1ea9ac506..94540a255 100644 --- a/src/live_effects/parameter/path.cpp +++ b/src/live_effects/parameter/path.cpp @@ -195,7 +195,7 @@ PathParam::param_newWidget(Gtk::Tooltips * tooltips) } void -PathParam::param_editOncanvas(SPItem * /*item*/, SPDesktop * dt) +PathParam::param_editOncanvas(SPItem *item, SPDesktop * dt) { using namespace Inkscape::UI; @@ -209,7 +209,7 @@ PathParam::param_editOncanvas(SPItem * /*item*/, SPDesktop * dt) ShapeRecord r; r.role = SHAPE_ROLE_LPE_PARAM; - r.edit_transform = Geom::identity(); // TODO this is almost certainly wrong + r.edit_transform = sp_item_i2d_affine(item); // TODO is it right? if (!href) { r.item = reinterpret_cast(param_effect->getLPEObj()); r.lpe_key = param_key; diff --git a/src/ui/tool/node-tool.cpp b/src/ui/tool/node-tool.cpp index 092ce7d87..08d893855 100644 --- a/src/ui/tool/node-tool.cpp +++ b/src/ui/tool/node-tool.cpp @@ -377,10 +377,6 @@ void gather_items(InkNodeTool *nt, SPItem *base, SPObject *obj, Inkscape::UI::Sh } } -struct IsPath { - bool operator()(SPItem *i) const { return SP_IS_PATH(i); } -}; - void ink_node_tool_selection_changed(InkNodeTool *nt, Inkscape::Selection *sel) { using namespace Inkscape::UI; @@ -401,7 +397,9 @@ void ink_node_tool_selection_changed(InkNodeTool *nt, Inkscape::Selection *sel) bool something_set = false; for (std::set::iterator i = shapes.begin(); i != shapes.end(); ++i) { ShapeRecord const &r = *i; - if (SP_IS_SHAPE(r.item) && !SP_IS_PATH(r.item)) { + if (SP_IS_SHAPE(r.item) || + (SP_IS_PATH(r.item) && r.item->repr->attribute("inkscape:original-d") != NULL)) + { nt->shape_editor->set_item(r.item, SH_KNOTHOLDER); something_set = true; break;