]> gerrit.simantics Code Review - simantics/district.git/blobdiff - org.simantics.district.network.ui/src/org/simantics/district/network/ui/nodes/DistrictNetworkHoverInfoNode.java
Fixed NPE, labels == null
[simantics/district.git] / org.simantics.district.network.ui / src / org / simantics / district / network / ui / nodes / DistrictNetworkHoverInfoNode.java
index f263dc2216383bf90c0f5c223982d6deaf787453..316370bd2911042683593fb0a1950825517c5859 100644 (file)
@@ -67,7 +67,7 @@ public class DistrictNetworkHoverInfoNode extends G2DNode implements HoverSensit
     public void renderDeferred(Graphics2D g) {
         if (!hover || activeNode.get() == null)
             return;
-        if (labels.isEmpty() || mousePosition == null)
+        if (labels == null || labels.isEmpty() || mousePosition == null)
             return;
         AffineTransform ot = g.getTransform();
         Font of = g.getFont();