Commit 98f6dd14 authored by Simon Barner's avatar Simon Barner

Merge branch '4119' into 'master'

4119

See merge request !31
parents 2b764705 33162fde
ChannelVisual.java 3cdee0047f9ee3f9414488551d471b2e9f74ad67 GREEN
ContentComponentPortVisual.java 6e398120650316a0649173efd70c508efd3b5d09 GREEN
ContentComponentVisual.java 78fb7e6210f1d3fc37b869c18b11f37e73daec04 GREEN
ContentComponentVisual.java d6b5a36bd42784be9aa259cb1c5a6338027ad8f6 GREEN
DiagramComponentPortVisual.java 918915c5801064ebfb2bb6028f4e588256b1aefe GREEN
......@@ -54,8 +54,11 @@ public final class ContentComponentVisual extends NamedLayoutedRectangularConten
/** The plug-in ID. */
public static final String PLUGIN_ID = AF3ComponentUIActivator.class.getPackage().getName();
/** The icon image. */
private static final Image ICON = getFXImage(PLUGIN_ID, "/icons/component.gif");
/** The icon for weekly causal {@link Component}s. */
private static Image WEAKLY_CAUSAL_ICON = getFXImage(PLUGIN_ID, "/icons/component.gif");
/** The icon for strongly causal {@link Component}s. */
private static Image STRONGLY_CAUSAL_ICON =
getFXImage(PLUGIN_ID, "/icons/component_stronglycausal.gif");
/** The fill color used by composite components. */
private static final Color COMPOSITE_COLOR = convertColor(SUBSTRUCTURE_COMPONENT_BACKGROUND);
/** The fill color used by strongly causal components. */
......@@ -65,7 +68,7 @@ public final class ContentComponentVisual extends NamedLayoutedRectangularConten
private static final Color WEAKLY_CAUSAL_COLOR =
convertColor(WEAKLY_CAUSAL_COMPONENT_BACKGROUND);
/** Stores the last tooltip for uninstalling */
/** Stores the last tooltip for uninstalling. */
private Tooltip tooltip;
/** Constructor. */
......@@ -119,6 +122,13 @@ public final class ContentComponentVisual extends NamedLayoutedRectangularConten
/** {@inheritDoc} */
@Override
protected Image getIcon() {
return ICON;
Component cmp = getModelElement();
if(cmp.getSubComponents().isEmpty()) {
if(cmp.isStronglyCausal()) {
return STRONGLY_CAUSAL_ICON;
}
return WEAKLY_CAUSAL_ICON;
}
return null;
}
}
ChannelHandler.java 176f943f87a60c1f3fae0009d629301d62932c61 GREEN
CodeSpecificationHandler.java d4a4a95773d6fd37ffe5785dc0fa19616579cf87 GREEN
ComponentArchitectureHandler.java ca584540b3e7a754f24356f61d4d2744653efc19 GREEN
ComponentHandler.java aa8663371b053ce668b618e506a9314ac6aaa380 GREEN
ComponentHandler.java b8eb8dcb1a8b1a33aa491a0a057e6c1b1019111f GREEN
ComponentSpecificationsContainerHandler.java f20fe325352656c74895dcd400733dec1babf7a3 GREEN
IComponentBehaviorDefinitionHandler.java f7598bc4994fcae7a77be29b51f68fc9fca9d284 GREEN
InputPortHandler.java 60baa521dd501d1e3cf2b864cdf5055207ab84e9 GREEN
LibraryComponentHandler.java 9b07c0d08bb2afc4defebc0a8666b265b2776e22 GREEN
LibraryComponentPackageHandler.java 04678ed7dd2f83967abade2f73e9014f40a20950 GREEN
OutputPortHandler.java 77ad3f443057c3107947d00165857fe49e8ed11a GREEN
......@@ -46,6 +46,9 @@ public class ComponentHandler extends NamedCommentedModelElementHandlerBase<Comp
/** {@inheritDoc} */
@Override
protected String getIconPath(Component element) {
if(element.isStronglyCausal())
return "icons/component_stronglycausal.gif";
return "icons/component.gif";
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment