Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authoratischenko2015-09-24 07:43:37 -0400
committeratischenko2015-09-24 07:43:37 -0400
commite401a1ff28f05bc051f97eeab0af31a593ba43ab (patch)
tree55dd6d6f021af94f8f5f43fcfed167316a4b67b2
parentfb8c19288b22074446c592ad55e5d18f94f97d18 (diff)
downloadorg.eclipse.gmf-tooling-R3_3_maintenance.tar.gz
org.eclipse.gmf-tooling-R3_3_maintenance.tar.xz
org.eclipse.gmf-tooling-R3_3_maintenance.zip
LinkLF - fix NPE while move affixed node with connected linkR3_3_maintenance
Change-Id: Ia3a4dc3ce75f269ba4ae5746863e9f810dc5913e Signed-off-by: atischenko <tischenko@montages.com>
-rw-r--r--plugins/org.eclipse.gmf.tooling.runtime/src/org/eclipse/gmf/tooling/runtime/linklf/policies/AdjustBorderItemAnchorsEditPolicy.java7
1 files changed, 6 insertions, 1 deletions
diff --git a/plugins/org.eclipse.gmf.tooling.runtime/src/org/eclipse/gmf/tooling/runtime/linklf/policies/AdjustBorderItemAnchorsEditPolicy.java b/plugins/org.eclipse.gmf.tooling.runtime/src/org/eclipse/gmf/tooling/runtime/linklf/policies/AdjustBorderItemAnchorsEditPolicy.java
index eeb9ab2bd..905d24e08 100644
--- a/plugins/org.eclipse.gmf.tooling.runtime/src/org/eclipse/gmf/tooling/runtime/linklf/policies/AdjustBorderItemAnchorsEditPolicy.java
+++ b/plugins/org.eclipse.gmf.tooling.runtime/src/org/eclipse/gmf/tooling/runtime/linklf/policies/AdjustBorderItemAnchorsEditPolicy.java
@@ -189,8 +189,13 @@ public class AdjustBorderItemAnchorsEditPolicy extends
protected PrecisionPoint rotateAnchorLocation(ConnectionAnchor anchor,
int quarters) {
String terminal = ((BaseSlidableAnchor) anchor).getTerminal();
- PrecisionPoint result = BaseSlidableAnchor
+ PrecisionPoint result;
+ if (terminal.length() == 0) {
+ result = new PrecisionPoint(0.5, 0.5);
+ } else {
+ result = BaseSlidableAnchor
.parseTerminalString(terminal);
+ }
for (int i = 0; i < quarters; i++) {
double newX = 1. - result.preciseY();
double newY = result.preciseX();

Back to the top