Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorNicolas FAUVERGUE2016-03-08 14:13:21 +0000
committerGerrit Code Review @ Eclipse.org2016-03-08 16:14:45 +0000
commitcd74b3e5dacd06b495f45294188ec0b9b854755f (patch)
treea7a252a27c72e01f97a3866530e741ef70b06f07 /plugins/infra
parentd0b87e9e0c09569e9ee16db2d058af1096c0d7c3 (diff)
downloadorg.eclipse.papyrus-cd74b3e5dacd06b495f45294188ec0b9b854755f.tar.gz
org.eclipse.papyrus-cd74b3e5dacd06b495f45294188ec0b9b854755f.tar.xz
org.eclipse.papyrus-cd74b3e5dacd06b495f45294188ec0b9b854755f.zip
Bug 487024: [Table] [CellEditor] The cell editors must manage datatypes
from EMF https://bugs.eclipse.org/bugs/show_bug.cgi?id=487024 Remove the EMF constants from UML constants to use the the EMF constants available in the EMF plugin. Change-Id: I7f5009b3b5ff203b2e8ff3882d0b943db58c9287 Signed-off-by: Nicolas FAUVERGUE <nicolas.fauvergue@all4tec.net>
Diffstat (limited to 'plugins/infra')
-rw-r--r--plugins/infra/core/org.eclipse.papyrus.infra.tools/src/org/eclipse/papyrus/infra/tools/util/TypesConstants.java8
-rw-r--r--plugins/infra/nattable/org.eclipse.papyrus.infra.emf.nattable/src/org/eclipse/papyrus/infra/emf/nattable/celleditor/config/SingleBooleanCellEditorConfiguration.java3
-rw-r--r--plugins/infra/nattable/org.eclipse.papyrus.infra.emf.nattable/src/org/eclipse/papyrus/infra/emf/nattable/celleditor/config/SingleIntegerCellEditorConfiguration.java3
-rw-r--r--plugins/infra/nattable/org.eclipse.papyrus.infra.emf.nattable/src/org/eclipse/papyrus/infra/emf/nattable/celleditor/config/SingleStringCellEditorConfiguration.java3
-rwxr-xr-xplugins/infra/nattable/org.eclipse.papyrus.infra.emf.nattable/src/org/eclipse/papyrus/infra/emf/nattable/filter/configuration/EBooleanComboBoxCellEditorFilterConfiguration.java3
-rw-r--r--plugins/infra/nattable/org.eclipse.papyrus.infra.emf.nattable/src/org/eclipse/papyrus/infra/emf/nattable/filter/configuration/EDoubleEditorFilterConfiguration.java3
-rw-r--r--plugins/infra/nattable/org.eclipse.papyrus.infra.emf.nattable/src/org/eclipse/papyrus/infra/emf/nattable/filter/configuration/EIntegereEditorFilterConfiguration.java3
7 files changed, 12 insertions, 14 deletions
diff --git a/plugins/infra/core/org.eclipse.papyrus.infra.tools/src/org/eclipse/papyrus/infra/tools/util/TypesConstants.java b/plugins/infra/core/org.eclipse.papyrus.infra.tools/src/org/eclipse/papyrus/infra/tools/util/TypesConstants.java
index b4359d2cee0..cf4a1a84be0 100644
--- a/plugins/infra/core/org.eclipse.papyrus.infra.tools/src/org/eclipse/papyrus/infra/tools/util/TypesConstants.java
+++ b/plugins/infra/core/org.eclipse.papyrus.infra.tools/src/org/eclipse/papyrus/infra/tools/util/TypesConstants.java
@@ -29,18 +29,10 @@ public class TypesConstants {
public static final String STRING = "String"; //$NON-NLS-1$
- public static final String ESTRING = "EString"; //$NON-NLS-1$
-
public static final String BOOLEAN = "Boolean"; //$NON-NLS-1$
- public static final String EBOOLEAN = "EBoolean"; //$NON-NLS-1$
-
public static final String INTEGER = "Integer"; //$NON-NLS-1$
- public static final String EINT = "EInt"; //$NON-NLS-1$
-
public static final String DOUBLE = "Double"; //$NON-NLS-1$
-
- public static final String EDOUBLE = "EDouble"; //$NON-NLS-1$
}
diff --git a/plugins/infra/nattable/org.eclipse.papyrus.infra.emf.nattable/src/org/eclipse/papyrus/infra/emf/nattable/celleditor/config/SingleBooleanCellEditorConfiguration.java b/plugins/infra/nattable/org.eclipse.papyrus.infra.emf.nattable/src/org/eclipse/papyrus/infra/emf/nattable/celleditor/config/SingleBooleanCellEditorConfiguration.java
index 21d2414bee6..49a370cc8b5 100644
--- a/plugins/infra/nattable/org.eclipse.papyrus.infra.emf.nattable/src/org/eclipse/papyrus/infra/emf/nattable/celleditor/config/SingleBooleanCellEditorConfiguration.java
+++ b/plugins/infra/nattable/org.eclipse.papyrus.infra.emf.nattable/src/org/eclipse/papyrus/infra/emf/nattable/celleditor/config/SingleBooleanCellEditorConfiguration.java
@@ -22,6 +22,7 @@ import org.eclipse.nebula.widgets.nattable.data.convert.DefaultBooleanDisplayCon
import org.eclipse.nebula.widgets.nattable.edit.EditConfigAttributes;
import org.eclipse.nebula.widgets.nattable.edit.editor.CheckBoxCellEditor;
import org.eclipse.nebula.widgets.nattable.style.DisplayMode;
+import org.eclipse.papyrus.infra.emf.utils.EMFContants;
import org.eclipse.papyrus.infra.nattable.celleditor.config.ICellAxisConfiguration;
import org.eclipse.papyrus.infra.nattable.model.nattable.Table;
import org.eclipse.papyrus.infra.nattable.painter.CustomCheckBoxPainter;
@@ -75,7 +76,7 @@ public class SingleBooleanCellEditorConfiguration implements ICellAxisConfigurat
EClassifier etype = feature.getEType();
if (etype instanceof EDataType) {
EDataType datatype = (EDataType) etype;
- return TypesConstants.BOOLEAN.equals(datatype.getName()) || TypesConstants.EBOOLEAN.equals(datatype.getName());
+ return TypesConstants.BOOLEAN.equals(datatype.getName()) || EMFContants.EBOOLEAN.equals(datatype.getName());
}
}
}
diff --git a/plugins/infra/nattable/org.eclipse.papyrus.infra.emf.nattable/src/org/eclipse/papyrus/infra/emf/nattable/celleditor/config/SingleIntegerCellEditorConfiguration.java b/plugins/infra/nattable/org.eclipse.papyrus.infra.emf.nattable/src/org/eclipse/papyrus/infra/emf/nattable/celleditor/config/SingleIntegerCellEditorConfiguration.java
index 2037921177e..ef95a7d8385 100644
--- a/plugins/infra/nattable/org.eclipse.papyrus.infra.emf.nattable/src/org/eclipse/papyrus/infra/emf/nattable/celleditor/config/SingleIntegerCellEditorConfiguration.java
+++ b/plugins/infra/nattable/org.eclipse.papyrus.infra.emf.nattable/src/org/eclipse/papyrus/infra/emf/nattable/celleditor/config/SingleIntegerCellEditorConfiguration.java
@@ -23,6 +23,7 @@ import org.eclipse.nebula.widgets.nattable.edit.EditConfigAttributes;
import org.eclipse.nebula.widgets.nattable.edit.editor.TextCellEditor;
import org.eclipse.nebula.widgets.nattable.painter.cell.TextPainter;
import org.eclipse.nebula.widgets.nattable.style.DisplayMode;
+import org.eclipse.papyrus.infra.emf.utils.EMFContants;
import org.eclipse.papyrus.infra.nattable.celleditor.config.ICellAxisConfiguration;
import org.eclipse.papyrus.infra.nattable.model.nattable.Table;
import org.eclipse.papyrus.infra.nattable.utils.AxisUtils;
@@ -75,7 +76,7 @@ public class SingleIntegerCellEditorConfiguration implements ICellAxisConfigurat
EClassifier etype = feature.getEType();
if (etype instanceof EDataType) {
EDataType datatype = (EDataType) etype;
- return TypesConstants.INTEGER.equals(datatype.getName()) || TypesConstants.EINT.equals(datatype.getName());
+ return TypesConstants.INTEGER.equals(datatype.getName()) || EMFContants.EINT.equals(datatype.getName());
}
}
}
diff --git a/plugins/infra/nattable/org.eclipse.papyrus.infra.emf.nattable/src/org/eclipse/papyrus/infra/emf/nattable/celleditor/config/SingleStringCellEditorConfiguration.java b/plugins/infra/nattable/org.eclipse.papyrus.infra.emf.nattable/src/org/eclipse/papyrus/infra/emf/nattable/celleditor/config/SingleStringCellEditorConfiguration.java
index 6052838bfbf..82c83fdfc6c 100644
--- a/plugins/infra/nattable/org.eclipse.papyrus.infra.emf.nattable/src/org/eclipse/papyrus/infra/emf/nattable/celleditor/config/SingleStringCellEditorConfiguration.java
+++ b/plugins/infra/nattable/org.eclipse.papyrus.infra.emf.nattable/src/org/eclipse/papyrus/infra/emf/nattable/celleditor/config/SingleStringCellEditorConfiguration.java
@@ -21,6 +21,7 @@ import org.eclipse.nebula.widgets.nattable.config.IConfigRegistry;
import org.eclipse.nebula.widgets.nattable.edit.EditConfigAttributes;
import org.eclipse.nebula.widgets.nattable.painter.cell.TextPainter;
import org.eclipse.nebula.widgets.nattable.style.DisplayMode;
+import org.eclipse.papyrus.infra.emf.utils.EMFContants;
import org.eclipse.papyrus.infra.nattable.celleditor.MultiLineTextCellEditorEx;
import org.eclipse.papyrus.infra.nattable.celleditor.config.ICellAxisConfiguration;
import org.eclipse.papyrus.infra.nattable.model.nattable.Table;
@@ -74,7 +75,7 @@ public class SingleStringCellEditorConfiguration implements ICellAxisConfigurati
EClassifier etype = feature.getEType();
if (etype instanceof EDataType) {
EDataType datatype = (EDataType) etype;
- return TypesConstants.STRING.equals(datatype.getName()) || TypesConstants.ESTRING.equals(datatype.getName());
+ return TypesConstants.STRING.equals(datatype.getName()) || EMFContants.ESTRING.equals(datatype.getName());
}
}
}
diff --git a/plugins/infra/nattable/org.eclipse.papyrus.infra.emf.nattable/src/org/eclipse/papyrus/infra/emf/nattable/filter/configuration/EBooleanComboBoxCellEditorFilterConfiguration.java b/plugins/infra/nattable/org.eclipse.papyrus.infra.emf.nattable/src/org/eclipse/papyrus/infra/emf/nattable/filter/configuration/EBooleanComboBoxCellEditorFilterConfiguration.java
index 1b494f2d75f..810d3ed71a0 100755
--- a/plugins/infra/nattable/org.eclipse.papyrus.infra.emf.nattable/src/org/eclipse/papyrus/infra/emf/nattable/filter/configuration/EBooleanComboBoxCellEditorFilterConfiguration.java
+++ b/plugins/infra/nattable/org.eclipse.papyrus.infra.emf.nattable/src/org/eclipse/papyrus/infra/emf/nattable/filter/configuration/EBooleanComboBoxCellEditorFilterConfiguration.java
@@ -17,6 +17,7 @@ import org.eclipse.emf.ecore.EClassifier;
import org.eclipse.emf.ecore.EDataType;
import org.eclipse.emf.ecore.EStructuralFeature;
import org.eclipse.nebula.widgets.nattable.config.IConfigRegistry;
+import org.eclipse.papyrus.infra.emf.utils.EMFContants;
import org.eclipse.papyrus.infra.nattable.filter.configuration.AbstractBooleanComboBoxCellEditorFilterConfiguration;
import org.eclipse.papyrus.infra.nattable.utils.AxisUtils;
import org.eclipse.papyrus.infra.tools.util.TypesConstants;
@@ -48,7 +49,7 @@ public class EBooleanComboBoxCellEditorFilterConfiguration extends AbstractBoole
EClassifier etype = feature.getEType();
if (etype instanceof EDataType) {
EDataType datatype = (EDataType) etype;
- return TypesConstants.BOOLEAN.equals(datatype.getName()) || TypesConstants.EBOOLEAN.equals(datatype.getName());
+ return TypesConstants.BOOLEAN.equals(datatype.getName()) || EMFContants.EBOOLEAN.equals(datatype.getName());
}
}
return false;
diff --git a/plugins/infra/nattable/org.eclipse.papyrus.infra.emf.nattable/src/org/eclipse/papyrus/infra/emf/nattable/filter/configuration/EDoubleEditorFilterConfiguration.java b/plugins/infra/nattable/org.eclipse.papyrus.infra.emf.nattable/src/org/eclipse/papyrus/infra/emf/nattable/filter/configuration/EDoubleEditorFilterConfiguration.java
index c91c995a8d5..0db8e6e36fe 100644
--- a/plugins/infra/nattable/org.eclipse.papyrus.infra.emf.nattable/src/org/eclipse/papyrus/infra/emf/nattable/filter/configuration/EDoubleEditorFilterConfiguration.java
+++ b/plugins/infra/nattable/org.eclipse.papyrus.infra.emf.nattable/src/org/eclipse/papyrus/infra/emf/nattable/filter/configuration/EDoubleEditorFilterConfiguration.java
@@ -17,6 +17,7 @@ import org.eclipse.emf.ecore.EClassifier;
import org.eclipse.emf.ecore.EDataType;
import org.eclipse.emf.ecore.EStructuralFeature;
import org.eclipse.nebula.widgets.nattable.config.IConfigRegistry;
+import org.eclipse.papyrus.infra.emf.utils.EMFContants;
import org.eclipse.papyrus.infra.nattable.filter.configuration.AbstractDoubleEditorFilterConfiguration;
import org.eclipse.papyrus.infra.nattable.utils.AxisUtils;
import org.eclipse.papyrus.infra.tools.util.TypesConstants;
@@ -47,7 +48,7 @@ public class EDoubleEditorFilterConfiguration extends AbstractDoubleEditorFilter
EClassifier etype = feature.getEType();
if (etype instanceof EDataType) {
EDataType datatype = (EDataType) etype;
- return TypesConstants.DOUBLE.equals(datatype.getName()) || TypesConstants.EDOUBLE.equals(datatype.getName());
+ return TypesConstants.DOUBLE.equals(datatype.getName()) || EMFContants.EDOUBLE.equals(datatype.getName());
}
}
return false;
diff --git a/plugins/infra/nattable/org.eclipse.papyrus.infra.emf.nattable/src/org/eclipse/papyrus/infra/emf/nattable/filter/configuration/EIntegereEditorFilterConfiguration.java b/plugins/infra/nattable/org.eclipse.papyrus.infra.emf.nattable/src/org/eclipse/papyrus/infra/emf/nattable/filter/configuration/EIntegereEditorFilterConfiguration.java
index e2390b18a89..bc7e1a2315d 100644
--- a/plugins/infra/nattable/org.eclipse.papyrus.infra.emf.nattable/src/org/eclipse/papyrus/infra/emf/nattable/filter/configuration/EIntegereEditorFilterConfiguration.java
+++ b/plugins/infra/nattable/org.eclipse.papyrus.infra.emf.nattable/src/org/eclipse/papyrus/infra/emf/nattable/filter/configuration/EIntegereEditorFilterConfiguration.java
@@ -17,6 +17,7 @@ import org.eclipse.emf.ecore.EClassifier;
import org.eclipse.emf.ecore.EDataType;
import org.eclipse.emf.ecore.EStructuralFeature;
import org.eclipse.nebula.widgets.nattable.config.IConfigRegistry;
+import org.eclipse.papyrus.infra.emf.utils.EMFContants;
import org.eclipse.papyrus.infra.nattable.filter.configuration.AbstractIntegerEditorFilterConfiguration;
import org.eclipse.papyrus.infra.nattable.utils.AxisUtils;
import org.eclipse.papyrus.infra.tools.util.TypesConstants;
@@ -47,7 +48,7 @@ public class EIntegereEditorFilterConfiguration extends AbstractIntegerEditorFil
EClassifier etype = feature.getEType();
if (etype instanceof EDataType) {
EDataType datatype = (EDataType) etype;
- return TypesConstants.INTEGER.equals(datatype.getName()) || TypesConstants.EINT.equals(datatype.getName());
+ return TypesConstants.INTEGER.equals(datatype.getName()) || EMFContants.EINT.equals(datatype.getName());
}
}
return false;

Back to the top