diff --git a/src/snapped-point.cpp b/src/snapped-point.cpp
index 48efa10e6fd3dacb1c51ee0ac7b6f311c0cf751a..52f0a7839b0468c10035ed913711822124733bdd 100644 (file)
--- a/src/snapped-point.cpp
+++ b/src/snapped-point.cpp
{
_point = Geom::Point(0,0);
_source = SNAPSOURCE_UNDEFINED,
{
_point = Geom::Point(0,0);
_source = SNAPSOURCE_UNDEFINED,
- _source_num = 0,
+ _source_num = -1,
_target = SNAPTARGET_UNDEFINED,
_at_intersection = false;
_constrained_snap = false;
_target = SNAPTARGET_UNDEFINED,
_at_intersection = false;
_constrained_snap = false;
{
_point = p;
_source = SNAPSOURCE_UNDEFINED,
{
_point = p;
_source = SNAPSOURCE_UNDEFINED,
- _source_num = 0,
+ _source_num = -1,
_target = SNAPTARGET_UNDEFINED,
_at_intersection = false;
_fully_constrained = false;
_target = SNAPTARGET_UNDEFINED,
_at_intersection = false;
_fully_constrained = false;
{
}
{
}
-void Inkscape::SnappedPoint::getPoint(Geom::Point &p) const
+void Inkscape::SnappedPoint::getPointIfSnapped(Geom::Point &p) const
{
// When we have snapped
if (getSnapped()) {
{
// When we have snapped
if (getSnapped()) {
@@ -127,7 +127,7 @@ bool getClosestSP(std::list<Inkscape::SnappedPoint> const &list, Inkscape::Snapp
bool Inkscape::SnappedPoint::isOtherSnapBetter(Inkscape::SnappedPoint const &other_one, bool weighted) const
{
bool Inkscape::SnappedPoint::isOtherSnapBetter(Inkscape::SnappedPoint const &other_one, bool weighted) const
{
- if (!other_one.getSnapped()) {
+ if (getSnapped() && !other_one.getSnapped()) {
return false;
}
return false;
}