summaryrefslogtreecommitdiffstats
path: root/src/sp-offset.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/sp-offset.cpp')
-rw-r--r--src/sp-offset.cpp25
1 files changed, 9 insertions, 16 deletions
diff --git a/src/sp-offset.cpp b/src/sp-offset.cpp
index c5a3557a7..c6a4b730d 100644
--- a/src/sp-offset.cpp
+++ b/src/sp-offset.cpp
@@ -1133,28 +1133,21 @@ refresh_offset_source(SPOffset* offset)
return;
}
- SPItem *item = SP_ITEM (refobj);
-
- SPCurve *curve=NULL;
-
- if (!SP_IS_SHAPE (item) && !SP_IS_TEXT (item)) {
- return;
- }
+ SPItem *item = SP_ITEM (refobj);
+ SPCurve *curve = NULL;
if (SP_IS_SHAPE (item)) {
curve = SP_SHAPE (item)->getCurve ();
-
- if (curve == NULL) {
- return;
- }
}
-
- if (SP_IS_TEXT (item)) {
+ else if (SP_IS_TEXT (item)) {
curve = SP_TEXT (item)->getNormalizedBpath ();
+ }
+ else {
+ return;
+ }
- if (curve == NULL) {
- return;
- }
+ if (curve == NULL) {
+ return;
}
Path *orig = new Path;