summaryrefslogtreecommitdiffstats
path: root/src/sp-lpe-item.cpp
diff options
context:
space:
mode:
authorVinícius dos Santos Oliveira <vini.ipsmaker@gmail.com>2014-05-05 07:13:35 +0000
committerVinícius dos Santos Oliveira <vini.ipsmaker@gmail.com>2014-05-05 07:13:35 +0000
commit5a8b00f027b9eb3d4abb290d2ddf26d36d71cf80 (patch)
treef85f72eb8642eb842dcd02f20967e5bd2b8b95d1 /src/sp-lpe-item.cpp
parentupdate to trunk (diff)
downloadinkscape-5a8b00f027b9eb3d4abb290d2ddf26d36d71cf80.tar.gz
inkscape-5a8b00f027b9eb3d4abb290d2ddf26d36d71cf80.zip
Enabling path manipulator to comunicate if paths are bspline when
accessing const objects. This change was required to correctly show on the GUI whether or not a node was a bspline. (bzr r11950.8.1)
Diffstat (limited to 'src/sp-lpe-item.cpp')
-rw-r--r--src/sp-lpe-item.cpp16
1 files changed, 16 insertions, 0 deletions
diff --git a/src/sp-lpe-item.cpp b/src/sp-lpe-item.cpp
index f59bc33ee..33359727a 100644
--- a/src/sp-lpe-item.cpp
+++ b/src/sp-lpe-item.cpp
@@ -606,6 +606,22 @@ SPLPEItem::getPathEffectOfType(int type)
return NULL;
}
+Inkscape::LivePathEffect::Effect const*
+SPLPEItem::getPathEffectOfType(int type) const
+{
+ std::list<Inkscape::LivePathEffect::LPEObjectReference *>::const_iterator i;
+ for (i = path_effect_list->begin(); i != path_effect_list->end(); ++i) {
+ LivePathEffectObject const *lpeobj = (*i)->lpeobject;
+ if (lpeobj) {
+ Inkscape::LivePathEffect::Effect const *lpe = lpeobj->get_lpe();
+ if (lpe && (lpe->effectType() == type)) {
+ return lpe;
+ }
+ }
+ }
+ return NULL;
+}
+
void SPLPEItem::editNextParamOncanvas(SPDesktop *dt)
{
Inkscape::LivePathEffect::LPEObjectReference *lperef = this->getCurrentLPEReference();