Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorjmallet2017-04-20 17:18:28 +0000
committerPierre-Charles David2017-05-03 12:44:18 +0000
commitd3ea514b60fb462f230f6f32b2f689d787fd277a (patch)
treeb711686b7e479cdacb16975e316fe3fab3a8d7b9
parent217c3e2e4a7192b6c673f7647160d4a1e0c9b600 (diff)
downloadorg.eclipse.sirius-d3ea514b60fb462f230f6f32b2f689d787fd277a.tar.gz
org.eclipse.sirius-d3ea514b60fb462f230f6f32b2f689d787fd277a.tar.xz
org.eclipse.sirius-d3ea514b60fb462f230f6f32b2f689d787fd277a.zip
[507774] Keep current feature values among valid choices
It's the job of the filters in the FeatureEditorDialog to not display the values which are already present on the reference, but we should still provide them so they are available to display when removed from the right side. Also take this opportunity to remove our own obsolete "fork" of EMF's FeatureEditorDialog. The patch which historically justified this forked version has long been intergrated in all versions of EMF that we are compatible with (see bug #381535). Bug: 507774 Change-Id: I0908382a07337cdfa2fd20dad46f0052e862a671 Signed-off-by: jmallet <jessy.mallet@obeo.fr>
-rw-r--r--plugins/org.eclipse.sirius.common.ui/src/org/eclipse/sirius/common/ui/tools/api/dialog/FeatureEditorDialog.java461
-rw-r--r--plugins/org.eclipse.sirius.doc/doc/Release_Notes.html9
-rw-r--r--plugins/org.eclipse.sirius.doc/doc/Release_Notes.textile4
-rw-r--r--plugins/org.eclipse.sirius.doc/doc/specifier/general/Specifying_Viewpoints.html11
-rw-r--r--plugins/org.eclipse.sirius.editor/META-INF/MANIFEST.MF3
-rw-r--r--plugins/org.eclipse.sirius.editor/src-gen/org/eclipse/sirius/editor/properties/sections/common/AbstractEditorDialogPropertySection.java3
-rw-r--r--plugins/org.eclipse.sirius.editor/src/org/eclipse/sirius/editor/properties/sections/common/AbstractEditorDialogWithListPropertySection.java2
-rw-r--r--plugins/org.eclipse.sirius.table.ui/src/org/eclipse/sirius/table/ui/tools/internal/editor/provider/DFeatureColumnEditingSupport.java2
8 files changed, 25 insertions, 470 deletions
diff --git a/plugins/org.eclipse.sirius.common.ui/src/org/eclipse/sirius/common/ui/tools/api/dialog/FeatureEditorDialog.java b/plugins/org.eclipse.sirius.common.ui/src/org/eclipse/sirius/common/ui/tools/api/dialog/FeatureEditorDialog.java
deleted file mode 100644
index 5be385040f..0000000000
--- a/plugins/org.eclipse.sirius.common.ui/src/org/eclipse/sirius/common/ui/tools/api/dialog/FeatureEditorDialog.java
+++ /dev/null
@@ -1,461 +0,0 @@
-/**
- * Copyright (c) 2002-2009 IBM Corporation and others.
- * 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:
- * IBM - Initial API and implementation
- */
-package org.eclipse.sirius.common.ui.tools.api.dialog;
-
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.Iterator;
-import java.util.List;
-import java.util.ListIterator;
-
-import org.eclipse.emf.common.notify.AdapterFactory;
-import org.eclipse.emf.common.notify.impl.AdapterFactoryImpl;
-import org.eclipse.emf.common.ui.celleditor.ExtendedComboBoxCellEditor;
-import org.eclipse.emf.common.util.BasicEList;
-import org.eclipse.emf.common.util.EList;
-import org.eclipse.emf.ecore.EClassifier;
-import org.eclipse.emf.ecore.EDataType;
-import org.eclipse.emf.ecore.EObject;
-import org.eclipse.emf.ecore.EStructuralFeature;
-import org.eclipse.emf.ecore.util.EcoreUtil;
-import org.eclipse.emf.edit.provider.ComposedAdapterFactory;
-import org.eclipse.emf.edit.provider.ItemProvider;
-import org.eclipse.emf.edit.ui.EMFEditUIPlugin;
-import org.eclipse.emf.edit.ui.provider.AdapterFactoryContentProvider;
-import org.eclipse.jface.dialogs.Dialog;
-import org.eclipse.jface.viewers.AbstractTreeViewer;
-import org.eclipse.jface.viewers.DoubleClickEvent;
-import org.eclipse.jface.viewers.IContentProvider;
-import org.eclipse.jface.viewers.IDoubleClickListener;
-import org.eclipse.jface.viewers.ILabelProvider;
-import org.eclipse.jface.viewers.IStructuredSelection;
-import org.eclipse.jface.viewers.StructuredSelection;
-import org.eclipse.jface.viewers.TableViewer;
-import org.eclipse.jface.viewers.Viewer;
-import org.eclipse.jface.viewers.ViewerFilter;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.events.KeyAdapter;
-import org.eclipse.swt.events.KeyEvent;
-import org.eclipse.swt.events.ModifyEvent;
-import org.eclipse.swt.events.ModifyListener;
-import org.eclipse.swt.events.SelectionAdapter;
-import org.eclipse.swt.events.SelectionEvent;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.layout.GridLayout;
-import org.eclipse.swt.widgets.Button;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.swt.widgets.Display;
-import org.eclipse.swt.widgets.Group;
-import org.eclipse.swt.widgets.Label;
-import org.eclipse.swt.widgets.Shell;
-import org.eclipse.swt.widgets.Table;
-import org.eclipse.swt.widgets.Text;
-import org.eclipse.ui.dialogs.PatternFilter;
-
-//CHECKSTYLE:OFF
-public class FeatureEditorDialog extends Dialog {
- protected ILabelProvider labelProvider;
-
- protected IContentProvider contentProvider;
-
- protected Object object;
-
- protected EClassifier eClassifier;
-
- protected String displayName;
-
- protected ItemProvider values;
-
- protected List<?> choiceOfValues;
-
- protected EList<?> result;
-
- protected boolean multiLine;
-
- protected boolean unique;
-
- /**
- * @since 0.9.0
- */
- public FeatureEditorDialog(Shell parent, ILabelProvider labelProvider, Object object, EClassifier eClassifier, List<?> currentValues, String displayName, List<?> choiceOfValues,
- boolean multiLine, boolean sortChoices, boolean unique) {
- super(parent);
- setShellStyle(getShellStyle() | SWT.RESIZE | SWT.MAX);
- this.labelProvider = labelProvider;
- this.object = object;
- this.eClassifier = eClassifier;
- this.displayName = displayName;
- this.choiceOfValues = choiceOfValues;
- this.multiLine = multiLine;
- this.unique = unique;
-
- AdapterFactory adapterFactory = new ComposedAdapterFactory(Collections.<AdapterFactory> emptyList());
- values = new ItemProvider(adapterFactory, currentValues);
- contentProvider = new AdapterFactoryContentProvider(adapterFactory);
- if (sortChoices && choiceOfValues != null) {
- this.choiceOfValues = new ArrayList<Object>(choiceOfValues);
- ExtendedComboBoxCellEditor.createItems(this.choiceOfValues, labelProvider, true);
- }
- }
-
- public FeatureEditorDialog(Shell parent, ILabelProvider labelProvider, EObject eObject, EStructuralFeature eStructuralFeature, String displayName, List<?> choiceOfValues) {
- this(parent, labelProvider, eObject, eStructuralFeature.getEType(), (List<?>) eObject.eGet(eStructuralFeature), displayName, choiceOfValues, false, false, eStructuralFeature.isUnique());
- }
-
- @Override
- protected void configureShell(Shell shell) {
- super.configureShell(shell);
- shell.setText(EMFEditUIPlugin.INSTANCE.getString("_UI_FeatureEditorDialog_title", new Object[] { displayName, labelProvider.getText(object) })); //$NON-NLS-1$
- shell.setImage(labelProvider.getImage(object));
- }
-
- @Override
- protected Control createDialogArea(Composite parent) {
- Composite contents = (Composite) super.createDialogArea(parent);
-
- GridLayout contentsGridLayout = (GridLayout) contents.getLayout();
- contentsGridLayout.numColumns = 3;
-
- GridData contentsGridData = (GridData) contents.getLayoutData();
- contentsGridData.horizontalAlignment = SWT.FILL;
- contentsGridData.verticalAlignment = SWT.FILL;
-
- Text patternText = null;
-
- if (choiceOfValues != null) {
- Group filterGroupComposite = new Group(contents, SWT.NONE);
- filterGroupComposite.setText(EMFEditUIPlugin.INSTANCE.getString("_UI_Choices_pattern_group")); //$NON-NLS-1$
- filterGroupComposite.setLayout(new GridLayout(2, false));
- filterGroupComposite.setLayoutData(new GridData(SWT.FILL, SWT.DEFAULT, true, false, 3, 1));
-
- Label label = new Label(filterGroupComposite, SWT.NONE);
- label.setText(EMFEditUIPlugin.INSTANCE.getString("_UI_Choices_pattern_label")); //$NON-NLS-1$
-
- patternText = new Text(filterGroupComposite, SWT.BORDER);
- patternText.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
- }
-
- Composite choiceComposite = new Composite(contents, SWT.NONE);
- {
- GridData data = new GridData(SWT.FILL, SWT.FILL, true, true);
- data.horizontalAlignment = SWT.END;
- choiceComposite.setLayoutData(data);
-
- GridLayout layout = new GridLayout();
- data.horizontalAlignment = SWT.FILL;
- layout.marginHeight = 0;
- layout.marginWidth = 0;
- layout.numColumns = 1;
- choiceComposite.setLayout(layout);
- }
-
- Label choiceLabel = new Label(choiceComposite, SWT.NONE);
- choiceLabel.setText(choiceOfValues == null ? EMFEditUIPlugin.INSTANCE.getString("_UI_Value_label") : EMFEditUIPlugin.INSTANCE.getString("_UI_Choices_label")); //$NON-NLS-1$ //$NON-NLS-2$
- GridData choiceLabelGridData = new GridData();
- choiceLabelGridData.verticalAlignment = SWT.FILL;
- choiceLabelGridData.horizontalAlignment = SWT.FILL;
- choiceLabel.setLayoutData(choiceLabelGridData);
-
- final Table choiceTable = choiceOfValues == null ? null : new Table(choiceComposite, SWT.MULTI | SWT.BORDER);
- if (choiceTable != null) {
- GridData choiceTableGridData = new GridData();
- choiceTableGridData.widthHint = Display.getCurrent().getBounds().width / 5;
- choiceTableGridData.heightHint = Display.getCurrent().getBounds().height / 3;
- choiceTableGridData.verticalAlignment = SWT.FILL;
- choiceTableGridData.horizontalAlignment = SWT.FILL;
- choiceTableGridData.grabExcessHorizontalSpace = true;
- choiceTableGridData.grabExcessVerticalSpace = true;
- choiceTable.setLayoutData(choiceTableGridData);
- }
-
- final TableViewer choiceTableViewer = choiceOfValues == null ? null : new TableViewer(choiceTable);
- if (choiceTableViewer != null) {
- choiceTableViewer.setContentProvider(new AdapterFactoryContentProvider(new AdapterFactoryImpl()));
- choiceTableViewer.setLabelProvider(labelProvider);
- final PatternFilter filter = new PatternFilter() {
- @Override
- protected boolean isParentMatch(Viewer viewer, Object element) {
- return viewer instanceof AbstractTreeViewer && super.isParentMatch(viewer, element);
- }
- };
- choiceTableViewer.addFilter(filter);
- if (patternText != null) {
- patternText.addModifyListener(new ModifyListener() {
- public void modifyText(ModifyEvent e) {
- filter.setPattern(((Text) e.widget).getText());
- choiceTableViewer.refresh();
- }
- });
- }
- if (unique) {
- choiceTableViewer.addFilter(new ViewerFilter() {
-
- @Override
- public boolean select(Viewer viewer, Object parentElement, Object element) {
- return !values.getChildren().contains(element);
- }
- });
- }
- choiceTableViewer.setInput(new ItemProvider(choiceOfValues));
- }
-
- // We use multi even for a single line because we want to respond to the
- // enter key.
- //
- int style = multiLine ? SWT.MULTI | SWT.H_SCROLL | SWT.V_SCROLL | SWT.BORDER : SWT.MULTI | SWT.BORDER;
- final Text choiceText = choiceOfValues == null ? new Text(choiceComposite, style) : null;
- if (choiceText != null) {
- GridData choiceTextGridData = new GridData();
- choiceTextGridData.widthHint = Display.getCurrent().getBounds().width / 5;
- choiceTextGridData.verticalAlignment = SWT.BEGINNING;
- choiceTextGridData.horizontalAlignment = SWT.FILL;
- choiceTextGridData.grabExcessHorizontalSpace = true;
- if (multiLine) {
- choiceTextGridData.verticalAlignment = SWT.FILL;
- choiceTextGridData.grabExcessVerticalSpace = true;
- }
- choiceText.setLayoutData(choiceTextGridData);
- }
-
- Composite controlButtons = new Composite(contents, SWT.NONE);
- GridData controlButtonsGridData = new GridData();
- controlButtonsGridData.verticalAlignment = SWT.FILL;
- controlButtonsGridData.horizontalAlignment = SWT.FILL;
- controlButtons.setLayoutData(controlButtonsGridData);
-
- GridLayout controlsButtonGridLayout = new GridLayout();
- controlButtons.setLayout(controlsButtonGridLayout);
-
- new Label(controlButtons, SWT.NONE);
-
- final Button addButton = new Button(controlButtons, SWT.PUSH);
- addButton.setText(EMFEditUIPlugin.INSTANCE.getString("_UI_Add_label")); //$NON-NLS-1$
- GridData addButtonGridData = new GridData();
- addButtonGridData.verticalAlignment = SWT.FILL;
- addButtonGridData.horizontalAlignment = SWT.FILL;
- addButton.setLayoutData(addButtonGridData);
-
- final Button removeButton = new Button(controlButtons, SWT.PUSH);
- removeButton.setText(EMFEditUIPlugin.INSTANCE.getString("_UI_Remove_label")); //$NON-NLS-1$
- GridData removeButtonGridData = new GridData();
- removeButtonGridData.verticalAlignment = SWT.FILL;
- removeButtonGridData.horizontalAlignment = SWT.FILL;
- removeButton.setLayoutData(removeButtonGridData);
-
- Label spaceLabel = new Label(controlButtons, SWT.NONE);
- GridData spaceLabelGridData = new GridData();
- spaceLabelGridData.verticalSpan = 2;
- spaceLabel.setLayoutData(spaceLabelGridData);
-
- final Button upButton = new Button(controlButtons, SWT.PUSH);
- upButton.setText(EMFEditUIPlugin.INSTANCE.getString("_UI_Up_label")); //$NON-NLS-1$
- GridData upButtonGridData = new GridData();
- upButtonGridData.verticalAlignment = SWT.FILL;
- upButtonGridData.horizontalAlignment = SWT.FILL;
- upButton.setLayoutData(upButtonGridData);
-
- final Button downButton = new Button(controlButtons, SWT.PUSH);
- downButton.setText(EMFEditUIPlugin.INSTANCE.getString("_UI_Down_label")); //$NON-NLS-1$
- GridData downButtonGridData = new GridData();
- downButtonGridData.verticalAlignment = SWT.FILL;
- downButtonGridData.horizontalAlignment = SWT.FILL;
- downButton.setLayoutData(downButtonGridData);
-
- Composite featureComposite = new Composite(contents, SWT.NONE);
- {
- GridData data = new GridData(SWT.FILL, SWT.FILL, true, true);
- data.horizontalAlignment = SWT.END;
- featureComposite.setLayoutData(data);
-
- GridLayout layout = new GridLayout();
- data.horizontalAlignment = SWT.FILL;
- layout.marginHeight = 0;
- layout.marginWidth = 0;
- layout.numColumns = 1;
- featureComposite.setLayout(layout);
- }
-
- Label featureLabel = new Label(featureComposite, SWT.NONE);
- featureLabel.setText(EMFEditUIPlugin.INSTANCE.getString("_UI_Feature_label")); //$NON-NLS-1$
- GridData featureLabelGridData = new GridData();
- featureLabelGridData.horizontalSpan = 2;
- featureLabelGridData.horizontalAlignment = SWT.FILL;
- featureLabelGridData.verticalAlignment = SWT.FILL;
- featureLabel.setLayoutData(featureLabelGridData);
-
- final Table featureTable = new Table(featureComposite, SWT.MULTI | SWT.BORDER);
- GridData featureTableGridData = new GridData();
- featureTableGridData.widthHint = Display.getCurrent().getBounds().width / 5;
- featureTableGridData.heightHint = Display.getCurrent().getBounds().height / 3;
- featureTableGridData.verticalAlignment = SWT.FILL;
- featureTableGridData.horizontalAlignment = SWT.FILL;
- featureTableGridData.grabExcessHorizontalSpace = true;
- featureTableGridData.grabExcessVerticalSpace = true;
- featureTable.setLayoutData(featureTableGridData);
-
- final TableViewer featureTableViewer = new TableViewer(featureTable);
- featureTableViewer.setContentProvider(contentProvider);
- featureTableViewer.setLabelProvider(labelProvider);
- featureTableViewer.setInput(values);
- final EList<Object> children = values.getChildren();
- if (!children.isEmpty()) {
- featureTableViewer.setSelection(new StructuredSelection(children.get(0)));
- }
-
- if (choiceTableViewer != null) {
- choiceTableViewer.addDoubleClickListener(new IDoubleClickListener() {
- public void doubleClick(DoubleClickEvent event) {
- if (addButton.isEnabled()) {
- addButton.notifyListeners(SWT.Selection, null);
- }
- }
- });
-
- featureTableViewer.addDoubleClickListener(new IDoubleClickListener() {
- public void doubleClick(DoubleClickEvent event) {
- if (removeButton.isEnabled()) {
- removeButton.notifyListeners(SWT.Selection, null);
- }
- }
- });
- }
-
- if (choiceText != null) {
- choiceText.addKeyListener(new KeyAdapter() {
- @Override
- public void keyPressed(KeyEvent event) {
- if (!multiLine && (event.character == '\r' || event.character == '\n')) {
- try {
- Object value = EcoreUtil.createFromString((EDataType) eClassifier, choiceText.getText());
- children.add(value);
- choiceText.setText(""); //$NON-NLS-1$
- featureTableViewer.refresh();
- featureTableViewer.setSelection(new StructuredSelection(value));
- event.doit = false;
- } catch (RuntimeException exception) {
- // Ignore
- }
- } else if (event.character == '\33') {
- choiceText.setText(""); //$NON-NLS-1$
- event.doit = false;
- }
- }
- });
- }
-
- upButton.addSelectionListener(new SelectionAdapter() {
- @Override
- public void widgetSelected(SelectionEvent event) {
- IStructuredSelection selection = (IStructuredSelection) featureTableViewer.getSelection();
- int minIndex = 0;
- for (Iterator<?> i = selection.iterator(); i.hasNext();) {
- Object value = i.next();
- int index = children.indexOf(value);
- children.move(Math.max(index - 1, minIndex++), value);
- }
- }
- });
-
- downButton.addSelectionListener(new SelectionAdapter() {
- @Override
- public void widgetSelected(SelectionEvent event) {
- IStructuredSelection selection = (IStructuredSelection) featureTableViewer.getSelection();
- int maxIndex = children.size() - 1;
- List<?> objects = selection.toList();
- for (ListIterator<?> i = objects.listIterator(objects.size()); i.hasPrevious();) {
- Object value = i.previous();
- int index = children.indexOf(value);
- children.move(Math.min(index + 1, maxIndex--), value);
- }
- }
- });
-
- addButton.addSelectionListener(new SelectionAdapter() {
- // event is null when choiceTableViewer is double clicked
- @Override
- public void widgetSelected(SelectionEvent event) {
- if (choiceTableViewer != null) {
- IStructuredSelection selection = (IStructuredSelection) choiceTableViewer.getSelection();
- for (Iterator<?> i = selection.iterator(); i.hasNext();) {
- Object value = i.next();
- if (!unique || !children.contains(value)) {
- children.add(value);
- }
- }
- featureTableViewer.refresh();
- featureTableViewer.setSelection(selection);
- choiceTableViewer.refresh();
- } else if (choiceText != null) {
- try {
- Object value = EcoreUtil.createFromString((EDataType) eClassifier, choiceText.getText());
- if (!unique || !children.contains(value)) {
- children.add(value);
- choiceText.setText(""); //$NON-NLS-1$
- }
- featureTableViewer.refresh();
- featureTableViewer.setSelection(new StructuredSelection(value));
- } catch (RuntimeException exception) {
- // Ignore
- }
- }
- }
- });
-
- removeButton.addSelectionListener(new SelectionAdapter() {
- // event is null when featureTableViewer is double clicked
- @Override
- public void widgetSelected(SelectionEvent event) {
- IStructuredSelection selection = (IStructuredSelection) featureTableViewer.getSelection();
- Object firstValue = null;
- for (Iterator<?> i = selection.iterator(); i.hasNext();) {
- Object value = i.next();
- if (firstValue == null) {
- firstValue = value;
- }
- children.remove(value);
- }
-
- if (!children.isEmpty()) {
- featureTableViewer.setSelection(new StructuredSelection(children.get(0)));
- }
-
- if (choiceTableViewer != null) {
- choiceTableViewer.refresh();
- choiceTableViewer.setSelection(selection);
- } else if (choiceText != null) {
- if (firstValue != null) {
- String value = EcoreUtil.convertToString((EDataType) eClassifier, firstValue);
- choiceText.setText(value);
- }
- }
- }
- });
-
- return contents;
- }
-
- @Override
- protected void okPressed() {
- result = new BasicEList<Object>(values.getChildren());
- super.okPressed();
- }
-
- @Override
- public boolean close() {
- contentProvider.dispose();
- return super.close();
- }
-
- public EList<?> getResult() {
- return result;
- }
-}
diff --git a/plugins/org.eclipse.sirius.doc/doc/Release_Notes.html b/plugins/org.eclipse.sirius.doc/doc/Release_Notes.html
index 25d8ac144a..06bd03144b 100644
--- a/plugins/org.eclipse.sirius.doc/doc/Release_Notes.html
+++ b/plugins/org.eclipse.sirius.doc/doc/Release_Notes.html
@@ -117,6 +117,15 @@
</ul>
<h3 id="SpecifierVisibleChanges">Specifier-Visible Changes</h3>
<h3 id="DeveloperVisibleChanges">Developer-Visible Changes</h3>
+ <h4 id="Changesinorg.eclipse.sirius.common.ui">Changes in
+ <code>org.eclipse.sirius.common.ui</code>
+ </h4>
+ <ul>
+ <li><span class="label label-danger">Removed</span> The
+ <code>org.eclipse.sirius.common.ui.tools.api.dialog.FeatureEditorDialog</code> class has been removed; use the
+ <code>org.eclipse.emf.edit.ui.celleditor.FeatureEditorDialog</code> equivalent provided by EMF directly instead.
+ </li>
+ </ul>
<h4 id="Changesinorg.eclipse.sirius.diagram.ui">Changes in
<code>org.eclipse.sirius.diagram.ui</code>
</h4>
diff --git a/plugins/org.eclipse.sirius.doc/doc/Release_Notes.textile b/plugins/org.eclipse.sirius.doc/doc/Release_Notes.textile
index 954f74fdd0..5dd8cd3e9b 100644
--- a/plugins/org.eclipse.sirius.doc/doc/Release_Notes.textile
+++ b/plugins/org.eclipse.sirius.doc/doc/Release_Notes.textile
@@ -14,6 +14,10 @@ h3. Specifier-Visible Changes
h3. Developer-Visible Changes
+h4. Changes in @org.eclipse.sirius.common.ui@
+
+* <span class="label label-danger">Removed</span> The @org.eclipse.sirius.common.ui.tools.api.dialog.FeatureEditorDialog@ class has been removed; use the @org.eclipse.emf.edit.ui.celleditor.FeatureEditorDialog@ equivalent provided by EMF directly instead.
+
h4. Changes in @org.eclipse.sirius.diagram.ui@
* <span class="label label-success">Added</span> Constants @org.eclipse.sirius.diagram.ui.business.api.query.ViewQuery.SPECIFIC_STYLES@ & @org.eclipse.sirius.diagram.ui.business.api.query.ViewQuery.VERTICAL_ALIGNMENT@ have been added to retrieve the initial label alignment of Notes from the Palette (see "user-visible changes":Release_Notes.html#UserVisibleChanges ). Currently the vertical alignment can not be changed (potential new feature later).
diff --git a/plugins/org.eclipse.sirius.doc/doc/specifier/general/Specifying_Viewpoints.html b/plugins/org.eclipse.sirius.doc/doc/specifier/general/Specifying_Viewpoints.html
index 81cea078c2..564348c77a 100644
--- a/plugins/org.eclipse.sirius.doc/doc/specifier/general/Specifying_Viewpoints.html
+++ b/plugins/org.eclipse.sirius.doc/doc/specifier/general/Specifying_Viewpoints.html
@@ -2,6 +2,9 @@
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
+ <title>Specifying_Viewpoints</title>
+ <link type="text/css" rel="stylesheet" href="../../resources/bootstrap.css"/>
+ <link type="text/css" rel="stylesheet" href="../../resources/custom.css"/>
</head>
<body>
<h1 id="SpecifyingViewpoints">Specifying Viewpoints</h1>
@@ -157,7 +160,7 @@
<code>description</code> folder. If you want to place them in a different location, make sure to add this location into the plug-in&#8217;s
<code>build.properties</code> so that it is included in the deployed version.
</p>
- <p>The VSM name is given according to the project name defined when using the previous wizard. If the project name is suffixed with &#171;design&#187;, the VSM name is provided by the last word before this suffix. Otherwise, the VSM name is given by the last word of the project name.</p>
+ <p>The VSM name is given according to the project name defined when using the previous wizard. If the project name is suffixed with &#8220;design&#8221;, the VSM name is provided by the last word before this suffix. Otherwise, the VSM name is given by the last word of the project name.</p>
<p>Other than that, the project is a normal Java plug-in project. You can add
<a href="Writing_Queries.html#service_methods">service classes</a> into it if the query language you use support it, and any other Java code, including Eclipse views, actions, etc.
</p>
@@ -321,7 +324,7 @@
<p>
<img border="0" src="images/interpreted_expressions.png"/>
</p>
- <p>Also, by clicking on the button next to the text field, you can open a dialog with a bigger text area (providing auto-completion too) to type your expression more comfortably. Note that you can add line feeds or tabulations if you want, since they are removed when clicking on the &#171;OK&#187; button.</p>
+ <p>Also, by clicking on the button next to the text field, you can open a dialog with a bigger text area (providing auto-completion too) to type your expression more comfortably. Note that you can add line feeds or tabulations if you want, since they are removed when clicking on the &#8220;OK&#8221; button.</p>
<p>
<img border="0" src="images/textAreaDialog.png"/>
</p>
@@ -455,7 +458,7 @@
<p>To validate your VSM, open your
<code>odesign</code> file, right-click on the top-level
<em>Group</em> element and select
- <em>Viewpoint specification Editor &gt; Validate</em>. A dialog Box will appear and indicate if the validation succeeded. If not, it will give you details about the detected problems (click on the &#8249;details&#8250; button of the dialog box). If problems are detected, they will also be added to the Eclipse
+ <em>Viewpoint specification Editor &gt; Validate</em>. A dialog Box will appear and indicate if the validation succeeded. If not, it will give you details about the detected problems (click on the &#8216;details&#8217; button of the dialog box). If problems are detected, they will also be added to the Eclipse
<em>Problems</em> view. Double-clicking on one of these problems will select the concerned element in the
<a href="../../Glossary.html#VSM">
<em>Viewpoint Specification Model</em>
@@ -477,7 +480,7 @@
</p>
<p>Keep both your representations and the VSM that define them open at the same time. Whenever you change some definition or add new elements into your VSM, simply save it. Sirius will automatically detect the change, reload the new definition and apply it to your existing representations. This way you can develop your representations iteratively, for example starting from an empty diagram and adding more elements, styles and tools while and testing them immediately.</p>
<p><div style="display: none">
- <br/> TODO Add a screenshot with both a VSM (on the left) and the corresponding diagram (on the right) opened at the same time. Make sure the &#171;Model Explorer&#187; is also visible to show both the VSP and the Modeling project they correspond to.
+ <br/> TODO Add a screenshot with both a VSM (on the left) and the corresponding diagram (on the right) opened at the same time. Make sure the &#8220;Model Explorer&#8221; is also visible to show both the VSP and the Modeling project they correspond to.
<br/></div>
</p>
<p>Note that Sirius does its best to take into account any change in the VSM, even for existing and opened representations. Sometimes, if the changes are too complex or in some corner cases not yet supported, you may need to close and reopen your representation, or in extreme case delete it and create a new one, in order to take the VSM changes into account properly.</p>
diff --git a/plugins/org.eclipse.sirius.editor/META-INF/MANIFEST.MF b/plugins/org.eclipse.sirius.editor/META-INF/MANIFEST.MF
index 1d9fbf9889..6aa423a45b 100644
--- a/plugins/org.eclipse.sirius.editor/META-INF/MANIFEST.MF
+++ b/plugins/org.eclipse.sirius.editor/META-INF/MANIFEST.MF
@@ -19,7 +19,8 @@ Require-Bundle: org.eclipse.ui.views.properties.tabbed;bundle-version="3.5.300",
org.eclipse.ui.navigator;bundle-version="3.5.200",
org.eclipse.jface.text;bundle-version="3.8.2",
org.eclipse.equinox.frameworkadmin;bundle-version="2.0.100",
- org.eclipse.pde.core;bundle-version="3.8.1"
+ org.eclipse.pde.core;bundle-version="3.8.1",
+ org.eclipse.emf.edit.ui;bundle-version="2.8.0"
Bundle-RequiredExecutionEnvironment: JavaSE-1.8
Eclipse-LazyStart: true
Export-Package: org.eclipse.sirius.editor.assist.content;version="2.0.4",
diff --git a/plugins/org.eclipse.sirius.editor/src-gen/org/eclipse/sirius/editor/properties/sections/common/AbstractEditorDialogPropertySection.java b/plugins/org.eclipse.sirius.editor/src-gen/org/eclipse/sirius/editor/properties/sections/common/AbstractEditorDialogPropertySection.java
index 43ec7deaf5..b43af0678a 100644
--- a/plugins/org.eclipse.sirius.editor/src-gen/org/eclipse/sirius/editor/properties/sections/common/AbstractEditorDialogPropertySection.java
+++ b/plugins/org.eclipse.sirius.editor/src-gen/org/eclipse/sirius/editor/properties/sections/common/AbstractEditorDialogPropertySection.java
@@ -25,11 +25,11 @@ import org.eclipse.emf.edit.domain.EditingDomain;
import org.eclipse.emf.edit.domain.IEditingDomainProvider;
import org.eclipse.emf.edit.provider.IItemPropertyDescriptor;
import org.eclipse.emf.edit.provider.ItemProviderAdapter;
+import org.eclipse.emf.edit.ui.celleditor.FeatureEditorDialog;
import org.eclipse.emf.edit.ui.provider.PropertyDescriptor;
import org.eclipse.jface.viewers.ILabelProvider;
import org.eclipse.jface.viewers.ISelection;
import org.eclipse.jface.viewers.TreeSelection;
-import org.eclipse.sirius.common.ui.tools.api.dialog.FeatureEditorDialog;
import org.eclipse.sirius.editor.properties.ViewpointPropertySheetPage;
import org.eclipse.sirius.ui.business.api.dialect.HierarchyLabelProvider;
import org.eclipse.swt.SWT;
@@ -242,7 +242,6 @@ public abstract class AbstractEditorDialogPropertySection extends AbstractViewpo
protected List<?> getChoiceOfValues(List<?> currentValues) {
List<?> list = Collections.emptyList();
Collection<?> choiceOfValues = getIItemPropertyDescriptor().getChoiceOfValues(eObject);
- choiceOfValues.removeAll(currentValues);
if (choiceOfValues != null) {
list = new ArrayList<Object>(choiceOfValues);
}
diff --git a/plugins/org.eclipse.sirius.editor/src/org/eclipse/sirius/editor/properties/sections/common/AbstractEditorDialogWithListPropertySection.java b/plugins/org.eclipse.sirius.editor/src/org/eclipse/sirius/editor/properties/sections/common/AbstractEditorDialogWithListPropertySection.java
index 1155fb771e..23e5765325 100644
--- a/plugins/org.eclipse.sirius.editor/src/org/eclipse/sirius/editor/properties/sections/common/AbstractEditorDialogWithListPropertySection.java
+++ b/plugins/org.eclipse.sirius.editor/src/org/eclipse/sirius/editor/properties/sections/common/AbstractEditorDialogWithListPropertySection.java
@@ -21,9 +21,9 @@ import org.eclipse.emf.ecore.provider.EcoreItemProviderAdapterFactory;
import org.eclipse.emf.edit.provider.ComposedAdapterFactory;
import org.eclipse.emf.edit.provider.ReflectiveItemProviderAdapterFactory;
import org.eclipse.emf.edit.provider.resource.ResourceItemProviderAdapterFactory;
+import org.eclipse.emf.edit.ui.celleditor.FeatureEditorDialog;
import org.eclipse.emf.edit.ui.provider.AdapterFactoryLabelProvider;
import org.eclipse.jface.viewers.ILabelProvider;
-import org.eclipse.sirius.common.ui.tools.api.dialog.FeatureEditorDialog;
import org.eclipse.sirius.ui.business.api.dialect.DialectUIManager;
import org.eclipse.sirius.ui.business.api.dialect.HierarchyLabelProvider;
import org.eclipse.sirius.ui.business.api.featureExtensions.FeatureExtensionsUIManager;
diff --git a/plugins/org.eclipse.sirius.table.ui/src/org/eclipse/sirius/table/ui/tools/internal/editor/provider/DFeatureColumnEditingSupport.java b/plugins/org.eclipse.sirius.table.ui/src/org/eclipse/sirius/table/ui/tools/internal/editor/provider/DFeatureColumnEditingSupport.java
index 8af70da6ba..758b07ca59 100644
--- a/plugins/org.eclipse.sirius.table.ui/src/org/eclipse/sirius/table/ui/tools/internal/editor/provider/DFeatureColumnEditingSupport.java
+++ b/plugins/org.eclipse.sirius.table.ui/src/org/eclipse/sirius/table/ui/tools/internal/editor/provider/DFeatureColumnEditingSupport.java
@@ -32,6 +32,7 @@ import org.eclipse.emf.ecore.EStructuralFeature;
import org.eclipse.emf.edit.provider.ComposedAdapterFactory;
import org.eclipse.emf.edit.provider.IItemPropertyDescriptor;
import org.eclipse.emf.edit.provider.IItemPropertySource;
+import org.eclipse.emf.edit.ui.celleditor.FeatureEditorDialog;
import org.eclipse.emf.edit.ui.provider.ExtendedImageRegistry;
import org.eclipse.emf.edit.ui.provider.PropertyDescriptor;
import org.eclipse.emf.transaction.RecordingCommand;
@@ -50,7 +51,6 @@ import org.eclipse.jface.viewers.ViewerCell;
import org.eclipse.sirius.business.api.logger.RuntimeLoggerManager;
import org.eclipse.sirius.common.tools.api.interpreter.EvaluationException;
import org.eclipse.sirius.common.tools.api.interpreter.IInterpreter;
-import org.eclipse.sirius.common.ui.tools.api.dialog.FeatureEditorDialog;
import org.eclipse.sirius.ecore.extender.business.api.accessor.ModelAccessor;
import org.eclipse.sirius.ecore.extender.business.api.accessor.exception.FeatureNotFoundException;
import org.eclipse.sirius.ecore.extender.business.api.permission.IPermissionAuthority;

Back to the top