Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorCamille Letavernier2014-10-23 14:52:14 +0000
committerCamille Letavernier2014-10-23 15:04:44 +0000
commitfb77eb1a047622852720c386c33400b27ad35aca (patch)
tree27a3d8f3c4fb7a9ea6892910edca9bf7529dae54 /plugins/uml/textedit/org.eclipse.papyrus.uml.textedit.property.xtext.ui
parentf7c3d9f2a2ed45c584dee56e17ba0dd558fdeba9 (diff)
downloadorg.eclipse.papyrus-fb77eb1a047622852720c386c33400b27ad35aca.tar.gz
org.eclipse.papyrus-fb77eb1a047622852720c386c33400b27ad35aca.tar.xz
org.eclipse.papyrus-fb77eb1a047622852720c386c33400b27ad35aca.zip
448385: [XText Editors] Embedded editors must be tested
https://bugs.eclipse.org/bugs/show_bug.cgi?id=448385 - Add default value test for Ports and Properties
Diffstat (limited to 'plugins/uml/textedit/org.eclipse.papyrus.uml.textedit.property.xtext.ui')
-rw-r--r--plugins/uml/textedit/org.eclipse.papyrus.uml.textedit.property.xtext.ui/src/org/eclipse/papyrus/uml/textedit/property/xtext/ui/contributions/UMLPropertyEditorPropertyUtil.java10
1 files changed, 7 insertions, 3 deletions
diff --git a/plugins/uml/textedit/org.eclipse.papyrus.uml.textedit.property.xtext.ui/src/org/eclipse/papyrus/uml/textedit/property/xtext/ui/contributions/UMLPropertyEditorPropertyUtil.java b/plugins/uml/textedit/org.eclipse.papyrus.uml.textedit.property.xtext.ui/src/org/eclipse/papyrus/uml/textedit/property/xtext/ui/contributions/UMLPropertyEditorPropertyUtil.java
index 427c2b953c1..313c7b1689f 100644
--- a/plugins/uml/textedit/org.eclipse.papyrus.uml.textedit.property.xtext.ui/src/org/eclipse/papyrus/uml/textedit/property/xtext/ui/contributions/UMLPropertyEditorPropertyUtil.java
+++ b/plugins/uml/textedit/org.eclipse.papyrus.uml.textedit.property.xtext.ui/src/org/eclipse/papyrus/uml/textedit/property/xtext/ui/contributions/UMLPropertyEditorPropertyUtil.java
@@ -51,14 +51,18 @@ public class UMLPropertyEditorPropertyUtil extends PropertyUtil {
if (!multiplicity.trim().equals("[1]")) {
buffer.append(multiplicity);
}
+ buffer.append(" ");
// property modifiers
- buffer.append(" ");
- buffer.append(PropertyUtil.getModifiersAsString(property, false));
+ String modifiers = PropertyUtil.getModifiersAsString(property, false);
+ if (!"".equals(modifiers)) {
+ buffer.append(modifiers);
+ buffer.append(" ");
+ }
// default value
if (property.getDefault() != null) {
- buffer.append(" = ");
+ buffer.append("= ");
String defaultValue = new UMLSwitch<String>() {
@Override
public String caseLiteralBoolean(org.eclipse.uml2.uml.LiteralBoolean object) {

Back to the top