Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJuergen Haug2016-09-28 15:39:57 +0000
committerJuergen Haug2016-09-28 17:24:59 +0000
commit997adc473cb628a22ae725d9a8e0cfd59c21ce63 (patch)
tree602e7a1907a5b8eafff8ca22e413cc2b35e0685e /plugins/org.eclipse.etrice.ui.commands
parent0f9c9c6e619bec471621d34340f3f4e35828f36d (diff)
downloadorg.eclipse.etrice-997adc473cb628a22ae725d9a8e0cfd59c21ce63.tar.gz
org.eclipse.etrice-997adc473cb628a22ae725d9a8e0cfd59c21ce63.tar.xz
org.eclipse.etrice-997adc473cb628a22ae725d9a8e0cfd59c21ce63.zip
[diagram] Bug 502073 - improved naming for new elements
Diffstat (limited to 'plugins/org.eclipse.etrice.ui.commands')
-rw-r--r--plugins/org.eclipse.etrice.ui.commands/src/org/eclipse/etrice/ui/commands/handlers/EditBehaviorHandler.java8
1 files changed, 4 insertions, 4 deletions
diff --git a/plugins/org.eclipse.etrice.ui.commands/src/org/eclipse/etrice/ui/commands/handlers/EditBehaviorHandler.java b/plugins/org.eclipse.etrice.ui.commands/src/org/eclipse/etrice/ui/commands/handlers/EditBehaviorHandler.java
index 7b6f9fb18..f581a8c3f 100644
--- a/plugins/org.eclipse.etrice.ui.commands/src/org/eclipse/etrice/ui/commands/handlers/EditBehaviorHandler.java
+++ b/plugins/org.eclipse.etrice.ui.commands/src/org/eclipse/etrice/ui/commands/handlers/EditBehaviorHandler.java
@@ -19,7 +19,7 @@ import org.eclipse.etrice.core.room.ActorClass;
import org.eclipse.etrice.core.fsm.fSM.State;
import org.eclipse.etrice.core.fsm.fSM.StateGraph;
import org.eclipse.etrice.core.fsm.fSM.Transition;
-import org.eclipse.etrice.core.room.util.RoomUtil;
+import org.eclipse.etrice.core.room.util.RoomNewNamingUtil;
import org.eclipse.etrice.core.ui.RoomUiModule;
import org.eclipse.etrice.ui.behavior.DiagramAccess;
import org.eclipse.jface.dialogs.MessageDialog;
@@ -61,7 +61,7 @@ public class EditBehaviorHandler extends AbstractEditHandler {
public void process(XtextResource resource) throws Exception {
if (resource != null) {
Injector injector = RoomUiModule.getInjector();
- RoomUtil util = injector.getInstance(RoomUtil.class);
+ RoomNewNamingUtil util = injector.getInstance(RoomNewNamingUtil.class);
EObject object = resource.getEObject(fragment);
if (object instanceof ActorClass) {
@@ -70,13 +70,13 @@ public class EditBehaviorHandler extends AbstractEditHandler {
}
}
- private void createTransitionNames(StateGraph sg, RoomUtil util) {
+ private void createTransitionNames(StateGraph sg, RoomNewNamingUtil util) {
if (sg==null)
return;
for (Transition tr : sg.getTransitions()) {
if (tr.getName()==null || tr.getName().isEmpty()) {
- tr.setName(util.getUniqueTransitionName(sg));
+ tr.setName(util.getUniqueName("tr", sg));
}
}

Back to the top