summaryrefslogtreecommitdiffstats
path: root/src/livarot/Path.cpp
diff options
context:
space:
mode:
authorMichael Soegtrop <MSoegtrop@yahoo.de>2017-06-05 13:01:17 +0000
committerMichael Soegtrop <MSoegtrop@yahoo.de>2017-06-05 13:01:17 +0000
commite7248b2fa042f42a5c4dd14cd86ab6a5b4524059 (patch)
tree9097520c54e355ded9bd0b4d6618af4e8dacdd91 /src/livarot/Path.cpp
parentupdated to latest trunk (diff)
parent[Bug #1695016] Xaml export misses some radialGradients. (diff)
downloadinkscape-e7248b2fa042f42a5c4dd14cd86ab6a5b4524059.tar.gz
inkscape-e7248b2fa042f42a5c4dd14cd86ab6a5b4524059.zip
updated to latest trunk
(bzr r14876.2.4)
Diffstat (limited to 'src/livarot/Path.cpp')
-rw-r--r--src/livarot/Path.cpp20
1 files changed, 7 insertions, 13 deletions
diff --git a/src/livarot/Path.cpp b/src/livarot/Path.cpp
index 68891e4aa..5fa418968 100644
--- a/src/livarot/Path.cpp
+++ b/src/livarot/Path.cpp
@@ -380,24 +380,18 @@ void Path::InsertBezierTo(Geom::Point const &iPt, int iNb, int at)
/*
- * points de la polyligne
+ * points of the polyline
*/
void
Path::SetBackData (bool nVal)
{
- if (back == false) {
- if (nVal == true && back == false) {
+ if (! back) {
+ if (nVal) {
back = true;
ResetPoints();
- } else if (nVal == false && back == true) {
- back = false;
- ResetPoints();
}
} else {
- if (nVal == true && back == false) {
- back = true;
- ResetPoints();
- } else if (nVal == false && back == true) {
+ if (! nVal) {
back = false;
ResetPoints();
}
@@ -417,7 +411,7 @@ int Path::AddPoint(Geom::Point const &iPt, bool mvto)
return AddPoint (iPt, -1, 0.0, mvto);
}
- if ( !mvto && pts.empty() == false && pts.back().p == iPt ) {
+ if ( !mvto && !pts.empty() && pts.back().p == iPt ) {
return -1;
}
@@ -441,11 +435,11 @@ int Path::ReplacePoint(Geom::Point const &iPt)
int Path::AddPoint(Geom::Point const &iPt, int ip, double it, bool mvto)
{
- if (back == false) {
+ if (! back) {
return AddPoint (iPt, mvto);
}
- if ( !mvto && pts.empty() == false && pts.back().p == iPt ) {
+ if ( !mvto && !pts.empty() && pts.back().p == iPt ) {
return -1;
}