diff options
Diffstat (limited to 'extraplugins/diagram-definition/org.eclipse.papyrus.dd.edit/src/org/eclipse/papyrus/dd/di/provider/DiagramItemProvider.java')
-rw-r--r-- | extraplugins/diagram-definition/org.eclipse.papyrus.dd.edit/src/org/eclipse/papyrus/dd/di/provider/DiagramItemProvider.java | 107 |
1 files changed, 57 insertions, 50 deletions
diff --git a/extraplugins/diagram-definition/org.eclipse.papyrus.dd.edit/src/org/eclipse/papyrus/dd/di/provider/DiagramItemProvider.java b/extraplugins/diagram-definition/org.eclipse.papyrus.dd.edit/src/org/eclipse/papyrus/dd/di/provider/DiagramItemProvider.java index b93e1dba077..c01f70b3f0b 100644 --- a/extraplugins/diagram-definition/org.eclipse.papyrus.dd.edit/src/org/eclipse/papyrus/dd/di/provider/DiagramItemProvider.java +++ b/extraplugins/diagram-definition/org.eclipse.papyrus.dd.edit/src/org/eclipse/papyrus/dd/di/provider/DiagramItemProvider.java @@ -31,10 +31,9 @@ import org.eclipse.papyrus.dd.di.DIPackage; import org.eclipse.papyrus.dd.di.Diagram; /** - * This is the item provider adapter for a - * {@link org.eclipse.papyrus.dd.di.Diagram} object. <!-- begin-user-doc --> + * This is the item provider adapter for a {@link org.eclipse.papyrus.dd.di.Diagram} object. + * <!-- begin-user-doc --> * <!-- end-user-doc --> - * * @generated */ public class DiagramItemProvider extends ShapeItemProvider implements @@ -70,21 +69,25 @@ public class DiagramItemProvider extends ShapeItemProvider implements } /** - * This adds a property descriptor for the Name feature. <!-- begin-user-doc + * This adds a property descriptor for the Name feature. + * <!-- begin-user-doc * --> <!-- end-user-doc --> - * * @generated */ protected void addNamePropertyDescriptor(Object object) { - itemPropertyDescriptors.add(createItemPropertyDescriptor( - ((ComposeableAdapterFactory) adapterFactory) - .getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_Diagram_name_feature"), - getString("_UI_PropertyDescriptor_description", - "_UI_Diagram_name_feature", "_UI_Diagram_type"), - DIPackage.Literals.DIAGRAM__NAME, true, false, false, - ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, null, null)); + itemPropertyDescriptors.add + (createItemPropertyDescriptor + (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), + getResourceLocator(), + getString("_UI_Diagram_name_feature"), + getString("_UI_PropertyDescriptor_description", "_UI_Diagram_name_feature", "_UI_Diagram_type"), + DIPackage.Literals.DIAGRAM__NAME, + true, + false, + false, + ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, + null, + null)); } /** @@ -94,18 +97,19 @@ public class DiagramItemProvider extends ShapeItemProvider implements * @generated */ protected void addDocumentationPropertyDescriptor(Object object) { - itemPropertyDescriptors - .add(createItemPropertyDescriptor( - ((ComposeableAdapterFactory) adapterFactory) - .getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_Diagram_documentation_feature"), - getString("_UI_PropertyDescriptor_description", - "_UI_Diagram_documentation_feature", - "_UI_Diagram_type"), - DIPackage.Literals.DIAGRAM__DOCUMENTATION, true, false, - false, ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, - null, null)); + itemPropertyDescriptors.add + (createItemPropertyDescriptor + (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), + getResourceLocator(), + getString("_UI_Diagram_documentation_feature"), + getString("_UI_PropertyDescriptor_description", "_UI_Diagram_documentation_feature", "_UI_Diagram_type"), + DIPackage.Literals.DIAGRAM__DOCUMENTATION, + true, + false, + false, + ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, + null, + null)); } /** @@ -115,36 +119,40 @@ public class DiagramItemProvider extends ShapeItemProvider implements * @generated */ protected void addResolutionPropertyDescriptor(Object object) { - itemPropertyDescriptors.add(createItemPropertyDescriptor( - ((ComposeableAdapterFactory) adapterFactory) - .getRootAdapterFactory(), - getResourceLocator(), - getString("_UI_Diagram_resolution_feature"), - getString("_UI_PropertyDescriptor_description", - "_UI_Diagram_resolution_feature", "_UI_Diagram_type"), - DIPackage.Literals.DIAGRAM__RESOLUTION, true, false, false, - ItemPropertyDescriptor.REAL_VALUE_IMAGE, null, null)); + itemPropertyDescriptors.add + (createItemPropertyDescriptor + (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), + getResourceLocator(), + getString("_UI_Diagram_resolution_feature"), + getString("_UI_PropertyDescriptor_description", "_UI_Diagram_resolution_feature", "_UI_Diagram_type"), + DIPackage.Literals.DIAGRAM__RESOLUTION, + true, + false, + false, + ItemPropertyDescriptor.REAL_VALUE_IMAGE, + null, + null)); } /** - * This returns the label text for the adapted class. <!-- begin-user-doc + * This returns the label text for the adapted class. + * <!-- begin-user-doc * --> <!-- end-user-doc --> - * * @generated */ @Override public String getText(Object object) { - String label = ((Diagram) object).getName(); - return label == null || label.length() == 0 ? getString("_UI_Diagram_type") - : getString("_UI_Diagram_type") + " " + label; + String label = ((Diagram)object).getName(); + return label == null || label.length() == 0 ? + getString("_UI_Diagram_type") : + getString("_UI_Diagram_type") + " " + label; } /** - * 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 */ @Override @@ -152,12 +160,11 @@ public class DiagramItemProvider extends ShapeItemProvider implements updateChildren(notification); switch (notification.getFeatureID(Diagram.class)) { - case DIPackage.DIAGRAM__NAME: - case DIPackage.DIAGRAM__DOCUMENTATION: - case DIPackage.DIAGRAM__RESOLUTION: - fireNotifyChanged(new ViewerNotification(notification, - notification.getNotifier(), false, true)); - return; + case DIPackage.DIAGRAM__NAME: + case DIPackage.DIAGRAM__DOCUMENTATION: + case DIPackage.DIAGRAM__RESOLUTION: + fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), false, true)); + return; } super.notifyChanged(notification); } |