Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorHenrik Rentz-Reichert2012-12-13 06:00:16 -0500
committerHenrik Rentz-Reichert2012-12-13 11:28:16 -0500
commitaa31e3d31fb365a041c55d7e6704bda925f8fb6a (patch)
tree27ad9c6d74bdc16f46055260ca12b8ce4a717ac6 /plugins
parentdf45f0f3129802f1c328993ed087444a88152b48 (diff)
downloadorg.eclipse.etrice-aa31e3d31fb365a041c55d7e6704bda925f8fb6a.tar.gz
org.eclipse.etrice-aa31e3d31fb365a041c55d7e6704bda925f8fb6a.tar.xz
org.eclipse.etrice-aa31e3d31fb365a041c55d7e6704bda925f8fb6a.zip
[ui.structure] improved tool tip
Diffstat (limited to 'plugins')
-rw-r--r--plugins/org.eclipse.etrice.ui.structure/src/org/eclipse/etrice/ui/structure/support/InterfaceItemSupport.java15
1 files changed, 11 insertions, 4 deletions
diff --git a/plugins/org.eclipse.etrice.ui.structure/src/org/eclipse/etrice/ui/structure/support/InterfaceItemSupport.java b/plugins/org.eclipse.etrice.ui.structure/src/org/eclipse/etrice/ui/structure/support/InterfaceItemSupport.java
index 85258bc56..e1a2f543a 100644
--- a/plugins/org.eclipse.etrice.ui.structure/src/org/eclipse/etrice/ui/structure/support/InterfaceItemSupport.java
+++ b/plugins/org.eclipse.etrice.ui.structure/src/org/eclipse/etrice/ui/structure/support/InterfaceItemSupport.java
@@ -693,11 +693,18 @@ public class InterfaceItemSupport {
EObject bo = Graphiti.getLinkService().getBusinessObjectForLinkedPictogramElement(pe);
if (bo instanceof InterfaceItem) {
- String name = ((InterfaceItem) bo).getName();
- String protocol = RoomHelpers.getGeneralProtocol(((InterfaceItem) bo)).getName();
- if (bo instanceof Port)
- if (((Port) bo).isConjugated())
+ InterfaceItem ifitem = (InterfaceItem) bo;
+ String name = ifitem.getName();
+ String protocol = RoomHelpers.getGeneralProtocol(ifitem).getName();
+ if (ifitem instanceof Port) {
+ Port port = (Port) ifitem;
+ if (port.getMultiplicity()==-1)
+ name += "[*]";
+ else if (port.getMultiplicity()>1)
+ name += "["+port.getMultiplicity()+"]";
+ if (port.isConjugated())
protocol = "conj "+protocol;
+ }
return name+"\n("+protocol+")";
}

Back to the top