summaryrefslogtreecommitdiffstats
path: root/src/ui/tool/node.h
diff options
context:
space:
mode:
authorTavmjong Bah <tavmjong@free.fr>2014-05-09 08:46:15 +0000
committertavmjong-free <tavmjong@free.fr>2014-05-09 08:46:15 +0000
commit6f43db26b0b07cf96664ba2bfbeeb1d622ecd14f (patch)
treead088651637edf691a57860c519a751a8a26d8fb /src/ui/tool/node.h
parentStyle rewrite: prevent crash when fill/stroke set to "currentColor". (diff)
parentMerging Jabier's spirolive+bspline branch (diff)
downloadinkscape-6f43db26b0b07cf96664ba2bfbeeb1d622ecd14f.tar.gz
inkscape-6f43db26b0b07cf96664ba2bfbeeb1d622ecd14f.zip
Update to tip.
(bzr r13341.1.2)
Diffstat (limited to '')
-rw-r--r--src/ui/tool/node.h12
1 files changed, 11 insertions, 1 deletions
diff --git a/src/ui/tool/node.h b/src/ui/tool/node.h
index 4582d998a..5971956e1 100644
--- a/src/ui/tool/node.h
+++ b/src/ui/tool/node.h
@@ -117,7 +117,7 @@ public:
protected:
Handle(NodeSharedData const &data, Geom::Point const &initial_pos, Node *parent);
-
+ virtual void handle_2button_press();
virtual bool _eventHandler(Inkscape::UI::Tools::ToolBase *event_context, GdkEvent *event);
virtual void dragged(Geom::Point &new_pos, GdkEventMotion *event);
virtual bool grabbed(GdkEventMotion *event);
@@ -131,6 +131,7 @@ protected:
private:
inline PathManipulator &_pm();
+ inline PathManipulator &_pm() const;
Node *_parent; // the handle's lifetime does not extend beyond that of the parent node,
// so a naked pointer is OK and allows setting it during Node's construction
SPCtrlLine *_handle_line;
@@ -217,6 +218,7 @@ public:
Node *nodeAwayFrom(Handle *h);
NodeList &nodeList() { return *(static_cast<ListNode*>(this)->ln_list); }
+ NodeList &nodeList() const { return *(static_cast<ListNode const*>(this)->ln_list); }
/**
* Move the node to the bottom of its canvas group.
@@ -263,6 +265,7 @@ private:
Inkscape::SnapSourceType _snapSourceType() const;
Inkscape::SnapTargetType _snapTargetType() const;
inline PathManipulator &_pm();
+ inline PathManipulator &_pm() const;
/** Determine whether two nodes are joined by a linear segment. */
static bool _is_line_segment(Node *first, Node *second);
@@ -490,10 +493,17 @@ inline double Handle::length() const {
inline PathManipulator &Handle::_pm() {
return _parent->_pm();
}
+inline PathManipulator &Handle::_pm() const {
+ return _parent->_pm();
+}
inline PathManipulator &Node::_pm() {
return nodeList().subpathList().pm();
}
+inline PathManipulator &Node::_pm() const {
+ return nodeList().subpathList().pm();
+}
+
// definitions for node iterator
template <typename N>
NodeIterator<N>::operator bool() const {