From e8514874e3bfee95b0b42799b4ec8962616793f7 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Jani=20M=C3=A4kinen?= Date: Tue, 28 May 2019 12:36:07 +0300 Subject: [PATCH] generateProposition uses component type name gitlab #299 Change-Id: Iee27e31d6f8b954ffedc6f31817669dd06ba0a9d --- .../org/simantics/modeling/services/ComponentNamingUtil.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bundles/org.simantics.modeling/src/org/simantics/modeling/services/ComponentNamingUtil.java b/bundles/org.simantics.modeling/src/org/simantics/modeling/services/ComponentNamingUtil.java index fc629bdb0..387b3a41a 100644 --- a/bundles/org.simantics.modeling/src/org/simantics/modeling/services/ComponentNamingUtil.java +++ b/bundles/org.simantics.modeling/src/org/simantics/modeling/services/ComponentNamingUtil.java @@ -189,7 +189,7 @@ public final class ComponentNamingUtil { if (containerGeneratedNamePrefix != null) proposition.append(containerGeneratedNamePrefix); String componentPrefix = graph.getPossibleRelatedValue(componentType, L0X.HasGeneratedNamePrefix, Bindings.STRING); - if (componentPrefix == null) { + if (componentPrefix == null || "".equals(componentPrefix)) { Layer0 L0 = Layer0.getInstance(graph); componentPrefix = graph.getPossibleRelatedValue(componentType, L0.HasName); if (componentPrefix == null) -- 2.47.1