Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorNathalie Lepine2015-03-06 10:08:49 +0000
committerNathalie Lepine2015-03-06 10:08:49 +0000
commite610b7a88025298a2da27bf877ab992773c40f43 (patch)
treea90cbefac77e142faaadee46f19f70823f8d8752
parent5c788e04d28ca732756339eff8c14d09e82b495c (diff)
downloadorg.eclipse.eef-e610b7a88025298a2da27bf877ab992773c40f43.tar.gz
org.eclipse.eef-e610b7a88025298a2da27bf877ab992773c40f43.tar.xz
org.eclipse.eef-e610b7a88025298a2da27bf877ab992773c40f43.zip
add drag n drop from ElementEditor to property binding
-rw-r--r--plugins/org.eclipse.emf.eef.editor/src-gen/org/eclipse/emf/eef/runtime/editingModel/provider/EClassBindingItemProvider.java31
-rw-r--r--plugins/org.eclipse.emf.eef.editor/src-gen/org/eclipse/emf/eef/runtime/editingModel/provider/EStructuralFeatureBindingItemProvider.java20
-rw-r--r--plugins/org.eclipse.emf.eef.editor/src-gen/org/eclipse/emf/eef/runtime/editingModel/provider/PropertyBindingItemProvider.java69
-rw-r--r--plugins/org.eclipse.emf.eef.editor/src-gen/org/eclipse/emf/eef/views/provider/CategoryItemProvider.java8
-rw-r--r--plugins/org.eclipse.emf.eef.editor/src-gen/org/eclipse/emf/eef/views/provider/ContainerItemProvider.java8
-rw-r--r--plugins/org.eclipse.emf.eef.editor/src-gen/org/eclipse/emf/eef/views/provider/CustomElementEditorItemProvider.java8
-rw-r--r--plugins/org.eclipse.emf.eef.editor/src-gen/org/eclipse/emf/eef/views/provider/CustomViewItemProvider.java8
-rw-r--r--plugins/org.eclipse.emf.eef.editor/src-gen/org/eclipse/emf/eef/views/provider/ElementEditorItemProvider.java77
-rw-r--r--plugins/org.eclipse.emf.eef.editor/src-gen/org/eclipse/emf/eef/views/provider/ViewElementItemProvider.java8
-rw-r--r--plugins/org.eclipse.emf.eef.editor/src-gen/org/eclipse/emf/eef/views/provider/ViewItemProvider.java8
-rw-r--r--plugins/org.eclipse.emf.eef.editor/src-gen/org/eclipse/emf/eef/views/provider/ViewReferenceItemProvider.java8
-rw-r--r--plugins/org.eclipse.emf.eef.editor/src-gen/org/eclipse/emf/eef/views/provider/ViewsRepositoryItemProvider.java2
-rw-r--r--plugins/org.eclipse.emf.eef.editor/src/org/eclipse/emf/eef/editor/internal/binding/command/PropertyBindingDragAndDropCommand.java136
-rw-r--r--plugins/org.eclipse.emf.eef.runtime.ui/META-INF/MANIFEST.MF24
-rw-r--r--plugins/org.eclipse.emf.eef.runtime.ui/model/views.ecore7
-rw-r--r--plugins/org.eclipse.emf.eef.runtime.ui/model/views.genmodel10
-rw-r--r--plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/Category.java2
-rw-r--r--plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/Container.java2
-rw-r--r--plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/DocumentedElement.java2
-rw-r--r--plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/ElementEditor.java2
-rw-r--r--plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/IdentifiedElement.java2
-rw-r--r--plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/View.java2
-rw-r--r--plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/ViewElement.java10
-rw-r--r--plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/ViewReference.java2
-rw-r--r--plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/ViewsRepository.java6
-rw-r--r--plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/impl/CategoryImpl.java5
-rw-r--r--plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/impl/ContainerImpl.java3
-rw-r--r--plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/impl/CustomElementEditorImpl.java1
-rw-r--r--plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/impl/CustomViewImpl.java1
-rw-r--r--plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/impl/DocumentedElementImpl.java3
-rw-r--r--plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/impl/ElementEditorImpl.java3
-rw-r--r--plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/impl/IdentifiedElementImpl.java3
-rw-r--r--plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/impl/ViewElementImpl.java27
-rw-r--r--plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/impl/ViewImpl.java7
-rw-r--r--plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/impl/ViewReferenceImpl.java3
-rw-r--r--plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/impl/ViewsFactoryImpl.java2
-rw-r--r--plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/impl/ViewsPackageImpl.java6
-rw-r--r--plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/impl/ViewsRepositoryImpl.java3
-rw-r--r--plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/toolkits/Toolkit.java2
-rw-r--r--plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/toolkits/Widget.java2
-rw-r--r--plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/toolkits/impl/ToolkitImpl.java3
-rw-r--r--plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/toolkits/impl/ToolkitsFactoryImpl.java2
-rw-r--r--plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/toolkits/impl/WidgetImpl.java5
-rw-r--r--plugins/org.eclipse.emf.eef.runtime.ui/src/org/eclipse/emf/eef/runtime/ui/util/BindingSettingsBuilder.java30
-rw-r--r--plugins/org.eclipse.emf.eef.runtime/model/editingModel.ecore1
-rw-r--r--plugins/org.eclipse.emf.eef.runtime/model/editingModel.genmodel1
-rw-r--r--plugins/org.eclipse.emf.eef.runtime/src-gen/org/eclipse/emf/eef/runtime/editingModel/PropertyBinding.java8
-rw-r--r--plugins/org.eclipse.emf.eef.runtime/src-gen/org/eclipse/emf/eef/runtime/editingModel/impl/EditingModelPackageImpl.java2
-rw-r--r--plugins/org.eclipse.emf.eef.runtime/src-gen/org/eclipse/emf/eef/runtime/editingModel/impl/PropertyBindingImpl.java21
49 files changed, 435 insertions, 171 deletions
diff --git a/plugins/org.eclipse.emf.eef.editor/src-gen/org/eclipse/emf/eef/runtime/editingModel/provider/EClassBindingItemProvider.java b/plugins/org.eclipse.emf.eef.editor/src-gen/org/eclipse/emf/eef/runtime/editingModel/provider/EClassBindingItemProvider.java
index b9fc3639a..d46dd7cf2 100644
--- a/plugins/org.eclipse.emf.eef.editor/src-gen/org/eclipse/emf/eef/runtime/editingModel/provider/EClassBindingItemProvider.java
+++ b/plugins/org.eclipse.emf.eef.editor/src-gen/org/eclipse/emf/eef/runtime/editingModel/provider/EClassBindingItemProvider.java
@@ -81,18 +81,26 @@ public class EClassBindingItemProvider extends ItemProviderAdapter implements IE
* @generated
*/
protected void addEClassPropertyDescriptor(Object object) {
- itemPropertyDescriptors.add(createItemPropertyDescriptor(((ComposeableAdapterFactory) adapterFactory).getRootAdapterFactory(), getResourceLocator(), getString("_UI_EClassBinding_eClass_feature"),
- getString("_UI_PropertyDescriptor_description", "_UI_EClassBinding_eClass_feature", "_UI_EClassBinding_type"), EditingModelPackage.Literals.ECLASS_BINDING__ECLASS, true, false, true, null, null, null));
+ itemPropertyDescriptors.add
+ (createItemPropertyDescriptor
+ (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
+ getResourceLocator(),
+ getString("_UI_EClassBinding_eClass_feature"),
+ getString("_UI_PropertyDescriptor_description", "_UI_EClassBinding_eClass_feature", "_UI_EClassBinding_type"),
+ EditingModelPackage.Literals.ECLASS_BINDING__ECLASS,
+ true,
+ false,
+ true,
+ null,
+ null,
+ null));
}
/**
- * This specifies how to implement {@link #getChildren} and is used to
- * deduce an appropriate feature for an
- * {@link org.eclipse.emf.edit.command.AddCommand},
- * {@link org.eclipse.emf.edit.command.RemoveCommand} or
- * {@link org.eclipse.emf.edit.command.MoveCommand} in
- * {@link #createCommand}. <!-- begin-user-doc --> <!-- end-user-doc -->
- *
+ * This specifies how to implement {@link #getChildren} and is used to deduce an appropriate feature for an
+ * {@link org.eclipse.emf.edit.command.AddCommand}, {@link org.eclipse.emf.edit.command.RemoveCommand} or
+ * {@link org.eclipse.emf.edit.command.MoveCommand} in {@link #createCommand}.
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
* @generated
*/
@Override
@@ -107,13 +115,11 @@ public class EClassBindingItemProvider extends ItemProviderAdapter implements IE
/**
* <!-- begin-user-doc --> <!-- end-user-doc -->
- *
* @generated
*/
@Override
protected EStructuralFeature getChildFeature(Object object, Object child) {
- // Check the type of the specified child object and return the proper
- // feature to use for
+ // Check the type of the specified child object and return the proper feature to use for
// adding (see {@link AddCommand}) it as a child.
return super.getChildFeature(object, child);
@@ -132,7 +138,6 @@ public class EClassBindingItemProvider extends ItemProviderAdapter implements IE
/**
* <!-- begin-user-doc --> <!-- end-user-doc -->
- *
* @generated
*/
@Override
diff --git a/plugins/org.eclipse.emf.eef.editor/src-gen/org/eclipse/emf/eef/runtime/editingModel/provider/EStructuralFeatureBindingItemProvider.java b/plugins/org.eclipse.emf.eef.editor/src-gen/org/eclipse/emf/eef/runtime/editingModel/provider/EStructuralFeatureBindingItemProvider.java
index c0cf16d2f..a1032ed47 100644
--- a/plugins/org.eclipse.emf.eef.editor/src-gen/org/eclipse/emf/eef/runtime/editingModel/provider/EStructuralFeatureBindingItemProvider.java
+++ b/plugins/org.eclipse.emf.eef.editor/src-gen/org/eclipse/emf/eef/runtime/editingModel/provider/EStructuralFeatureBindingItemProvider.java
@@ -25,10 +25,8 @@ import org.eclipse.emf.eef.runtime.editingModel.PropertyBinding;
import org.eclipse.emf.eef.views.ElementEditor;
/**
- * This is the item provider adapter for a
- * {@link org.eclipse.emf.eef.runtime.editingModel.EStructuralFeatureBinding}
- * object. <!-- begin-user-doc --> <!-- end-user-doc -->
- *
+ * This is the item provider adapter for a {@link org.eclipse.emf.eef.runtime.editingModel.EStructuralFeatureBinding} object.
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
* @generated
*/
public class EStructuralFeatureBindingItemProvider extends PropertyBindingItemProvider {
@@ -82,9 +80,9 @@ public class EStructuralFeatureBindingItemProvider extends PropertyBindingItemPr
}
/**
- * This returns EStructuralFeatureBinding.gif. <!-- begin-user-doc --> <!--
+ * This returns EStructuralFeatureBinding.gif.
+ * <!-- begin-user-doc --> <!--
* end-user-doc -->
- *
* @generated
*/
@Override
@@ -94,7 +92,6 @@ public class EStructuralFeatureBindingItemProvider extends PropertyBindingItemPr
/**
* <!-- begin-user-doc --> <!-- end-user-doc -->
- *
* @generated
*/
@Override
@@ -139,12 +136,11 @@ public class EStructuralFeatureBindingItemProvider extends PropertyBindingItemPr
}
/**
- * This handles model notifications by calling {@link #updateChildren} to
- * update any cached children and by creating a viewer notification, which
- * it passes to {@link #fireNotifyChanged}. <!-- begin-user-doc --> <!--
+ * This handles model notifications by calling {@link #updateChildren} to update any cached
+ * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}.
+ * <!-- begin-user-doc --> <!--
* end-user-doc -->
- *
- * @generated
+ * @generated not
*/
@Override
public void notifyChanged(Notification notification) {
diff --git a/plugins/org.eclipse.emf.eef.editor/src-gen/org/eclipse/emf/eef/runtime/editingModel/provider/PropertyBindingItemProvider.java b/plugins/org.eclipse.emf.eef.editor/src-gen/org/eclipse/emf/eef/runtime/editingModel/provider/PropertyBindingItemProvider.java
index 3d7df8789..77d0c6828 100644
--- a/plugins/org.eclipse.emf.eef.editor/src-gen/org/eclipse/emf/eef/runtime/editingModel/provider/PropertyBindingItemProvider.java
+++ b/plugins/org.eclipse.emf.eef.editor/src-gen/org/eclipse/emf/eef/runtime/editingModel/provider/PropertyBindingItemProvider.java
@@ -9,11 +9,13 @@ package org.eclipse.emf.eef.runtime.editingModel.provider;
import java.util.Collection;
import java.util.List;
+import org.eclipse.emf.common.command.Command;
import org.eclipse.emf.common.notify.AdapterFactory;
import org.eclipse.emf.common.notify.Notification;
import org.eclipse.emf.common.util.ResourceLocator;
import org.eclipse.emf.ecore.EObject;
import org.eclipse.emf.ecore.EStructuralFeature;
+import org.eclipse.emf.edit.domain.EditingDomain;
import org.eclipse.emf.edit.provider.ComposeableAdapterFactory;
import org.eclipse.emf.edit.provider.IEditingDomainItemProvider;
import org.eclipse.emf.edit.provider.IItemLabelProvider;
@@ -25,12 +27,14 @@ import org.eclipse.emf.edit.provider.ItemPropertyDescriptor;
import org.eclipse.emf.edit.provider.ItemProviderAdapter;
import org.eclipse.emf.edit.provider.ViewerNotification;
import org.eclipse.emf.eef.editor.EditingModelEditPlugin;
+import org.eclipse.emf.eef.editor.internal.binding.command.PropertyBindingDragAndDropCommand;
import org.eclipse.emf.eef.runtime.editingModel.EObjectEditor;
import org.eclipse.emf.eef.runtime.editingModel.EditingModelFactory;
import org.eclipse.emf.eef.runtime.editingModel.EditingModelPackage;
import org.eclipse.emf.eef.runtime.editingModel.JavaEditor;
import org.eclipse.emf.eef.runtime.editingModel.PropertyBinding;
import org.eclipse.emf.eef.views.ElementEditor;
+import org.eclipse.emf.eef.views.ViewElement;
/**
* This is the item provider adapter for a
@@ -73,18 +77,26 @@ public class PropertyBindingItemProvider extends ItemProviderAdapter implements
* @generated
*/
protected void addBindingCustomizerPropertyDescriptor(Object object) {
- itemPropertyDescriptors.add(createItemPropertyDescriptor(((ComposeableAdapterFactory) adapterFactory).getRootAdapterFactory(), getResourceLocator(), getString("_UI_PropertyBinding_bindingCustomizer_feature"),
- getString("_UI_PropertyDescriptor_description", "_UI_PropertyBinding_bindingCustomizer_feature", "_UI_PropertyBinding_type"), EditingModelPackage.Literals.PROPERTY_BINDING__BINDING_CUSTOMIZER, true, false, false, ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, null, null));
+ itemPropertyDescriptors.add
+ (createItemPropertyDescriptor
+ (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
+ getResourceLocator(),
+ getString("_UI_PropertyBinding_bindingCustomizer_feature"),
+ getString("_UI_PropertyDescriptor_description", "_UI_PropertyBinding_bindingCustomizer_feature", "_UI_PropertyBinding_type"),
+ EditingModelPackage.Literals.PROPERTY_BINDING__BINDING_CUSTOMIZER,
+ true,
+ false,
+ false,
+ ItemPropertyDescriptor.GENERIC_VALUE_IMAGE,
+ null,
+ null));
}
/**
- * This specifies how to implement {@link #getChildren} and is used to
- * deduce an appropriate feature for an
- * {@link org.eclipse.emf.edit.command.AddCommand},
- * {@link org.eclipse.emf.edit.command.RemoveCommand} or
- * {@link org.eclipse.emf.edit.command.MoveCommand} in
- * {@link #createCommand}. <!-- begin-user-doc --> <!-- end-user-doc -->
- *
+ * This specifies how to implement {@link #getChildren} and is used to deduce an appropriate feature for an
+ * {@link org.eclipse.emf.edit.command.AddCommand}, {@link org.eclipse.emf.edit.command.RemoveCommand} or
+ * {@link org.eclipse.emf.edit.command.MoveCommand} in {@link #createCommand}.
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
* @generated
*/
@Override
@@ -100,22 +112,20 @@ public class PropertyBindingItemProvider extends ItemProviderAdapter implements
/**
* <!-- begin-user-doc --> <!-- end-user-doc -->
- *
* @generated
*/
@Override
protected EStructuralFeature getChildFeature(Object object, Object child) {
- // Check the type of the specified child object and return the proper
- // feature to use for
+ // Check the type of the specified child object and return the proper feature to use for
// adding (see {@link AddCommand}) it as a child.
return super.getChildFeature(object, child);
}
/**
- * This returns PropertyBinding.gif. <!-- begin-user-doc --> <!--
+ * This returns PropertyBinding.gif.
+ * <!-- begin-user-doc --> <!--
* end-user-doc -->
- *
* @generated
*/
@Override
@@ -125,7 +135,6 @@ public class PropertyBindingItemProvider extends ItemProviderAdapter implements
/**
* <!-- begin-user-doc --> <!-- end-user-doc -->
- *
* @generated
*/
@Override
@@ -235,4 +244,34 @@ public class PropertyBindingItemProvider extends ItemProviderAdapter implements
return EditingModelEditPlugin.INSTANCE;
}
+ /**
+ * (non-Javadoc)
+ *
+ * @see org.eclipse.emf.edit.provider.ItemProviderAdapter#createDragAndDropCommand(org.eclipse.emf.edit.domain.EditingDomain,
+ * java.lang.Object, float, int, int, java.util.Collection)
+ * @generated NOT
+ */
+ @Override
+ protected Command createDragAndDropCommand(EditingDomain domain, Object owner, float location, int operations, int operation, Collection<?> collection) {
+ final PropertyBinding binding = (PropertyBinding) owner;
+ if (!isValidDrop(collection, binding)) {
+ return new PropertyBindingDragAndDropCommand(domain, binding, location, operations, operation, collection);
+ }
+ return super.createDragAndDropCommand(domain, owner, location, operations, operation, collection);
+ }
+
+ /**
+ * @param collection
+ * @param propertiesEditingModel
+ * @generated NOT
+ */
+ public boolean isValidDrop(Collection<?> collection, PropertyBinding propertyBinding) {
+ for (Object object : collection) {
+ if (!(object instanceof ViewElement)) {
+ return true;
+ }
+ }
+ return false;
+ }
+
}
diff --git a/plugins/org.eclipse.emf.eef.editor/src-gen/org/eclipse/emf/eef/views/provider/CategoryItemProvider.java b/plugins/org.eclipse.emf.eef.editor/src-gen/org/eclipse/emf/eef/views/provider/CategoryItemProvider.java
index afcb3aa0d..6d7925699 100644
--- a/plugins/org.eclipse.emf.eef.editor/src-gen/org/eclipse/emf/eef/views/provider/CategoryItemProvider.java
+++ b/plugins/org.eclipse.emf.eef.editor/src-gen/org/eclipse/emf/eef/views/provider/CategoryItemProvider.java
@@ -38,13 +38,7 @@ import org.eclipse.emf.eef.views.ViewsPackage;
* @generated
*/
public class CategoryItemProvider
- extends DocumentedElementItemProvider
- implements
- IEditingDomainItemProvider,
- IStructuredItemContentProvider,
- ITreeItemContentProvider,
- IItemLabelProvider,
- IItemPropertySource {
+ extends DocumentedElementItemProvider {
/**
* This constructs an instance from a factory and a notifier.
* <!-- begin-user-doc -->
diff --git a/plugins/org.eclipse.emf.eef.editor/src-gen/org/eclipse/emf/eef/views/provider/ContainerItemProvider.java b/plugins/org.eclipse.emf.eef.editor/src-gen/org/eclipse/emf/eef/views/provider/ContainerItemProvider.java
index 1778592fd..509050502 100644
--- a/plugins/org.eclipse.emf.eef.editor/src-gen/org/eclipse/emf/eef/views/provider/ContainerItemProvider.java
+++ b/plugins/org.eclipse.emf.eef.editor/src-gen/org/eclipse/emf/eef/views/provider/ContainerItemProvider.java
@@ -39,13 +39,7 @@ import org.eclipse.emf.eef.views.ViewsPackage;
* @generated
*/
public class ContainerItemProvider
- extends ViewElementItemProvider
- implements
- IEditingDomainItemProvider,
- IStructuredItemContentProvider,
- ITreeItemContentProvider,
- IItemLabelProvider,
- IItemPropertySource {
+ extends ViewElementItemProvider {
/**
* This constructs an instance from a factory and a notifier.
* <!-- begin-user-doc -->
diff --git a/plugins/org.eclipse.emf.eef.editor/src-gen/org/eclipse/emf/eef/views/provider/CustomElementEditorItemProvider.java b/plugins/org.eclipse.emf.eef.editor/src-gen/org/eclipse/emf/eef/views/provider/CustomElementEditorItemProvider.java
index 980118c89..43a1f843f 100644
--- a/plugins/org.eclipse.emf.eef.editor/src-gen/org/eclipse/emf/eef/views/provider/CustomElementEditorItemProvider.java
+++ b/plugins/org.eclipse.emf.eef.editor/src-gen/org/eclipse/emf/eef/views/provider/CustomElementEditorItemProvider.java
@@ -32,13 +32,7 @@ import org.eclipse.emf.eef.views.CustomElementEditor;
* @generated
*/
public class CustomElementEditorItemProvider
- extends ElementEditorItemProvider
- implements
- IEditingDomainItemProvider,
- IStructuredItemContentProvider,
- ITreeItemContentProvider,
- IItemLabelProvider,
- IItemPropertySource {
+ extends ElementEditorItemProvider {
/**
* This constructs an instance from a factory and a notifier.
* <!-- begin-user-doc -->
diff --git a/plugins/org.eclipse.emf.eef.editor/src-gen/org/eclipse/emf/eef/views/provider/CustomViewItemProvider.java b/plugins/org.eclipse.emf.eef.editor/src-gen/org/eclipse/emf/eef/views/provider/CustomViewItemProvider.java
index 33af8b584..ab4cafb71 100644
--- a/plugins/org.eclipse.emf.eef.editor/src-gen/org/eclipse/emf/eef/views/provider/CustomViewItemProvider.java
+++ b/plugins/org.eclipse.emf.eef.editor/src-gen/org/eclipse/emf/eef/views/provider/CustomViewItemProvider.java
@@ -32,13 +32,7 @@ import org.eclipse.emf.eef.views.CustomView;
* @generated
*/
public class CustomViewItemProvider
- extends ViewItemProvider
- implements
- IEditingDomainItemProvider,
- IStructuredItemContentProvider,
- ITreeItemContentProvider,
- IItemLabelProvider,
- IItemPropertySource {
+ extends ViewItemProvider {
/**
* This constructs an instance from a factory and a notifier.
* <!-- begin-user-doc -->
diff --git a/plugins/org.eclipse.emf.eef.editor/src-gen/org/eclipse/emf/eef/views/provider/ElementEditorItemProvider.java b/plugins/org.eclipse.emf.eef.editor/src-gen/org/eclipse/emf/eef/views/provider/ElementEditorItemProvider.java
index 50a6cf91a..7a0021d83 100644
--- a/plugins/org.eclipse.emf.eef.editor/src-gen/org/eclipse/emf/eef/views/provider/ElementEditorItemProvider.java
+++ b/plugins/org.eclipse.emf.eef.editor/src-gen/org/eclipse/emf/eef/views/provider/ElementEditorItemProvider.java
@@ -31,13 +31,12 @@ import org.eclipse.emf.eef.views.ViewsFactory;
import org.eclipse.emf.eef.views.ViewsPackage;
/**
- * This is the item provider adapter for a
- * {@link org.eclipse.emf.eef.views.ElementEditor} object. <!-- begin-user-doc
+ * This is the item provider adapter for a {@link org.eclipse.emf.eef.views.ElementEditor} object.
+ * <!-- begin-user-doc
* --> <!-- end-user-doc -->
- *
* @generated
*/
-public class ElementEditorItemProvider extends ViewElementItemProvider implements IEditingDomainItemProvider, IStructuredItemContentProvider, ITreeItemContentProvider, IItemLabelProvider, IItemPropertySource {
+public class ElementEditorItemProvider extends ViewElementItemProvider {
/**
* This constructs an instance from a factory and a notifier. <!--
* begin-user-doc --> <!-- end-user-doc -->
@@ -69,12 +68,22 @@ public class ElementEditorItemProvider extends ViewElementItemProvider implement
/**
* This adds a property descriptor for the Qualified Identifier feature.
* <!-- begin-user-doc --> <!-- end-user-doc -->
- *
* @generated
*/
protected void addQualifiedIdentifierPropertyDescriptor(Object object) {
- itemPropertyDescriptors.add(createItemPropertyDescriptor(((ComposeableAdapterFactory) adapterFactory).getRootAdapterFactory(), getResourceLocator(), getString("_UI_IdentifiedElement_qualifiedIdentifier_feature"),
- getString("_UI_PropertyDescriptor_description", "_UI_IdentifiedElement_qualifiedIdentifier_feature", "_UI_IdentifiedElement_type"), ViewsPackage.Literals.IDENTIFIED_ELEMENT__QUALIFIED_IDENTIFIER, false, false, false, ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, null, null));
+ itemPropertyDescriptors.add
+ (createItemPropertyDescriptor
+ (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
+ getResourceLocator(),
+ getString("_UI_IdentifiedElement_qualifiedIdentifier_feature"),
+ getString("_UI_PropertyDescriptor_description", "_UI_IdentifiedElement_qualifiedIdentifier_feature", "_UI_IdentifiedElement_type"),
+ ViewsPackage.Literals.IDENTIFIED_ELEMENT__QUALIFIED_IDENTIFIER,
+ false,
+ false,
+ false,
+ ItemPropertyDescriptor.GENERIC_VALUE_IMAGE,
+ null,
+ null));
}
/**
@@ -84,8 +93,19 @@ public class ElementEditorItemProvider extends ViewElementItemProvider implement
* @generated
*/
protected void addReadOnlyPropertyDescriptor(Object object) {
- itemPropertyDescriptors.add(createItemPropertyDescriptor(((ComposeableAdapterFactory) adapterFactory).getRootAdapterFactory(), getResourceLocator(), getString("_UI_ElementEditor_readOnly_feature"),
- getString("_UI_PropertyDescriptor_description", "_UI_ElementEditor_readOnly_feature", "_UI_ElementEditor_type"), ViewsPackage.Literals.ELEMENT_EDITOR__READ_ONLY, true, false, false, ItemPropertyDescriptor.BOOLEAN_VALUE_IMAGE, null, null));
+ itemPropertyDescriptors.add
+ (createItemPropertyDescriptor
+ (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
+ getResourceLocator(),
+ getString("_UI_ElementEditor_readOnly_feature"),
+ getString("_UI_PropertyDescriptor_description", "_UI_ElementEditor_readOnly_feature", "_UI_ElementEditor_type"),
+ ViewsPackage.Literals.ELEMENT_EDITOR__READ_ONLY,
+ true,
+ false,
+ false,
+ ItemPropertyDescriptor.BOOLEAN_VALUE_IMAGE,
+ null,
+ null));
}
/**
@@ -95,18 +115,26 @@ public class ElementEditorItemProvider extends ViewElementItemProvider implement
* @generated
*/
protected void addNameAsLabelPropertyDescriptor(Object object) {
- itemPropertyDescriptors.add(createItemPropertyDescriptor(((ComposeableAdapterFactory) adapterFactory).getRootAdapterFactory(), getResourceLocator(), getString("_UI_ElementEditor_nameAsLabel_feature"),
- getString("_UI_PropertyDescriptor_description", "_UI_ElementEditor_nameAsLabel_feature", "_UI_ElementEditor_type"), ViewsPackage.Literals.ELEMENT_EDITOR__NAME_AS_LABEL, true, false, false, ItemPropertyDescriptor.BOOLEAN_VALUE_IMAGE, null, null));
+ itemPropertyDescriptors.add
+ (createItemPropertyDescriptor
+ (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
+ getResourceLocator(),
+ getString("_UI_ElementEditor_nameAsLabel_feature"),
+ getString("_UI_PropertyDescriptor_description", "_UI_ElementEditor_nameAsLabel_feature", "_UI_ElementEditor_type"),
+ ViewsPackage.Literals.ELEMENT_EDITOR__NAME_AS_LABEL,
+ true,
+ false,
+ false,
+ ItemPropertyDescriptor.BOOLEAN_VALUE_IMAGE,
+ null,
+ null));
}
/**
- * This specifies how to implement {@link #getChildren} and is used to
- * deduce an appropriate feature for an
- * {@link org.eclipse.emf.edit.command.AddCommand},
- * {@link org.eclipse.emf.edit.command.RemoveCommand} or
- * {@link org.eclipse.emf.edit.command.MoveCommand} in
- * {@link #createCommand}. <!-- begin-user-doc --> <!-- end-user-doc -->
- *
+ * This specifies how to implement {@link #getChildren} and is used to deduce an appropriate feature for an
+ * {@link org.eclipse.emf.edit.command.AddCommand}, {@link org.eclipse.emf.edit.command.RemoveCommand} or
+ * {@link org.eclipse.emf.edit.command.MoveCommand} in {@link #createCommand}.
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
* @generated
*/
@Override
@@ -120,13 +148,11 @@ public class ElementEditorItemProvider extends ViewElementItemProvider implement
/**
* <!-- begin-user-doc --> <!-- end-user-doc -->
- *
* @generated
*/
@Override
protected EStructuralFeature getChildFeature(Object object, Object child) {
- // Check the type of the specified child object and return the proper
- // feature to use for
+ // Check the type of the specified child object and return the proper feature to use for
// adding (see {@link AddCommand}) it as a child.
return super.getChildFeature(object, child);
@@ -171,12 +197,11 @@ public class ElementEditorItemProvider extends ViewElementItemProvider implement
}
/**
- * This handles model notifications by calling {@link #updateChildren} to
- * update any cached children and by creating a viewer notification, which
- * it passes to {@link #fireNotifyChanged}. <!-- begin-user-doc --> <!--
+ * This handles model notifications by calling {@link #updateChildren} to update any cached
+ * children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}.
+ * <!-- begin-user-doc --> <!--
* end-user-doc -->
- *
- * @generated
+ * @generated not
*/
@Override
public void notifyChanged(Notification notification) {
diff --git a/plugins/org.eclipse.emf.eef.editor/src-gen/org/eclipse/emf/eef/views/provider/ViewElementItemProvider.java b/plugins/org.eclipse.emf.eef.editor/src-gen/org/eclipse/emf/eef/views/provider/ViewElementItemProvider.java
index 99b47e915..36826e0bd 100644
--- a/plugins/org.eclipse.emf.eef.editor/src-gen/org/eclipse/emf/eef/views/provider/ViewElementItemProvider.java
+++ b/plugins/org.eclipse.emf.eef.editor/src-gen/org/eclipse/emf/eef/views/provider/ViewElementItemProvider.java
@@ -36,13 +36,7 @@ import org.eclipse.emf.eef.views.ViewsPackage;
* @generated
*/
public class ViewElementItemProvider
- extends DocumentedElementItemProvider
- implements
- IEditingDomainItemProvider,
- IStructuredItemContentProvider,
- ITreeItemContentProvider,
- IItemLabelProvider,
- IItemPropertySource {
+ extends DocumentedElementItemProvider {
/**
* This constructs an instance from a factory and a notifier.
* <!-- begin-user-doc -->
diff --git a/plugins/org.eclipse.emf.eef.editor/src-gen/org/eclipse/emf/eef/views/provider/ViewItemProvider.java b/plugins/org.eclipse.emf.eef.editor/src-gen/org/eclipse/emf/eef/views/provider/ViewItemProvider.java
index 69d99a593..890e0b696 100644
--- a/plugins/org.eclipse.emf.eef.editor/src-gen/org/eclipse/emf/eef/views/provider/ViewItemProvider.java
+++ b/plugins/org.eclipse.emf.eef.editor/src-gen/org/eclipse/emf/eef/views/provider/ViewItemProvider.java
@@ -36,13 +36,7 @@ import org.eclipse.emf.eef.views.ViewsPackage;
* @generated
*/
public class ViewItemProvider
- extends ContainerItemProvider
- implements
- IEditingDomainItemProvider,
- IStructuredItemContentProvider,
- ITreeItemContentProvider,
- IItemLabelProvider,
- IItemPropertySource {
+ extends ContainerItemProvider {
/**
* This constructs an instance from a factory and a notifier.
* <!-- begin-user-doc -->
diff --git a/plugins/org.eclipse.emf.eef.editor/src-gen/org/eclipse/emf/eef/views/provider/ViewReferenceItemProvider.java b/plugins/org.eclipse.emf.eef.editor/src-gen/org/eclipse/emf/eef/views/provider/ViewReferenceItemProvider.java
index 7aa101475..cd0c68582 100644
--- a/plugins/org.eclipse.emf.eef.editor/src-gen/org/eclipse/emf/eef/views/provider/ViewReferenceItemProvider.java
+++ b/plugins/org.eclipse.emf.eef.editor/src-gen/org/eclipse/emf/eef/views/provider/ViewReferenceItemProvider.java
@@ -36,13 +36,7 @@ import org.eclipse.emf.eef.views.ViewsPackage;
* @generated
*/
public class ViewReferenceItemProvider
- extends ViewElementItemProvider
- implements
- IEditingDomainItemProvider,
- IStructuredItemContentProvider,
- ITreeItemContentProvider,
- IItemLabelProvider,
- IItemPropertySource {
+ extends ViewElementItemProvider {
/**
* This constructs an instance from a factory and a notifier.
* <!-- begin-user-doc -->
diff --git a/plugins/org.eclipse.emf.eef.editor/src-gen/org/eclipse/emf/eef/views/provider/ViewsRepositoryItemProvider.java b/plugins/org.eclipse.emf.eef.editor/src-gen/org/eclipse/emf/eef/views/provider/ViewsRepositoryItemProvider.java
index 90e64b892..fdc566d9a 100644
--- a/plugins/org.eclipse.emf.eef.editor/src-gen/org/eclipse/emf/eef/views/provider/ViewsRepositoryItemProvider.java
+++ b/plugins/org.eclipse.emf.eef.editor/src-gen/org/eclipse/emf/eef/views/provider/ViewsRepositoryItemProvider.java
@@ -36,7 +36,7 @@ import org.eclipse.emf.eef.views.ViewsRepository;
* --> <!-- end-user-doc -->
* @generated
*/
-public class ViewsRepositoryItemProvider extends DocumentedElementItemProvider implements IEditingDomainItemProvider, IStructuredItemContentProvider, ITreeItemContentProvider, IItemLabelProvider, IItemPropertySource {
+public class ViewsRepositoryItemProvider extends DocumentedElementItemProvider {
/**
* This constructs an instance from a factory and a notifier. <!--
* begin-user-doc --> <!-- end-user-doc -->
diff --git a/plugins/org.eclipse.emf.eef.editor/src/org/eclipse/emf/eef/editor/internal/binding/command/PropertyBindingDragAndDropCommand.java b/plugins/org.eclipse.emf.eef.editor/src/org/eclipse/emf/eef/editor/internal/binding/command/PropertyBindingDragAndDropCommand.java
new file mode 100644
index 000000000..012de20aa
--- /dev/null
+++ b/plugins/org.eclipse.emf.eef.editor/src/org/eclipse/emf/eef/editor/internal/binding/command/PropertyBindingDragAndDropCommand.java
@@ -0,0 +1,136 @@
+/*******************************************************************************
+ * Copyright (c) 2015 Obeo.
+ * All rights reserved. This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution, and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * Obeo - initial API and implementation
+ *******************************************************************************/
+package org.eclipse.emf.eef.editor.internal.binding.command;
+
+import java.util.Collection;
+
+import org.eclipse.emf.common.command.IdentityCommand;
+import org.eclipse.emf.common.command.UnexecutableCommand;
+import org.eclipse.emf.common.notify.Notifier;
+import org.eclipse.emf.edit.command.ChangeCommand;
+import org.eclipse.emf.edit.domain.EditingDomain;
+import org.eclipse.emf.eef.runtime.editingModel.EObjectView;
+import org.eclipse.emf.eef.runtime.editingModel.PropertyBinding;
+import org.eclipse.emf.eef.runtime.editingModel.View;
+import org.eclipse.emf.eef.views.ViewElement;
+
+/**
+ * Drag and drop for {@link ViewElement} on PropertyBinding. If ViewElement does
+ * not already exist, add it in PropertyBinding.
+ *
+ * @author <a href="mailto:nathalie.lepine@obeo.fr">Nathalie Lepine</a>
+ *
+ */
+public class PropertyBindingDragAndDropCommand extends AbstractDragAndDropCommand {
+
+ /**
+ * PropertyBinding
+ */
+ private PropertyBinding propertyBinding;
+
+ /**
+ * @param domain
+ * EditingDomain
+ * @param propertiesEditingModel
+ * PropertiesEditingModel
+ * @param location
+ * @param operations
+ * @param operation
+ * @param collection
+ * eClassToDrop
+ */
+ public PropertyBindingDragAndDropCommand(EditingDomain domain, PropertyBinding propertyBinding, float location, int operations, int operation, Collection<?> collection) {
+ super(domain, propertyBinding.getEClassBinding().getEditingModel(), location, operations, operation, collection);
+ this.propertyBinding = propertyBinding;
+ }
+
+ /**
+ * (non-Javadoc)
+ *
+ * @see org.eclipse.emf.edit.command.DragAndDropCommand#prepareDropMoveOn()
+ */
+ protected boolean prepareDropMoveOn() {
+ if (isCrossDomain()) {
+ dragCommand = IdentityCommand.INSTANCE;
+ dropCommand = UnexecutableCommand.INSTANCE;
+ } else {
+ dropCommand = new DropElementEditorCommand(getPropertiesEditingModel());
+ dragCommand = IdentityCommand.INSTANCE;
+ }
+
+ boolean result = dragCommand.canExecute() && dropCommand.canExecute();
+ return result;
+ }
+
+ /**
+ * Drop ElementEditor Command
+ *
+ * @author <a href="mailto:nathalie.lepine@obeo.fr">Nathalie Lepine</a>
+ *
+ */
+ private final class DropElementEditorCommand extends ChangeCommand {
+ private DropElementEditorCommand(Notifier notifier) {
+ super(notifier);
+ }
+
+ @Override
+ protected void doExecute() {
+ for (Object object : getElementToDrop()) {
+ if (object instanceof ViewElement) {
+ ViewElement eObject = (ViewElement) object;
+ // add editor
+ getBuilder().createEObjectEditor(propertyBinding, eObject);
+ // check if view in binding
+
+ if (!checkBindingViews(propertyBinding, eObject)) {
+ getBuilder().createEObjectView(eObject.getContainingView(), propertyBinding.getEClassBinding());
+ }
+
+ }
+ }
+
+ }
+
+ /**
+ * @param propertyBinding
+ * PropertyBinding
+ * @param eObject
+ * ViewElement
+ */
+ public boolean checkBindingViews(PropertyBinding propertyBinding, ViewElement eObject) {
+ for (View view : propertyBinding.getEClassBinding().getViews()) {
+ if (view instanceof EObjectView && ((EObjectView) view).getDefinition() != null && ((EObjectView) view).getDefinition().equals(eObject.getContainingView())) {
+ return true;
+ }
+ }
+ return false;
+ }
+
+ /**
+ * (non-Javadoc)
+ *
+ * @see org.eclipse.emf.common.command.AbstractCommand#canExecute()
+ */
+ @Override
+ public boolean canExecute() {
+ boolean canExecute = super.canExecute();
+ if (!canExecute) {
+ return canExecute;
+ }
+ for (Object object : getElementToDrop()) {
+ if (!(object instanceof ViewElement)) {
+ return false;
+ }
+ }
+ return true;
+ }
+ }
+}
diff --git a/plugins/org.eclipse.emf.eef.runtime.ui/META-INF/MANIFEST.MF b/plugins/org.eclipse.emf.eef.runtime.ui/META-INF/MANIFEST.MF
index 87954fb89..41694f3e1 100644
--- a/plugins/org.eclipse.emf.eef.runtime.ui/META-INF/MANIFEST.MF
+++ b/plugins/org.eclipse.emf.eef.runtime.ui/META-INF/MANIFEST.MF
@@ -11,11 +11,17 @@ Bundle-ActivationPolicy: lazy
Export-Package: org.eclipse.emf.eef.runtime.ui,
org.eclipse.emf.eef.runtime.ui.adapters;version="2.0.0",
org.eclipse.emf.eef.runtime.ui.commands,
- org.eclipse.emf.eef.runtime.ui.internal.resources;x-friends:="org.eclipse.emf.eef.editor",
- org.eclipse.emf.eef.runtime.ui.internal.util;x-friends:="org.eclipse.emf.eef.runtime.tests",
- org.eclipse.emf.eef.runtime.ui.internal.view.handle.reflect;x-friends:="org.eclipse.emf.eef.runtime.tests,org.eclipse.emf.eef.runtime.ui.swt",
- org.eclipse.emf.eef.runtime.ui.internal.view.propertyeditors;x-friends:="org.eclipse.emf.eef.runtime.tests",
- org.eclipse.emf.eef.runtime.ui.internal.view.util;x-friends:="org.eclipse.emf.eef.runtime.tests",
+ org.eclipse.emf.eef.runtime.ui.internal.resources;
+ x-friends:="org.eclipse.emf.eef.editor",
+ org.eclipse.emf.eef.runtime.ui.internal.util;
+ x-friends:="org.eclipse.emf.eef.runtime.tests",
+ org.eclipse.emf.eef.runtime.ui.internal.view.handle.reflect;
+ x-friends:="org.eclipse.emf.eef.runtime.tests,
+ org.eclipse.emf.eef.runtime.ui.swt",
+ org.eclipse.emf.eef.runtime.ui.internal.view.propertyeditors;
+ x-friends:="org.eclipse.emf.eef.runtime.tests",
+ org.eclipse.emf.eef.runtime.ui.internal.view.util;
+ x-friends:="org.eclipse.emf.eef.runtime.tests",
org.eclipse.emf.eef.runtime.ui.util,
org.eclipse.emf.eef.runtime.ui.util.impl,
org.eclipse.emf.eef.runtime.ui.view,
@@ -24,11 +30,17 @@ Export-Package: org.eclipse.emf.eef.runtime.ui,
org.eclipse.emf.eef.runtime.ui.viewer,
org.eclipse.emf.eef.runtime.ui.viewer.filters,
org.eclipse.emf.eef.views,
+ org.eclipse.emf.eef.views.impl,
org.eclipse.emf.eef.views.toolkits,
+ org.eclipse.emf.eef.views.toolkits.impl,
org.eclipse.emf.eef.views.toolkits.util,
org.eclipse.emf.eef.views.util
+Require-Bundle: org.eclipse.core.runtime,
+ org.eclipse.emf.ecore;visibility:=reexport
Bundle-Activator: org.eclipse.emf.eef.runtime.ui.EEFRuntimeUI$Plugin
-Service-Component: OSGI-INF/ReflectViewHandler.xml, OSGI-INF/ViewServiceProvider.xml, OSGI-INF/EEFToolkitProvider.xml
+Service-Component: OSGI-INF/ReflectViewHandler.xml,
+ OSGI-INF/ViewServiceProvider.xml,
+ OSGI-INF/EEFToolkitProvider.xml
Import-Package: com.google.common.base;version="10.0.1",
com.google.common.collect;version="10.0.1",
org.eclipse.core.commands.common,
diff --git a/plugins/org.eclipse.emf.eef.runtime.ui/model/views.ecore b/plugins/org.eclipse.emf.eef.runtime.ui/model/views.ecore
index aa4823e31..844c08aba 100644
--- a/plugins/org.eclipse.emf.eef.runtime.ui/model/views.ecore
+++ b/plugins/org.eclipse.emf.eef.runtime.ui/model/views.ecore
@@ -1,8 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
-<ecore:EPackage xmi:version="2.0"
- xmlns:xmi="http://www.omg.org/XMI" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xmlns:ecore="http://www.eclipse.org/emf/2002/Ecore" name="views"
- nsURI="http://www.eclipse.org/emf/eef/views/1.0.0" nsPrefix="eef-views">
+<ecore:EPackage xmi:version="2.0" xmlns:xmi="http://www.omg.org/XMI" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xmlns:ecore="http://www.eclipse.org/emf/2002/Ecore" name="views" nsURI="http://www.eclipse.org/emf/eef/views/1.0.0" nsPrefix="eef-views">
<eClassifiers xsi:type="ecore:EClass" name="ViewsRepository" eSuperTypes="#//DocumentedElement #//IdentifiedElement">
<eStructuralFeatures xsi:type="ecore:EReference" name="views" upperBound="-1"
eType="#//View" containment="true" eOpposite="#//View/repository"/>
@@ -41,6 +39,7 @@
eType="#//ViewElement" containment="true" eOpposite="#//ViewElement/container"/>
</eClassifiers>
<eClassifiers xsi:type="ecore:EClass" name="ViewElement" abstract="true" eSuperTypes="#//DocumentedElement">
+ <eOperations name="getContainingView" eType="#//View"/>
<eStructuralFeatures xsi:type="ecore:EReference" name="representation" eType="#//toolkits/Widget"/>
<eStructuralFeatures xsi:type="ecore:EReference" name="container" eType="#//Container"
eOpposite="#//Container/elements"/>
diff --git a/plugins/org.eclipse.emf.eef.runtime.ui/model/views.genmodel b/plugins/org.eclipse.emf.eef.runtime.ui/model/views.genmodel
index 98097b03a..b8caab79d 100644
--- a/plugins/org.eclipse.emf.eef.runtime.ui/model/views.genmodel
+++ b/plugins/org.eclipse.emf.eef.runtime.ui/model/views.genmodel
@@ -1,10 +1,9 @@
<?xml version="1.0" encoding="UTF-8"?>
-<genmodel:GenModel xmi:version="2.0"
- xmlns:xmi="http://www.omg.org/XMI" xmlns:ecore="http://www.eclipse.org/emf/2002/Ecore"
+<genmodel:GenModel xmi:version="2.0" xmlns:xmi="http://www.omg.org/XMI" xmlns:ecore="http://www.eclipse.org/emf/2002/Ecore"
xmlns:genmodel="http://www.eclipse.org/emf/2002/GenModel" copyrightText="Copyright (c) 2008, 2011 Obeo.&#xA;All rights reserved. This program and the accompanying materials&#xA;are made available under the terms of the Eclipse Public License v1.0&#xA;which accompanies this distribution, and is available at&#xA;http://www.eclipse.org/legal/epl-v10.html&#xA;&#xA;Contributors:&#xA; Obeo - initial API and implementation&#xA;"
- modelDirectory="/org.eclipse.emf.eef.runtime.ui/src-gen" editDirectory="/org.eclipse.emf.eef.editor/src-gen"
- editorDirectory="/org.eclipse.emf.eef.editor/src-gen" modelPluginID="org.eclipse.emf.eef.runtime.ui"
- modelName="Views" editPluginClass="org.eclipse.emf.eef.editor.EditingModelEditPlugin"
+ modelDirectory="/org.eclipse.emf.eef.runtime.ui/src-gen" creationIcons="false"
+ editDirectory="/org.eclipse.emf.eef.editor/src-gen" editorDirectory="/org.eclipse.emf.eef.editor/src-gen"
+ modelPluginID="org.eclipse.emf.eef.runtime.ui" modelName="Views" editPluginClass="org.eclipse.emf.eef.editor.EditingModelEditPlugin"
editorPluginClass="" importerID="org.eclipse.emf.importer.ecore" complianceLevel="5.0"
copyrightFields="false" editPluginID="org.eclipse.emf.eef.editor" editorPluginID="org.eclipse.emf.eef.editor"
runtimeVersion="2.5" language="">
@@ -40,6 +39,7 @@
<genFeatures notify="false" createChild="false" propertySortChoices="true" ecoreFeature="ecore:EReference views.ecore#//ViewElement/representation"/>
<genFeatures property="None" notify="false" createChild="false" ecoreFeature="ecore:EReference views.ecore#//ViewElement/container"/>
<genFeatures createChild="false" ecoreFeature="ecore:EAttribute views.ecore#//ViewElement/name"/>
+ <genOperations ecoreOperation="views.ecore#//ViewElement/getContainingView"/>
</genClasses>
<genClasses ecoreClass="views.ecore#//CustomElementEditor"/>
<genClasses ecoreClass="views.ecore#//CustomView"/>
diff --git a/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/Category.java b/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/Category.java
index 7e05e9a59..a73091d98 100644
--- a/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/Category.java
+++ b/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/Category.java
@@ -20,13 +20,13 @@ import org.eclipse.emf.common.util.EList;
*
* <p>
* The following features are supported:
+ * </p>
* <ul>
* <li>{@link org.eclipse.emf.eef.views.Category#getViews <em>Views</em>}</li>
* <li>{@link org.eclipse.emf.eef.views.Category#getRepository <em>Repository</em>}</li>
* <li>{@link org.eclipse.emf.eef.views.Category#getCategories <em>Categories</em>}</li>
* <li>{@link org.eclipse.emf.eef.views.Category#getName <em>Name</em>}</li>
* </ul>
- * </p>
*
* @see org.eclipse.emf.eef.views.ViewsPackage#getCategory()
* @model
diff --git a/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/Container.java b/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/Container.java
index 0aea5cca6..ac547d8a4 100644
--- a/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/Container.java
+++ b/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/Container.java
@@ -20,10 +20,10 @@ import org.eclipse.emf.common.util.EList;
*
* <p>
* The following features are supported:
+ * </p>
* <ul>
* <li>{@link org.eclipse.emf.eef.views.Container#getElements <em>Elements</em>}</li>
* </ul>
- * </p>
*
* @see org.eclipse.emf.eef.views.ViewsPackage#getContainer()
* @model
diff --git a/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/DocumentedElement.java b/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/DocumentedElement.java
index 0d9ce929e..bfeb02d6f 100644
--- a/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/DocumentedElement.java
+++ b/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/DocumentedElement.java
@@ -20,10 +20,10 @@ import org.eclipse.emf.ecore.EObject;
*
* <p>
* The following features are supported:
+ * </p>
* <ul>
* <li>{@link org.eclipse.emf.eef.views.DocumentedElement#getDocumentation <em>Documentation</em>}</li>
* </ul>
- * </p>
*
* @see org.eclipse.emf.eef.views.ViewsPackage#getDocumentedElement()
* @model abstract="true"
diff --git a/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/ElementEditor.java b/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/ElementEditor.java
index 0cd4c87e7..32a53d0c4 100644
--- a/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/ElementEditor.java
+++ b/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/ElementEditor.java
@@ -21,12 +21,12 @@ import org.eclipse.emf.common.util.EList;
*
* <p>
* The following features are supported:
+ * </p>
* <ul>
* <li>{@link org.eclipse.emf.eef.views.ElementEditor#isReadOnly <em>Read Only</em>}</li>
* <li>{@link org.eclipse.emf.eef.views.ElementEditor#isNameAsLabel <em>Name As Label</em>}</li>
* <li>{@link org.eclipse.emf.eef.views.ElementEditor#getSubElementEditors <em>Sub Element Editors</em>}</li>
* </ul>
- * </p>
*
* @see org.eclipse.emf.eef.views.ViewsPackage#getElementEditor()
* @model
diff --git a/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/IdentifiedElement.java b/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/IdentifiedElement.java
index 12168efbb..296017780 100644
--- a/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/IdentifiedElement.java
+++ b/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/IdentifiedElement.java
@@ -20,10 +20,10 @@ import org.eclipse.emf.ecore.EObject;
*
* <p>
* The following features are supported:
+ * </p>
* <ul>
* <li>{@link org.eclipse.emf.eef.views.IdentifiedElement#getQualifiedIdentifier <em>Qualified Identifier</em>}</li>
* </ul>
- * </p>
*
* @see org.eclipse.emf.eef.views.ViewsPackage#getIdentifiedElement()
* @model abstract="true"
diff --git a/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/View.java b/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/View.java
index c2df183ce..23a50661e 100644
--- a/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/View.java
+++ b/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/View.java
@@ -19,12 +19,12 @@ package org.eclipse.emf.eef.views;
*
* <p>
* The following features are supported:
+ * </p>
* <ul>
* <li>{@link org.eclipse.emf.eef.views.View#getRepository <em>Repository</em>}</li>
* <li>{@link org.eclipse.emf.eef.views.View#isExplicit <em>Explicit</em>}</li>
* <li>{@link org.eclipse.emf.eef.views.View#getCategory <em>Category</em>}</li>
* </ul>
- * </p>
*
* @see org.eclipse.emf.eef.views.ViewsPackage#getView()
* @model
diff --git a/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/ViewElement.java b/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/ViewElement.java
index ace60dc3d..0003a36c5 100644
--- a/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/ViewElement.java
+++ b/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/ViewElement.java
@@ -20,12 +20,12 @@ import org.eclipse.emf.eef.views.toolkits.Widget;
*
* <p>
* The following features are supported:
+ * </p>
* <ul>
* <li>{@link org.eclipse.emf.eef.views.ViewElement#getRepresentation <em>Representation</em>}</li>
* <li>{@link org.eclipse.emf.eef.views.ViewElement#getContainer <em>Container</em>}</li>
* <li>{@link org.eclipse.emf.eef.views.ViewElement#getName <em>Name</em>}</li>
* </ul>
- * </p>
*
* @see org.eclipse.emf.eef.views.ViewsPackage#getViewElement()
* @model abstract="true"
@@ -112,4 +112,12 @@ public interface ViewElement extends DocumentedElement {
*/
void setName(String value);
+ /**
+ * <!-- begin-user-doc -->
+ * <!-- end-user-doc -->
+ * @model kind="operation"
+ * @generated
+ */
+ View getContainingView();
+
} // ViewElement
diff --git a/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/ViewReference.java b/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/ViewReference.java
index 06462e7ac..d4bd83781 100644
--- a/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/ViewReference.java
+++ b/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/ViewReference.java
@@ -19,10 +19,10 @@ package org.eclipse.emf.eef.views;
*
* <p>
* The following features are supported:
+ * </p>
* <ul>
* <li>{@link org.eclipse.emf.eef.views.ViewReference#getView <em>View</em>}</li>
* </ul>
- * </p>
*
* @see org.eclipse.emf.eef.views.ViewsPackage#getViewReference()
* @model
diff --git a/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/ViewsRepository.java b/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/ViewsRepository.java
index 8e5e1deec..30c211fd0 100644
--- a/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/ViewsRepository.java
+++ b/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/ViewsRepository.java
@@ -20,13 +20,13 @@ import org.eclipse.emf.common.util.EList;
*
* <p>
* The following features are supported:
+ * </p>
* <ul>
* <li>{@link org.eclipse.emf.eef.views.ViewsRepository#getViews <em>Views</em>}</li>
* <li>{@link org.eclipse.emf.eef.views.ViewsRepository#getRepositoryKind <em>Repository Kind</em>}</li>
* <li>{@link org.eclipse.emf.eef.views.ViewsRepository#getCategories <em>Categories</em>}</li>
* <li>{@link org.eclipse.emf.eef.views.ViewsRepository#getName <em>Name</em>}</li>
* </ul>
- * </p>
*
* @see org.eclipse.emf.eef.views.ViewsPackage#getViewsRepository()
* @model
@@ -62,7 +62,7 @@ public interface ViewsRepository extends DocumentedElement, IdentifiedElement {
* <!-- end-user-doc -->
* @return the value of the '<em>Repository Kind</em>' attribute list.
* @see org.eclipse.emf.eef.views.ViewsPackage#getViewsRepository_RepositoryKind()
- * @model
+ * @model required="true"
* @generated
*/
EList<String> getRepositoryKind();
@@ -96,7 +96,7 @@ public interface ViewsRepository extends DocumentedElement, IdentifiedElement {
* @return the value of the '<em>Name</em>' attribute.
* @see #setName(String)
* @see org.eclipse.emf.eef.views.ViewsPackage#getViewsRepository_Name()
- * @model
+ * @model required="true"
* @generated
*/
String getName();
diff --git a/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/impl/CategoryImpl.java b/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/impl/CategoryImpl.java
index 3b3364a82..c97744073 100644
--- a/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/impl/CategoryImpl.java
+++ b/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/impl/CategoryImpl.java
@@ -33,14 +33,15 @@ import org.eclipse.emf.eef.views.ViewsRepository;
* An implementation of the model object '<em><b>Category</b></em>'.
* <!-- end-user-doc -->
* <p>
+ * <p>
* The following features are implemented:
+ * </p>
* <ul>
* <li>{@link org.eclipse.emf.eef.views.impl.CategoryImpl#getViews <em>Views</em>}</li>
* <li>{@link org.eclipse.emf.eef.views.impl.CategoryImpl#getRepository <em>Repository</em>}</li>
* <li>{@link org.eclipse.emf.eef.views.impl.CategoryImpl#getCategories <em>Categories</em>}</li>
* <li>{@link org.eclipse.emf.eef.views.impl.CategoryImpl#getName <em>Name</em>}</li>
* </ul>
- * </p>
*
* @generated
*/
@@ -123,7 +124,7 @@ public class CategoryImpl extends DocumentedElementImpl implements Category {
*/
public ViewsRepository getRepository() {
if (eContainerFeatureID() != ViewsPackage.CATEGORY__REPOSITORY) return null;
- return (ViewsRepository)eContainer();
+ return (ViewsRepository)eInternalContainer();
}
/**
diff --git a/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/impl/ContainerImpl.java b/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/impl/ContainerImpl.java
index 3a2db55bb..4168b8009 100644
--- a/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/impl/ContainerImpl.java
+++ b/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/impl/ContainerImpl.java
@@ -30,12 +30,13 @@ import org.eclipse.emf.eef.views.ViewsPackage;
* <!-- begin-user-doc --> An implementation of the model object '
* <em><b>Container</b></em>'. <!-- end-user-doc -->
* <p>
+ * <p>
* The following features are implemented:
+ * </p>
* <ul>
* <li>{@link org.eclipse.emf.eef.views.impl.ContainerImpl#getQualifiedIdentifier <em>Qualified Identifier</em>}</li>
* <li>{@link org.eclipse.emf.eef.views.impl.ContainerImpl#getElements <em>Elements</em>}</li>
* </ul>
- * </p>
*
* @generated
*/
diff --git a/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/impl/CustomElementEditorImpl.java b/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/impl/CustomElementEditorImpl.java
index 05d1cfd5b..ead984093 100644
--- a/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/impl/CustomElementEditorImpl.java
+++ b/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/impl/CustomElementEditorImpl.java
@@ -20,7 +20,6 @@ import org.eclipse.emf.eef.views.ViewsPackage;
* An implementation of the model object '<em><b>Custom Element Editor</b></em>'.
* <!-- end-user-doc -->
* <p>
- * </p>
*
* @generated
*/
diff --git a/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/impl/CustomViewImpl.java b/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/impl/CustomViewImpl.java
index 9f810f0de..7eda24640 100644
--- a/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/impl/CustomViewImpl.java
+++ b/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/impl/CustomViewImpl.java
@@ -20,7 +20,6 @@ import org.eclipse.emf.eef.views.ViewsPackage;
* An implementation of the model object '<em><b>Custom View</b></em>'.
* <!-- end-user-doc -->
* <p>
- * </p>
*
* @generated
*/
diff --git a/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/impl/DocumentedElementImpl.java b/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/impl/DocumentedElementImpl.java
index da9aa4c2d..542906aec 100644
--- a/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/impl/DocumentedElementImpl.java
+++ b/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/impl/DocumentedElementImpl.java
@@ -23,11 +23,12 @@ import org.eclipse.emf.eef.views.ViewsPackage;
* An implementation of the model object '<em><b>Documented Element</b></em>'.
* <!-- end-user-doc -->
* <p>
+ * <p>
* The following features are implemented:
+ * </p>
* <ul>
* <li>{@link org.eclipse.emf.eef.views.impl.DocumentedElementImpl#getDocumentation <em>Documentation</em>}</li>
* </ul>
- * </p>
*
* @generated
*/
diff --git a/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/impl/ElementEditorImpl.java b/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/impl/ElementEditorImpl.java
index e4cedffec..582e62d4b 100644
--- a/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/impl/ElementEditorImpl.java
+++ b/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/impl/ElementEditorImpl.java
@@ -32,14 +32,15 @@ import org.eclipse.emf.eef.views.ViewsPackage;
* An implementation of the model object '<em><b>Element Editor</b></em>'.
* <!-- end-user-doc -->
* <p>
+ * <p>
* The following features are implemented:
+ * </p>
* <ul>
* <li>{@link org.eclipse.emf.eef.views.impl.ElementEditorImpl#getQualifiedIdentifier <em>Qualified Identifier</em>}</li>
* <li>{@link org.eclipse.emf.eef.views.impl.ElementEditorImpl#isReadOnly <em>Read Only</em>}</li>
* <li>{@link org.eclipse.emf.eef.views.impl.ElementEditorImpl#isNameAsLabel <em>Name As Label</em>}</li>
* <li>{@link org.eclipse.emf.eef.views.impl.ElementEditorImpl#getSubElementEditors <em>Sub Element Editors</em>}</li>
* </ul>
- * </p>
*
* @generated
*/
diff --git a/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/impl/IdentifiedElementImpl.java b/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/impl/IdentifiedElementImpl.java
index a91656d0f..65748a064 100644
--- a/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/impl/IdentifiedElementImpl.java
+++ b/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/impl/IdentifiedElementImpl.java
@@ -21,11 +21,12 @@ import org.eclipse.emf.eef.views.ViewsPackage;
* An implementation of the model object '<em><b>Identified Element</b></em>'.
* <!-- end-user-doc -->
* <p>
+ * <p>
* The following features are implemented:
+ * </p>
* <ul>
* <li>{@link org.eclipse.emf.eef.views.impl.IdentifiedElementImpl#getQualifiedIdentifier <em>Qualified Identifier</em>}</li>
* </ul>
- * </p>
*
* @generated
*/
diff --git a/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/impl/ViewElementImpl.java b/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/impl/ViewElementImpl.java
index 400e6da69..964bb291c 100644
--- a/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/impl/ViewElementImpl.java
+++ b/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/impl/ViewElementImpl.java
@@ -14,10 +14,13 @@ package org.eclipse.emf.eef.views.impl;
import org.eclipse.emf.common.notify.Notification;
import org.eclipse.emf.common.notify.NotificationChain;
import org.eclipse.emf.ecore.EClass;
+import org.eclipse.emf.ecore.EObject;
import org.eclipse.emf.ecore.InternalEObject;
import org.eclipse.emf.ecore.impl.ENotificationImpl;
import org.eclipse.emf.ecore.util.EcoreUtil;
+import org.eclipse.emf.eef.runtime.editingModel.EClassBinding;
import org.eclipse.emf.eef.views.Container;
+import org.eclipse.emf.eef.views.View;
import org.eclipse.emf.eef.views.ViewElement;
import org.eclipse.emf.eef.views.ViewsPackage;
import org.eclipse.emf.eef.views.toolkits.Widget;
@@ -27,13 +30,14 @@ import org.eclipse.emf.eef.views.toolkits.Widget;
* An implementation of the model object '<em><b>View Element</b></em>'.
* <!-- end-user-doc -->
* <p>
+ * <p>
* The following features are implemented:
+ * </p>
* <ul>
* <li>{@link org.eclipse.emf.eef.views.impl.ViewElementImpl#getRepresentation <em>Representation</em>}</li>
* <li>{@link org.eclipse.emf.eef.views.impl.ViewElementImpl#getContainer <em>Container</em>}</li>
* <li>{@link org.eclipse.emf.eef.views.impl.ViewElementImpl#getName <em>Name</em>}</li>
* </ul>
- * </p>
*
* @generated
*/
@@ -132,7 +136,7 @@ public abstract class ViewElementImpl extends DocumentedElementImpl implements V
*/
public Container getContainer() {
if (eContainerFeatureID() != ViewsPackage.VIEW_ELEMENT__CONTAINER) return null;
- return (Container)eContainer();
+ return (Container)eInternalContainer();
}
/**
@@ -190,6 +194,25 @@ public abstract class ViewElementImpl extends DocumentedElementImpl implements V
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ * @generated not
+ */
+ public View getContainingView() {
+ if (eContainer() instanceof View) {
+ return (View) eContainer();
+ }
+ EObject parent = eContainer();
+ while (parent.eContainer() != null && !(parent.eContainer() instanceof View)) {
+ parent = parent.eContainer();
+ }
+ if (parent instanceof View) {
+ return (View) parent;
+ }
+ return null;
+ }
+
+ /**
+ * <!-- begin-user-doc -->
+ * <!-- end-user-doc -->
* @generated
*/
@Override
diff --git a/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/impl/ViewImpl.java b/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/impl/ViewImpl.java
index 267568272..3173e8662 100644
--- a/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/impl/ViewImpl.java
+++ b/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/impl/ViewImpl.java
@@ -30,13 +30,14 @@ import org.eclipse.emf.eef.views.ViewsRepository;
* An implementation of the model object '<em><b>View</b></em>'.
* <!-- end-user-doc -->
* <p>
+ * <p>
* The following features are implemented:
+ * </p>
* <ul>
* <li>{@link org.eclipse.emf.eef.views.impl.ViewImpl#getRepository <em>Repository</em>}</li>
* <li>{@link org.eclipse.emf.eef.views.impl.ViewImpl#isExplicit <em>Explicit</em>}</li>
* <li>{@link org.eclipse.emf.eef.views.impl.ViewImpl#getCategory <em>Category</em>}</li>
* </ul>
- * </p>
*
* @generated
*/
@@ -107,7 +108,7 @@ public class ViewImpl extends ContainerImpl implements View {
*/
public ViewsRepository getRepository() {
if (eContainerFeatureID() != ViewsPackage.VIEW__REPOSITORY) return null;
- return (ViewsRepository)eContainer();
+ return (ViewsRepository)eInternalContainer();
}
/**
@@ -169,7 +170,7 @@ public class ViewImpl extends ContainerImpl implements View {
*/
public Category getCategory() {
if (eContainerFeatureID() != ViewsPackage.VIEW__CATEGORY) return null;
- return (Category)eContainer();
+ return (Category)eInternalContainer();
}
/**
diff --git a/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/impl/ViewReferenceImpl.java b/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/impl/ViewReferenceImpl.java
index ad7ebe413..b6c0a235d 100644
--- a/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/impl/ViewReferenceImpl.java
+++ b/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/impl/ViewReferenceImpl.java
@@ -27,12 +27,13 @@ import org.eclipse.emf.eef.views.ViewsPackage;
* An implementation of the model object '<em><b>View Reference</b></em>'.
* <!-- end-user-doc -->
* <p>
+ * <p>
* The following features are implemented:
+ * </p>
* <ul>
* <li>{@link org.eclipse.emf.eef.views.impl.ViewReferenceImpl#getQualifiedIdentifier <em>Qualified Identifier</em>}</li>
* <li>{@link org.eclipse.emf.eef.views.impl.ViewReferenceImpl#getView <em>View</em>}</li>
* </ul>
- * </p>
*
* @generated
*/
diff --git a/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/impl/ViewsFactoryImpl.java b/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/impl/ViewsFactoryImpl.java
index 6bc6071e5..1d357fafc 100644
--- a/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/impl/ViewsFactoryImpl.java
+++ b/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/impl/ViewsFactoryImpl.java
@@ -42,7 +42,7 @@ public class ViewsFactoryImpl extends EFactoryImpl implements ViewsFactory {
*/
public static ViewsFactory init() {
try {
- ViewsFactory theViewsFactory = (ViewsFactory)EPackage.Registry.INSTANCE.getEFactory("http://www.eclipse.org/emf/eef/views/1.0.0");
+ ViewsFactory theViewsFactory = (ViewsFactory)EPackage.Registry.INSTANCE.getEFactory(ViewsPackage.eNS_URI);
if (theViewsFactory != null) {
return theViewsFactory;
}
diff --git a/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/impl/ViewsPackageImpl.java b/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/impl/ViewsPackageImpl.java
index 8c791d3dc..8fa58507f 100644
--- a/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/impl/ViewsPackageImpl.java
+++ b/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/impl/ViewsPackageImpl.java
@@ -593,9 +593,9 @@ public class ViewsPackageImpl extends EPackageImpl implements ViewsPackage {
// Initialize classes and features; add operations and parameters
initEClass(viewsRepositoryEClass, ViewsRepository.class, "ViewsRepository", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
initEReference(getViewsRepository_Views(), this.getView(), this.getView_Repository(), "views", null, 0, -1, ViewsRepository.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
- initEAttribute(getViewsRepository_RepositoryKind(), ecorePackage.getEString(), "RepositoryKind", null, 0, -1, ViewsRepository.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
+ initEAttribute(getViewsRepository_RepositoryKind(), ecorePackage.getEString(), "RepositoryKind", null, 1, -1, ViewsRepository.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEReference(getViewsRepository_Categories(), this.getCategory(), this.getCategory_Repository(), "categories", null, 0, -1, ViewsRepository.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
- initEAttribute(getViewsRepository_Name(), ecorePackage.getEString(), "name", null, 0, 1, ViewsRepository.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
+ initEAttribute(getViewsRepository_Name(), ecorePackage.getEString(), "name", null, 1, 1, ViewsRepository.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEClass(viewEClass, View.class, "View", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
initEReference(getView_Repository(), this.getViewsRepository(), this.getViewsRepository_Views(), "repository", null, 0, 1, View.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
@@ -621,6 +621,8 @@ public class ViewsPackageImpl extends EPackageImpl implements ViewsPackage {
initEReference(getViewElement_Container(), this.getContainer(), this.getContainer_Elements(), "container", null, 0, 1, ViewElement.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEAttribute(getViewElement_Name(), ecorePackage.getEString(), "name", null, 1, 1, ViewElement.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
+ addEOperation(viewElementEClass, this.getView(), "getContainingView", 0, 1, IS_UNIQUE, IS_ORDERED);
+
initEClass(customElementEditorEClass, CustomElementEditor.class, "CustomElementEditor", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
initEClass(customViewEClass, CustomView.class, "CustomView", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
diff --git a/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/impl/ViewsRepositoryImpl.java b/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/impl/ViewsRepositoryImpl.java
index aa7d8321d..607e89540 100644
--- a/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/impl/ViewsRepositoryImpl.java
+++ b/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/impl/ViewsRepositoryImpl.java
@@ -33,7 +33,9 @@ import org.eclipse.emf.eef.views.ViewsRepository;
* An implementation of the model object '<em><b>Repository</b></em>'.
* <!-- end-user-doc -->
* <p>
+ * <p>
* The following features are implemented:
+ * </p>
* <ul>
* <li>{@link org.eclipse.emf.eef.views.impl.ViewsRepositoryImpl#getQualifiedIdentifier <em>Qualified Identifier</em>}</li>
* <li>{@link org.eclipse.emf.eef.views.impl.ViewsRepositoryImpl#getViews <em>Views</em>}</li>
@@ -41,7 +43,6 @@ import org.eclipse.emf.eef.views.ViewsRepository;
* <li>{@link org.eclipse.emf.eef.views.impl.ViewsRepositoryImpl#getCategories <em>Categories</em>}</li>
* <li>{@link org.eclipse.emf.eef.views.impl.ViewsRepositoryImpl#getName <em>Name</em>}</li>
* </ul>
- * </p>
*
* @generated
*/
diff --git a/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/toolkits/Toolkit.java b/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/toolkits/Toolkit.java
index 81fdbe3df..8fbc59194 100644
--- a/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/toolkits/Toolkit.java
+++ b/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/toolkits/Toolkit.java
@@ -21,11 +21,11 @@ import org.eclipse.emf.ecore.EObject;
*
* <p>
* The following features are supported:
+ * </p>
* <ul>
* <li>{@link org.eclipse.emf.eef.views.toolkits.Toolkit#getWidgets <em>Widgets</em>}</li>
* <li>{@link org.eclipse.emf.eef.views.toolkits.Toolkit#getName <em>Name</em>}</li>
* </ul>
- * </p>
*
* @see org.eclipse.emf.eef.views.toolkits.ToolkitsPackage#getToolkit()
* @model
diff --git a/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/toolkits/Widget.java b/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/toolkits/Widget.java
index b296a72f0..d64764389 100644
--- a/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/toolkits/Widget.java
+++ b/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/toolkits/Widget.java
@@ -20,13 +20,13 @@ import org.eclipse.emf.ecore.EObject;
*
* <p>
* The following features are supported:
+ * </p>
* <ul>
* <li>{@link org.eclipse.emf.eef.views.toolkits.Widget#getName <em>Name</em>}</li>
* <li>{@link org.eclipse.emf.eef.views.toolkits.Widget#getIcon <em>Icon</em>}</li>
* <li>{@link org.eclipse.emf.eef.views.toolkits.Widget#getImplementation <em>Implementation</em>}</li>
* <li>{@link org.eclipse.emf.eef.views.toolkits.Widget#getToolkit <em>Toolkit</em>}</li>
* </ul>
- * </p>
*
* @see org.eclipse.emf.eef.views.toolkits.ToolkitsPackage#getWidget()
* @model
diff --git a/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/toolkits/impl/ToolkitImpl.java b/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/toolkits/impl/ToolkitImpl.java
index 459d40eaa..10cf10171 100644
--- a/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/toolkits/impl/ToolkitImpl.java
+++ b/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/toolkits/impl/ToolkitImpl.java
@@ -31,12 +31,13 @@ import org.eclipse.emf.eef.views.toolkits.Widget;
* An implementation of the model object '<em><b>Toolkit</b></em>'.
* <!-- end-user-doc -->
* <p>
+ * <p>
* The following features are implemented:
+ * </p>
* <ul>
* <li>{@link org.eclipse.emf.eef.views.toolkits.impl.ToolkitImpl#getWidgets <em>Widgets</em>}</li>
* <li>{@link org.eclipse.emf.eef.views.toolkits.impl.ToolkitImpl#getName <em>Name</em>}</li>
* </ul>
- * </p>
*
* @generated
*/
diff --git a/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/toolkits/impl/ToolkitsFactoryImpl.java b/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/toolkits/impl/ToolkitsFactoryImpl.java
index e5902e879..cd3950039 100644
--- a/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/toolkits/impl/ToolkitsFactoryImpl.java
+++ b/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/toolkits/impl/ToolkitsFactoryImpl.java
@@ -37,7 +37,7 @@ public class ToolkitsFactoryImpl extends EFactoryImpl implements ToolkitsFactory
*/
public static ToolkitsFactory init() {
try {
- ToolkitsFactory theToolkitsFactory = (ToolkitsFactory)EPackage.Registry.INSTANCE.getEFactory("http://www.eclipse.org/emf/eef/views/toolkits/1.0.0");
+ ToolkitsFactory theToolkitsFactory = (ToolkitsFactory)EPackage.Registry.INSTANCE.getEFactory(ToolkitsPackage.eNS_URI);
if (theToolkitsFactory != null) {
return theToolkitsFactory;
}
diff --git a/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/toolkits/impl/WidgetImpl.java b/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/toolkits/impl/WidgetImpl.java
index 5e5dc3c97..9aadd20aa 100644
--- a/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/toolkits/impl/WidgetImpl.java
+++ b/plugins/org.eclipse.emf.eef.runtime.ui/src-gen/org/eclipse/emf/eef/views/toolkits/impl/WidgetImpl.java
@@ -27,14 +27,15 @@ import org.eclipse.emf.eef.views.toolkits.Widget;
* An implementation of the model object '<em><b>Widget</b></em>'.
* <!-- end-user-doc -->
* <p>
+ * <p>
* The following features are implemented:
+ * </p>
* <ul>
* <li>{@link org.eclipse.emf.eef.views.toolkits.impl.WidgetImpl#getName <em>Name</em>}</li>
* <li>{@link org.eclipse.emf.eef.views.toolkits.impl.WidgetImpl#getIcon <em>Icon</em>}</li>
* <li>{@link org.eclipse.emf.eef.views.toolkits.impl.WidgetImpl#getImplementation <em>Implementation</em>}</li>
* <li>{@link org.eclipse.emf.eef.views.toolkits.impl.WidgetImpl#getToolkit <em>Toolkit</em>}</li>
* </ul>
- * </p>
*
* @generated
*/
@@ -188,7 +189,7 @@ public class WidgetImpl extends EObjectImpl implements Widget {
*/
public Toolkit getToolkit() {
if (eContainerFeatureID() != ToolkitsPackage.WIDGET__TOOLKIT) return null;
- return (Toolkit)eContainer();
+ return (Toolkit)eInternalContainer();
}
/**
diff --git a/plugins/org.eclipse.emf.eef.runtime.ui/src/org/eclipse/emf/eef/runtime/ui/util/BindingSettingsBuilder.java b/plugins/org.eclipse.emf.eef.runtime.ui/src/org/eclipse/emf/eef/runtime/ui/util/BindingSettingsBuilder.java
index 6ce63581c..627d3b50a 100644
--- a/plugins/org.eclipse.emf.eef.runtime.ui/src/org/eclipse/emf/eef/runtime/ui/util/BindingSettingsBuilder.java
+++ b/plugins/org.eclipse.emf.eef.runtime.ui/src/org/eclipse/emf/eef/runtime/ui/util/BindingSettingsBuilder.java
@@ -28,10 +28,12 @@ import org.eclipse.emf.eef.runtime.editingModel.EStructuralFeatureBinding;
import org.eclipse.emf.eef.runtime.editingModel.EditingModelEnvironment;
import org.eclipse.emf.eef.runtime.editingModel.EditingModelFactory;
import org.eclipse.emf.eef.runtime.editingModel.PropertiesEditingModel;
+import org.eclipse.emf.eef.runtime.editingModel.PropertyBinding;
import org.eclipse.emf.eef.runtime.ui.view.propertyeditors.ToolkitHandler;
import org.eclipse.emf.eef.views.Container;
import org.eclipse.emf.eef.views.ElementEditor;
import org.eclipse.emf.eef.views.View;
+import org.eclipse.emf.eef.views.ViewElement;
import org.eclipse.emf.eef.views.ViewsFactory;
import org.eclipse.emf.eef.views.ViewsRepository;
import org.eclipse.emf.eef.views.toolkits.Widget;
@@ -209,14 +211,22 @@ public class BindingSettingsBuilder {
createdGroup.getElements().add(newElementEditor);
}
// create EObjectEditor
- EObjectEditor buildedEditor = EditingModelFactory.eINSTANCE.createEObjectEditor();
- ((EObjectEditor) buildedEditor).setDefinition(newElementEditor);
- propertyBinding.setEditor(buildedEditor);
+ createEObjectEditor(propertyBinding, newElementEditor);
}
eClassBinding.getPropertyBindings().add(propertyBinding);
}
/**
+ * @param propertyBinding
+ * @param newElementEditor
+ */
+ public void createEObjectEditor(PropertyBinding propertyBinding, ViewElement newElementEditor) {
+ EObjectEditor buildedEditor = EditingModelFactory.eINSTANCE.createEObjectEditor();
+ ((EObjectEditor) buildedEditor).setDefinition(newElementEditor);
+ propertyBinding.setEditor(buildedEditor);
+ }
+
+ /**
* @param eObject
* EObject
* @param createdView
@@ -304,11 +314,21 @@ public class BindingSettingsBuilder {
public EClassBinding createEClassBinding(EClass eObject, org.eclipse.emf.eef.views.View createdView) {
EClassBinding eClassBinding = EditingModelFactory.eINSTANCE.createEClassBinding();
eClassBinding.setEClass(eObject);
+ createEObjectView(createdView, eClassBinding);
+ propertiesEditingModel.getBindings().add(eClassBinding);
+ return eClassBinding;
+ }
+
+ /**
+ * @param createdView
+ * org.eclipse.emf.eef.views.View
+ * @param eClassBinding
+ * EClassBinding
+ */
+ public void createEObjectView(org.eclipse.emf.eef.views.View createdView, EClassBinding eClassBinding) {
EObjectView modelView = EditingModelFactory.eINSTANCE.createEObjectView();
((EObjectView) modelView).setDefinition((EObject) createdView);
eClassBinding.getViews().add(modelView);
- propertiesEditingModel.getBindings().add(eClassBinding);
- return eClassBinding;
}
/**
diff --git a/plugins/org.eclipse.emf.eef.runtime/model/editingModel.ecore b/plugins/org.eclipse.emf.eef.runtime/model/editingModel.ecore
index 7b07ff900..15a70a6d8 100644
--- a/plugins/org.eclipse.emf.eef.runtime/model/editingModel.ecore
+++ b/plugins/org.eclipse.emf.eef.runtime/model/editingModel.ecore
@@ -44,6 +44,7 @@
<eClassifiers xsi:type="ecore:EClass" name="View" abstract="true"/>
<eClassifiers xsi:type="ecore:EClass" name="Editor" abstract="true"/>
<eClassifiers xsi:type="ecore:EClass" name="PropertyBinding">
+ <eOperations name="getEClassBinding" eType="#//EClassBinding"/>
<eStructuralFeatures xsi:type="ecore:EReference" name="editor" lowerBound="1"
eType="#//Editor" containment="true"/>
<eStructuralFeatures xsi:type="ecore:EReference" name="subPropertyBindings" upperBound="-1"
diff --git a/plugins/org.eclipse.emf.eef.runtime/model/editingModel.genmodel b/plugins/org.eclipse.emf.eef.runtime/model/editingModel.genmodel
index 0189e1ed8..8c7340fdc 100644
--- a/plugins/org.eclipse.emf.eef.runtime/model/editingModel.genmodel
+++ b/plugins/org.eclipse.emf.eef.runtime/model/editingModel.genmodel
@@ -53,6 +53,7 @@
<genFeatures property="None" children="true" createChild="true" ecoreFeature="ecore:EReference editingModel.ecore#//PropertyBinding/subPropertyBindings"/>
<genFeatures property="None" children="true" createChild="true" ecoreFeature="ecore:EReference editingModel.ecore#//PropertyBinding/settings"/>
<genFeatures createChild="false" ecoreFeature="ecore:EAttribute editingModel.ecore#//PropertyBinding/bindingCustomizer"/>
+ <genOperations ecoreOperation="editingModel.ecore#//PropertyBinding/getEClassBinding"/>
</genClasses>
<genClasses ecoreClass="editingModel.ecore#//EStructuralFeatureBinding">
<genFeatures notify="false" createChild="false" propertySortChoices="true" ecoreFeature="ecore:EReference editingModel.ecore#//EStructuralFeatureBinding/feature"/>
diff --git a/plugins/org.eclipse.emf.eef.runtime/src-gen/org/eclipse/emf/eef/runtime/editingModel/PropertyBinding.java b/plugins/org.eclipse.emf.eef.runtime/src-gen/org/eclipse/emf/eef/runtime/editingModel/PropertyBinding.java
index b5144fbf2..70d351c83 100644
--- a/plugins/org.eclipse.emf.eef.runtime/src-gen/org/eclipse/emf/eef/runtime/editingModel/PropertyBinding.java
+++ b/plugins/org.eclipse.emf.eef.runtime/src-gen/org/eclipse/emf/eef/runtime/editingModel/PropertyBinding.java
@@ -115,4 +115,12 @@ public interface PropertyBinding extends EModelElement {
*/
void setBindingCustomizer(String value);
+ /**
+ * <!-- begin-user-doc -->
+ * <!-- end-user-doc -->
+ * @model kind="operation"
+ * @generated
+ */
+ EClassBinding getEClassBinding();
+
} // PropertyBinding
diff --git a/plugins/org.eclipse.emf.eef.runtime/src-gen/org/eclipse/emf/eef/runtime/editingModel/impl/EditingModelPackageImpl.java b/plugins/org.eclipse.emf.eef.runtime/src-gen/org/eclipse/emf/eef/runtime/editingModel/impl/EditingModelPackageImpl.java
index 465a1a4e8..58c1c0966 100644
--- a/plugins/org.eclipse.emf.eef.runtime/src-gen/org/eclipse/emf/eef/runtime/editingModel/impl/EditingModelPackageImpl.java
+++ b/plugins/org.eclipse.emf.eef.runtime/src-gen/org/eclipse/emf/eef/runtime/editingModel/impl/EditingModelPackageImpl.java
@@ -680,6 +680,8 @@ public class EditingModelPackageImpl extends EPackageImpl implements EditingMode
initEReference(getPropertyBinding_Settings(), this.getEditorSettings(), null, "settings", null, 0, -1, PropertyBinding.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEAttribute(getPropertyBinding_BindingCustomizer(), ecorePackage.getEString(), "bindingCustomizer", null, 0, 1, PropertyBinding.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
+ addEOperation(propertyBindingEClass, this.getEClassBinding(), "getEClassBinding", 0, 1, IS_UNIQUE, IS_ORDERED);
+
initEClass(eStructuralFeatureBindingEClass, EStructuralFeatureBinding.class, "EStructuralFeatureBinding", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
initEReference(getEStructuralFeatureBinding_Feature(), theEcorePackage.getEStructuralFeature(), null, "feature", null, 1, 1, EStructuralFeatureBinding.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
diff --git a/plugins/org.eclipse.emf.eef.runtime/src-gen/org/eclipse/emf/eef/runtime/editingModel/impl/PropertyBindingImpl.java b/plugins/org.eclipse.emf.eef.runtime/src-gen/org/eclipse/emf/eef/runtime/editingModel/impl/PropertyBindingImpl.java
index bd64025c0..ae27b2c95 100644
--- a/plugins/org.eclipse.emf.eef.runtime/src-gen/org/eclipse/emf/eef/runtime/editingModel/impl/PropertyBindingImpl.java
+++ b/plugins/org.eclipse.emf.eef.runtime/src-gen/org/eclipse/emf/eef/runtime/editingModel/impl/PropertyBindingImpl.java
@@ -12,12 +12,14 @@ import org.eclipse.emf.common.notify.Notification;
import org.eclipse.emf.common.notify.NotificationChain;
import org.eclipse.emf.common.util.EList;
import org.eclipse.emf.ecore.EClass;
+import org.eclipse.emf.ecore.EObject;
import org.eclipse.emf.ecore.InternalEObject;
import org.eclipse.emf.ecore.impl.EModelElementImpl;
import org.eclipse.emf.ecore.impl.ENotificationImpl;
import org.eclipse.emf.ecore.util.EObjectContainmentEList;
import org.eclipse.emf.ecore.util.InternalEList;
import org.eclipse.emf.eef.runtime.binding.PropertyBindingCustomizer;
+import org.eclipse.emf.eef.runtime.editingModel.EClassBinding;
import org.eclipse.emf.eef.runtime.editingModel.EditingModelPackage;
import org.eclipse.emf.eef.runtime.editingModel.Editor;
import org.eclipse.emf.eef.runtime.editingModel.EditorSettings;
@@ -201,6 +203,25 @@ public class PropertyBindingImpl extends EModelElementImpl implements PropertyBi
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ * @generated not
+ */
+ public EClassBinding getEClassBinding() {
+ if (eContainer() instanceof EClassBinding) {
+ return (EClassBinding) eContainer();
+ }
+ EObject parent = eContainer();
+ while (parent.eContainer() != null && !(parent.eContainer() instanceof EClassBinding)) {
+ parent = parent.eContainer();
+ }
+ if (parent instanceof EClassBinding) {
+ return (EClassBinding) parent;
+ }
+ return null;
+ }
+
+ /**
+ * <!-- begin-user-doc -->
+ * <!-- end-user-doc -->
* @generated
*/
@Override

Back to the top