Backup the work made to remove embedded editors.
diff --git a/plugins/org.eclipse.bpel.common.ui/META-INF/MANIFEST.MF b/plugins/org.eclipse.bpel.common.ui/META-INF/MANIFEST.MF
index 4cce43d..9a1f9b2 100644
--- a/plugins/org.eclipse.bpel.common.ui/META-INF/MANIFEST.MF
+++ b/plugins/org.eclipse.bpel.common.ui/META-INF/MANIFEST.MF
@@ -17,7 +17,6 @@
  org.eclipse.bpel.common.ui.assist,
  org.eclipse.bpel.common.ui.calendar,
  org.eclipse.bpel.common.ui.command,
- org.eclipse.bpel.common.ui.composite,
  org.eclipse.bpel.common.ui.decorator,
  org.eclipse.bpel.common.ui.details,
  org.eclipse.bpel.common.ui.details.viewers,
diff --git a/plugins/org.eclipse.bpel.common.ui/plugin.xml b/plugins/org.eclipse.bpel.common.ui/plugin.xml
index 45e3912..97b6668 100644
--- a/plugins/org.eclipse.bpel.common.ui/plugin.xml
+++ b/plugins/org.eclipse.bpel.common.ui/plugin.xml
@@ -1,7 +1,6 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <?eclipse version="3.0"?>
 <plugin>
-   <extension-point id="embeddedEditors" name="Embedded Editors" schema="schema/embeddedEditors.exsd"/>
    <extension-point id="paletteAdditions" name="Palette Additions" schema="schema/paletteAdditions.exsd"/>
    <extension-point id="resourceSetProvider" name="Resource Set Provider" schema="schema/resourceSetProvider.exsd"/>
    
diff --git a/plugins/org.eclipse.bpel.common.ui/schema/embeddedEditors.exsd b/plugins/org.eclipse.bpel.common.ui/schema/embeddedEditors.exsd
deleted file mode 100644
index 8225d2a..0000000
--- a/plugins/org.eclipse.bpel.common.ui/schema/embeddedEditors.exsd
+++ /dev/null
@@ -1,151 +0,0 @@
-<?xml version='1.0' encoding='UTF-8'?>
-<!-- Schema file written by PDE -->
-<schema targetNamespace="org.eclipse.bpel.common.ui">
-<annotation>
-      <appInfo>
-         <meta.schema plugin="org.eclipse.bpel.common.ui" id="embeddedEditors" name="Embedded Editors"/>
-      </appInfo>
-      <documentation>
-         This extension point enumerates the text editors which can be used in the &quot;embedded&quot; sense 
-to edit expressions in the expression languages selected by the BPEL process.
-&lt;p&gt;
-Such &quot;embedded&quot; editors differ from a normal text editor in eclispe in that they do not open a resource (such as a file) but operate on some internal memory representation of a document. Such editos also are not openeable in the main editor area but rather open in various views where their services is necessary.
-      </documentation>
-   </annotation>
-
-   <element name="extension">
-      <complexType>
-         <sequence>
-            <element ref="editor" minOccurs="1" maxOccurs="unbounded"/>
-         </sequence>
-         <attribute name="point" type="string" use="required">
-            <annotation>
-               <documentation>
-                  
-               </documentation>
-            </annotation>
-         </attribute>
-         <attribute name="id" type="string">
-            <annotation>
-               <documentation>
-                  
-               </documentation>
-            </annotation>
-         </attribute>
-         <attribute name="name" type="string">
-            <annotation>
-               <documentation>
-                  
-               </documentation>
-               <appInfo>
-                  <meta.attribute translatable="true"/>
-               </appInfo>
-            </annotation>
-         </attribute>
-      </complexType>
-   </element>
-
-   <element name="editor">
-      <complexType>
-         <attribute name="class" type="string" use="required">
-            <annotation>
-               <documentation>
-                  The name of a class that implements &lt;tt&gt;org.eclipse.ui.IEditorPart.&lt;/tt&gt;.
-               </documentation>
-               <appInfo>
-                  <meta.attribute kind="java" basedOn="org.eclipse.ui.texteditor.IEditorPart"/>
-               </appInfo>
-            </annotation>
-         </attribute>
-         <attribute name="contributorClass" type="string">
-            <annotation>
-               <documentation>
-                  The name of a class that implements &lt;tt&gt;org.eclipse.ui.IEditorActionBarContributor.&lt;/tt&gt;
-This attribute should only be defined if the class attribute is defined. This class is used to add new actions to the workbench menu and tool bar which reflect the features of the editor type.
-               </documentation>
-               <appInfo>
-                  <meta.attribute kind="java" basedOn="org.eclipse.ui.IEditorActionBarContributor"/>
-               </appInfo>
-            </annotation>
-         </attribute>
-         <attribute name="id" type="string" use="required">
-            <annotation>
-               <documentation>
-                  A unique id that will be used to identify this editor
-               </documentation>
-            </annotation>
-         </attribute>
-         <attribute name="name" type="string" use="required">
-            <annotation>
-               <documentation>
-                  The name of this editor (XPath Editor, Ruby Editor).
-               </documentation>
-            </annotation>
-         </attribute>
-      </complexType>
-   </element>
-
-   <annotation>
-      <appInfo>
-         <meta.section type="since"/>
-      </appInfo>
-      <documentation>
-         Since 0.0.1 of the BPEL editor plugin.
-      </documentation>
-   </annotation>
-
-   <annotation>
-      <appInfo>
-         <meta.section type="examples"/>
-      </appInfo>
-      <documentation>
-         &lt;pre&gt;
-
-&lt;extension
-      point=&quot;org.eclipse.bpel.common.ui.embeddedEditors&quot;&gt;
-      &lt;editor
-            contributorClass=&quot;org.eclipse.ui.texteditor.BasicTextEditorActionContributor&quot;
-            class=&quot;org.eclipse.bpel.ui.editors.xpath.XPathTextEditor&quot;
-            name=&quot;XPath 1.0 Text Editor.&quot;
-            id=&quot;org.eclipse.bpel.ui.editors.xpath.XPathTextEditor&quot;&gt;
-      &lt;/editor&gt;
-      &lt;editor
-            contributorClass=&quot;org.eclipse.ui.texteditor.BasicTextEditorActionContributor&quot;
-            class=&quot;org.eclipse.bpel.ui.editors.TextEditor&quot;
-            name=&quot;Default Expression Editor&quot;
-            id=&quot;org.eclipse.bpel.ui.editors.TextEditor&quot;&gt;
-      &lt;/editor&gt;
-&lt;/extension&gt;
-
-&lt;/pre&gt;
-      </documentation>
-   </annotation>
-
-   <annotation>
-      <appInfo>
-         <meta.section type="apiInfo"/>
-      </appInfo>
-      <documentation>
-         
-      </documentation>
-   </annotation>
-
-   <annotation>
-      <appInfo>
-         <meta.section type="implementation"/>
-      </appInfo>
-      <documentation>
-         An implementation of an XPath text editor and a Default text editor is provided.
-      </documentation>
-   </annotation>
-
-   <annotation>
-      <appInfo>
-         <meta.section type="copyright"/>
-      </appInfo>
-      <documentation>
-         Copyright IBM (2006+)
-      </documentation>
-   </annotation>
-
-</schema>
diff --git a/plugins/org.eclipse.bpel.common.ui/src/org/eclipse/bpel/common/ui/composite/CompositeEditor.java b/plugins/org.eclipse.bpel.common.ui/src/org/eclipse/bpel/common/ui/composite/CompositeEditor.java
deleted file mode 100644
index 19e37a5..0000000
--- a/plugins/org.eclipse.bpel.common.ui/src/org/eclipse/bpel/common/ui/composite/CompositeEditor.java
+++ /dev/null
@@ -1,445 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005 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 Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.bpel.common.ui.composite;
-
-import java.util.ArrayList;
-import java.util.List;
-
-import org.eclipse.bpel.common.ui.CommonUIPlugin;
-import org.eclipse.bpel.common.ui.Messages;
-import org.eclipse.bpel.common.ui.Policy;
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.core.runtime.ISafeRunnable;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.Status;
-import org.eclipse.jface.util.SafeRunnable;
-import org.eclipse.osgi.util.NLS;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.layout.FillLayout;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.swt.widgets.Event;
-import org.eclipse.swt.widgets.Listener;
-import org.eclipse.ui.IEditorInput;
-import org.eclipse.ui.IEditorPart;
-import org.eclipse.ui.IEditorSite;
-import org.eclipse.ui.IPartListener;
-import org.eclipse.ui.IPropertyListener;
-import org.eclipse.ui.IWorkbenchPart;
-import org.eclipse.ui.PartInitException;
-import org.eclipse.ui.part.EditorPart;
-
-
-/**
- * The CompositeEditor contains a collection of embedded editors.
- * Each embedded editor provides its own contributions. The contributions
- * are available for the user when the embedded editor is activated.
- * Embedded editors have to be registered through the embeddedEditors
- * extension point like the example bellow:
- * 
- * <extension point="org.eclipse.bpel.common.ui.embeddedEditors">
- *    <editor
- *       id="com.examples.MyEmbeddedEditor"
- *       class="com.examples.MyEmbeddedEditor"
- *       contributorClass="com.examples.MyEmbeddedEditorActionBarContributor"/>
- * </extension>
- * 
- * Notes:
- * Embedded editors can never be the workbench active part. The
- * active part is aways the CompositeEditor.
- */
-public abstract class CompositeEditor extends EditorPart {
-
-	protected EmbeddedEditorsCollection embeddedEditors;
-	protected IPropertyListener propertyListener;
-	protected CompositeEditorManager editorManager;
-	protected IEditorPart mainEditor;
-
-	/**
-	 * Since subclasses might implement their own part listeners
-	 * we make this attribute private so that there are no name
-	 * conflicts and subclasses do not overwrite this listener by accident.
-	 */
-	private IPartListener partListener;
-
-	/**
-	 * Represents the collection of embedded editors
-	 * and the active editor index. It also helps to
-	 * maintain the collection and the index in sync.   
-	 */
-	class EmbeddedEditorsCollection {
-		private List<IEditorPart> editors;
-		private IEditorPart[] editorsArrayCache;
-		private int activeEditorIndex;
-
-		EmbeddedEditorsCollection() {
-			editors = new ArrayList<IEditorPart>(10);
-			editorsArrayCache = null;
-			activeEditorIndex = -1; // -1 means there are no active editors
-		}
-
-		void add(IEditorPart editor) {
-			editors.add(editor);
-			editorsArrayCache = null;
-		}
-
-		/**
-		 * We should never be able to remove the active editor.
-		 */
-		void remove(IEditorPart editor) {
-			IEditorPart currentActiveEditor = getActiveEditor();
-			if (currentActiveEditor == editor) {
-				throw new IllegalArgumentException(Messages.CompositeEditor_0); 
-			}
-			editors.remove(editor);
-			editorsArrayCache = null;
-			// we need to keep the index updated after removing an editor
-			setActiveEditor(currentActiveEditor);
-		}
-
-		IEditorPart[] getEmbeddedEditors() {
-			if (editorsArrayCache == null) {
-				editorsArrayCache = (IEditorPart[]) editors.toArray(new IEditorPart[editors.size()]);
-			}
-			return editorsArrayCache;
-		}
-
-		IEditorPart getActiveEditor() {
-			// there are no active editors yet
-			if (activeEditorIndex == -1) {
-				return null;
-			}
-			IEditorPart[] editors = getEmbeddedEditors();
-			return editors[activeEditorIndex];
-		}
-
-		boolean contains(IEditorPart editor) {
-			return editors.contains(editor);
-		}
-
-		void setActiveEditor(IEditorPart editor) {
-			if (editor == null) {
-				activeEditorIndex = -1;
-				return;
-			}
-			IEditorPart[] editors = getEmbeddedEditors();
-			for (int i = 0; i < editors.length; i++) {
-				if (editor == editors[i]) {
-					activeEditorIndex = i;
-					return;
-				}
-			}
-		}
-		
-		void clearEditors() {
-			setActiveEditor(null);
-			editors.clear();
-			editorsArrayCache = null;
-		}
-	}
-
-	public CompositeEditor() {
-		embeddedEditors = new EmbeddedEditorsCollection();
-	}
-
-	/**
-	 * Creates an embedded editor corresponding to the given editorId and
-	 * connects it to the CompositeEditor.
-	 * <p>
-	 * It is important to notice that the returned editor will never be
-	 * the workbench active part.
-	 * <p>
-	 * For each composite editor one of its embedded editors should be
-	 * designated as the main editor. In order to do that you have to
-	 * call <code>CompositeEditor#setMainEditor</code>.
-	 * 
-	 * @param editor the embedded editor
-	 * @param editorComposite the editor's parent composite
-	 * @return IEditorPart the embedded editor instance
-	 * 
-	 * @see CompositeEditor#setMainEditor
-	 */
-	public IEditorPart connectEditor(String editorId, IEditorInput input, Composite editorComposite) throws CoreException {
-		final IEditorPart editor = editorManager.createEditor(editorId, input);
-		embeddedEditors.add(editor);
-
-		Composite composite = new Composite(editorComposite, SWT.NONE);
-		composite.setLayout(new FillLayout());
-		editor.createPartControl(composite);
-		editor.addPropertyListener(getPropertyListener());
-
-		// This is the fundamental part of our implementation.
-		// Editors are activated when we get an Activate
-		// event from the editor's composite.
-		associate(editor, composite);
-
-		return editor;
-	}
-
-	/**
-	 * Associates the control with the given editor. When the control
-	 * is activated all the editor contributions will be activated
-	 * as well. This is useful when the CompositeEditor is not only
-	 * composed by embedded editor but also by other controls. If no editor
-	 * is associated with these controls the available contributions
-	 * (menus, toolbars, status line, etc...) will be the contributions
-	 * for the last active editor and might cause confusion to the user. 
-	 */
-	public void associate(final IEditorPart editor, Control control) {
-		control.addListener(SWT.Activate, new Listener() {
-			public void handleEvent(Event event) {
-				activateEditor(editor);
-			}
-		});
-	}
-
-	/**
-	 * Activates contributions from the given editor and
-	 * deactivates contributions from the current editor.
-	 */
-	protected void activateEditor(IEditorPart newEditor) {
-		IEditorPart oldEditor = embeddedEditors.getActiveEditor();
-		// It can only be null when the first editor is activated.
-		// If that is the case just go ahead and activate newEditor
-		if (oldEditor != null) {
-			if (oldEditor == newEditor) {
-				return;
-			}
-			editorManager.deactivate(oldEditor);
-		}
-		editorManager.activate(newEditor);
-		embeddedEditors.setActiveEditor(newEditor);
-	}
-
-	/**
-	 * Removes the given editor from this composite editor. If the given
-	 * editor is the current active editor the main editor will be activated
-	 * instead. The main editor cannot be disconnected by calling this
-	 * method.
-	 * 
-	 * @exception CoreException if the editor cannot be disconnected. Reasons include:
-	 * <ul>
-	 * <li> The editor is the main editor.</li>
-	 * <li> The editor is the current active editor and the main editor was not defined.</li>
-	 * </ul>
-	 */
-	public void disconnectEditor(IEditorPart editor) throws CoreException {
-		if (editor == embeddedEditors.getActiveEditor()) {
-			if (mainEditor != null && editor != mainEditor) {
-				activateEditor(mainEditor);
-			} else {
-				IStatus status = new Status(IStatus.ERROR, CommonUIPlugin.PLUGIN_ID, ICompositeEditorConstants.COULD_NOT_DISCONNECT_EDITOR, NLS.bind(Messages.CompositeEditor_Cannot_disconnect_active_editor, (new Object[] { editor.getTitle() })), null); 
-				throw new CoreException(status);
-			}
-		}
-		embeddedEditors.remove(editor);
-		editor.removePropertyListener(getPropertyListener());
-		CompositeEditorSite site = (CompositeEditorSite) editor.getSite();
-		CompositeEditorActionBars actionBars = (CompositeEditorActionBars) site.getActionBars();
-		actionBars.dispose();
-		site.dispose();
-		editor.dispose();
-	}
-
-	/**
-	 * Listens and propagates all property changes from embedded editors.
-	 * This is the default implementation. Subclasses may overwrite
-	 * and specialize the behaviour.  
-	 */
-	protected IPropertyListener getPropertyListener() {
-		if (propertyListener == null) {
-			propertyListener = new IPropertyListener() {
-				public void propertyChanged(Object source, int propId) {
-					firePropertyChange(propId);
-				}
-			};
-		}
-		return propertyListener;
-	}
-
-	/**
-	 * Disconects all of the embedded editors. Subclasses should implement
-	 * internalDispose() instead of dispose();
-	 */
-	@Override
-	public final void dispose() {
-		embeddedEditors.setActiveEditor(null);
-		internalDispose();
-		IEditorPart[] editors = embeddedEditors.getEmbeddedEditors();
-		for (int i = 0; i < editors.length; i++) {
-			try {
-				disconnectEditor(editors[i]);
-			} catch (CoreException e) {
-				// should never hapen because there should
-				// be no active editors at this point
-			}
-		}
-		getEditorSite().getPage().removePartListener(getPartlistener());
-		super.dispose();
-		getEditorSite().setSelectionProvider(null);
-		// discard our references to editors (to help reduce memory leakage)
-		embeddedEditors.clearEditors();
-		embeddedEditors = null;
-	}
-
-	/**
-	 * Should be implemented by clients. 
-	 */
-	protected void internalDispose() {
-	}
-
-	@Override
-	public boolean isDirty() {
-		IEditorPart[] editors = embeddedEditors.getEmbeddedEditors();
-		for (int i = 0; i < editors.length; i++) {
-			if (editors[i].isDirty()) {
-				return true;
-			}
-		}
-		return false;
-	}
-
-	/**
-	 * Default implementation saves all of the embedded editors but
-	 * it can be overwritten by subclasses.
-	 */
-	@Override
-	public void doSave(IProgressMonitor monitor) {
-		monitor = Policy.monitorFor(monitor);
-		try {
-			IEditorPart[] editors = getEmbeddedEditorsSaveOrder(embeddedEditors.getEmbeddedEditors());
-			String message = Messages.CompositeEditor_2; 
-			monitor.beginTask(message, Math.max(1, editors.length));
-			for (int i = 0; i < editors.length; i++) {
-				final IProgressMonitor subMonitor = Policy.subMonitorFor(monitor, 1);
-				final IEditorPart editor = editors[i];
-				ISafeRunnable runnable = new ISafeRunnable() {
-					public void run() throws Exception {
-						editor.doSave(subMonitor);
-					}
-					public void handleException(Throwable exception) {
-					}
-				};
-				SafeRunnable.run(runnable);				
-			}
-		} finally {
-			monitor.done();
-		}
-	}
-
-	/**
-	 * Defines the order the embedded editors should be saved.
-	 * 
-	 * @param editors the embedded editors that will be saved
-	 * @return the same editors in the order they should be saved 
-	 */
-	protected IEditorPart[] getEmbeddedEditorsSaveOrder(IEditorPart[] editors) {
-		return editors;
-	}
-
-	/**
-	 * Default implementation. It can be overwritten by subclasses.
-	 */
-	@Override
-	public void setFocus() {
-		IEditorPart active = embeddedEditors.getActiveEditor();
-		if (active != null) {
-			active.setFocus();
-		}
-	}
-
-	/**
-	 * Designate the given editor to be the main editor. 
-	 * The editor will be activated.
-	 * 
-	 * @param editor the main editor
-	 * @exception CoreException if the editor cannot be set as the main editor. Reasons include:
-	 * <ul>
-	 * <li> The editor is not connected to this composite editor.</li>
-	 * </ul>
-	 */
-	public void setMainEditor(IEditorPart editor) throws CoreException {
-		if (!embeddedEditors.contains(editor)) {
-			IStatus status = new Status(IStatus.ERROR, CommonUIPlugin.PLUGIN_ID, ICompositeEditorConstants.EDITOR_NOT_CONNECTED, Messages.CompositeEditor_3 + editor.getTitle(), null); 
-			throw new CoreException(status);
-		}
-		mainEditor = editor;
-		activateEditor(editor);
-	}
-
-	/**
-	 * Returns the main editor or null if none has been defined. 
-	 */
-	public IEditorPart getMainEditor() {
-		return mainEditor;
-	}
-
-	/**
-	 * Returns the current active editor.
-	 */
-	public IEditorPart getActiveEditor() {
-		return embeddedEditors.getActiveEditor();
-	}
-
-	@Override
-	public void init(IEditorSite site, IEditorInput input) throws PartInitException {
-		setSite(site);
-		setInput(input);
-		editorManager = new CompositeEditorManager(site);
-		getEditorSite().getPage().addPartListener(getPartlistener());
-		getEditorSite().setSelectionProvider(new CompositeEditorSelectionProvider(this));
-	}
-
-	/**
-	 * The workbench caches IActionBars according to the editor type (editor id),
-	 * so editors of the same type share the same IActionBars instance.
-	 * The CompositeEditor controls embedded editors' contributions by deactivating
-	 * the previous active embedded editor and activating the new active embedded editor.
-	 * If the actions are not deactivated they remain visible for the IActionBars.
-	 * When switching between two CompositeEditor instances of the same type (id)
-	 * the origin CompositeEditor does not know it has to deactivate its current active
-	 * embedded editor and it causes incorrect or duplicate contributions to appear.
-	 * The solution is to coordinate the current embedded editor activation and deactivation
-	 * with the CompositeEditor (IWorkbenchPart) activation and deactivation.
-	 */
-	private IPartListener getPartlistener() {
-		if (partListener == null) {
-			partListener = new IPartListener() {
-				public void partActivated(IWorkbenchPart part) {
-					if (part == CompositeEditor.this) {
-						IEditorPart lastActiveEditor = embeddedEditors.getActiveEditor();
-						if (lastActiveEditor != null) {
-							editorManager.activate(lastActiveEditor);
-						}
-					}
-				}
-
-				public void partBroughtToTop(IWorkbenchPart part) {
-				}
-
-				public void partClosed(IWorkbenchPart part) {
-				}
-
-				public void partDeactivated(IWorkbenchPart part) {
-					if (part == CompositeEditor.this) {
-						editorManager.deactivate(embeddedEditors.getActiveEditor());
-					}
-				}
-
-				public void partOpened(IWorkbenchPart part) {
-				}
-			};
-		}
-		return partListener;
-	}
-
-}
\ No newline at end of file
diff --git a/plugins/org.eclipse.bpel.common.ui/src/org/eclipse/bpel/common/ui/composite/CompositeEditorActionBars.java b/plugins/org.eclipse.bpel.common.ui/src/org/eclipse/bpel/common/ui/composite/CompositeEditorActionBars.java
deleted file mode 100644
index 2f0d0b6..0000000
--- a/plugins/org.eclipse.bpel.common.ui/src/org/eclipse/bpel/common/ui/composite/CompositeEditorActionBars.java
+++ /dev/null
@@ -1,112 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005 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 Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.bpel.common.ui.composite;
-
-import java.util.Iterator;
-import java.util.Map;
-
-import org.eclipse.jface.action.IAction;
-import org.eclipse.jface.action.IToolBarManager;
-import org.eclipse.jface.action.SubToolBarManager;
-import org.eclipse.ui.internal.EditorActionBars;
-import org.eclipse.ui.internal.WorkbenchPage;
-import org.eclipse.ui.services.IServiceLocator;
-
-/**
- * IActionBars implementation for the CompositeEditor. This class was
- * created to workaround problems we had when simply using instances of
- * SubActionBars.
- * 
- * 1) The main problem was that global actions contributed by
- * the workbench (copy, cut, paste, etc..) to the edit menu were never
- * enabled for the embedded editors. The summary is that the SubActionBars
- * for the embedded editor did not have any listeners associated to it.
- * The listeners were in the CompositeEditor action bars. These listeners
- * are responsible for updating the enablement of the menu items for global
- * action bars. The workaround is to set the global action handlers from
- * this instance to the CompositeEditor action bars (parent) upon activate
- * calls and remove them upon deactivate calls.
- * 
- * 2) The reason why we subclass EditorActionBars instead of SubActionBars
- * is that some workbench classes assume that if the part is an IEditorPart
- * than its IActionsBars is an EditorActionBars (e.g. EditorSite.getActionBarContributor()).
- */
-public class CompositeEditorActionBars extends EditorActionBars {
-
-	protected SubToolBarManager toolBarMgr;
-
-	public CompositeEditorActionBars(WorkbenchPage page, IServiceLocator serviceLocator, String type) {
-		super(page, serviceLocator, type);
-	}
-
-	/**
-	 * We are implementing this method only to avoid a ClassCastException.
-	 * This implementation is similar to the one in SubActionBars.
-	 */
-	@Override
-	public IToolBarManager getToolBarManager() {
-		if (toolBarMgr == null) {
-			// TODO: The code below does not work anymore in Eclipse 3.2M5.
-			// We cannot call this API anymore because we get an exception.
-			// See WWinActionBars.getToolBarManager()
-//			toolBarMgr = createSubToolBarManager(getParent().getToolBarManager());
-			toolBarMgr = createSubToolBarManager(null);
-			toolBarMgr.setVisible(getActive());
-		}
-		return toolBarMgr;
-	}
-
-	/**
-	 * We have to add to the parent (CompositeEditor action bars)
-	 * global action handlers contributed to this instance.
-	 */
-	@Override
-	public void activate(boolean forceVisibility) {
-		Map globalActionHandlers = getGlobalActionHandlers();
-		if (globalActionHandlers != null) {
-			for (Iterator iter = globalActionHandlers.entrySet().iterator(); iter.hasNext();) {
-				Map.Entry entry = (Map.Entry) iter.next();
-				String actionId = (String) entry.getKey();
-				IAction actionHandler = (IAction) entry.getValue();
-				getParent().setGlobalActionHandler(actionId, actionHandler);
-			}
-		}
-		super.activate(forceVisibility);
-		updateActionBars();
-	}
-
-	/**
-	 * We have to remove from the parent (CompositeEditor action bars)
-	 * global action handlers contributed to this instance.
-	 */
-	@Override
-	public void deactivate(boolean forceVisibility) {
-		Map globalActionHandlers = getGlobalActionHandlers();
-		if (globalActionHandlers != null) {
-			for (Iterator iter = globalActionHandlers.keySet().iterator(); iter.hasNext();) {
-				String actionId = (String) iter.next();
-				getParent().setGlobalActionHandler(actionId, null);
-			}
-		}
-		super.deactivate(forceVisibility);
-		updateActionBars();
-	}
-
-	/**
-	 * Same implementation as in SubActionBars. The EditorActionBars
-	 * implementation simply returns null.
-	 */
-	@Override
-	protected SubToolBarManager createSubToolBarManager(IToolBarManager parent) {
-		return new SubToolBarManager(parent);
-	}
-
-}
\ No newline at end of file
diff --git a/plugins/org.eclipse.bpel.common.ui/src/org/eclipse/bpel/common/ui/composite/CompositeEditorKeyBindingService.java b/plugins/org.eclipse.bpel.common.ui/src/org/eclipse/bpel/common/ui/composite/CompositeEditorKeyBindingService.java
deleted file mode 100644
index c5155c0..0000000
--- a/plugins/org.eclipse.bpel.common.ui/src/org/eclipse/bpel/common/ui/composite/CompositeEditorKeyBindingService.java
+++ /dev/null
@@ -1,95 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005 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 Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.bpel.common.ui.composite;
-
-import java.util.Iterator;
-import java.util.SortedMap;
-import java.util.TreeMap;
-
-import org.eclipse.jface.action.IAction;
-import org.eclipse.swt.events.KeyEvent;
-import org.eclipse.ui.IKeyBindingService;
-
-/**
- * Responsible for contributing key bindings for embedded editors.
- * 
- * TODO: look at the implementation of KeyBindingService
- * We might need to copy and modify that class for our
- * own use.
- */
-public class CompositeEditorKeyBindingService implements IKeyBindingService {
-
-	protected IKeyBindingService parent;
-	protected SortedMap commandIdToActionMap;
-
-	public CompositeEditorKeyBindingService(IKeyBindingService parent) {
-		this.parent = parent;
-		commandIdToActionMap = new TreeMap();
-	}
-
-	public void activate() {
-		for (Iterator iter = commandIdToActionMap.values().iterator(); iter.hasNext();) {
-			IAction action = (IAction) iter.next();
-			parent.registerAction(action);
-		}
-	}
-
-	public void deactivate() {
-		for (Iterator iter = commandIdToActionMap.values().iterator(); iter.hasNext();) {
-			IAction action = (IAction) iter.next();
-			parent.unregisterAction(action);
-		}
-	}
-
-	public void enable(boolean enable) {
-	}
-
-	public String getActiveAcceleratorConfigurationId() {
-		return null;
-	}
-
-	public String getActiveAcceleratorScopeId() {
-		return null;
-	}
-
-	public boolean processKey(KeyEvent event) {
-		return false;
-	}
-
-	/**
-	 * Registered actions are stored and only enabled when the embedded editor
-	 * associated with it becomes active.
-	 */
-	public void registerAction(IAction action) throws IllegalArgumentException {
-		String command = action.getActionDefinitionId();
-		if (command != null) {
-			commandIdToActionMap.put(command, action);
-		}
-	}
-
-	public void setActiveAcceleratorScopeId(String scopeId) throws IllegalArgumentException {
-	}
-
-	public void unregisterAction(IAction action) throws IllegalArgumentException {
-		String command = action.getActionDefinitionId();
-		if (command != null) {
-			commandIdToActionMap.remove(command);
-		}
-	}
-
-	public String[] getScopes() {
-		return null;
-	}
-
-	public void setScopes(String[] scopes) throws IllegalArgumentException {
-	}
-
-}
diff --git a/plugins/org.eclipse.bpel.common.ui/src/org/eclipse/bpel/common/ui/composite/CompositeEditorManager.java b/plugins/org.eclipse.bpel.common.ui/src/org/eclipse/bpel/common/ui/composite/CompositeEditorManager.java
deleted file mode 100644
index 3ff8a08..0000000
--- a/plugins/org.eclipse.bpel.common.ui/src/org/eclipse/bpel/common/ui/composite/CompositeEditorManager.java
+++ /dev/null
@@ -1,280 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005 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 Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.bpel.common.ui.composite;
-
-import java.lang.reflect.Constructor;
-import java.lang.reflect.InvocationTargetException;
-import java.lang.reflect.Method;
-import java.util.HashMap;
-import java.util.Map;
-
-import org.eclipse.bpel.common.ui.CommonUIPlugin;
-import org.eclipse.bpel.common.ui.Messages;
-import org.eclipse.bpel.common.ui.Utils;
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.core.runtime.IConfigurationElement;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.Status;
-import org.eclipse.jface.action.IMenuManager;
-import org.eclipse.osgi.util.NLS;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.layout.FillLayout;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.swt.widgets.Event;
-import org.eclipse.swt.widgets.Listener;
-import org.eclipse.ui.IEditorActionBarContributor;
-import org.eclipse.ui.IEditorInput;
-import org.eclipse.ui.IEditorPart;
-import org.eclipse.ui.IEditorReference;
-import org.eclipse.ui.IEditorSite;
-import org.eclipse.ui.internal.EditorActionBuilder;
-import org.eclipse.ui.internal.EditorSite;
-import org.eclipse.ui.internal.WorkbenchPage;
-import org.eclipse.ui.internal.registry.EditorDescriptor;
-
-
-/**
- * Handles embedded editor's contributions activation and deactivation.
- */
-public class CompositeEditorManager {
-
-	protected WorkbenchPage page;
-	protected IEditorSite mainEditorSite;
-	protected Map idToDescriptor;
-
-	private static final String EXTPT_EMBEDDED_EDITORS = "embeddedEditors"; //$NON-NLS-1$
-	private static final String CHILD_EDITOR = "editor"; //$NON-NLS-1$
-	private static final String ATT_EDITOR_ID = "id"; //$NON-NLS-1$
-	private static final String ATT_EDITOR_CLASS = "class"; //$NON-NLS-1$
-
-	public CompositeEditorManager(IEditorSite mainEditorSite) {
-		this.mainEditorSite = mainEditorSite;
-		idToDescriptor = new HashMap(10);
-		page = (WorkbenchPage) mainEditorSite.getPage();
-	}
-
-	/**
-	 * Creates and initializes an IEditorPart given its id and input. 
-	 */
-	public IEditorPart createEditor(String editorId, IEditorInput input) throws CoreException {
-		IEditorPart editor = instantiateEditor(editorId);
-		EditorSite site = createEditorSite(editorId, editor);
-		editor.init(site, input);
-
-		// Force menus to be created.
-		IMenuManager menuManager = mainEditorSite.getActionBars().getMenuManager();
-		menuManager.setVisible(false);
-		menuManager.setVisible(true);
-
-		return editor;
-	}
-
-	/**
-	 * Instantiates an editor given its id. The editor id has to be declared
-	 * through the <code>embeddedEditors</code> extension point.
-	 * 
-	 * @throws CoreException if the editorId is not found
-	 */
-	protected IEditorPart instantiateEditor(String editorId) throws CoreException {
-		EditorDescriptor descriptor = (EditorDescriptor) idToDescriptor.get(editorId);
-		if (descriptor == null) {
-			descriptor = readDescriptor(editorId);
-			if (descriptor == null) {
-				IStatus status = new Status(IStatus.ERROR, CommonUIPlugin.PLUGIN_ID, ICompositeEditorConstants.COULD_NOT_INSTANTIATE_EDITOR, NLS.bind(Messages.CompositeEditorManager_Could_not_find_editor, (new Object[] { editorId })), null); 
-				throw new CoreException(status);
-			}
-		}
-		return (IEditorPart) descriptor.getConfigurationElement().createExecutableExtension(ATT_EDITOR_CLASS);
-	}
-
-	/**
-	 * Creates an editor descriptor based on the information defined in the <code>embeddedEditors</code>
-	 * extension point for the given editorId.
-	 * 
-	 * @return the editor descriptor or <code>null</code> if there none for the given editorId  
-	 */
-	protected EditorDescriptor readDescriptor(String editorId) {
-		IConfigurationElement[] elements = Utils.getConfigurationElements(EXTPT_EMBEDDED_EDITORS);
-		for (int i = 0; i < elements.length; i++) {
-			IConfigurationElement element = elements[i];
-			if (element.getName().equals(CHILD_EDITOR)) {
-				String extensionId = element.getAttribute(ATT_EDITOR_ID);
-				if (extensionId == null) {
-					// the editor id is mandatory - log error
-					String pluginId = element.getDeclaringExtension().getNamespace();
-					IStatus status = new Status(IStatus.ERROR, pluginId, ICompositeEditorConstants.MISSING_ATTRIBUTE, Messages.CompositeEditorManager_5, null); 
-					CommonUIPlugin.getDefault().getLog().log(status);
-				} else if (editorId.equals(extensionId)) {
-					// Use reflection to create and set state on an editor descriptor
-					// This was done to avoid copying the class to this package
-					try {
-						Constructor constuctor = EditorDescriptor.class.getDeclaredConstructor(new Class[0]);
-						constuctor.setAccessible(true);
-						EditorDescriptor descriptor = (EditorDescriptor)constuctor.newInstance(new Object[0]);
-
-						Method method = descriptor.getClass().getDeclaredMethod("setID", new Class[] {String.class});
-						method.setAccessible(true);
-						method.invoke(descriptor, new Object[]{editorId});
-
-						method = descriptor.getClass().getDeclaredMethod("setConfigurationElement", new Class[] {IConfigurationElement.class});
-						method.setAccessible(true);
-						method.invoke(descriptor, new Object[]{element});
-
-						idToDescriptor.put(editorId, descriptor);
-						return descriptor;
-					} catch (SecurityException e) {
-						CommonUIPlugin.getDefault().createErrorStatus("Problem creating descriptor for " + editorId, e, true);
-					} catch (IllegalArgumentException e) {
-						CommonUIPlugin.getDefault().createErrorStatus("Problem creating descriptor for " + editorId, e, true);
-					} catch (NoSuchMethodException e) {
-						CommonUIPlugin.getDefault().createErrorStatus("Problem creating descriptor for " + editorId, e, true);
-					} catch (InstantiationException e) {
-						CommonUIPlugin.getDefault().createErrorStatus("Problem creating descriptor for " + editorId, e, true);
-					} catch (IllegalAccessException e) {
-						CommonUIPlugin.getDefault().createErrorStatus("Problem creating descriptor for " + editorId, e, true);
-					} catch (InvocationTargetException e) {
-						CommonUIPlugin.getDefault().createErrorStatus("Problem creating descriptor for " + editorId, e, true);
-					}
-				}
-			}
-		}
-		return null;
-	}
-
-	/**
-	 * Creates and populates an editor site for the given editor.
-	 */
-	protected EditorSite createEditorSite(String editorId, IEditorPart editor) {
-		EditorDescriptor descriptor = (EditorDescriptor) idToDescriptor.get(editorId);
-		IEditorReference ref = new EditorReference();
-		EditorSite site = new CompositeEditorSite(mainEditorSite, ref, editor, page, descriptor);
-		IEditorActionBarContributor contributor = descriptor.createActionBarContributor();
-		site.setActionBars(createEditorActionBars(descriptor, contributor, site));
-		return site;
-	}
-
-	/**
-	 * Creates the action bars for the given editor. It also searches for editor
-	 * contribution extensions.
-	 */
-	protected CompositeEditorActionBars createEditorActionBars(EditorDescriptor descriptor, IEditorActionBarContributor contributor, EditorSite site) {
-		String type = String.valueOf(System.currentTimeMillis());
-//		IActionBars2 parentActionBars = (IActionBars2) mainEditorSite.getActionBars();
-		CompositeEditorActionBars actionBars = new CompositeEditorActionBars(page, site, type);
-		if (contributor != null) {
-			actionBars.setEditorContributor(contributor);
-			contributor.init(actionBars, page);
-		}
-
-		// Read action extensions.
-		EditorActionBuilder builder = new EditorActionBuilder();
-		IEditorActionBarContributor extension = builder.readActionExtensions(descriptor /*WDG , actionBars */);
-		if (extension != null) {
-			actionBars.setExtensionContributor(extension);
-			extension.init(actionBars, page);
-		}
-
-		return actionBars;
-	}
-
-	/**
-	 * Activate contributions.
-	 */
-	public void activate(IEditorPart editor) {
-		editor.setFocus();
-		IEditorSite site = editor.getEditorSite();
-		CompositeEditorActionBars actionBars = (CompositeEditorActionBars) site.getActionBars();
-		actionBars.partChanged(editor);
-		actionBars.activate(true);
-		((CompositeEditorSite) site).activate();
-	}
-
-	/**
-	 * Deactivate contributions.
-	 */
-	public void deactivate(IEditorPart editor) {
-		if (editor != null) {
-			CompositeEditorActionBars actionBars = (CompositeEditorActionBars) editor.getEditorSite().getActionBars();
-			actionBars.deactivate(true);
-			IEditorSite site = editor.getEditorSite();
-			((CompositeEditorSite) site).deactivate();
-		}
-	}
-
-	/**
-	 * Creates an embedded editor corresponding to the given editorId.
-	 * <p>
-	 * It is important to notice that the returned editor will never be
-	 * the workbench active part.
-	 * <p>
-	 * @param editorId the embedded editor id
-	 * @param editorComposite the editor's parent composite
-	 * @return IEditorPart the embedded editor instance
-	 * 
-	 */
-	public IEditorPart createEditor(String editorId, IEditorInput input, Composite editorComposite) throws CoreException {
-		final IEditorPart editor = createEditor(editorId, input);
-
-		Composite composite = new Composite(editorComposite, SWT.NONE);
-		composite.setLayout(new FillLayout());
-		editor.createPartControl(composite);
-
-		// This is the fundamental part of our implementation.
-		// Editors are activated when we get an Activate
-		// event from the editor's composite.
-		associate(editor, composite);
-
-		return editor;
-	}
-
-	/**
-	 * Associates the control with the given editor. When the control
-	 * is activated all the editor contributions will be activated
-	 * as well. This is useful when the CompositeEditor is not only
-	 * composed by embedded editor but also by other controls. If no editor
-	 * is associated with these controls the available contributions
-	 * (menus, toolbars, status line, etc...) will be the contributions
-	 * for the last active editor and might cause confusion to the user. 
-	 */
-	protected void associate(final IEditorPart editor, Control control) {
-		control.addListener(SWT.Activate, new Listener() {
-			public void handleEvent(Event event) {
-				activate(editor);
-			}
-		});
-		control.addListener(SWT.Deactivate, new Listener() {
-			public void handleEvent(Event event) {
-				deactivate(editor);
-			}
-		});
-	}
-
-	/**
-	 * Removes the given editor from this composite editor. If the given
-	 * editor is the current active editor the main editor will be activated
-	 * instead. The main editor cannot be disconnected by calling this
-	 * method.
-	 * 
-	 * @exception CoreException if the editor cannot be disconnected. Reasons include:
-	 * <ul>
-	 * <li> The editor is the main editor.</li>
-	 * <li> The editor is the current active editor and the main editor was not defined.</li>
-	 * </ul>
-	 */
-	public void disposeEditor(IEditorPart editor) {
-		CompositeEditorSite site = (CompositeEditorSite) editor.getSite();
-		CompositeEditorActionBars actionBars = (CompositeEditorActionBars) site.getActionBars();
-		actionBars.dispose();
-		site.dispose();
-		editor.dispose();
-	}
-}
\ No newline at end of file
diff --git a/plugins/org.eclipse.bpel.common.ui/src/org/eclipse/bpel/common/ui/composite/CompositeEditorSelectionProvider.java b/plugins/org.eclipse.bpel.common.ui/src/org/eclipse/bpel/common/ui/composite/CompositeEditorSelectionProvider.java
deleted file mode 100644
index 73a8023..0000000
--- a/plugins/org.eclipse.bpel.common.ui/src/org/eclipse/bpel/common/ui/composite/CompositeEditorSelectionProvider.java
+++ /dev/null
@@ -1,107 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005 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 Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.bpel.common.ui.composite;
-
-import org.eclipse.ui.IEditorPart;
-import org.eclipse.core.runtime.Assert;
-import org.eclipse.jface.util.ListenerList;
-import org.eclipse.jface.util.SafeRunnable;
-import org.eclipse.jface.viewers.*;
-
-public class CompositeEditorSelectionProvider implements ISelectionProvider {
-
-	/**
-	 * Registered selection changed listeners (element type: 
-	 * <code>ISelectionChangedListener</code>).
-	 */
-	private ListenerList listeners = new ListenerList();
-
-	/**
-	 * The composite editor.
-	 */
-	private CompositeEditor compositeEditor;
-
-/**
- * Creates a selection provider for the given composite editor.
- *
- * @param compositeEditor the composite editor
- */
-public CompositeEditorSelectionProvider(CompositeEditor compositeEditor) {
-	Assert.isNotNull(compositeEditor);
-	this.compositeEditor = compositeEditor;
-}
-
-/* (non-Javadoc)
- * Method declared on <code>ISelectionProvider</code>.
- */
-public void addSelectionChangedListener(ISelectionChangedListener listener) {
-	listeners.add(listener);
-}
-
-/**
- * Notifies all registered selection changed listeners that the editor's 
- * selection has changed. Only listeners registered at the time this method is
- * called are notified.
- *
- * @param event the selection changed event
- */
-public void fireSelectionChanged(final SelectionChangedEvent event) {
-	Object[] listeners = this.listeners.getListeners();
-	for (int i = 0; i < listeners.length; ++i) {
-		final ISelectionChangedListener l = (ISelectionChangedListener)listeners[i];
-		
-		SafeRunnable.run(new SafeRunnable() {
-			public void run() {
-				l.selectionChanged(event);
-			}
-			@Override
-			public void handleException(Throwable e) {
-				super.handleException(e);
-				//If an unexpected exception happens, remove it
-				//to make sure the workbench keeps running.
-				removeSelectionChangedListener(l);
-			}
-		});		
-	}
-}
-
-/* (non-Javadoc)
- * Method declared on <code>ISelectionProvider</code>.
- */
-public ISelection getSelection() {
-	IEditorPart activeEditor = compositeEditor.getActiveEditor();
-	if (activeEditor != null) {
-		ISelectionProvider selectionProvider = activeEditor.getSite().getSelectionProvider();
-		if (selectionProvider != null)
-			return selectionProvider.getSelection();
-	}
-	return null;
-}
-
-/* (non-JavaDoc)
- * Method declaed on <code>ISelectionProvider</code>.
- */
-public void removeSelectionChangedListener(ISelectionChangedListener listener) {
-	listeners.remove(listener);
-}
-
-/* (non-Javadoc)
- * Method declared on <code>ISelectionProvider</code>.
- */
-public void setSelection(ISelection selection) {
-	IEditorPart activeEditor = compositeEditor.getActiveEditor();
-	if (activeEditor != null) {
-		ISelectionProvider selectionProvider = activeEditor.getSite().getSelectionProvider();
-		if (selectionProvider != null)
-			selectionProvider.setSelection(selection);
-	}
-}
-}
diff --git a/plugins/org.eclipse.bpel.common.ui/src/org/eclipse/bpel/common/ui/composite/CompositeEditorSite.java b/plugins/org.eclipse.bpel.common.ui/src/org/eclipse/bpel/common/ui/composite/CompositeEditorSite.java
deleted file mode 100644
index 496418f..0000000
--- a/plugins/org.eclipse.bpel.common.ui/src/org/eclipse/bpel/common/ui/composite/CompositeEditorSite.java
+++ /dev/null
@@ -1,139 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005 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 Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.bpel.common.ui.composite;
-
-import org.eclipse.jface.viewers.ISelectionChangedListener;
-import org.eclipse.jface.viewers.ISelectionProvider;
-import org.eclipse.jface.viewers.SelectionChangedEvent;
-import org.eclipse.ui.IEditorPart;
-import org.eclipse.ui.IEditorReference;
-import org.eclipse.ui.IEditorSite;
-import org.eclipse.ui.IKeyBindingService;
-import org.eclipse.ui.internal.EditorSite;
-import org.eclipse.ui.internal.WorkbenchPage;
-import org.eclipse.ui.internal.registry.EditorDescriptor;
-
-/**
- * TODO: do we really want/need to extend EditorSite or do
- * we want to implement our own like the MultiPageEditor does?
- */
-public class CompositeEditorSite extends EditorSite {
-
-	protected IEditorSite parent;
-	protected CompositeEditorKeyBindingService keyBindingService;
-	private ISelectionProvider selectionProvider;
-	private ISelectionChangedListener selectionChangedListener;
-
-	public CompositeEditorSite(IEditorSite parent, IEditorReference ref, IEditorPart editor, WorkbenchPage page, EditorDescriptor desc) {
-		super(ref, editor, page, desc);
-		this.parent = parent;
-	}
-
-	/**
-	 * Returns a CompositeEditorKeybinding for an embedded editor.
-	 */
-	@Override
-	public IKeyBindingService getKeyBindingService() {
-		if (keyBindingService == null) {
-			keyBindingService = new CompositeEditorKeyBindingService(parent.getKeyBindingService());
-		}
-		return keyBindingService;
-	}
-
-	/**
-	 * Activate the key bindings for an embedded editor.
-	 */
-	public void activate() {
-		if (keyBindingService == null) {
-			return;
-		}
-		keyBindingService.activate();
-		// The workbench only calls updateActiveKeyBindingService() when a workbench part
-		// becomes active. We have to explicitly call it since for the
-		// workbench the active part has not changed. 
-
-		// TODO: find an alternative in Eclipse 3.0 for the following call:
-//		 ((Workbench) getWorkbenchWindow().getWorkbench()).updateActiveKeyBindingService();
-	}
-
-	/**
-	 * Deactivate the key bindings for an embedded editor.
-	 */
-	public void deactivate() {
-		if (keyBindingService == null) {
-			return;
-		}
-		keyBindingService.deactivate();
-	}
-
-	/**
-	 * The <code>CompositeEditorSite</code> implementation of this
-	 * <code>IWorkbenchPartSite</code> method remembers the selection provider, 
-	 * and also hooks a listener on it, which calls <code>handleSelectionChanged</code> 
-	 * when a selection changed event occurs.
-	 *
-	 * @see #handleSelectionChanged
-	 */
-	@Override
-	public void setSelectionProvider(ISelectionProvider provider) {
-		ISelectionProvider oldSelectionProvider = selectionProvider;
-		selectionProvider = provider;
-		if (oldSelectionProvider != null) {
-			oldSelectionProvider.removeSelectionChangedListener(getSelectionChangedListener());
-		}
-		if (selectionProvider != null) {
-			selectionProvider.addSelectionChangedListener(getSelectionChangedListener());
-		}
-	}
-
-	/**
-	 * Returns the selection changed listener which listens to the embedded editor's selection
-	 * changes, and calls <code>handleSelectionChanged</code>.
-	 *
-	 * @return the selection changed listener
-	 */
-	private ISelectionChangedListener getSelectionChangedListener() {
-		if (selectionChangedListener == null) {
-			selectionChangedListener = new ISelectionChangedListener() {
-				public void selectionChanged(SelectionChangedEvent event) {
-					CompositeEditorSite.this.handleSelectionChanged(event);
-				}
-			};
-		}
-		return selectionChangedListener;
-	}
-
-	/**
-	 * Handles a selection changed event from the embedded editor.
-	 * The default implementation gets the selection provider from the
-	 * composite editor's site, and calls <code>fireSelectionChanged</code>
-	 * on it (only if it is an instance of <code>CompositeEditorSelectionProvider</code>),
-	 * passing a new event object.
-	 * <p>
-	 * Subclasses may extend or reimplement this method.
-	 * </p>
-	 *
-	 * @param event the event
-	 */
-	protected void handleSelectionChanged(SelectionChangedEvent event) {
-		ISelectionProvider parentProvider = parent.getSelectionProvider();
-		if (parentProvider instanceof CompositeEditorSelectionProvider) {
-			SelectionChangedEvent newEvent = new SelectionChangedEvent(parentProvider, event.getSelection());
-			((CompositeEditorSelectionProvider) parentProvider).fireSelectionChanged(newEvent);
-		}
-	}
-
-	@Override
-	public ISelectionProvider getSelectionProvider() {
-		return selectionProvider;
-	}
-
-}
diff --git a/plugins/org.eclipse.bpel.common.ui/src/org/eclipse/bpel/common/ui/composite/EditorInViewManager.java b/plugins/org.eclipse.bpel.common.ui/src/org/eclipse/bpel/common/ui/composite/EditorInViewManager.java
deleted file mode 100644
index f95ee01..0000000
--- a/plugins/org.eclipse.bpel.common.ui/src/org/eclipse/bpel/common/ui/composite/EditorInViewManager.java
+++ /dev/null
@@ -1,374 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005 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 Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.bpel.common.ui.composite;
-
-import java.lang.reflect.Constructor;
-import java.lang.reflect.Field;
-import java.lang.reflect.InvocationTargetException;
-import java.lang.reflect.Method;
-import java.util.HashMap;
-import java.util.Map;
-
-import org.eclipse.bpel.common.ui.CommonUIPlugin;
-import org.eclipse.bpel.common.ui.Messages;
-import org.eclipse.bpel.common.ui.Utils;
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.core.runtime.IConfigurationElement;
-import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.Status;
-import org.eclipse.jface.action.CoolBarManager;
-import org.eclipse.jface.action.IAction;
-import org.eclipse.jface.action.ICoolBarManager;
-import org.eclipse.jface.action.IMenuManager;
-import org.eclipse.jface.action.IStatusLineManager;
-import org.eclipse.jface.action.IToolBarManager;
-import org.eclipse.osgi.util.NLS;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.layout.FillLayout;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.swt.widgets.Event;
-import org.eclipse.swt.widgets.Listener;
-import org.eclipse.ui.IActionBars;
-import org.eclipse.ui.IActionBars2;
-import org.eclipse.ui.IEditorActionBarContributor;
-import org.eclipse.ui.IEditorInput;
-import org.eclipse.ui.IEditorPart;
-import org.eclipse.ui.IEditorReference;
-import org.eclipse.ui.IEditorSite;
-import org.eclipse.ui.IViewSite;
-import org.eclipse.ui.internal.EditorActionBuilder;
-import org.eclipse.ui.internal.EditorManager;
-import org.eclipse.ui.internal.EditorReference;
-import org.eclipse.ui.internal.EditorSite;
-import org.eclipse.ui.internal.WorkbenchPage;
-import org.eclipse.ui.internal.registry.EditorDescriptor;
-import org.eclipse.ui.services.IServiceLocator;
-
-
-/**
- * Handles embedded editor's contributions activation and deactivation.
- */
-public class EditorInViewManager {
-
-	protected WorkbenchPage page;
-	protected IViewSite fViewSite;
-	protected Map<String,EditorDescriptor> idToDescriptor;
-	protected EditorManager eclipseEditorManager;
-
-	private static final String EXTPT_EMBEDDED_EDITORS = "embeddedEditors"; //$NON-NLS-1$
-	private static final String CHILD_EDITOR = "editor"; //$NON-NLS-1$
-	private static final String ATT_EDITOR_ID = "id"; //$NON-NLS-1$
-	private static final String ATT_EDITOR_CLASS = "class"; //$NON-NLS-1$
-	
-	/**
-	 * Brand new EditorInView manager.
-	 * 
-	 * @param viewSite
-	 */
-	
-	public EditorInViewManager (IViewSite viewSite) {
-		this.fViewSite = viewSite;
-		idToDescriptor = new HashMap<String,EditorDescriptor>(10);
-		page = (WorkbenchPage) viewSite.getPage();
-	}
-
-	/**
-	 * Creates and initializes an IEditorPart given its id and input. 
-	 * @param editorId 
-	 * @param input 
-	 * @return the editor part.
-	 * @throws CoreException 
-	 */
-	public IEditorPart createEditor(String editorId, IEditorInput input) throws CoreException {
-		IEditorPart editor = instantiateEditor(editorId);
-		EditorSite site = createEditorSite(editorId, input, editor);
-		editor.init(site, input);
-
-		// Force menus to be created.
-		// TODO: The following lines do not seem to be necessary anymore.
-		// Keep them at least until Eclipse 3.0 is released so that if we
-		// face the same problem again we can workaround it.
-//		IMenuManager menuManager = site.getActionBars().getMenuManager();
-//		menuManager.setVisible(false);
-//		menuManager.setVisible(true);
-
-		return editor;
-	}
-
-	/**
-	 * Instantiates an editor given its id. The editor id has to be declared
-	 * through the <code>embeddedEditors</code> extension point.
-	 * 
-	 * @throws CoreException if the editorId is not found
-	 */
-	protected IEditorPart instantiateEditor (String editorId) throws CoreException {
-		EditorDescriptor descriptor = idToDescriptor.get(editorId);
-		if (descriptor == null) {
-			descriptor = readDescriptor(editorId);
-			if (descriptor == null) {
-				IStatus status = new Status(IStatus.ERROR, CommonUIPlugin.PLUGIN_ID, ICompositeEditorConstants.COULD_NOT_INSTANTIATE_EDITOR, NLS.bind(Messages.CompositeEditorManager_Could_not_find_editor, (new Object[] { editorId })), null); 
-				throw new CoreException(status);
-			}
-		}
-		return (IEditorPart) descriptor.getConfigurationElement().createExecutableExtension(ATT_EDITOR_CLASS);
-	}
-
-	/**
-	 * Creates an editor descriptor based on the information defined in the <code>embeddedEditors</code>
-	 * extension point for the given editorId.
-	 * 
-	 * @return the editor descriptor or <code>null</code> if there none for the given editorId  
-	 */
-	protected EditorDescriptor readDescriptor (String editorId) {
-		
-		for(IConfigurationElement element : Utils.getConfigurationElements(EXTPT_EMBEDDED_EDITORS)) {
-			if (CHILD_EDITOR.equals(element.getName()) == false) {
-				continue;
-			}
-			String extensionId = element.getAttribute(ATT_EDITOR_ID);
-			if (extensionId == null) {
-				// the editor id is mandatory - log error
-				String pluginId = element.getDeclaringExtension().getNamespace();
-				IStatus status = new Status(IStatus.ERROR, pluginId, ICompositeEditorConstants.MISSING_ATTRIBUTE, Messages.CompositeEditorManager_5, null); 
-				CommonUIPlugin.getDefault().getLog().log(status);
-				continue;
-			}
-			
-			if (editorId.equals(extensionId)) {
-				// Use reflection to create and set state on an editor descriptor
-				// This was done to avoid copying the class to this package
-				try {
-					Constructor constuctor = EditorDescriptor.class.getDeclaredConstructor(new Class[0]);
-					constuctor.setAccessible(true);
-					EditorDescriptor descriptor = (EditorDescriptor)constuctor.newInstance(new Object[0]);
-
-					Method method = descriptor.getClass().getDeclaredMethod("setID", new Class[] {String.class});
-					method.setAccessible(true);
-					method.invoke(descriptor, new Object[]{editorId});
-
-					method = descriptor.getClass().getDeclaredMethod("setConfigurationElement", new Class[] {IConfigurationElement.class});
-					method.setAccessible(true);
-					method.invoke(descriptor, new Object[]{element});
-
-					method = descriptor.getClass().getDeclaredMethod("setName", new Class[] {String.class});
-					method.setAccessible(true);
-					method.invoke(descriptor, new Object[]{editorId});
-
-					idToDescriptor.put(editorId, descriptor);
-					
-					return descriptor;
-					
-				} catch (SecurityException e) {
-					CommonUIPlugin.getDefault().createErrorStatus("Problem creating descriptor for " + editorId, e, true);
-				} catch (IllegalArgumentException e) {
-					CommonUIPlugin.getDefault().createErrorStatus("Problem creating descriptor for " + editorId, e, true);
-				} catch (NoSuchMethodException e) {
-					CommonUIPlugin.getDefault().createErrorStatus("Problem creating descriptor for " + editorId, e, true);
-				} catch (InstantiationException e) {
-					CommonUIPlugin.getDefault().createErrorStatus("Problem creating descriptor for " + editorId, e, true);
-				} catch (IllegalAccessException e) {
-					CommonUIPlugin.getDefault().createErrorStatus("Problem creating descriptor for " + editorId, e, true);
-				} catch (InvocationTargetException e) {
-					CommonUIPlugin.getDefault().createErrorStatus("Problem creating descriptor for " + editorId, e, true);
-				}
-			}
-		}
-		return null;
-	}
-
-	/**
-	 * Creates and populates an editor site for the given editor.
-	 */
-	protected EditorSite createEditorSite(String editorId, IEditorInput input, IEditorPart editor) {
-		EditorDescriptor descriptor = idToDescriptor.get(editorId);
-		IEditorReference ref = new EditorReference(getEditorManager(), input, descriptor);
-		EditorSite site = new EditorInViewSite(fViewSite, ref, editor, page, descriptor);
-		
-		IEditorActionBarContributor contributor = descriptor.createActionBarContributor();
-		site.setActionBars(createEditorActionBars(descriptor, contributor, site));
-		return site;
-	}
-
-	/**
-	 * Creates the action bars for the given editor. It also searches for editor
-	 * contribution extensions.
-	 */
-	protected CompositeEditorActionBars createEditorActionBars(EditorDescriptor descriptor, IEditorActionBarContributor contributor, EditorSite site) {
-		String type = String.valueOf(System.currentTimeMillis());
-//		IActionBars viewActionBars = viewSite.getActionBars();
-//		IActionBars2 parentActionBars = getIActionBars2Wrapper(viewActionBars);
-		CompositeEditorActionBars actionBars = new CompositeEditorActionBars(page, site, type);
-		if (contributor != null) {
-			actionBars.setEditorContributor(contributor);
-			contributor.init(actionBars, page);
-		}
-
-		// Read action extensions.
-		EditorActionBuilder builder = new EditorActionBuilder();
-		IEditorActionBarContributor extension = builder.readActionExtensions(descriptor /*WDG , actionBars*/);
-		if (extension != null) {
-			actionBars.setExtensionContributor(extension);
-			extension.init(actionBars, page);
-		}
-
-		return actionBars;
-	}
-	
-	/**
-	 * Creates an IActionBars2 as a wrapper of an IActionBars.
-	 */
-	protected IActionBars2 getIActionBars2Wrapper(final IActionBars actionBars) {
-		return new IActionBars2() {
-			public ICoolBarManager getCoolBarManager() {
-				return new CoolBarManager();
-			}
-			public void clearGlobalActionHandlers() {
-				actionBars.clearGlobalActionHandlers();
-			}
-			public IAction getGlobalActionHandler(String actionId) {
-				return actionBars.getGlobalActionHandler(actionId);
-			}
-			public IMenuManager getMenuManager() {
-				// Returns the page menu manager so that the editor
-				// can contribute to any menu (Edit, Navigate, etc...).
-				return page.getActionBars().getMenuManager();
-			}
-			public IStatusLineManager getStatusLineManager() {
-				return actionBars.getStatusLineManager();
-			}
-			public IToolBarManager getToolBarManager() {
-				return actionBars.getToolBarManager();
-			}
-			public void setGlobalActionHandler(String actionId, IAction handler) {
-				actionBars.setGlobalActionHandler(actionId, handler);
-			}
-			public void updateActionBars() {
-				actionBars.updateActionBars();
-			}
-			public IServiceLocator getServiceLocator() {
-				return actionBars.getServiceLocator();
-			}
-		};
-	}
-
-	/**
-	 * Activate contributions.
-	 * @param editor 
-	 */
-	public void activate(IEditorPart editor) {
-		editor.setFocus();
-		IEditorSite site = editor.getEditorSite();
-		CompositeEditorActionBars actionBars = (CompositeEditorActionBars) site.getActionBars();
-		actionBars.partChanged(editor);
-		actionBars.activate(true);
-		((EditorInViewSite) site).activate();
-	}
-
-	/**
-	 * Deactivate contributions.
-	 * @param editor 
-	 */
-	public void deactivate(IEditorPart editor) {
-		if (editor != null) {
-			CompositeEditorActionBars actionBars = (CompositeEditorActionBars) editor.getEditorSite().getActionBars();
-			actionBars.deactivate(true);
-			IEditorSite site = editor.getEditorSite();
-			((EditorInViewSite) site).deactivate();
-		}
-	}
-
-	/**
-	 * Creates an embedded editor corresponding to the given editorId.
-	 * <p>
-	 * It is important to notice that the returned editor will never be
-	 * the workbench active part.
-	 * <p>
-	 * @param editorId the embedded editor id
-	 * @param editorComposite the editor's parent composite
-	 * @return IEditorPart the embedded editor instance
-	 * 
-	 */
-	public IEditorPart createEditor(String editorId, IEditorInput input, Composite editorComposite) throws CoreException {
-		final IEditorPart editor = createEditor(editorId, input);
-
-		Composite composite = new Composite(editorComposite, SWT.NONE);
-		composite.setLayout(new FillLayout());
-		editor.createPartControl(composite);
-
-		// This is the fundamental part of our implementation.
-		// Editors are activated when we get an Activate
-		// event from the editor's composite.
-		associate(editor, composite);
-
-		return editor;
-	}
-
-	/**
-	 * Associates the control with the given editor. When the control
-	 * is activated all the editor contributions will be activated
-	 * as well. This is useful when the CompositeEditor is not only
-	 * composed by embedded editor but also by other controls. If no editor
-	 * is associated with these controls the available contributions
-	 * (menus, toolbars, status line, etc...) will be the contributions
-	 * for the last active editor and might cause confusion to the user. 
-	 */
-	protected void associate(final IEditorPart editor, Control control) {
-		control.addListener(SWT.Activate, new Listener() {
-			public void handleEvent(Event event) {
-				activate(editor);
-			}
-		});
-		control.addListener(SWT.Deactivate, new Listener() {
-			public void handleEvent(Event event) {
-				deactivate(editor);
-			}
-		});
-	}
-
-	/**
-	 * Removes the given editor from this composite editor. If the given
-	 * editor is the current active editor the main editor will be activated
-	 * instead. The main editor cannot be disconnected by calling this
-	 * method.
-	 * 
-	 * @param editor   
-	 */
-	
-	public void disposeEditor(IEditorPart editor) {
-		EditorInViewSite site = (EditorInViewSite) editor.getSite();
-		CompositeEditorActionBars actionBars = (CompositeEditorActionBars) site.getActionBars();
-		actionBars.dispose();		
-		site.dispose();
-		try {
-			editor.dispose();
-		} catch (Throwable t) {
-			System.out.println("disposeEditor: " + editor);
-		}
-	}
-
-	/**
-	 * TODO: remove this internal access
-	 */
-	public EditorManager getEditorManager() {
-		if (eclipseEditorManager == null) {
-			try {
-				Field field = WorkbenchPage.class.getDeclaredField("editorMgr"); //$NON-NLS-1$
-				field.setAccessible(true);
-				eclipseEditorManager = (EditorManager) field.get(page); 
-			} catch (Exception e) {
-				CommonUIPlugin.log(e);
-			}
-		}
-		return eclipseEditorManager;
-	}
-	
-}
\ No newline at end of file
diff --git a/plugins/org.eclipse.bpel.common.ui/src/org/eclipse/bpel/common/ui/composite/EditorInViewSite.java b/plugins/org.eclipse.bpel.common.ui/src/org/eclipse/bpel/common/ui/composite/EditorInViewSite.java
deleted file mode 100644
index 45d27c8..0000000
--- a/plugins/org.eclipse.bpel.common.ui/src/org/eclipse/bpel/common/ui/composite/EditorInViewSite.java
+++ /dev/null
@@ -1,166 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005 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 Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.bpel.common.ui.composite;
-
-import org.eclipse.jface.viewers.ISelectionChangedListener;
-import org.eclipse.jface.viewers.ISelectionProvider;
-import org.eclipse.jface.viewers.SelectionChangedEvent;
-import org.eclipse.ui.IEditorPart;
-import org.eclipse.ui.IEditorReference;
-import org.eclipse.ui.IKeyBindingService;
-import org.eclipse.ui.INestableKeyBindingService;
-import org.eclipse.ui.IViewSite;
-import org.eclipse.ui.internal.EditorSite;
-import org.eclipse.ui.internal.WorkbenchPage;
-import org.eclipse.ui.internal.registry.EditorDescriptor;
-
-/**
- * TODO: do we really want/need to extend EditorSite or do
- * we want to implement our own like the MultiPageEditor does?
- */
-public class EditorInViewSite extends EditorSite {
-
-	protected IViewSite parent;
-	protected IKeyBindingService keyBindingService;
-	private ISelectionProvider selectionProvider;
-	private ISelectionChangedListener selectionChangedListener;
-
-	public EditorInViewSite(IViewSite parent, IEditorReference ref, IEditorPart editor, WorkbenchPage page, EditorDescriptor desc) {
-		super(ref, editor, page, desc);
-		this.parent = parent;
-	}
-
-	/**
-	 * Returns a CompositeEditorKeybinding for an embedded editor.
-	 */
-	@Override
-	public IKeyBindingService getKeyBindingService() {
-		if (keyBindingService == null) {
-			INestableKeyBindingService service = (INestableKeyBindingService) parent.getKeyBindingService();
-			keyBindingService = service.getKeyBindingService(this);
-		}
-		return keyBindingService;
-	}
-
-	/**
-	 * Activate the key bindings for an embedded editor.
-	 */
-	public void activate() {
-		if (keyBindingService == null) {
-			return;
-		}
-		INestableKeyBindingService service = (INestableKeyBindingService) parent.getKeyBindingService();
-		service.activateKeyBindingService(this);
-		
-		// The workbench only calls updateActiveKeyBindingService() when a workbench part
-		// becomes active. We have to explicitly call it since for the
-		// workbench the active part has not changed. 
-		// TODO: find an alternative in Eclipse 3.0 for the following call:
-//		 ((Workbench) getWorkbenchWindow().getWorkbench()).updateActiveKeyBindingService();
-		// TODO: I've tried the following lines but they seem to be unnecessary since the key bindings are working.
-//		IWorkbench workbench = getWorkbenchWindow().getWorkbench();
-//      WorkbenchCommandSupport support = (WorkbenchCommandSupport) workbench.getCommandSupport();
-//      support.processHandlerSubmissions(true, workbench.getDisplay().getActiveShell());
-	}
-
-	/**
-	 * Deactivate the key bindings for an embedded editor.
-	 */
-	public void deactivate() {
-		if (keyBindingService == null) {
-			return;
-		}
-		INestableKeyBindingService service = (INestableKeyBindingService) parent.getKeyBindingService();
-		service.activateKeyBindingService(null);
-	}
-
-	/**
-	 * The <code>CompositeEditorSite</code> implementation of this
-	 * <code>IWorkbenchPartSite</code> method remembers the selection provider, 
-	 * and also hooks a listener on it, which calls <code>handleSelectionChanged</code> 
-	 * when a selection changed event occurs.
-	 *
-	 * @see #handleSelectionChanged
-	 */
-	@Override
-	public void setSelectionProvider(ISelectionProvider provider) {
-		ISelectionProvider oldSelectionProvider = selectionProvider;
-		selectionProvider = provider;
-		if (oldSelectionProvider != null) {
-			oldSelectionProvider.removeSelectionChangedListener(getSelectionChangedListener());
-		}
-		if (selectionProvider != null) {
-			selectionProvider.addSelectionChangedListener(getSelectionChangedListener());
-		}
-	}
-
-	/**
-	 * Returns the selection changed listener which listens to the embedded editor's selection
-	 * changes, and calls <code>handleSelectionChanged</code>.
-	 *
-	 * @return the selection changed listener
-	 */
-	private ISelectionChangedListener getSelectionChangedListener() {
-		if (selectionChangedListener == null) {
-			selectionChangedListener = new ISelectionChangedListener() {
-				public void selectionChanged(SelectionChangedEvent event) {
-					EditorInViewSite.this.handleSelectionChanged(event);
-				}
-			};
-		}
-		return selectionChangedListener;
-	}
-
-	/**
-	 * Handles a selection changed event from the embedded editor.
-	 * The default implementation gets the selection provider from the
-	 * composite editor's site, and calls <code>fireSelectionChanged</code>
-	 * on it (only if it is an instance of <code>CompositeEditorSelectionProvider</code>),
-	 * passing a new event object.
-	 * <p>
-	 * Subclasses may extend or reimplement this method.
-	 * </p>
-	 *
-	 * @param event the event
-	 */
-	protected void handleSelectionChanged(SelectionChangedEvent event) {
-		ISelectionProvider parentProvider = parent.getSelectionProvider();
-		if (parentProvider instanceof CompositeEditorSelectionProvider) {
-			SelectionChangedEvent newEvent = new SelectionChangedEvent(parentProvider, event.getSelection());
-			((CompositeEditorSelectionProvider) parentProvider).fireSelectionChanged(newEvent);
-		}
-	}
-
-	@Override
-	public ISelectionProvider getSelectionProvider() {
-		return selectionProvider;
-	}
-
-	/**
-	 * @return Returns the parent.
-	 */
-	public IViewSite getParent() {
-		return parent;
-	}
-	
-	/* (non-Javadoc)
-	 * @see org.eclipse.ui.internal.PartSite#dispose()
-	 */
-	@Override
-	public void dispose() {
-	   deactivate();
-	   super.dispose();
-	        
-	   setSelectionProvider(null);
-	   super.setSelectionProvider(null);
-       setPart(null);
-	}
-}
diff --git a/plugins/org.eclipse.bpel.common.ui/src/org/eclipse/bpel/common/ui/composite/EditorReference.java b/plugins/org.eclipse.bpel.common.ui/src/org/eclipse/bpel/common/ui/composite/EditorReference.java
deleted file mode 100644
index 7f1c367..0000000
--- a/plugins/org.eclipse.bpel.common.ui/src/org/eclipse/bpel/common/ui/composite/EditorReference.java
+++ /dev/null
@@ -1,97 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005 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 Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.bpel.common.ui.composite;
-
-import org.eclipse.jface.util.IPropertyChangeListener;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.ui.IEditorInput;
-import org.eclipse.ui.IEditorPart;
-import org.eclipse.ui.IEditorReference;
-import org.eclipse.ui.IPropertyListener;
-import org.eclipse.ui.IWorkbenchPage;
-import org.eclipse.ui.IWorkbenchPart;
-import org.eclipse.ui.PartInitException;
-
-/**
- * Workaround for instantiating an EditorPart. 
- */
-/* package */ class EditorReference implements IEditorReference {
-	public String getFactoryId() {
-		return null;
-	}
-	public String getName() {
-		return null;
-	}
-	public IEditorPart getEditor(boolean restore) {
-		return null;
-	}
-	public boolean isPinned() {
-		return false;
-	}
-	public IWorkbenchPart getPart(boolean restore) {
-		return null;
-	}
-	public IWorkbenchPage getPage() {
-		return null;
-	}
-	public boolean isDirty() {
-		return false;
-	}
-	public String getTitle() {
-		return null;
-	}
-	public Image getTitleImage() {
-		return null;
-	}
-	public String getTitleToolTip() {
-		return null;
-	}
-	public String getId() {
-		return null;
-	}
-	public void addPropertyListener(IPropertyListener listener) {
-	}
-	public void removePropertyListener(IPropertyListener listener) {
-	}
-	public String getPartName() {
-		return null;
-	}
-	public String getContentDescription() {
-		return null;
-	}
-	// WDG:
-	public IEditorInput getEditorInput() throws PartInitException {
-		return null;
-	}
-	
-	/**
-	 * @see org.eclipse.ui.IWorkbenchPartReference#addPartPropertyListener(org.eclipse.jface.util.IPropertyChangeListener)
-	 */
-	public void addPartPropertyListener(IPropertyChangeListener listener) {
-		// TODO Auto-generated method stub
-		
-	}
-	/**
-	 * @see org.eclipse.ui.IWorkbenchPartReference#getPartProperty(java.lang.String)
-	 */
-	public String getPartProperty(String key) {
-		// TODO Auto-generated method stub
-		return null;
-	}
-	
-	/**
-	 * @see org.eclipse.ui.IWorkbenchPartReference#removePartPropertyListener(org.eclipse.jface.util.IPropertyChangeListener)
-	 */
-	public void removePartPropertyListener(IPropertyChangeListener listener) {
-		// TODO Auto-generated method stub
-		
-	}
-}
\ No newline at end of file
diff --git a/plugins/org.eclipse.bpel.common.ui/src/org/eclipse/bpel/common/ui/composite/ICompositeEditorConstants.java b/plugins/org.eclipse.bpel.common.ui/src/org/eclipse/bpel/common/ui/composite/ICompositeEditorConstants.java
deleted file mode 100644
index 929e780..0000000
--- a/plugins/org.eclipse.bpel.common.ui/src/org/eclipse/bpel/common/ui/composite/ICompositeEditorConstants.java
+++ /dev/null
@@ -1,23 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2005 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 Corporation - initial API and implementation
- *******************************************************************************/
-package org.eclipse.bpel.common.ui.composite;
-
-/**
- * General constants.
- */
-public interface ICompositeEditorConstants {
-
-	// error codes
-	public static final int MISSING_ATTRIBUTE = 1;
-	public static final int COULD_NOT_INSTANTIATE_EDITOR = 2;
-	public static final int COULD_NOT_DISCONNECT_EDITOR = 3;
-	public static final int EDITOR_NOT_CONNECTED = 4;
-}
diff --git a/plugins/org.eclipse.bpel.examples.extensionPoints/plugin.xml b/plugins/org.eclipse.bpel.examples.extensionPoints/plugin.xml
index e3af2b7..2aa1bdd 100644
--- a/plugins/org.eclipse.bpel.examples.extensionPoints/plugin.xml
+++ b/plugins/org.eclipse.bpel.examples.extensionPoints/plugin.xml
@@ -20,34 +20,6 @@
                default="false"/>
       </additions>
    </extension>
-   <!-- NOTE: This extension point is not yet implemented -->
-   <extension
-         point="org.eclipse.bpel.common.ui.embeddedEditors">
-      <editor
-            class="org.eclipse.bpel.examples.extensionpoints.expression.editors.SimpleTextEditor"
-            id="org.eclipse.bpel.examples.extensionPoints.textEditor"
-            name="Ruby-Text">
-      </editor>
-      <editor
-            class="org.eclipse.bpel.examples.extensionpoints.expression.editors.JavaTextEditor"
-            contributorClass="org.eclipse.jdt.internal.ui.javaeditor.BasicJavaEditorActionContributor"
-            id="org.eclipse.bpel.examples.extensionPoints.javaEditor"
-            name="Java Editor">
-      </editor>
-      <editor
-            class="org.eclipse.bpel.examples.extensionpoints.expression.editors.JavaScriptTextEditor"
-            id="org.eclipse.bpel.examples.extensionPoints.javaScriptEditor"
-            name="JavaScript Editor">
-      </editor>
-   </extension>
-   <extension
-         point="org.eclipse.bpel.ui.expressionEditors">
-      <editor
-            class="org.eclipse.bpel.examples.extensionpoints.expression.editors.SimpleTextExpressionEditor"
-            expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:ruby"
-            label="Ruby (Simple Text Editor)">
-      </editor>
-   </extension>
    <extension
          point="org.eclipse.bpel.common.model.functionRegistry">
       <registry
diff --git a/plugins/org.eclipse.bpel.examples.extensionPoints/src/org/eclipse/bpel/examples/extensionpoints/expression/editors/JavaExpressionEditor.java b/plugins/org.eclipse.bpel.examples.extensionPoints/src/org/eclipse/bpel/examples/extensionpoints/expression/editors/JavaExpressionEditor.java
deleted file mode 100644
index 8520b2a..0000000
--- a/plugins/org.eclipse.bpel.examples.extensionPoints/src/org/eclipse/bpel/examples/extensionpoints/expression/editors/JavaExpressionEditor.java
+++ /dev/null
@@ -1,32 +0,0 @@
-/*******************************************************************************

- * Copyright (c) 2008, 2012 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 Corporation - initial API and implementation

- *******************************************************************************/

-package org.eclipse.bpel.examples.extensionpoints.expression.editors;

-

-

-

-/**

- * Simple text editor used as an expression editor.

- * 

- * This example shows the use of the eclipse default text editor as an expression

- * editor for the expression language set in the extension point.

- * 

- * @author Michal Chmielewski (michal.chmielewski@oracle.com)

- * @date Jul 17, 2007

- */

-

-public class JavaExpressionEditor extends SimpleTextExpressionEditor {

-

-	@Override

-	protected String getTextEditorId () {

-		return JavaTextEditor.TEXT_EDITOR_ID;

-	}

-	

-}

diff --git a/plugins/org.eclipse.bpel.examples.extensionPoints/src/org/eclipse/bpel/examples/extensionpoints/expression/editors/JavaScriptExpressionEditor.java b/plugins/org.eclipse.bpel.examples.extensionPoints/src/org/eclipse/bpel/examples/extensionpoints/expression/editors/JavaScriptExpressionEditor.java
deleted file mode 100644
index 5653552..0000000
--- a/plugins/org.eclipse.bpel.examples.extensionPoints/src/org/eclipse/bpel/examples/extensionpoints/expression/editors/JavaScriptExpressionEditor.java
+++ /dev/null
@@ -1,57 +0,0 @@
-/*******************************************************************************

- * Copyright (c) 2008, 2012 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 Corporation - initial API and implementation

- *******************************************************************************/

-package org.eclipse.bpel.examples.extensionpoints.expression.editors;

-

-import org.eclipse.bpel.ui.expressions.IEditorConstants;

-import org.eclipse.bpel.ui.util.BPELDateTimeHelpers;

-

-

-

-/**

- * JavaScript editor used as an expression editor.

- * 

- * This example shows the use of the WTPs JavaScript editor as an expression

- * editor for the expression language set in the extension point.

- *    

- * @author Michal Chmielewski (michal.chmielewski@oracle.com)

- * @date Jul 17, 2007

- */

-

-public class JavaScriptExpressionEditor extends SimpleTextExpressionEditor {

-

-	@Override

-	protected String getTextEditorId () {

-		return JavaScriptTextEditor.TEXT_EDITOR_ID;

-	}

-

-	/**

-	 * @see org.eclipse.bpel.examples.extensionpoints.expression.editors.SimpleTextExpressionEditor#getDefaultContent()

-	 */

-	

-	@SuppressWarnings("nls")

-	@Override

-	public String getDefaultContent() {

-		

-		String exprType = getExprType();

-		if (exprType.indexOf(IEditorConstants.ET_BOOLEAN) >= 0) {

-			return "true";

-		} else if (exprType.indexOf(IEditorConstants.ET_UNSIGNED_INT) >= 0) {

-			return "1";

-		} else if (exprType.indexOf(IEditorConstants.ET_DATETIME) >= 0) {

-			return "new Date() // sample"; 					

-		} else if (exprType.indexOf(IEditorConstants.ET_DURATION) >= 0) {

-			return "parseTime(\"0d0h0m0s\") // sample";

-		}

-		

-		return ""; //$NON-NLS-1$

-	}

-

-}

diff --git a/plugins/org.eclipse.bpel.examples.extensionPoints/src/org/eclipse/bpel/examples/extensionpoints/expression/editors/JavaScriptTextEditor.java b/plugins/org.eclipse.bpel.examples.extensionPoints/src/org/eclipse/bpel/examples/extensionpoints/expression/editors/JavaScriptTextEditor.java
deleted file mode 100644
index d193205..0000000
--- a/plugins/org.eclipse.bpel.examples.extensionPoints/src/org/eclipse/bpel/examples/extensionpoints/expression/editors/JavaScriptTextEditor.java
+++ /dev/null
@@ -1,71 +0,0 @@
-/*******************************************************************************

- * Copyright (c) 2006, 2012 Oracle 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:

- *     Oracle Corporation - initial API and implementation

- *******************************************************************************/

-package org.eclipse.bpel.examples.extensionpoints.expression.editors;

-

-import org.eclipse.jface.text.IDocument;

-import org.eclipse.ui.IEditorInput;

-import org.eclipse.ui.texteditor.ITextEditorActionConstants;

-

-/**

- * @author Michal Chmielewski (michal.chmielewski@oracle.com)

- * @date Jul 17, 2007

- *

- * NOTE: This needs to be reworked to use the WST JSDT toolkit. Also, the org.eclipse.bpel.common.ui.embeddedEditors

- * extension point has not yet been fully defined in the documentation (nor can I find any references in

- * the code to where an embedded editor is actually being instantiated, with the exception of expression editors,

- * which are defined with the org.eclipse.bpel.ui.expressionEditors extension point!)

- */

-@SuppressWarnings("nls")

-public class JavaScriptTextEditor /* extends org.eclipse.wst.javascript.ui.internal.editor.JSEditor */ {

-	

-	/** The Editor ID */

-	public static final String TEXT_EDITOR_ID = "org.eclipse.bpel.examples.extensionPoints.javaScriptEditor";

-

-//	/**

-//	 * 

-//	 */

-//	public JavaScriptTextEditor() {

-//		super();

-//		setDocumentProvider(new TextDocumentProvider());

-//		

-//	}

-//

-//	/**

-//	 * Remove unnecessary actions.

-//	 */

-//	@Override

-//	protected void createActions() {

-//		super.createActions();

-//		setAction(ITextEditorActionConstants.PRINT, null);

-//		setAction(ITextEditorActionConstants.SAVE, null);

-//		setAction(ITextEditorActionConstants.REVERT_TO_SAVED, null);

-//	}

-//

-//	/**

-//	 * Returns the current contents of this editor.

-//	 * @return the contents of the editor

-//	 */

-//	

-//	public String getContents() {

-//		IEditorInput input = getEditorInput();

-//		IDocument doc = getDocumentProvider().getDocument(input);

-//		return doc.get();

-//	}

-//

-//	/**

-//	 * Removes the dirty state.

-//	 */

-//	public void markAsClean() {

-//		// this is almost a no-op

-//		doSave(null);

-//	}

-	

-}

diff --git a/plugins/org.eclipse.bpel.examples.extensionPoints/src/org/eclipse/bpel/examples/extensionpoints/expression/editors/JavaTextEditor.java b/plugins/org.eclipse.bpel.examples.extensionPoints/src/org/eclipse/bpel/examples/extensionpoints/expression/editors/JavaTextEditor.java
deleted file mode 100644
index 2051056..0000000
--- a/plugins/org.eclipse.bpel.examples.extensionPoints/src/org/eclipse/bpel/examples/extensionpoints/expression/editors/JavaTextEditor.java
+++ /dev/null
@@ -1,90 +0,0 @@
-/*******************************************************************************

- * Copyright (c) 2006, 2012 Oracle 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:

- *     Oracle Corporation - initial API and implementation

- *******************************************************************************/

-package org.eclipse.bpel.examples.extensionpoints.expression.editors;

-

-import org.eclipse.jdt.core.IJavaElement;

-import org.eclipse.jdt.internal.ui.javaeditor.ClassFileEditor;

-import org.eclipse.jdt.internal.ui.javaeditor.CompilationUnitEditor;

-import org.eclipse.jdt.internal.ui.javaeditor.JavaEditor;

-import org.eclipse.jface.text.IDocument;

-import org.eclipse.ui.IEditorInput;

-import org.eclipse.ui.texteditor.ITextEditorActionConstants;

-

-/**

- * 

- * @author Michal Chmielewski (michal.chmielewski@oracle.com)

- * @date Jul 17, 2007

- *

- */

-@SuppressWarnings("nls")

-public class JavaTextEditor extends JavaEditor {

-	

-	/** The Editor ID */

-	public static final String TEXT_EDITOR_ID = "org.eclipse.bpel.examples.extensionPoints.javaEditor";

-

-	/**

-	 * 

-	 */

-	public JavaTextEditor() {

-		super();

-		setDocumentProvider(new TextDocumentProvider());

-		

-	}

-

-	/**

-	 * Remove unnecessary actions.

-	 */

-	@Override

-	protected void createActions() {

-		super.createActions();

-		setAction(ITextEditorActionConstants.PRINT, null);

-		setAction(ITextEditorActionConstants.SAVE, null);

-		setAction(ITextEditorActionConstants.REVERT_TO_SAVED, null);

-	}

-

-	/**

-	 * Returns the current contents of this editor.

-	 * @return the contents of the editor

-	 */

-	

-	public String getContents() {

-		IEditorInput input = getEditorInput();

-		IDocument doc = getDocumentProvider().getDocument(input);

-		return doc.get();

-	}

-

-	/**

-	 * Removes the dirty state.

-	 */

-	public void markAsClean() {

-		// this is almost a no-op

-		doSave(null);

-	}

-

-	/* (non-Javadoc)

-	 * @see org.eclipse.jdt.internal.ui.javaeditor.JavaEditor#getCorrespondingElement(org.eclipse.jdt.core.IJavaElement)

-	 */

-	@Override

-	protected IJavaElement getCorrespondingElement(IJavaElement element) {

-		// TODO Auto-generated method stub

-		return null;

-	}

-

-	/* (non-Javadoc)

-	 * @see org.eclipse.jdt.internal.ui.javaeditor.JavaEditor#getElementAt(int)

-	 */

-	@Override

-	protected IJavaElement getElementAt(int offset) {

-		// TODO Auto-generated method stub

-		return null;

-	}

-

-}

diff --git a/plugins/org.eclipse.bpel.examples.extensionPoints/src/org/eclipse/bpel/examples/extensionpoints/expression/editors/SimpleTextEditor.java b/plugins/org.eclipse.bpel.examples.extensionPoints/src/org/eclipse/bpel/examples/extensionpoints/expression/editors/SimpleTextEditor.java
deleted file mode 100644
index 32e9db1..0000000
--- a/plugins/org.eclipse.bpel.examples.extensionPoints/src/org/eclipse/bpel/examples/extensionpoints/expression/editors/SimpleTextEditor.java
+++ /dev/null
@@ -1,73 +0,0 @@
-/*******************************************************************************

- * Copyright (c) 2005, 2012 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 Corporation - initial API and implementation

- *******************************************************************************/

-package org.eclipse.bpel.examples.extensionpoints.expression.editors;

-

-import org.eclipse.jface.text.IDocument;

-import org.eclipse.ui.IEditorInput;

-import org.eclipse.ui.texteditor.AbstractDecoratedTextEditor;

-import org.eclipse.ui.texteditor.ITextEditorActionConstants;

-

-/**

- * Text editor for IText objects.

- */

-

-@SuppressWarnings("nls")

-public class SimpleTextEditor extends AbstractDecoratedTextEditor {

-

-	/** The Editor ID */

-	public static final String TEXT_EDITOR_ID = "org.eclipse.bpel.examples.extensionPoints.textEditor";

-

-	/**

-	 * 

-	 */

-	public SimpleTextEditor() {

-		super();

-		setDocumentProvider(new TextDocumentProvider());

-		

-	}

-

-	/**

-	 * Remove unnecessary actions.

-	 */

-	@Override

-	protected void createActions() {

-		super.createActions();

-		setAction(ITextEditorActionConstants.PRINT, null);

-		setAction(ITextEditorActionConstants.SAVE, null);

-		setAction(ITextEditorActionConstants.REVERT_TO_SAVED, null);

-	}

-

-	/**

-	 * Returns the current contents of this editor.

-	 * @return the contents of the editor

-	 */

-	

-	public String getContents() {

-		IEditorInput input = getEditorInput();

-		IDocument doc = getDocumentProvider().getDocument(input);

-		return doc.get();

-	}

-

-	/**

-	 * Removes the dirty state.

-	 */

-	public void markAsClean() {

-		// this is almost a no-op

-		doSave(null);

-	}

-	

-	

-	@Override

-	protected boolean isOverviewRulerVisible() {    	

-	   	return false;

-	}

-

-}
\ No newline at end of file
diff --git a/plugins/org.eclipse.bpel.examples.extensionPoints/src/org/eclipse/bpel/examples/extensionpoints/expression/editors/SimpleTextExpressionEditor.java b/plugins/org.eclipse.bpel.examples.extensionPoints/src/org/eclipse/bpel/examples/extensionpoints/expression/editors/SimpleTextExpressionEditor.java
deleted file mode 100644
index df394b1..0000000
--- a/plugins/org.eclipse.bpel.examples.extensionPoints/src/org/eclipse/bpel/examples/extensionpoints/expression/editors/SimpleTextExpressionEditor.java
+++ /dev/null
@@ -1,227 +0,0 @@
-/*******************************************************************************

- * Copyright (c) 2008, 2012 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 Corporation - initial API and implementation

- *******************************************************************************/

-package org.eclipse.bpel.examples.extensionpoints.expression.editors;

-

-

-import org.eclipse.bpel.ui.expressions.AbstractExpressionEditor;

-import org.eclipse.core.resources.IMarker;

-import org.eclipse.swt.SWT;

-import org.eclipse.swt.layout.FillLayout;

-import org.eclipse.swt.widgets.Composite;

-import org.eclipse.ui.IEditorPart;

-import org.eclipse.ui.IPropertyListener;

-import org.eclipse.ui.forms.widgets.FormToolkit;

-

-/**

- * Simple text editor used as an expression editor.

- * 

- * This example shows the use of the eclipse default text editor as an expression

- * editor for the expression language set in the extension point.

- * 

- * @author Michal Chmielewski (michal.chmielewski@oracle.com)

- * @date Jul 17, 2007

- */

-

-@SuppressWarnings("nls")

-public class SimpleTextExpressionEditor extends AbstractExpressionEditor {

-

-	protected Composite fEditorComposite;

-	protected IEditorPart fEditorPart;

-	protected IPropertyListener fPropertyListener;	

-	protected String fBody = "";

-	protected boolean updating = false;

-	protected TextEditorInput fInput;

-	

-	/**

-	 * 

-	 * @see org.eclipse.bpel.ui.expressions.AbstractExpressionEditor#getEditorContent()

-	 */

-	

-	@Override

-	public String getEditorContent() {

-		if (fEditorPart != null) {		

-			return (String) fEditorPart.getEditorInput().getAdapter(String.class);			

-		}

-		return fBody;

-	}

-

-	

-	protected String getTextEditorId () {

-		return SimpleTextEditor.TEXT_EDITOR_ID;

-	}

-	

-	/**

-	 * 

-	 * @see org.eclipse.bpel.ui.expressions.AbstractExpressionEditor#createControls(org.eclipse.swt.widgets.Composite, org.eclipse.bpel.ui.properties.BPELPropertySection)

-	 */

-	

-	@Override

-	public void createControls (Composite parent, FormToolkit toolkit) {

-		super.createControls(parent, toolkit);

-		createEditor(parent);

-	}

-

-	/**

-	 * (non-Javadoc)

-	 * @see org.eclipse.bpel.ui.expressions.AbstractExpressionEditor#setEditorContent(java.lang.String)

-	 */

-	

-	@Override

-	public void setEditorContent (String aBody) {

-	    this.fBody = aBody;

-	    	    

-	    try {

-	    	updating = true;

-	    	

-	    	if (fInput != null) {	    		

-	    		fInput.setEditorContent( fBody, getModelObject(), getExprType() );

-	    	}

-	    	

-	    } finally {

-	    	updating = false;

-	    }

-	}

-	

-	@SuppressWarnings("nls")

-	

-	protected void createEditor (Composite parent) {

-	

-		fInput = new TextEditorInput( fBody, getModelObject(), getExprType() );

-		

-		fEditorComposite = wf.createComposite(parent, SWT.BORDER);

-		fEditorComposite.setLayout( new FillLayout() );	

-		

-		fEditorPart = createEditor(	getTextEditorId() ,	fInput,	fEditorComposite );

-	}

-

-	

-	/** (non-Javadoc)

-	 * @see org.eclipse.bpel.ui.expressions.IExpressionEditor#dispose()

-	 */

-	

-	public void dispose() {

-		disposeEditor();

-	}

-	

-	protected void disposeEditor() {

-		

-		if (fEditorPart != null) {

-			getEditorManager().disposeEditor(fEditorPart);

-			if (fEditorComposite != null && !fEditorComposite.isDisposed()) {				

-				fEditorComposite.dispose();

-				fEditorComposite = null;

-			}

-			fEditorPart = null;

-		}

-	}

-

-	/**

-	 *  About to be Hidden.

-	 */

-	

-	public void aboutToBeHidden() {

-		if (fEditorPart != null) {

-			fEditorPart.removePropertyListener(getPropertyListener());

-		}

-	}

-

-	

-	/** 

-	 * Editor is about to be shown.

-	 * @see org.eclipse.bpel.ui.expressions.IExpressionEditor#aboutToBeShown()

-	 */

-	

-	public void aboutToBeShown() {		

-		if (fEditorPart != null) {

-			fEditorPart.addPropertyListener(getPropertyListener());

-		}					

-	}

-

-	/**

-	 * If the editor is dirty it registers an ongoing change.

-	 */

-	protected IPropertyListener getPropertyListener() {

-		

-		if (fPropertyListener == null) {

-			fPropertyListener = new IPropertyListener() {

-				@SuppressWarnings("synthetic-access")

-				public void propertyChanged(Object source, int propId) {

-					if (!updating && propId == IEditorPart.PROP_DIRTY && fEditorPart.isDirty()) { 

-						notifyChanged();

-					}

-				}

-			};

-		}

-		return fPropertyListener;

-	}

-

-	

-	/**

-	 * Get the user context to remember for next invocation.

-	 * 

-	 * @see org.eclipse.bpel.ui.expressions.IExpressionEditor#getUserContext()

-	 */

-	public Object getUserContext() {

-		return null;

-	}

-

-	/**

-	 * Restore the user context.

-	 * 

-	 * @see org.eclipse.bpel.ui.expressions.IExpressionEditor#restoreUserContext(java.lang.Object)

-	 */

-	

-	public void restoreUserContext(Object userContext) {

-		fEditorPart.setFocus();

-	}

-

-	 

-	/**

-	 * Return the default body for this type of expression. Since the editor is not aware of any syntax

-	 * for any particular language, the empty string is returned.

-	 * @see org.eclipse.bpel.ui.expressions.IExpressionEditor#getDefaultContent()

-	 */

-	public String getDefaultContent() {

-		return ""; //$NON-NLS-1$

-	}

-	

-	/** (non-Javadoc)

-	 * @see org.eclipse.bpel.ui.expressions.IExpressionEditor#gotoTextMarker(org.eclipse.core.resources.IMarker, java.lang.String, java.lang.Object)

-	 */

-	public void gotoTextMarker(IMarker marker, String codeType, Object modelObject) {

-		// TODO: Goto text marker in default text editor.

-	}

-

-	

-	/** 

-	 * Answer true, because a generic text editor will simply do everything.

-	 * 

-	 * @see org.eclipse.bpel.ui.expressions.IExpressionEditor#supportsExpressionType(java.lang.String)

-	 */

-	

-	public boolean supportsExpressionType( String exprType ) {

-		return true;

-	}

-	

-	

-	/**

-	 * Mark it clean.

-	 * @see org.eclipse.bpel.ui.expressions.IExpressionEditor#markAsClean()

-	 */

-	

-	public void markAsClean() {

-		if (fEditorPart != null) {

-			fEditorPart.doSave(null);			

-		}

-	}

-	

-

-}

diff --git a/plugins/org.eclipse.bpel.examples.extensionPoints/src/org/eclipse/bpel/examples/extensionpoints/expression/editors/TextDocumentProvider.java b/plugins/org.eclipse.bpel.examples.extensionPoints/src/org/eclipse/bpel/examples/extensionpoints/expression/editors/TextDocumentProvider.java
deleted file mode 100644
index 26a7b2b..0000000
--- a/plugins/org.eclipse.bpel.examples.extensionPoints/src/org/eclipse/bpel/examples/extensionpoints/expression/editors/TextDocumentProvider.java
+++ /dev/null
@@ -1,79 +0,0 @@
-/*******************************************************************************

- * Copyright (c) 2005, 2012 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 Corporation - initial API and implementation

- *******************************************************************************/

-package org.eclipse.bpel.examples.extensionpoints.expression.editors;

-

-import org.eclipse.core.runtime.IProgressMonitor;

-import org.eclipse.jface.operation.IRunnableContext;

-import org.eclipse.jface.text.Document;

-import org.eclipse.jface.text.IDocument;

-import org.eclipse.jface.text.source.IAnnotationModel;

-import org.eclipse.ui.texteditor.AbstractDocumentProvider;

-

-/**

- * Document provider for TextEditor.

- */

-public class TextDocumentProvider extends AbstractDocumentProvider {

-

-	@Override

-	protected IDocument createDocument (Object element) {

-		

-		if (element instanceof TextEditorInput) {

-			

-			TextEditorInput input = (TextEditorInput) element;

-			Document doc = new Document( input.getEditorContent() );

-			input.setDocument ( doc );

-			

-			return doc;

-		}		

-		return null;

-	}

-

-	@Override

-	protected IAnnotationModel createAnnotationModel(Object element) {

-		return null;

-	}

-

-	/**

-	 * Does not do anything. For this editor we do not have a save concept. All the changes

-	 * are stored in a certain model object and saved in a model file.

-	 * 

-	 */

-	

-	@Override

-	protected void doSaveDocument(IProgressMonitor monitor, Object element, IDocument document, boolean overwrite) {

-		

-	}

-

-	/**

-	 * @see org.eclipse.ui.texteditor.AbstractDocumentProvider#isReadOnly(java.lang.Object)

-	 */

-	@Override

-	public boolean isReadOnly(Object element) {

-		return false;

-	}

-

-	

-	/**

-	 * 

-	 * @see org.eclipse.ui.texteditor.AbstractDocumentProvider#isModifiable(java.lang.Object)

-	 */

-	@Override

-	public boolean isModifiable(Object element) {

-		return true;

-	}

-

-	

-	@Override

-	protected IRunnableContext getOperationRunner (IProgressMonitor monitor) {

-		// TODO: Need to implement for 6.0

-		return null;

-	}

-}

diff --git a/plugins/org.eclipse.bpel.examples.extensionPoints/src/org/eclipse/bpel/examples/extensionpoints/expression/editors/TextEditorInput.java b/plugins/org.eclipse.bpel.examples.extensionPoints/src/org/eclipse/bpel/examples/extensionpoints/expression/editors/TextEditorInput.java
deleted file mode 100644
index b640bd2..0000000
--- a/plugins/org.eclipse.bpel.examples.extensionPoints/src/org/eclipse/bpel/examples/extensionpoints/expression/editors/TextEditorInput.java
+++ /dev/null
@@ -1,168 +0,0 @@
-/*******************************************************************************

- * Copyright (c) 2005, 2012 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 Corporation - initial API and implementation

- *******************************************************************************/

-package org.eclipse.bpel.examples.extensionpoints.expression.editors;

-

-import org.eclipse.jface.resource.ImageDescriptor;

-import org.eclipse.jface.text.IDocument;

-import org.eclipse.ui.IEditorInput;

-import org.eclipse.ui.IPersistableElement;

-

-/**

- * Editor input for TextEditor.

- */

-@SuppressWarnings("nls")

-public class TextEditorInput implements IEditorInput {

-

-	/** body of the document, the initial value */

-	String fBody = "";

-	

-	/** A context object */

-	Object fContext;

-	

-	// expression context

-	String fExpressionContext;

-

-	/**

-	 * Create a new Text Editor Input. 

-	 * @param text

-	 * @param eObject

-	 * @param expressionContext 

-	 */

-	

-	public TextEditorInput (String text, Object eObject, String expressionContext) {

-		setEditorContent (text,eObject,expressionContext);

-		

-	}

-

-	

-	/**

-	 * @return return the expression context, represented by this TextEditor input.

-	 */

-	

-	public String getExpressionContext() {

-		return fExpressionContext;

-	}

-	

-	/**

-	 * Returns the body from this TextEditorInput. This may include the modified editor

-	 * body once the editor has notified us that its content has changed.

-	 * 

-	 * @return the editor's body.

-	 */

-	

-	public String getEditorContent() {

-		return fDocument == null ? fBody : fDocument.get() ;		

-	}

-	

-	/**

-	 * Set the body on the document.

-	 * 

-	 * @param text

-	 * @param eObject

-	 */

-	

-	public void setEditorContent (String text, Object eObject, String expressionContext) {

-		

-		fBody = text;

-		fContext = eObject;

-		fExpressionContext = expressionContext;

-		

-		if (fDocument != null) {

-			fDocument.set(text);

-		}

-		

-	}

-

-	/** 

-	 * @see org.eclipse.ui.IEditorInput#exists()

-	 */

-	

-	public boolean exists() {

-		return false;

-	}

-

-	/**

-	 * @see org.eclipse.ui.IEditorInput#getImageDescriptor()

-	 */

-	

-	public ImageDescriptor getImageDescriptor() {

-		return null;

-	}

-

-	/**

-	 * @see org.eclipse.ui.IEditorInput#getName()

-	 */

-	public String getName() {

-		return null;

-	}

-

-	/** 

-	 * @see org.eclipse.ui.IEditorInput#getPersistable()

-	 */

-	public IPersistableElement getPersistable() {

-		return null;

-	}

-

-	/**

-	 * @see org.eclipse.ui.IEditorInput#getToolTipText()

-	 */

-	public String getToolTipText() {

-		return "XPath Expressions"; //$NON-NLS-1$

-	}

-

-	/**

-	 * Adapt to the adapter class.

-	 * 

-	 * The receiver carries the string input to the editor, so if String.class is passed

-	 * we just return that.

-	 * 

-	 * We also hold a context object. If the context object is of the adapter class we 

-	 * return it is. The context object can be anything ... in our case we pass the reference 

-	 * to the model object that is "closest" to the expression node. 

-	 * @param adapter The adapter class to use.

-	 * @return the adapted object ...

-	 */

-	

-	

-	

-	@SuppressWarnings("unchecked")

-	public Object getAdapter (Class adapter) {

-		

-		if (adapter.isInstance(fContext)) {

-			return fContext;

-		}

-				

-		if (adapter.isInstance(fBody)) {

-			return getEditorContent() ;

-		}

-

-		// hack

-		if (adapter == Integer.class) {

-			return fExpressionContext;

-		}

-

-		return null;

-	}

-

-	

-	IDocument fDocument;

-	

-	/**

-	 * Set the document that this text editor input manages.

-	 * 

-	 * @param doc

-	 */

-	

-	public void setDocument ( IDocument doc ) {

-		fDocument = doc;

-	}

-	

-}

diff --git a/plugins/org.eclipse.bpel.ui/.settings/org.eclipse.jdt.core.prefs b/plugins/org.eclipse.bpel.ui/.settings/org.eclipse.jdt.core.prefs
index 88c528f..5d3c5a0 100644
--- a/plugins/org.eclipse.bpel.ui/.settings/org.eclipse.jdt.core.prefs
+++ b/plugins/org.eclipse.bpel.ui/.settings/org.eclipse.jdt.core.prefs
@@ -1,12 +1,12 @@
-#Fri Apr 22 06:01:34 MDT 2011
-eclipse.preferences.version=1
-org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
-org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.6
-org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve
-org.eclipse.jdt.core.compiler.compliance=1.6
-org.eclipse.jdt.core.compiler.debug.lineNumber=generate
-org.eclipse.jdt.core.compiler.debug.localVariable=generate
-org.eclipse.jdt.core.compiler.debug.sourceFile=generate
-org.eclipse.jdt.core.compiler.problem.assertIdentifier=error
-org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
-org.eclipse.jdt.core.compiler.source=1.6
+#Thu Feb 09 11:24:04 CET 2012

+eclipse.preferences.version=1

+org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled

+org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.6

+org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve

+org.eclipse.jdt.core.compiler.compliance=1.6

+org.eclipse.jdt.core.compiler.debug.lineNumber=generate

+org.eclipse.jdt.core.compiler.debug.localVariable=generate

+org.eclipse.jdt.core.compiler.debug.sourceFile=generate

+org.eclipse.jdt.core.compiler.problem.assertIdentifier=error

+org.eclipse.jdt.core.compiler.problem.enumIdentifier=error

+org.eclipse.jdt.core.compiler.source=1.6

diff --git a/plugins/org.eclipse.bpel.ui/plugin.xml b/plugins/org.eclipse.bpel.ui/plugin.xml
index 2d43d7e..5bfb636 100644
--- a/plugins/org.eclipse.bpel.ui/plugin.xml
+++ b/plugins/org.eclipse.bpel.ui/plugin.xml
@@ -3,7 +3,6 @@
 <plugin>

 

    <extension-point id="hoverHelpers" name="%HOVERHELP_HELPER_NAME" schema="schema/hoverHelpers.exsd"/>

-   <extension-point id="expressionEditors" name="%EXPRESSION_LANGUAGE_EDITORS" schema="schemas/expressionEditors.exsd"/>

    <extension-point id="actions" name="%ACTIONS_NAME" schema="schemas/actions.exsd"/>

    <extension-point id="modelListener" name="Model Listener" schema="schemas/modelListener.exsd"/>

    <extension-point id="uiObjectFactories" name="UIObjectFactories" schema="schemas/uiObjectFactories.exsd"/>

@@ -110,7 +109,7 @@
             name="%PREFERENCE_PAGE_EDITOR">

       </page>

       <page

-            category="org.eclipse.bpel.ui.preferences.ExpressionEditorsPreferencePage"

+            category="org.eclipse.bpel.ui.preferences.BPELHomePreferencePage"

             class="org.eclipse.bpel.ui.preferences.XPathTemplatePreferencePage"

             id="org.eclipse.bpel.ui.preferences.BPELPreferencePage.XPathTemplatePreferencePage"

             name="%PREFERENCE_PAGE_XPATH_EDITOR_TEMPLATES"/>

@@ -120,11 +119,6 @@
             name="%PREFERENCE_PAGE_HOME"/>

       <page

             category="org.eclipse.bpel.ui.preferences.BPELHomePreferencePage"

-            class="org.eclipse.bpel.ui.preferences.ExpressionEditorsPreferencePage"

-            id="org.eclipse.bpel.ui.preferences.ExpressionEditorsPreferencePage"

-            name="%PREFERENCE_PAGE_EXPRESSION_EDITOR"/>

-      <page

-            category="org.eclipse.bpel.ui.preferences.BPELHomePreferencePage"

             class="org.eclipse.bpel.ui.preferences.WSILPreferencePage"

             id="org.eclipse.bpel.ui.preferences.WSILPreferencePage"

             name="%PREFERENCE_PAGE_WSIL"/>

@@ -582,10 +576,6 @@
             project="false"/>

    </extension>

    <extension

-         point="org.eclipse.core.runtime.preferences">

-      <initializer class="org.eclipse.bpel.ui.preferences.PreferenceInitializer"/>

-   </extension>

-   <extension

          point="org.eclipse.ui.editors.templates">

       <contextType

             class="org.eclipse.jface.text.templates.TemplateContextType"

@@ -609,36 +599,6 @@
    </extension>

 

    <extension

-         point="org.eclipse.bpel.common.ui.embeddedEditors">

-      <editor

-            contributorClass="org.eclipse.ui.texteditor.BasicTextEditorActionContributor"

-            class="org.eclipse.bpel.ui.editors.xpath.XPathTextEditor"

-            name="XPath 1.0 Text Editor."

-            id="org.eclipse.bpel.ui.editors.xpath.XPathTextEditor">

-             <!-- TODO: remove the name="" in the future -->

-      </editor>

-      <editor

-            contributorClass="org.eclipse.ui.texteditor.BasicTextEditorActionContributor"

-            class="org.eclipse.bpel.ui.editors.TextEditor"

-            name="Default Expression Editor"

-            id="org.eclipse.bpel.ui.editors.TextEditor">

-             <!-- TODO: remove the name="" in the future -->

-      </editor>

-   </extension>

-   

-   <extension

-         point="org.eclipse.bpel.ui.expressionEditors">

-      <editor

-            label="%XPATH_LABEL"

-            class="org.eclipse.bpel.ui.expressions.XPathExpressionEditor"

-            expressionLanguage="http://www.w3.org/TR/1999/REC-xpath-19991116">

-      </editor>

-      <editor

-            class="org.eclipse.bpel.ui.expressions.XPathExpressionEditor"

-            expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath1.0"

-            label="%XPATH_LABEL20"/>

-   </extension>

-   <extension

          id="org.eclipse.bpel.ui.bpel.provider"

          name="BPEL Palette Provider"

          point="org.eclipse.bpel.common.ui.paletteAdditions">

diff --git a/plugins/org.eclipse.bpel.ui/schemas/expressionEditors.exsd b/plugins/org.eclipse.bpel.ui/schemas/expressionEditors.exsd
deleted file mode 100644
index 49a646b..0000000
--- a/plugins/org.eclipse.bpel.ui/schemas/expressionEditors.exsd
+++ /dev/null
@@ -1,129 +0,0 @@
-<?xml version='1.0' encoding='UTF-8'?>
-<!-- Schema file written by PDE -->
-<schema targetNamespace="org.eclipse.bpel.ui">
-<annotation>
-      <appInfo>
-         <meta.schema plugin="org.eclipse.bpel.ui" id="expressionEditors" name="Expression Language Editors"/>
-      </appInfo>
-      <documentation>
-         The BPEL Editor provides a mechanism to plugin expression editors for the various
-expression languages that may be used by a BPEL runtime. XPath 1.0 is the default
-standard expression language that is used by BPEL. However, implementations may choose
-to provide other expression language implementations (such as JavaScript).
-      </documentation>
-   </annotation>
-
-   <element name="extension">
-      <complexType>
-         <sequence>
-            <element ref="editor" minOccurs="1" maxOccurs="unbounded"/>
-         </sequence>
-      </complexType>
-   </element>
-
-   <element name="editor">
-      <annotation>
-         <appInfo>
-            <meta.element labelAttribute="label"/>
-         </appInfo>
-         <documentation>
-            The editor used for editing expression languages.
-         </documentation>
-      </annotation>
-      <complexType>
-         <attribute name="class" type="string" use="required">
-            <annotation>
-               <documentation>
-                  The class which must implement org.eclipse.bpel.ui.expressions.IExpressionEditor or 
-alternatively extend &lt;tt&gt;org.eclipse.bpel.ui.expressions.AbstractExpressionEditor.&lt;/tt&gt;
-               </documentation>
-               <appInfo>
-                  <meta.attribute kind="java" basedOn="org.eclipse.bpel.ui.expressions.IExpressionEditor"/>
-               </appInfo>
-            </annotation>
-         </attribute>
-         <attribute name="expressionLanguage" type="string" use="required">
-            <annotation>
-               <documentation>
-                  The URI of the expression language that identifies this expression editor.
-               </documentation>
-            </annotation>
-         </attribute>
-         <attribute name="label" type="string" use="required">
-            <annotation>
-               <documentation>
-                  The user friendly lable describing this expression language.
-               </documentation>
-               <appInfo>
-                  <meta.attribute translatable="true"/>
-               </appInfo>
-            </annotation>
-         </attribute>
-      </complexType>
-   </element>
-
-   <annotation>
-      <appInfo>
-         <meta.section type="since"/>
-      </appInfo>
-      <documentation>
-         0.0.1
-      </documentation>
-   </annotation>
-
-   <annotation>
-      <appInfo>
-         <meta.section type="examples"/>
-      </appInfo>
-      <documentation>
-         The following example illustrates the XPath expression editor which is provided 
-within the &lt;tt&gt;org.eclipse.bpel.ui&lt;/tt&gt; plugin.
-&lt;p&gt;
-
-&lt;pre&gt;
-&lt;extension point=&quot;org.eclipse.bpel.ui.expressionEditors&quot;&gt;
-   &lt;editor
-         label=&quot;%XPATH_LABEL&quot;
-         class=&quot;org.eclipse.bpel.ui.expressions.XPathExpressionEditor&quot;
-         expressionLanguage=&quot;http://www.w3.org/TR/1999/REC-xpath-19991116&quot;&gt;
-   &lt;/editor&gt;
-&lt;/extension&gt;
-&lt;/pre&gt;
-      </documentation>
-   </annotation>
-
-   <annotation>
-      <appInfo>
-         <meta.section type="apiInfo"/>
-      </appInfo>
-      <documentation>
-         The value of the attribute class must represent a fully qualified name of a class
-which implements &lt;tt&gt;org.eclipse.bpel.ui.expressions.IExpressionEditor&lt;/tt&gt;.
-&lt;p&gt;
-Alternatively can be a class which extend &lt;tt&gt;org.eclipse.bpel.ui.expressions.AbstractExpressionEditor&lt;/tt&gt;.
-      </documentation>
-   </annotation>
-
-   <annotation>
-      <appInfo>
-         <meta.section type="implementation"/>
-      </appInfo>
-      <documentation>
-         The plugin &lt;tt&gt;org.eclipse.bpel.ui&lt;/tt&gt; provides the XPath 1.0 expression editor. It also
-provides a default expression editor for expressions for which the expression
-language (identified by the namespace URI) does not match any registered expression editors.
-&lt;p&gt;
-In such cases, a very simple opaque editor is provided.
-      </documentation>
-   </annotation>
-
-   <annotation>
-      <appInfo>
-         <meta.section type="copyright"/>
-      </appInfo>
-      <documentation>
-         
-      </documentation>
-   </annotation>
-
-</schema>
diff --git a/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/IHelpContextIds.java b/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/IHelpContextIds.java
index 45a028f..161bd81 100644
--- a/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/IHelpContextIds.java
+++ b/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/IHelpContextIds.java
@@ -10,42 +10,68 @@
  *******************************************************************************/

 package org.eclipse.bpel.ui;

 

-import org.eclipse.bpel.ui.dialogs.*;

-import org.eclipse.bpel.ui.expressions.XPathExpressionEditor;

-import org.eclipse.bpel.ui.preferences.*;

-import org.eclipse.bpel.ui.properties.*;

+import org.eclipse.bpel.ui.dialogs.EditMessagePropertyDialog;

+import org.eclipse.bpel.ui.dialogs.EditPropertyAliasDialog;

+import org.eclipse.bpel.ui.preferences.BPELPreferencePage;

+import org.eclipse.bpel.ui.preferences.WSILPreferencePage;

+import org.eclipse.bpel.ui.properties.ActionImplementationSection;

+import org.eclipse.bpel.ui.properties.AssignImplSection;

+import org.eclipse.bpel.ui.properties.AttributesSection;

+import org.eclipse.bpel.ui.properties.CompensateScopeSection;

+import org.eclipse.bpel.ui.properties.CorrSetImplSection;

+import org.eclipse.bpel.ui.properties.CorrelationSection;

+import org.eclipse.bpel.ui.properties.CreateInstanceSection;

+import org.eclipse.bpel.ui.properties.DocumentationSection;

+import org.eclipse.bpel.ui.properties.ExitOnStandardFaultSection;

+import org.eclipse.bpel.ui.properties.FaultCatchNameSection;

+import org.eclipse.bpel.ui.properties.FaultThrowNameSection;

+import org.eclipse.bpel.ui.properties.ForEachSection;

+import org.eclipse.bpel.ui.properties.ForEachSuccessfulBranchesOnlySection;

+import org.eclipse.bpel.ui.properties.ImportsSection;

+import org.eclipse.bpel.ui.properties.InvokeImplSection;

+import org.eclipse.bpel.ui.properties.JoinFailureSection;

+import org.eclipse.bpel.ui.properties.MessageExchangeSection;

+import org.eclipse.bpel.ui.properties.NameSection;

+import org.eclipse.bpel.ui.properties.NamespacePrefixesSection;

+import org.eclipse.bpel.ui.properties.NamespaceSection;

+import org.eclipse.bpel.ui.properties.PartnerLinkImplSection;

+import org.eclipse.bpel.ui.properties.RepeatingAlarmConditionSection;

+import org.eclipse.bpel.ui.properties.ScopeImplSection;

+import org.eclipse.bpel.ui.properties.ValidateSection;

+import org.eclipse.bpel.ui.properties.ValidateVariablesSection;

+import org.eclipse.bpel.ui.properties.WaitConditionSection;

 

 /**

- * This class contains context IDs that are used by different sections 

+ * This class contains context IDs that are used by different sections

  * of the BPEL designer and may be used by a help plugin.

  */

 public interface IHelpContextIds {

-  

+

   /** The prefix for all context IDs in this class. */

 	public static final String PREFIX = BPELUIPlugin.PLUGIN_ID + '.';

 

 	// Preferences

-	

+

 	/** Context ID for the {@link BPELPreferencePage} and {@link WSILPreferencePage}. */

 	public static final String PREFERENCES_PAGE = PREFIX + "preferences_page"; //$NON-NLS-1$

-	

+

 	// Editor

-	

+

 	/** Context ID for the {@link BPELEditor}. */

 	public static final String EDITOR_CANVAS = PREFIX + "editor_canvas"; //$NON-NLS-1$

 	/** Context ID for the palette of the {@link BPELEditor}. */

 	public static final String EDITOR_PALETTE = PREFIX + "editor_palette"; //$NON-NLS-1$

   /** Context ID for the tray of the {@link BPELEditor}. */

   public static final String TRAY_DESCRIPTION = PREFIX + "editor_tray"; //$NON-NLS-1$

-  

+

 	// Dialogs

-	

+

 	/** Context ID for the {@link EditMessagePropertyDialog}. */

 	public static final String PROPERTY_DIALOG = PREFIX + "property_dialog"; //$NON-NLS-1$

-	

+

 	/** Context ID for the {@link EditPropertyAliasDialog}. */

 	public static final String PROPERTY_ALIAS_DIALOG = PREFIX + "property_alias_dialog"; //$NON-NLS-1$

-	

+

 	// Property Pages

 	/** Context ID for the {@link FaultCatchNameSection} and {@link FaultThrowNameSection}. */

 	public static final String PROPERTY_PAGE_FAULT = PREFIX + "property_fault"; //$NON-NLS-1$

@@ -95,9 +121,9 @@
   public static final String PROPERTY_PAGE_ASSIGN = PREFIX + "property_assign";

   /** Context ID for the {@link ForEachSuccessfulBranchesOnlySection}. */

   public static final String PROPERTY_PAGE_FOR_EACH_SUCCESSFUL = PREFIX + "property_for_each_successful";

-  

+

 	// XPATH Expression editor

-	

+

   /** Context ID for the date time editor in the {@link XPathExpressionEditor}. */

   public static final String XPATH_DATE = PREFIX + "xpath_date"; //$NON-NLS-1$

   /** Context ID for the duration editor in the {@link XPathExpressionEditor}. */

diff --git a/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/details/providers/ExpressionEditorDescriptorContentProvider.java b/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/details/providers/ExpressionEditorDescriptorContentProvider.java
deleted file mode 100644
index 60370ac..0000000
--- a/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/details/providers/ExpressionEditorDescriptorContentProvider.java
+++ /dev/null
@@ -1,44 +0,0 @@
-/*******************************************************************************

- * Copyright (c) 2005, 2012 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 Corporation - initial API and implementation

- *******************************************************************************/

-package org.eclipse.bpel.ui.details.providers;

-

-import java.util.List;

-

-import org.eclipse.bpel.ui.extensions.BPELUIRegistry;

-import org.eclipse.bpel.ui.extensions.ExpressionEditorDescriptor;

-

-

-/**

- * @author IBM Original Contribution.

- * @author Michal Chmielewski (michal.chmielewski@oracle.com)

- * @date Jul 16, 2007

- *

- */

-public class ExpressionEditorDescriptorContentProvider extends AbstractContentProvider {

-	

-	/**

-	 * Brand new shiny ExpressionEditorContentProvider.

-	 */

-	public ExpressionEditorDescriptorContentProvider() {

-		super();

-	}

-	

-	/**

-	 * @see org.eclipse.bpel.ui.details.providers.AbstractContentProvider#collectElements(java.lang.Object, java.util.List)

-	 */

-	@Override

-	public void collectElements (Object input, List<Object> list) {

-						

-		for (ExpressionEditorDescriptor next : BPELUIRegistry.getInstance().getExpressionEditorDescriptors() ) {

-			list.add(next);

-		}

-	}	

-}

diff --git a/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/details/providers/ExpressionEditorDescriptorLabelProvider.java b/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/details/providers/ExpressionEditorDescriptorLabelProvider.java
deleted file mode 100644
index c501b6d..0000000
--- a/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/details/providers/ExpressionEditorDescriptorLabelProvider.java
+++ /dev/null
@@ -1,23 +0,0 @@
-/*******************************************************************************

- * Copyright (c) 2005, 2012 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 Corporation - initial API and implementation

- *******************************************************************************/

-package org.eclipse.bpel.ui.details.providers;

-

-import org.eclipse.bpel.ui.extensions.ExpressionEditorDescriptor;

-

-public class ExpressionEditorDescriptorLabelProvider extends org.eclipse.jface.viewers.LabelProvider {

-	

-	@Override

-	public String getText(Object element) {

-		ExpressionEditorDescriptor descriptor = (ExpressionEditorDescriptor) element;

-		String text = descriptor.getLabel();

-		return (text != null) ? text : descriptor.getExpressionLanguage();

-	}

-}

diff --git a/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/details/providers/ExpressionLanguageFilter.java b/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/details/providers/ExpressionLanguageFilter.java
deleted file mode 100644
index 0ead531..0000000
--- a/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/details/providers/ExpressionLanguageFilter.java
+++ /dev/null
@@ -1,46 +0,0 @@
-/*******************************************************************************

- * Copyright (c) 2005, 2012 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 Corporation - initial API and implementation

- *******************************************************************************/

-package org.eclipse.bpel.ui.details.providers;

-

-import org.eclipse.bpel.ui.extensions.ExpressionEditorDescriptor;

-import org.eclipse.jface.viewers.Viewer;

-import org.eclipse.jface.viewers.ViewerFilter;

-

-

-/**

- * Filters expression language editors.

- * 

- * This is also reused for query languages. In the future we should have

- * a separate extensibility mechanism for query languages.

- */

-public class ExpressionLanguageFilter extends ViewerFilter {

-

-	protected String[] exclude;

-	

-	public ExpressionLanguageFilter(String[] exclude) {

-		super();

-		this.exclude = exclude;

-	}

-

-	@Override

-	public boolean select(Viewer viewer, Object parentElement, Object element) {

-		if (element instanceof ExpressionEditorDescriptor) {

-			ExpressionEditorDescriptor descriptor = (ExpressionEditorDescriptor)element;

-			if (exclude != null) {

-				for (int i = 0; i < exclude.length; i++) {

-					if (exclude[i].equals(descriptor.getExpressionLanguage())) return false;

-				}

-			}

-		}

-		return true;

-	}

-

-}

diff --git a/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/dialogs/EditPropertyAliasDialog.java b/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/dialogs/EditPropertyAliasDialog.java
index 8501331..b7eaa4a 100644
--- a/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/dialogs/EditPropertyAliasDialog.java
+++ b/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/dialogs/EditPropertyAliasDialog.java
@@ -74,91 +74,60 @@
 	protected BPELEditor bpelEditor;

 	protected Property property;

 	protected PropertyAlias alias;

-	

+

 	protected EObject activeTypeElementOrMessage;

 	protected Query activeQuery;

-	

+

 	protected XSDTypeDefinition xsdTypeDefinition;

 	protected Query xsdTypeQuery;

-	

+

 	protected XSDElementDeclaration xsdElementDeclaration;

 	protected Query xsdElementQuery;

-	

+

 	protected Message message;

 	protected String messagePart;

 	protected Query messageQuery;

-	

+

 	protected Label typeElementOrMessageNameLabel;

 	protected Label typeElementOrMessageNameText;

 	private Button typeRadio;

 	private Button elementRadio;

 	private Button messageRadio;

 	private int typeElementOrMessage;

-	

+

 	private QueryEditor queryEditor;

 

 	protected Button browseTypeButton;

-	

+

 	protected TabbedPropertySheetWidgetFactory wf;

-	

+

 	public class QueryEditor extends ExpressionSection {

-	

-		public void create(Composite parent)

-		{

-			createControls(parent, null);

-		}

-		

-		public void setInput(EObject obj)

-		{

+		public void setInput(EObject obj) {

 			basicSetInput(obj);

 		}

-		

-		public String getQuery()

-		{

-			if (getExpressionEditor()!=null)

-				return getExpressionEditor().getEditorContent();

-			return null;

-		}

-		

-		public String getQueryLanguage()

-		{

-			Object elm = selectedExpressionLanguage();

-			if (elm == NO_EXPRESSION || elm == null )

-				return null;

-			return getExpressionLanguage(elm);

-		}

-		

-		@Override

-		protected String getExpressionType() { 

-			return IEditorConstants.ET_ANY; 

-		}

-		

-		@Override

-		public BPELEditor getBPELEditor() {

-			return bpelEditor;

-		}

-		

-		@Override

-		public TabbedPropertySheetWidgetFactory getWidgetFactory() {

-			return wf;

-		}

-		

-		@Override

-		protected EStructuralFeature getStructuralFeature () {

-			fStructuralFeature = MessagepropertiesPackage.eINSTANCE.getPropertyAlias_Query();

-			return fStructuralFeature;

+

+		public String getQuery() {

+			return this.fEditor.getContents();

 		}

 

 		@Override

-		protected void setStructuralFeature ( EStructuralFeature feature ) {

-			fStructuralFeature = feature;

+		protected String getExpressionType() {

+			return IEditorConstants.ET_ANY;

+		}

+

+		@Override

+		public BPELEditor getBPELEditor() {

+			return EditPropertyAliasDialog.this.bpelEditor;

+		}

+

+		@Override

+		public TabbedPropertySheetWidgetFactory getWidgetFactory() {

+			return EditPropertyAliasDialog.this.wf;

 		}

 

 		@Override

 		protected EStructuralFeature getStructuralFeature ( EObject eObject ) {

-			if (eObject != null)

-				return MessagepropertiesPackage.eINSTANCE.getPropertyAlias_Query();

-			return null;

+			return eObject != null ? MessagepropertiesPackage.eINSTANCE.getPropertyAlias_Query() : null;

 		}

 

 		@Override

@@ -168,7 +137,7 @@
 		}

 

 	}

-	

+

 	public EditPropertyAliasDialog(Shell parentShell, Property property, PropertyAlias alias, BPELEditor bpelEditor, TabbedPropertySheetWidgetFactory wf) {

 		super(parentShell);

 		setShellStyle(getShellStyle() | SWT.RESIZE);

@@ -177,26 +146,26 @@
 		this.property = property;

 		this.bpelEditor = bpelEditor;

 		this.wf = wf;

-		if (isNew) {

-			typeElementOrMessage = BID_USE_MESSAGE;

+		if (this.isNew) {

+			this.typeElementOrMessage = BID_USE_MESSAGE;

 			this.alias = MessagepropertiesFactory.eINSTANCE.createPropertyAlias();

 		}

 		else  {

 			if (alias.getMessageType() != null) {

-				typeElementOrMessage = BID_USE_MESSAGE;

-				message = (Message)alias.getMessageType();

-				messagePart = alias.getPart();

-				messageQuery = alias.getQuery();

+				this.typeElementOrMessage = BID_USE_MESSAGE;

+				this.message = (Message)alias.getMessageType();

+				this.messagePart = alias.getPart();

+				this.messageQuery = alias.getQuery();

 			}

 			else if (alias.getType() != null) {

-				typeElementOrMessage = BID_USE_TYPE;

-				xsdTypeDefinition = (XSDTypeDefinition)alias.getType();

-				xsdTypeQuery = alias.getQuery();

+				this.typeElementOrMessage = BID_USE_TYPE;

+				this.xsdTypeDefinition = (XSDTypeDefinition)alias.getType();

+				this.xsdTypeQuery = alias.getQuery();

 			}

 			else if (alias.getXSDElement() != null) {

-				typeElementOrMessage = BID_USE_ELEMENT;

-				xsdElementDeclaration = (XSDElementDeclaration)alias.getXSDElement();

-				xsdElementQuery = alias.getQuery();

+				this.typeElementOrMessage = BID_USE_ELEMENT;

+				this.xsdElementDeclaration = (XSDElementDeclaration)alias.getXSDElement();

+				this.xsdElementQuery = alias.getQuery();

 			}

 		}

 	}

@@ -213,225 +182,225 @@
 				updateEnablement();

 			}

 		};

-		

+

 		// create widgets

 		String groupText = Messages.EditMessagePropertyDialog_10;

 		// PropertyAlias must have either XSD Type or XSD Element or (message type and part): create radio button group

 		Group typeElementOrMessageRadioGroup = new Group(composite,SWT.SHADOW_ETCHED_IN);

 		typeElementOrMessageRadioGroup.setText(groupText);

 		layout = new GridLayout();

-		layout.makeColumnsEqualWidth = true;		

-		layout.numColumns = 1;		

+		layout.makeColumnsEqualWidth = true;

+		layout.numColumns = 1;

 		typeElementOrMessageRadioGroup.setLayout(layout);

-		messageRadio = createRadioButton(typeElementOrMessageRadioGroup,Messages.EditMessagePropertyDialog_13, BID_USE_MESSAGE, typeElementOrMessage == BID_USE_MESSAGE);

-		typeRadio = createRadioButton(typeElementOrMessageRadioGroup,Messages.EditMessagePropertyDialog_11, BID_USE_TYPE, typeElementOrMessage == BID_USE_TYPE);

-		elementRadio = createRadioButton(typeElementOrMessageRadioGroup,Messages.EditMessagePropertyDialog_12, BID_USE_ELEMENT, typeElementOrMessage == BID_USE_ELEMENT);

-		messageRadio.addListener(SWT.Selection, enablementListener);

-		typeRadio.addListener(SWT.Selection, enablementListener);

-		elementRadio.addListener(SWT.Selection, enablementListener);

+		this.messageRadio = createRadioButton(typeElementOrMessageRadioGroup,Messages.EditMessagePropertyDialog_13, BID_USE_MESSAGE, this.typeElementOrMessage == BID_USE_MESSAGE);

+		this.typeRadio = createRadioButton(typeElementOrMessageRadioGroup,Messages.EditMessagePropertyDialog_11, BID_USE_TYPE, this.typeElementOrMessage == BID_USE_TYPE);

+		this.elementRadio = createRadioButton(typeElementOrMessageRadioGroup,Messages.EditMessagePropertyDialog_12, BID_USE_ELEMENT, this.typeElementOrMessage == BID_USE_ELEMENT);

+		this.messageRadio.addListener(SWT.Selection, enablementListener);

+		this.typeRadio.addListener(SWT.Selection, enablementListener);

+		this.elementRadio.addListener(SWT.Selection, enablementListener);

 

 		// type label and text

-		typeElementOrMessageNameLabel = new Label(composite, SWT.NONE);

-		typeElementOrMessageNameText = new Label(composite, SWT.NONE);

-		browseTypeButton = new Button(composite, SWT.PUSH);

-		browseTypeButton.setText(Messages.EditMessagePropertyDialog_18); 

-		browseTypeButton.addListener(SWT.Selection, new Listener() {

+		this.typeElementOrMessageNameLabel = new Label(composite, SWT.NONE);

+		this.typeElementOrMessageNameText = new Label(composite, SWT.NONE);

+		this.browseTypeButton = new Button(composite, SWT.PUSH);

+		this.browseTypeButton.setText(Messages.EditMessagePropertyDialog_18);

+		this.browseTypeButton.addListener(SWT.Selection, new Listener() {

 			public void handleEvent(Event event) {

 				browsePropertyType();

 			}

 		});

 

-		

+

 		// layout widgets

 		GridData data;

-		

-		queryEditor = new QueryEditor();

+

+		this.queryEditor = new QueryEditor();

 		Group queryGroup = new Group(composite,SWT.SHADOW_ETCHED_IN);

 		queryGroup.setText("Query");

 		layout = new GridLayout();

-		layout.makeColumnsEqualWidth = true;		

-		layout.numColumns = 1;		

+		layout.makeColumnsEqualWidth = true;

+		layout.numColumns = 1;

 		queryGroup.setLayout(layout);

 		data = new GridData(GridData.FILL_BOTH);

 		data.horizontalSpan = 3;

 		queryGroup.setLayoutData(data);

-		queryEditor.create(queryGroup);

-		

+		this.queryEditor.createControls( queryGroup, null );

+

 		data = new GridData(GridData.FILL_BOTH);

 		data.horizontalSpan = 3;

 //		data.widthHint = convertHorizontalDLUsToPixels(IDialogConstants.MINIMUM_MESSAGE_AREA_WIDTH);

 //		topLabel.setLayoutData(data);

 		typeElementOrMessageRadioGroup.setLayoutData(data);

 		data = new GridData(GridData.FILL_HORIZONTAL);

-		messageRadio.setLayoutData(data);

+		this.messageRadio.setLayoutData(data);

 		data = new GridData(GridData.FILL_HORIZONTAL);

-		typeRadio.setLayoutData(data);

+		this.typeRadio.setLayoutData(data);

 		data = new GridData(GridData.FILL_HORIZONTAL);

-		elementRadio.setLayoutData(data);

-		

+		this.elementRadio.setLayoutData(data);

+

 		data = new GridData(GridData.HORIZONTAL_ALIGN_BEGINNING);

-		typeElementOrMessageNameLabel.setLayoutData(data);

+		this.typeElementOrMessageNameLabel.setLayoutData(data);

 		data = new GridData(GridData.HORIZONTAL_ALIGN_BEGINNING | GridData.FILL_HORIZONTAL);

-		typeElementOrMessageNameText.setLayoutData(data);

+		this.typeElementOrMessageNameText.setLayoutData(data);

 		data = new GridData(GridData.HORIZONTAL_ALIGN_END);

-		browseTypeButton.setLayoutData(data);

+		this.browseTypeButton.setLayoutData(data);

 

 		// update widgets

 		updateWidgets();

-		

+

 		PlatformUI.getWorkbench().getHelpSystem().setHelp(

-			parent, IHelpContextIds.PROPERTY_ALIAS_DIALOG);	

-		

+			parent, IHelpContextIds.PROPERTY_ALIAS_DIALOG);

+

 		composite.pack();

-		

+

 		return composite;

 	}

-	

+

 	protected Button createRadioButton(Composite parent, String label, int id, boolean checked) {

-		

+

 		Button button = new Button(parent,SWT.RADIO);

 		button.setText(label);

 		button.setFont(JFaceResources.getDialogFont());

-		button.setData( Integer.valueOf( id ));		

+		button.setData( Integer.valueOf( id ));

 		button.setSelection( checked );

-		

+

 		button.addSelectionListener (new SelectionAdapter() {

 			@Override

 			public void widgetSelected (SelectionEvent event) {

 				Button b = (Button) event.widget;

 				int val = ((Integer) b.getData()).intValue();

-				

+

 				buttonPressed(val, b.getSelection(), true );

 			}

 		});

-		

+

 		return button;

-	

+

 	}

 

 	/**

 	 * Handle the check button and radio button callbacks.

-	 * 

+	 *

 	 * @param id

 	 * @param checked

 	 * @param refresh unless this is set, no refresh is done.

 	 */

-	

+

 	protected void buttonPressed(int id, boolean checked, boolean bRefresh) {

-				

+

 		switch (id) {

-		

+

 		case BID_USE_ELEMENT:

 		case BID_USE_TYPE:

 		case BID_USE_MESSAGE:

 			if (!checked)

 				return;

-			typeElementOrMessage = id;

+			this.typeElementOrMessage = id;

 			break;

-		

-		default : 			

+

+		default :

 			break;

 		}

-	

-	

+

+

 		if (bRefresh) {

 			updateWidgets();

 		}

 	}

 

 	protected void updateWidgets() {

-		String s = queryEditor.getQuery();

-		if (s!=null && activeQuery!=null) {

-			activeQuery.setValue(s);

-			activeQuery.setQueryLanguage(queryEditor.getQueryLanguage());

-		}

-		

-		if (typeElementOrMessage == BID_USE_TYPE) {

-			typeRadio.setSelection(true);

-			elementRadio.setSelection(false);

-			messageRadio.setSelection(false);

-			activeTypeElementOrMessage = xsdTypeDefinition;

-			if (xsdTypeQuery == null) {

-				xsdTypeQuery = MessagepropertiesFactory.eINSTANCE.createQuery();

-			}

-			activeQuery = xsdTypeQuery;

-			typeElementOrMessageNameLabel.setText(Messages.EditMessagePropertyDialog_Type_1);

-			

-			alias.setMessageType(null);

-			alias.setPart(null);

-			alias.setType(xsdTypeDefinition);

-			alias.setXSDElement(null);

-		}

-		else if (typeElementOrMessage == BID_USE_ELEMENT) {

-			typeRadio.setSelection(false);

-			elementRadio.setSelection(true);

-			messageRadio.setSelection(false);

-			activeTypeElementOrMessage = xsdElementDeclaration;

-			if (xsdElementQuery == null) {

-				xsdElementQuery = MessagepropertiesFactory.eINSTANCE.createQuery();

-			}

-			activeQuery = xsdElementQuery;

-			typeElementOrMessageNameLabel.setText(Messages.EditMessagePropertyDialog_Element_1);

+//		String s = this.queryEditor.getQuery();

+//		if (s!=null && this.activeQuery!=null) {

+//			this.activeQuery.setValue(s);

+//			this.activeQuery.setQueryLanguage(this.queryEditor.getQueryLanguage());

+//		}

 

-			alias.setMessageType(null);

-			alias.setPart(null);

-			alias.setType(null);

-			alias.setXSDElement(xsdElementDeclaration);

-		}

-		else if (typeElementOrMessage == BID_USE_MESSAGE) {

-			typeRadio.setSelection(false);

-			elementRadio.setSelection(false);

-			messageRadio.setSelection(true);

-			activeTypeElementOrMessage = message;

-			if (messageQuery == null) {

-				messageQuery = MessagepropertiesFactory.eINSTANCE.createQuery();

+		if (this.typeElementOrMessage == BID_USE_TYPE) {

+			this.typeRadio.setSelection(true);

+			this.elementRadio.setSelection(false);

+			this.messageRadio.setSelection(false);

+			this.activeTypeElementOrMessage = this.xsdTypeDefinition;

+			if (this.xsdTypeQuery == null) {

+				this.xsdTypeQuery = MessagepropertiesFactory.eINSTANCE.createQuery();

 			}

-			activeQuery = messageQuery;

-			typeElementOrMessageNameLabel.setText(Messages.EditMessagePropertyDialog_Message_1);

+			this.activeQuery = this.xsdTypeQuery;

+			this.typeElementOrMessageNameLabel.setText(Messages.EditMessagePropertyDialog_Type_1);

 

-			alias.setMessageType(message);

-			alias.setPart(messagePart);

-			alias.setType(null);

-			alias.setXSDElement(null);

+			this.alias.setMessageType(null);

+			this.alias.setPart(null);

+			this.alias.setType(this.xsdTypeDefinition);

+			this.alias.setXSDElement(null);

 		}

-		alias.setQuery(activeQuery);

-		queryEditor.setInput(alias);

+		else if (this.typeElementOrMessage == BID_USE_ELEMENT) {

+			this.typeRadio.setSelection(false);

+			this.elementRadio.setSelection(true);

+			this.messageRadio.setSelection(false);

+			this.activeTypeElementOrMessage = this.xsdElementDeclaration;

+			if (this.xsdElementQuery == null) {

+				this.xsdElementQuery = MessagepropertiesFactory.eINSTANCE.createQuery();

+			}

+			this.activeQuery = this.xsdElementQuery;

+			this.typeElementOrMessageNameLabel.setText(Messages.EditMessagePropertyDialog_Element_1);

+

+			this.alias.setMessageType(null);

+			this.alias.setPart(null);

+			this.alias.setType(null);

+			this.alias.setXSDElement(this.xsdElementDeclaration);

+		}

+		else if (this.typeElementOrMessage == BID_USE_MESSAGE) {

+			this.typeRadio.setSelection(false);

+			this.elementRadio.setSelection(false);

+			this.messageRadio.setSelection(true);

+			this.activeTypeElementOrMessage = this.message;

+			if (this.messageQuery == null) {

+				this.messageQuery = MessagepropertiesFactory.eINSTANCE.createQuery();

+			}

+			this.activeQuery = this.messageQuery;

+			this.typeElementOrMessageNameLabel.setText(Messages.EditMessagePropertyDialog_Message_1);

+

+			this.alias.setMessageType(this.message);

+			this.alias.setPart(this.messagePart);

+			this.alias.setType(null);

+			this.alias.setXSDElement(null);

+		}

+		this.alias.setQuery(this.activeQuery);

+		this.queryEditor.setInput(this.alias);

 

 		updateTypeElementOrMessageName();

 		updateEnablement();

 	}

-	

+

 	protected void updateTypeElementOrMessageName() {

-		if (activeTypeElementOrMessage instanceof XSDTypeDefinition) {

-			xsdTypeDefinition = (XSDTypeDefinition) activeTypeElementOrMessage;

-			xsdTypeQuery = activeQuery;

-			typeElementOrMessageNameText.setText(xsdTypeDefinition.getName());

-		} else if (activeTypeElementOrMessage instanceof XSDElementDeclaration) {

-			xsdElementDeclaration = (XSDElementDeclaration) activeTypeElementOrMessage;

-			xsdElementQuery = activeQuery;

-			typeElementOrMessageNameText.setText(xsdElementDeclaration.getName());

-		} else if (activeTypeElementOrMessage instanceof Message) {

-			message = (Message) activeTypeElementOrMessage;

-			String s = message.getQName().getLocalPart();

-			messageQuery = activeQuery;

-			if (messagePart!=null) {

-				s += "." + messagePart;

+		if (this.activeTypeElementOrMessage instanceof XSDTypeDefinition) {

+			this.xsdTypeDefinition = (XSDTypeDefinition) this.activeTypeElementOrMessage;

+			this.xsdTypeQuery = this.activeQuery;

+			this.typeElementOrMessageNameText.setText(this.xsdTypeDefinition.getName());

+		} else if (this.activeTypeElementOrMessage instanceof XSDElementDeclaration) {

+			this.xsdElementDeclaration = (XSDElementDeclaration) this.activeTypeElementOrMessage;

+			this.xsdElementQuery = this.activeQuery;

+			this.typeElementOrMessageNameText.setText(this.xsdElementDeclaration.getName());

+		} else if (this.activeTypeElementOrMessage instanceof Message) {

+			this.message = (Message) this.activeTypeElementOrMessage;

+			String s = this.message.getQName().getLocalPart();

+			this.messageQuery = this.activeQuery;

+			if (this.messagePart!=null) {

+				s += "." + this.messagePart;

 			}

-			typeElementOrMessageNameText.setText(s);

+			this.typeElementOrMessageNameText.setText(s);

 		}

 		else

 		{

-			typeElementOrMessageNameText.setText("");

+			this.typeElementOrMessageNameText.setText("");

 		}

 	}

 

 	@Override

 	protected void configureShell(Shell newShell) {

 		super.configureShell(newShell);

-		if (isNew) {

-			newShell.setText(Messages.EditPropertyAliasDialog_9); 

+		if (this.isNew) {

+			newShell.setText(Messages.EditPropertyAliasDialog_9);

 		} else {

-			newShell.setText(Messages.EditPropertyAliasDialog_10); 

+			newShell.setText(Messages.EditPropertyAliasDialog_10);

 		}

 	}

 

@@ -440,48 +409,49 @@
 	 * Updates the property type according to the user choice.

 	 */

 	protected void browsePropertyType() {

-		

+

 		Object type = null;

 		Object part = null;

 		Object query = null;

 		Object result[] = null;

-		if (typeElementOrMessage == BID_USE_TYPE)

-			result = BrowseUtil.browseForXSDType(bpelEditor.getProcess(), getShell());

-		else if (typeElementOrMessage == BID_USE_ELEMENT)

-			result = BrowseUtil.browseForXSDElement(bpelEditor.getProcess(), getShell(), true);

+		if (this.typeElementOrMessage == BID_USE_TYPE)

+			result = BrowseUtil.browseForXSDType(this.bpelEditor.getProcess(), getShell());

+		else if (this.typeElementOrMessage == BID_USE_ELEMENT)

+			result = BrowseUtil.browseForXSDElement(this.bpelEditor.getProcess(), getShell(), true);

 		else {

-			result = BrowseUtil.browseForMessageType(bpelEditor.getProcess(), getShell(), true);

+			result = BrowseUtil.browseForMessageType(this.bpelEditor.getProcess(), getShell(), true);

 		}

 		if (result!=null) {

 			if (result.length>=1) {

-				

+

 				type = result[0];

 				int index = 1;

 				if (type instanceof Message) {

-					message = (Message) type;

+					this.message = (Message) type;

 					if (result.length>=2 && result[1] instanceof Part) {

 						part = ((Part)result[1]).getName();

 						index = 2;

 					}

 				}

-				

+

 				// build the query string

 				// NOTE: The namespace for the XSD type may be different from the message namespace

 				// e.g. the message is defined in a WSDL and the XSD type is defined in externally

 				// with a different namespace.

-				Definition definition = property.getEnclosingDefinition();

+				Definition definition = this.property.getEnclosingDefinition();

 				if (definition==null) {

-					IFile targetFile = bpelEditor.getEditModelClient().getArtifactsResourceInfo().getFile();

-					URI uri = URI.createPlatformResourceURI(targetFile.getFullPath().toString());

-					Resource resource = bpelEditor.getResourceSet().getResource(uri, true);

+					IFile targetFile = this.bpelEditor.getEditModelClient().getArtifactsResourceInfo().getFile();

+					URI uri = URI.createPlatformResourceURI( targetFile.getFullPath().toString(), true );

+					Resource resource = this.bpelEditor.getResourceSet().getResource(uri, true);

 					definition = (Definition) resource.getContents().get(0);

 				}

+

 				query = "";

 				while (index<result.length) {

 					if (result[index] instanceof XSDComponent) {

 						XSDNamedComponent nc = (XSDNamedComponent)result[index];

 						WSDLImportHelper.addImportAndNamespace(definition, nc.getSchema(),

-								bpelEditor.getEditModelClient().getPrimaryResourceInfo().getFile());

+								this.bpelEditor.getEditModelClient().getPrimaryResourceInfo().getFile());

 						String prefix = definition.getPrefix(nc.getTargetNamespace());

 						if (prefix!=null)

 							query = query + "/" + prefix + ":" + nc.getName();

@@ -491,65 +461,65 @@
 					++index;

 				}

 			}

-			

-			activeTypeElementOrMessage = (EObject)type;

+

+			this.activeTypeElementOrMessage = (EObject)type;

 			if (query!=null)

-				activeQuery.setValue(query.toString());

+				this.activeQuery.setValue(query.toString());

 			else

-				activeQuery.setValue("");

-			

-			if (typeElementOrMessage == BID_USE_TYPE) {

-				xsdTypeDefinition = (XSDTypeDefinition) type;

-				xsdTypeQuery = activeQuery;

+				this.activeQuery.setValue("");

+

+			if (this.typeElementOrMessage == BID_USE_TYPE) {

+				this.xsdTypeDefinition = (XSDTypeDefinition) type;

+				this.xsdTypeQuery = this.activeQuery;

 			}

-			else if (typeElementOrMessage == BID_USE_ELEMENT) {

-				xsdElementDeclaration = (XSDElementDeclaration) type;

-				xsdElementQuery = activeQuery;

+			else if (this.typeElementOrMessage == BID_USE_ELEMENT) {

+				this.xsdElementDeclaration = (XSDElementDeclaration) type;

+				this.xsdElementQuery = this.activeQuery;

 			}

 			else {

-				message = (Message)type;

+				this.message = (Message)type;

 				if (part!=null)

-					messagePart = part.toString();

-				messageQuery = activeQuery;

+					this.messagePart = part.toString();

+				this.messageQuery = this.activeQuery;

 			}

-			

+

 			// hack: don't fetch query from XPath Expression Editor

 			// because it will overwrite the currently selected element

-			activeQuery = null;

+			this.activeQuery = null;

 			updateWidgets();

 		}

 	}

-	

+

 	/**

 	 * @return Returns the alias.

 	 */

 	public PropertyAlias getPropertyAlias() {

-		return alias;

+		return this.alias;

 	}

 

 	@Override

 	protected void okPressed() {

-		alias.setPropertyName(property);

-		if (typeElementOrMessage == BID_USE_TYPE) {

-			alias.setType(xsdTypeDefinition);

-			if (xsdTypeQuery!=null && (xsdTypeQuery.getValue()==null || xsdTypeQuery.getValue().trim().equals("")) )

-				xsdTypeQuery = null;

-			alias.setQuery(xsdTypeQuery);

+		this.alias.setPropertyName(this.property);

+		if (this.typeElementOrMessage == BID_USE_TYPE) {

+			this.alias.setType(this.xsdTypeDefinition);

+			if (this.xsdTypeQuery!=null && (this.xsdTypeQuery.getValue()==null || this.xsdTypeQuery.getValue().trim().equals("")) )

+				this.xsdTypeQuery = null;

+			this.alias.setQuery(this.xsdTypeQuery);

 		}

-		else if (typeElementOrMessage == BID_USE_ELEMENT) {

-			alias.setXSDElement(xsdElementDeclaration);

-			if (xsdElementQuery!=null && (xsdElementQuery.getValue()==null || xsdElementQuery.getValue().trim().equals("")) )

-				xsdElementQuery = null;

-			alias.setQuery(xsdElementQuery);

+		else if (this.typeElementOrMessage == BID_USE_ELEMENT) {

+			this.alias.setXSDElement(this.xsdElementDeclaration);

+			if (this.xsdElementQuery!=null && (this.xsdElementQuery.getValue()==null || this.xsdElementQuery.getValue().trim().equals("")) )

+				this.xsdElementQuery = null;

+			this.alias.setQuery(this.xsdElementQuery);

 		}

 		else {

-			alias.setMessageType(message);

-			alias.setPart(messagePart);

-			if (messageQuery!=null && (messageQuery.getValue()==null || messageQuery.getValue().trim().equals("")) )

-				messageQuery = null;

-			alias.setQuery(messageQuery);

+			this.alias.setMessageType(this.message);

+			this.alias.setPart(this.messagePart);

+			if (this.messageQuery!=null && (this.messageQuery.getValue()==null || this.messageQuery.getValue().trim().equals("")) )

+				this.messageQuery = null;

+			this.alias.setQuery(this.messageQuery);

 		}

-		

+

 		super.okPressed();

 	}

 

diff --git a/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/editors/xpath/XPathTextEditor.java b/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/editors/xpath/XPathTextEditor.java
index 63be9f2..2301bc3 100644
--- a/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/editors/xpath/XPathTextEditor.java
+++ b/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/editors/xpath/XPathTextEditor.java
@@ -49,180 +49,178 @@
 

 /**

  * The XPath Text Editor.

- * 

- * A bunch of the code is borrowed from the Java Text Editor. 

- * 

+ *

+ * A bunch of the code is borrowed from the Java Text Editor.

+ *

  * @author Michal Chmielewski (michal.chmielewski@oracle.com)

  * @date Oct 26, 2006

  */

-

-

 public class XPathTextEditor extends TextEditor {

-	

+

 	/** The editor id, based on the name of our class */

 	public static final String XPATH_EDITOR_ID = XPathTextEditor.class.getName();

-	

+

 	/** Matchable character pairs */

 	protected final static char[] BRACKETS= { '(', ')', '[', ']' };

-	

+

 	/** The editor's bracket maTtcher */

 	protected XPathCharPairMatcher fBracketMatcher= new XPathCharPairMatcher(BRACKETS);

-	

+

 	/** The bracket inserter. */

-	BracketInserter fBracketInserter= new BracketInserter();	

-	

-	private ColorManager fColorManager;

-	

+	BracketInserter fBracketInserter= new BracketInserter();

+

+	private final ColorManager fColorManager;

+

 	IWhitespaceDetector fWhitespaceDetector = new XPathWhitespaceDetector();

 

 	VariablePickerAction fVariablePickerAction;

 

 	/** Decoration for the content assist */

 	private ControlDecoration decoration;

-	

+

 	/**

-	 * 

+	 *

 	 */

 	public XPathTextEditor() {

 		super();

-		fColorManager = new ColorManager();

-		

-		setSourceViewerConfiguration(new XPathSourceViewerConfiguration(fColorManager) ); 

+		this.fColorManager = new ColorManager();

+

+		setSourceViewerConfiguration(new XPathSourceViewerConfiguration(this.fColorManager) );

 	}

-	

+

 	/**

-	 * 

+	 *

 	 */

 	@Override

-	

+

 	protected void createActions() {

 		super.createActions();

-		

+

 		ResourceBundle bundle = ResourceBundle.getBundle("bpelexpression"); //$NON-NLS-1$

 		Action action = new ContentAssistAction(bundle, "ContentAssistProposal.", this);  //$NON-NLS-1$

 		String id = ITextEditorActionDefinitionIds.CONTENT_ASSIST_PROPOSALS;

 		action.setActionDefinitionId(id);

 		setAction("ContentAssistProposal", action);  //$NON-NLS-1$

 		markAsStateDependentAction("ContentAssistProposal", true); //$NON-NLS-1$

-		

 

-		

-		fVariablePickerAction = new VariablePickerAction(XPathEditorMessages.getBundleForConstructedKeys(), "Editor.VariablePicker.", this); //$NON-NLS-1$

+

+

+		this.fVariablePickerAction = new VariablePickerAction(XPathEditorMessages.getBundleForConstructedKeys(), "Editor.VariablePicker.", this); //$NON-NLS-1$

 		// action.setHelpContextId(IAbstractTextEditorHelpContextIds.GOTO_LINE_ACTION);

-		fVariablePickerAction.setActionDefinitionId(IXPathEditorActionDefinitionIds.VARIABLE_PICKER);

-		setAction(IXPathEditorActionConstants.VARIABLE_PICKER, fVariablePickerAction);

-		

-		

+		this.fVariablePickerAction.setActionDefinitionId(IXPathEditorActionDefinitionIds.VARIABLE_PICKER);

+		setAction(IXPathEditorActionConstants.VARIABLE_PICKER, this.fVariablePickerAction);

+

+

 	}

-	

-	

+

+

 	@Override

 	protected void doSetInput (IEditorInput input) throws CoreException {

-		

+

 		super.doSetInput(input);

-		

+

 		ExpressionContentAssistProcessor caproc = (ExpressionContentAssistProcessor)

 							this.getSourceViewerConfiguration().

 							getContentAssistant( this.getSourceViewer() ).

 							getContentAssistProcessor(IDocument.DEFAULT_CONTENT_TYPE);

-	

+

 		EObject eObj = (EObject) input.getAdapter(EObject.class);

-		

+

 		if (eObj != null) {

 			caproc.setModelObject( eObj );

 		}

-		

+

 		String expressionContext = (String) input.getAdapter(Integer.class);

 		if (expressionContext != null) {

 			caproc.setExpressionContext(expressionContext);

-			// 

-			if (fVariablePickerAction != null) {

-				fVariablePickerAction.setEnabled(expressionContext.indexOf(IEditorConstants.ET_JOIN) < 0);

+			//

+			if (this.fVariablePickerAction != null) {

+				this.fVariablePickerAction.setEnabled(expressionContext.indexOf(IEditorConstants.ET_JOIN) < 0);

 			}

 		}

-	}		

-	

+	}

+

 	/**

 	 * @see AbstractTextEditor#createPartControl(Composite)

 	 */

 	@Override

 	public void createPartControl(Composite parent) {

-		

+

 		super.createPartControl(parent);

-					

+

 		IPreferenceStore preferenceStore= getPreferenceStore();

 		boolean closeBrackets= preferenceStore.getBoolean(PreferenceConstants.EDITOR_CLOSE_BRACKETS);

 		boolean closeStrings= preferenceStore.getBoolean(PreferenceConstants.EDITOR_CLOSE_STRINGS);

-		

-		fBracketInserter.setCloseBracketsEnabled(closeBrackets);

-		fBracketInserter.setCloseStringsEnabled(closeStrings);

-		

+

+		this.fBracketInserter.setCloseBracketsEnabled(closeBrackets);

+		this.fBracketInserter.setCloseStringsEnabled(closeStrings);

+

 		ISourceViewer sourceViewer = getSourceViewer();

-		

+

 		if (sourceViewer instanceof ITextViewerExtension) {

-			((ITextViewerExtension) sourceViewer).prependVerifyKeyListener(fBracketInserter);

+			((ITextViewerExtension) sourceViewer).prependVerifyKeyListener(this.fBracketInserter);

 		}

-		

+

 	}

-	

-	

+

+

 	/**

 	 * @see org.eclipse.ui.texteditor.AbstractTextEditor#editorContextMenuAboutToShow(org.eclipse.jface.action.IMenuManager)

 	 * @since 3.1

 	 */

-	

+

 	@Override

 	protected void editorContextMenuAboutToShow(IMenuManager menu) {

-		

+

 		super.editorContextMenuAboutToShow(menu);

 

 		IAction variablePicker = getAction(IXPathEditorActionConstants.VARIABLE_PICKER);

 		menu.add( new Separator() );

 		menu.add( variablePicker );

-		

+

 //		menu.appendToGroup(IWorkbenchActionConstants.MB_ADDITIONS, new Separator(ITextEditorActionConstants.GROUP_SETTINGS));

 //		menu.appendToGroup(ITextEditorActionConstants.GROUP_SETTINGS, preferencesAction);

-//		

+//

 //		menu.appendToGroup(ITextEditorActionConstants.GROUP_SAVE, new Separator(ITextEditorActionConstants.GROUP_OPEN));

 //		MenuManager showInSubMenu= new MenuManager(getShowInMenuLabel());

 //		showInSubMenu.add(ContributionItemFactory.VIEWS_SHOW_IN.create(getEditorSite().getWorkbenchWindow()));

-//		menu.appendToGroup(ITextEditorActionConstants.GROUP_OPEN, showInSubMenu); 

+//		menu.appendToGroup(ITextEditorActionConstants.GROUP_OPEN, showInSubMenu);

 	}

 

 

 	/**

-	 * 

+	 *

 	 * @see org.eclipse.ui.texteditor.AbstractTextEditor#dispose()

 	 */

 	@Override

-	

-	public void dispose() 

+

+	public void dispose()

     {

-		fColorManager.dispose();

-		fBracketMatcher.dispose();

-		

+		this.fColorManager.dispose();

+		this.fBracketMatcher.dispose();

+

 		ISourceViewer sourceViewer= getSourceViewer();

 		if (sourceViewer instanceof ITextViewerExtension) {

-			((ITextViewerExtension) sourceViewer).removeVerifyKeyListener(fBracketInserter);

+			((ITextViewerExtension) sourceViewer).removeVerifyKeyListener(this.fBracketInserter);

 		}

-		

-		super.dispose();		

+

+		super.dispose();

 	}

 

-    

-	

-    

-   

-    

-    

+

+

+

+

+

+

     @Override

 	protected void configureSourceViewerDecorationSupport(SourceViewerDecorationSupport support) {

-		

-		support.setCharacterPairMatcher(fBracketMatcher);

+

+		support.setCharacterPairMatcher(this.fBracketMatcher);

 		support.setMatchingCharacterPainterPreferenceKeys(

-				PreferenceConstants.EDITOR_MATCHING_BRACKETS, 

+				PreferenceConstants.EDITOR_MATCHING_BRACKETS,

 				PreferenceConstants.EDITOR_MATCHING_BRACKETS_COLOR);

-		

+

 		super.configureSourceViewerDecorationSupport(support);

 	}

 

@@ -233,66 +231,66 @@
 		}

 		super.setPreferenceStore(store);

 	}

-	

-	

+

+

 	/**

 	 * @see AbstractTextEditor#handlePreferenceStoreChanged(PropertyChangeEvent)

 	 */

 	@Override

 	protected void handlePreferenceStoreChanged (PropertyChangeEvent event) {

-		

-		String p = event.getProperty();		

-		

+

+		String p = event.getProperty();

+

 		if (PreferenceConstants.EDITOR_CLOSE_BRACKETS.equals(p)) {

-			fBracketInserter.setCloseBracketsEnabled(getPreferenceStore().getBoolean(p));

-			return;	

+			this.fBracketInserter.setCloseBracketsEnabled(getPreferenceStore().getBoolean(p));

+			return;

 		}

 

 		if (PreferenceConstants.EDITOR_CLOSE_STRINGS.equals(p)) {

-			fBracketInserter.setCloseStringsEnabled(getPreferenceStore().getBoolean(p));

+			this.fBracketInserter.setCloseStringsEnabled(getPreferenceStore().getBoolean(p));

 			return;

 		}

-								

+

 		super.handlePreferenceStoreChanged(event);

 	}

-	

+

 	/**

 	 * Enable/disable content assist decoration

 	 * @param enabled

 	 */

 	public void setDecoration(boolean enabled) {

 		if (enabled){

-			decoration = new ControlDecoration(getSourceViewer().getTextWidget(), SWT.TOP | SWT.LEFT);

-			decoration.setMarginWidth(25);

-			decoration.setDescriptionText("Content Assist Available (Ctrl+Space)");

-			decoration.setShowOnlyOnFocus(true);

+			this.decoration = new ControlDecoration(getSourceViewer().getTextWidget(), SWT.TOP | SWT.LEFT);

+			this.decoration.setMarginWidth(25);

+			this.decoration.setDescriptionText("Content Assist Available (Ctrl+Space)");

+			this.decoration.setShowOnlyOnFocus(true);

 			FieldDecoration dec = FieldDecorationRegistry.getDefault().getFieldDecoration(FieldDecorationRegistry.DEC_CONTENT_PROPOSAL);

-			decoration.setImage(dec.getImage());

+			this.decoration.setImage(dec.getImage());

 		} else {

-			decoration.dispose();

+			this.decoration.dispose();

 		}

 	}

 

 	/*** Private Classes */

-	

+

 	class BracketInserter implements VerifyKeyListener  {

-		

+

 		private boolean fCloseBrackets = true;

-		private boolean fCloseStrings  = true;		

-		

+		private boolean fCloseStrings  = true;

+

 		/**

 		 * @param enabled

 		 */

 		public void setCloseBracketsEnabled(boolean enabled) {

-			fCloseBrackets= enabled;

+			this.fCloseBrackets= enabled;

 		}

 

 		/**

 		 * @param enabled

 		 */

 		public void setCloseStringsEnabled(boolean enabled) {

-			fCloseStrings= enabled ;

-			

+			this.fCloseStrings= enabled ;

+

 		}

 

 		private boolean hasIdentifierToTheRight(IDocument document, int offset) {

@@ -300,7 +298,7 @@
 				int end= offset;

 				IRegion endLine= document.getLineInformationOfOffset(end);

 				int maxEnd= endLine.getOffset() + endLine.getLength();

-				while (end != maxEnd &&  fWhitespaceDetector.isWhitespace(document.getChar(end)))

+				while (end != maxEnd &&  XPathTextEditor.this.fWhitespaceDetector.isWhitespace(document.getChar(end)))

 					++end;

 

 				return end != maxEnd && Character.isJavaIdentifierPart(document.getChar(end));

@@ -316,14 +314,14 @@
 				int start= offset;

 				IRegion startLine= document.getLineInformationOfOffset(start);

 				int minStart= startLine.getOffset();

-				while (start != minStart && fWhitespaceDetector.isWhitespace(document.getChar(start - 1)))

+				while (start != minStart && XPathTextEditor.this.fWhitespaceDetector.isWhitespace(document.getChar(start - 1)))

 					--start;

-				

+

 				return start != minStart && Character.isJavaIdentifierPart(document.getChar(start - 1));

 

 			} catch (BadLocationException e) {

 				return true;

-			}			

+			}

 		}

 

 		private boolean hasCharacterToTheRight(IDocument document, int offset, char character) {

@@ -331,41 +329,41 @@
 				int end= offset;

 				IRegion endLine= document.getLineInformationOfOffset(end);

 				int maxEnd= endLine.getOffset() + endLine.getLength();

-				while (end != maxEnd && fWhitespaceDetector.isWhitespace(document.getChar(end)))

+				while (end != maxEnd && XPathTextEditor.this.fWhitespaceDetector.isWhitespace(document.getChar(end)))

 					++end;

-				

+

 				return end != maxEnd && document.getChar(end) == character;

 

 

 			} catch (BadLocationException e) {

 				// be conservative

 				return true;

-			}			

+			}

 		}

 

 

-		

+

 		private boolean hasCharacterAtOffset (IDocument document, int offset, char character) {

 			try {

 				return document.getChar(offset) == character ;

 			} catch (BadLocationException e) {

 				return false;

-			}		

+			}

 		}

 

-		

+

 		/**

 		 *  (non-Javadoc)

 		 * @see org.eclipse.swt.custom.VerifyKeyListener#verifyKey(org.eclipse.swt.events.VerifyEvent)

 		 */

-		

+

 		@SuppressWarnings("fallthrough")

-		public void verifyKey(VerifyEvent event) {			

+		public void verifyKey(VerifyEvent event) {

 

 			if (!event.doit || getInsertMode() != SMART_INSERT) {

 				return;

 			}

-				

+

 			ISourceViewer sourceViewer = getSourceViewer();

 			IDocument document= sourceViewer.getDocument();

 

@@ -374,21 +372,21 @@
 			final int length= selection.y;

 

 			switch (event.character) {

-			

+

 			case ']' :

-				if (!fCloseBrackets) {

+				if (!this.fCloseBrackets) {

 					return ;

 				}

 				// Fall through

-				

-			case ')':				

+

+			case ')':

 				if (hasCharacterAtOffset(document, offset + length, event.character ) ) {

 					sourceViewer.setSelectedRange(offset + length + 1,0);

 					event.doit = false;

 					return ;

 				}

-				break; 				

-				

+				break;

+

 			case '(':

 				if (hasCharacterToTheRight(document, offset + length, '('))

 					return;

@@ -396,60 +394,60 @@
 				// fall through

 

 			case '[':

-					if (!fCloseBrackets)

+					if (!this.fCloseBrackets)

 						return;

 					if (hasIdentifierToTheRight(document, offset + length))

 						return;

-			

+

 				// fall through

-			

+

 			case '\'':

 				if (event.character == '\'') {

-					if (!fCloseStrings)

+					if (!this.fCloseStrings)

 						return;

-					

+

 					if ( hasCharacterAtOffset(document,offset-1,'\\')) {

 						return ;

-					}					

+					}

 

-					if ( hasCharacterAtOffset(document,offset + length,'\'') ) { 

+					if ( hasCharacterAtOffset(document,offset + length,'\'') ) {

 						sourceViewer.setSelectedRange(offset + length + 1,0);

 						event.doit = false;

 						return ;

 					}

-					

+

 					if (hasIdentifierToTheLeft(document, offset) || hasIdentifierToTheRight(document, offset + length)) {

 						return;

-					}					

+					}

 				}

-				

+

 				// fall through

 

 			case '"':

 				if (event.character == '"') {

-					if (!fCloseStrings)

+					if (!this.fCloseStrings)

 						return;

-					

+

 					if ( hasCharacterAtOffset(document,offset-1,'\\')) {

 						return ;

-					}					

-					if ( hasCharacterAtOffset(document,offset+length,'"') ) {																

-						sourceViewer.setSelectedRange(offset+length+1,0);	

+					}

+					if ( hasCharacterAtOffset(document,offset+length,'"') ) {

+						sourceViewer.setSelectedRange(offset+length+1,0);

 						event.doit = false;

 						return ;

 					}

-					

+

 					if (hasIdentifierToTheLeft(document, offset) || hasIdentifierToTheRight(document, offset + length))

 						return;

-					

+

 				}

-				

-				try {		

+

+				try {

 //					ITypedRegion partition= TextUtilities.getPartition(document, IJavaPartitions.JAVA_PARTITIONING, offset, true);

 ////					if (! IDocument.DEFAULT_CONTENT_TYPE.equals(partition.getType()) && partition.getOffset() != offset)

 //					if (! IDocument.DEFAULT_CONTENT_TYPE.equals(partition.getType()))

 //						return;

-//						

+//

 					if (!validateEditorInputState()) {

 						return ;

 					}

@@ -459,25 +457,25 @@
 					buffer.append( getPeerCharacter(event.character) );

 

 					document.replace(offset, length, buffer.toString());

-					

+

 					// move to the right of the inserted element

 					sourceViewer.setSelectedRange(offset+1,0);

-					

-//					

+

+//

 //					BracketLevel level= new BracketLevel();

 //					fBracketLevelStack.push(level);

-//					

-//					LinkedPositionGroup group= new LinkedPositionGroup(); 

+//

+//					LinkedPositionGroup group= new LinkedPositionGroup();

 //					group.addPosition(new LinkedPosition(document, offset + 1, 0, LinkedPositionGroup.NO_STOP));

 //

 //					LinkedModeModel model= new LinkedModeModel();

 //					model.addLinkingListener(this);

 //					model.addGroup(group);

 //					model.forceInstall();

-//					

+//

 //					level.fOffset= offset;

 //					level.fLength= 2;

-//			

+//

 //					// set up position tracking for our magic peers

 //					if (fBracketLevelStack.size() == 1) {

 //						document.addPositionCategory(CATEGORY);

@@ -487,18 +485,18 @@
 //					level.fSecondPosition= new Position(offset + 1, 1);

 //					document.addPosition(CATEGORY, level.fFirstPosition);

 //					document.addPosition(CATEGORY, level.fSecondPosition);

-//					

+//

 //					level.fUI= new EditorLinkedModeUI(model, sourceViewer);

 //					level.fUI.setSimpleMode(true);

 //					level.fUI.setExitPolicy(new ExitPolicy(closingCharacter, getEscapeCharacter(closingCharacter), fBracketLevelStack));

 //					level.fUI.setExitPosition(sourceViewer, offset + 2, 0, Integer.MAX_VALUE);

 //					level.fUI.setCyclingMode(LinkedModeUI.CYCLE_NEVER);

 //					level.fUI.enter();

-//					

-//					

+//

+//

 //					IRegion newSelection= level.fUI.getSelectedRegion();

 					// sourceViewer.setSelectedRange(newSelection.getOffset(), newSelection.getLength());

-	

+

 					event.doit= false;

 

 				} catch (BadLocationException e) {

@@ -507,11 +505,11 @@
 //					catch (BadPositionCategoryException e) {

 //					BPELUIPlugin.log(e);

 //				}

-				break;	

+				break;

 			}

 		}

 	}

-	

+

 	static char getEscapeCharacter (char character) {

 		switch (character) {

 			case '"':

@@ -521,31 +519,31 @@
 				return 0;

 		}

 	}

-	

+

 	static char getPeerCharacter(char character) {

 		switch (character) {

 			case '(':

 				return ')';

-				

+

 			case ')':

 				return '(';

-				

+

 			case '[':

 				return ']';

-				

+

 			case '"':

 				return character;

-				

+

 			case '\'':

 				return character;

-			

+

 			default:

 				throw new IllegalArgumentException();

-		}					

+		}

 	}

 

 	public void addFocusListener(FocusListener focusListener) {

 		getSourceViewer().getTextWidget().addFocusListener(focusListener);

 	}

-	

+

 }

diff --git a/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/expressions/AbstractExpressionEditor.java b/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/expressions/AbstractExpressionEditor.java
deleted file mode 100644
index 96e82bf..0000000
--- a/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/expressions/AbstractExpressionEditor.java
+++ /dev/null
@@ -1,164 +0,0 @@
-/*******************************************************************************

- * Copyright (c) 2005, 2012 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 Corporation - initial API and implementation

- *******************************************************************************/

-package org.eclipse.bpel.ui.expressions;

-

-import java.util.ArrayList;

-import java.util.List;

-

-import org.eclipse.bpel.common.ui.composite.EditorInViewManager;

-import org.eclipse.bpel.ui.BPELUIPlugin;

-import org.eclipse.bpel.ui.IBPELUIConstants;

-import org.eclipse.bpel.ui.commands.CompoundCommand;

-import org.eclipse.core.runtime.CoreException;

-import org.eclipse.swt.widgets.Composite;

-import org.eclipse.ui.IEditorInput;

-import org.eclipse.ui.IEditorPart;

-import org.eclipse.ui.IViewPart;

-import org.eclipse.ui.IWorkbench;

-import org.eclipse.ui.IWorkbenchPage;

-import org.eclipse.ui.PartInitException;

-import org.eclipse.ui.PlatformUI;

-import org.eclipse.ui.forms.widgets.FormToolkit;

-

-/**

- * @author IBM Original Contribution.

- * @author Michal Chmielewski (michal.chmielewski@oracle.com)

- * @date Jul 16, 2007

- *

- */

-public abstract class AbstractExpressionEditor implements IExpressionEditor {

-

-	protected List<Listener> listeners = new ArrayList<Listener>();

-

-	protected EditorInViewManager fManager;

-

-	/** The underlying model object */

-	private Object fModelObject;

-	

-	/** a {@link FormToolkit} to use */

-	protected FormToolkit wf;

-	

-	/** The expression type */

-	private String fExprType ;

-

-	/**

-	 * @see org.eclipse.bpel.ui.expressions.IExpressionEditor#createControls(org.eclipse.swt.widgets.Composite,

-	 *      org.eclipse.bpel.ui.properties.BPELPropertySection)

-	 */

-	public void createControls(Composite parent, FormToolkit toolkit) {

-		this.wf = toolkit;

-	}

-

-	/**

-	 * @see org.eclipse.bpel.ui.expressions.IExpressionEditor#addListener(org.eclipse.bpel.ui.expressions.IExpressionEditor.Listener)

-	 */

-	public void addListener(Listener listener) {

-		listeners.add(listener);

-	}

-

-	/**

-	 * @see org.eclipse.bpel.ui.expressions.IExpressionEditor#removeListener(org.eclipse.bpel.ui.expressions.IExpressionEditor.Listener)

-	 */

-

-	public void removeListener(Listener listener) {

-		listeners.remove(listener);

-	}

-

-	protected void notifyChanged() {

-		for (Listener next : listeners) {

-			next.notifyChanged();

-		}

-	}

-	

-	protected void notifyFocusOut() {

-		for (Listener next : listeners) {

-			next.focusOut();

-		}

-	}

-	

-	/**

-	 * @see org.eclipse.bpel.ui.expressions.IExpressionEditor#getEditorContent()

-	 * 

-	 * 

-	 */

-	public abstract String getEditorContent() ;

-

-	

-	/**

-	 * @see org.eclipse.bpel.ui.expressions.IExpressionEditor#setEditorContent(java.lang.String)

-	 */

-	public abstract void setEditorContent (String body) ;

-

-	

-	protected void refresh() {

-

-	}

-

-	/**

-	 * @see org.eclipse.bpel.ui.expressions.IExpressionEditor#addExtraStoreCommands(org.eclipse.gef.commands.CompoundCommand)

-	 */

-	public void addExtraStoreCommands(CompoundCommand compoundCommand) {

-		// Default is to do nothing.

-	}

-

-	protected IEditorPart createEditor(String editorID, IEditorInput input,

-			Composite parent) {

-		try {

-			return getEditorManager().createEditor(editorID, input, parent);

-		} catch (CoreException e) {

-			BPELUIPlugin.log(e);

-		}

-		return null;

-	}

-

-	protected EditorInViewManager getEditorManager() {

-		if (fManager == null) {

-			IWorkbench workbench = PlatformUI.getWorkbench();

-			IWorkbenchPage page = workbench.getActiveWorkbenchWindow()

-					.getActivePage();

-			IViewPart view = page.findView(IBPELUIConstants.PROPERTY_VIEW_ID);

-			try {

-				if (view == null) {

-					view = page.showView(IBPELUIConstants.PROPERTY_VIEW_ID);

-				}

-				fManager = new EditorInViewManager(view.getViewSite());

-			} catch (PartInitException e) {

-				BPELUIPlugin.log(e);

-			}

-		}

-		return fManager;

-	}

-

-	/**

-	 * @see org.eclipse.bpel.ui.expressions.IExpressionEditor#setExpressionType(java.lang.String)

-	 */

-

-	public void setExpressionType (String exprType ) {

-		this.fExprType = exprType;		

-	}

-

-	/**

-	 * @see org.eclipse.bpel.ui.expressions.IExpressionEditor#setModelObject(java.lang.Object)

-	 */

-	public void setModelObject(Object modelObject) {

-		this.fModelObject = modelObject;

-	}

-

-

-	protected String getExprType() {

-		return fExprType;

-	}

-

-	protected Object getModelObject() {

-		return fModelObject;

-	}

-

-}

diff --git a/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/expressions/DefaultExpressionEditor.java b/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/expressions/DefaultExpressionEditor.java
deleted file mode 100644
index 89d9219..0000000
--- a/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/expressions/DefaultExpressionEditor.java
+++ /dev/null
@@ -1,230 +0,0 @@
-/*******************************************************************************

- * Copyright (c) 2005, 2012 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 Corporation - initial API and implementation

- *******************************************************************************/

-package org.eclipse.bpel.ui.expressions;

-

-import org.eclipse.bpel.ui.editors.TextEditor;

-import org.eclipse.bpel.ui.editors.TextEditorInput;

-import org.eclipse.core.resources.IMarker;

-import org.eclipse.swt.SWT;

-import org.eclipse.swt.events.FocusAdapter;

-import org.eclipse.swt.events.FocusEvent;

-import org.eclipse.swt.events.FocusListener;

-import org.eclipse.swt.layout.FillLayout;

-import org.eclipse.swt.widgets.Composite;

-import org.eclipse.ui.IEditorInput;

-import org.eclipse.ui.IEditorPart;

-import org.eclipse.ui.IPropertyListener;

-import org.eclipse.ui.forms.widgets.FormToolkit;

-

-

-/**

- * When an editor is not found for a given expression language this

- * default editor is used instead.

- * 

- * TODO: reconcile differences between this class and XPathExpressionEditor ?

- */

-public class DefaultExpressionEditor extends AbstractExpressionEditor {

-

-	protected Composite editorComposite;

-	protected TextEditor editor;

-	protected IPropertyListener propertyListener;

-	protected String undoRedoLabel;

-	protected String fBody;

-	protected boolean updating = false;

-	protected FocusListener focusListener;

-	

-	/**

-	 * 

-	 * @see org.eclipse.bpel.ui.expressions.AbstractExpressionEditor#getEditorContent()

-	 */

-	

-	@Override

-	public String getEditorContent() {

-		if (editor != null) {

-			return editor.getContents();

-		}

-		return fBody;

-	}

-

-	

-	/**

-	 * 

-	 * @see org.eclipse.bpel.ui.expressions.AbstractExpressionEditor#createControls(org.eclipse.swt.widgets.Composite, org.eclipse.bpel.ui.properties.BPELPropertySection)

-	 */

-	

-	@Override

-	public void createControls(Composite parent, FormToolkit toolkit) {

-		super.createControls(parent, toolkit);

-		createEditor(parent);

-	}

-

-	/**

-	 * (non-Javadoc)

-	 * @see org.eclipse.bpel.ui.expressions.AbstractExpressionEditor#setEditorContent(java.lang.String)

-	 */

-	

-	@Override

-	public void setEditorContent (String aBody) {

-	    this.fBody = aBody;

-	    	    

-	    try {

-	    	updating = true;

-	    	

-	    	if (editor != null) {

-	    		editor.setInput(new TextEditorInput( fBody, getModelObject(), getExprType() ));

-	    	}

-	    	

-	    } finally {

-	    	updating = false;

-	    }

-	}

-	

-	protected void createEditor(Composite parent) {

-		IEditorInput input = new TextEditorInput( fBody, getModelObject(), getExprType() );

-		

-		

-		editorComposite = wf.createComposite(parent, SWT.BORDER);

-		editorComposite.setLayout( new FillLayout() );		

-		editor = (TextEditor) createEditor(TextEditor.TEXT_EDITOR_ID, 

-				input, 

-				editorComposite);

-	}

-

-	/** (non-Javadoc)

-	 * @see org.eclipse.bpel.ui.expressions.IExpressionEditor#dispose()

-	 */

-	

-	public void dispose() {

-		disposeEditor();

-	}

-	

-	protected void disposeEditor() {

-		

-		if (editor != null) {

-			getEditorManager().disposeEditor(editor);

-			if (editorComposite != null && !editorComposite.isDisposed()) {				

-				editorComposite.dispose();

-				editorComposite = null;

-			}

-			editor = null;

-		}

-	}

-

-	/**

-	 *  About to be Hidden.

-	 */

-	

-	public void aboutToBeHidden() {

-		if (editor != null) {

-			editor.removePropertyListener(getPropertyListener());

-			editor.removeFocusListener(getFocusListener());

-		}

-	}

-

-	

-	/** 

-	 * Editor is about to be shown.

-	 * @see org.eclipse.bpel.ui.expressions.IExpressionEditor#aboutToBeShown()

-	 */

-	

-	public void aboutToBeShown() {		

-		if (editor != null) {

-			editor.addPropertyListener(getPropertyListener());

-			editor.addFocusListener(getFocusListener());

-		}					

-	}

-

-	/**

-	 * If the editor is dirty it registers an ongoing change.

-	 */

-	protected IPropertyListener getPropertyListener() {

-		

-		if (propertyListener == null) {

-			propertyListener = new IPropertyListener() {

-				public void propertyChanged(Object source, int propId) {

-					if (!updating && propId == IEditorPart.PROP_DIRTY && editor.isDirty()) {

-						notifyChanged();

-					}

-				}

-			};

-		}

-		return propertyListener;

-	}

-

-	protected FocusListener getFocusListener() {

-		if (focusListener == null){

-			focusListener = new FocusAdapter(){

-			public void focusLost(FocusEvent e) {

-				notifyFocusOut();

-			}

-		};}

-		return focusListener;

-	}

-	

-	/**

-	 * Get the user context to remember for next invocation.

-	 * 

-	 * @see org.eclipse.bpel.ui.expressions.IExpressionEditor#getUserContext()

-	 */

-	public Object getUserContext() {

-		return null;

-	}

-

-	/**

-	 * Restore the user context.

-	 * 

-	 * @see org.eclipse.bpel.ui.expressions.IExpressionEditor#restoreUserContext(java.lang.Object)

-	 */

-	

-	public void restoreUserContext(Object userContext) {

-		editor.setFocus();

-	}

-

-	 

-	/**

-	 * Return the default body for this type of expression. Since the editor is not aware of any syntax

-	 * for any particular language, the empty string is returned.

-	 * @see org.eclipse.bpel.ui.expressions.IExpressionEditor#getDefaultContent()

-	 */

-	public String getDefaultContent() {

-		return ""; //$NON-NLS-1$

-	}

-	

-	/** (non-Javadoc)

-	 * @see org.eclipse.bpel.ui.expressions.IExpressionEditor#gotoTextMarker(org.eclipse.core.resources.IMarker, java.lang.String, java.lang.Object)

-	 */

-	public void gotoTextMarker(IMarker marker, String codeType, Object modelObject) {

-		// TODO: Goto text marker in default text editor.

-	}

-

-	

-	/** 

-	 * Answer true, because a generic text editor will simply do everything.

-	 * 

-	 * @see org.eclipse.bpel.ui.expressions.IExpressionEditor#supportsExpressionType(java.lang.String)

-	 */

-	

-	public boolean supportsExpressionType( String exprType ) {

-		return true;

-	}

-	

-	

-	/**

-	 * Mark it clean.

-	 * @see org.eclipse.bpel.ui.expressions.IExpressionEditor#markAsClean()

-	 */

-	

-	public void markAsClean() {

-		if (editor != null) {

-			editor.markAsClean();

-		}

-	}

-}

diff --git a/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/expressions/IExpressionEditor.java b/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/expressions/IExpressionEditor.java
deleted file mode 100644
index 835635b..0000000
--- a/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/expressions/IExpressionEditor.java
+++ /dev/null
@@ -1,156 +0,0 @@
-/*******************************************************************************

- * Copyright (c) 2005, 2012 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 Corporation - initial API and implementation

- *******************************************************************************/

-package org.eclipse.bpel.ui.expressions;

-

-import org.eclipse.bpel.ui.commands.CompoundCommand;

-import org.eclipse.bpel.ui.properties.BPELPropertySection;

-import org.eclipse.core.resources.IMarker;

-import org.eclipse.swt.widgets.Composite;

-import org.eclipse.ui.forms.widgets.FormToolkit;

-

-

-/**

- * @author IBM Original Contribution.

- * @author Michal Chmielewski (michal.chmielewski@oracle.com)

- * @date Jul 16, 2007

- *

- */

-public interface IExpressionEditor {

-	

-	/**

-	 * Goto the text marker indicated.

-	 * 

-	 * @param marker the marker

-	 * @param codeType code type

-	 * @param modelObject the model object

-	 */

-	public void gotoTextMarker(IMarker marker, String codeType, Object modelObject);

-

-	/**

-	 * Creates the editor widgets.

-	 * @param parent the parent composite

-	 * @param tk a {@link FormToolkit}, retrieved for example from the host {@link BPELPropertySection}

-	 */

-	void createControls(Composite parent, FormToolkit tk);

-

-	/**

-	 * Dispose of the editor.

-	 */

-	

-	void dispose();

-

-	/**

-	 * Notifies the editor that its controls are about to be hidden.

-	 */

-	void aboutToBeHidden();

-

-	/**

-	 * Notifies the editor that its controls are about to be shown.

-	 * Any widget state could be updated at this point.

-	 */

-	void aboutToBeShown();

-	

-	/**

-	 * This method is used just like IDetailsSection.getUserContext().

-	 * @return the user context 	 

-	 */

-	Object getUserContext();

-	

-	/**

-	 * This method is used just like IDetailsSection.restoreUserContext().

-	 * @param userContext the user context 

-	 * 

-	 */

-	void restoreUserContext (Object userContext);

-	

-	/**

-	 * Return the editor content

-	 * @return return the body of the edited expression 

-	 */

-	String getEditorContent ();

-	

-	/**

-	 * Set the editor content

-	 * @param body the content of the editor.

-	 */

-	void setEditorContent (String body);

-	

-	/**

-	 * Add a listener

-	 * 

-	 * @param listener the listener to add.

-	 */

-	void addListener(Listener listener);

-	

-	/**

-	 * Remove a listener.

-	 * @param listener the listener to remove.

-	 */

-	void removeListener(Listener listener);

-	

-	/**

-	 * The listener interface. 

-	 */

-	

-	public static interface Listener {

-		/**

-		 * Notify that we have changed.

-		 */

-		public void notifyChanged();

-		public void focusOut();

-		public void focusIn();

-	}

-	

-	/**

-	 * Allow the editor to modify 

-	 * @param compoundCommand

-	 */

-	void addExtraStoreCommands(CompoundCommand compoundCommand);

-	

-	/**

-	 * Get the default body.

-	 * @return the default body 

-	 */

-	

-	public String getDefaultContent ();	

-	

-	/**

-	 * Returns true if this editor supports this expression type.

-	 * 

-	 * @param exprType the expression type.

-	 * @return true if the expression type is supported.

-	 */

-	boolean supportsExpressionType(String exprType);

-	

-	/**

-	 * Informs the editor of the expression type it will be editing.

-	 * The supportsExpressionType() method will always be called first to make sure

-	 * the editor actually supports this exprType combination.

-	 * @param exprType the expression type

-	 */

-	void setExpressionType ( String exprType );

-

-	/**

-	 * Informs the editor of the underlying model object in which this expression

-	 * will be stored.  The model object's type and relationship to other objects

-	 * may depend on the expression type and context provided above (for example: the

-	 * model for a transition condition is a Link, but the model for a join condition

-	 * is an Activity). 

-	 * 

-	 * @param modelObject 

-	 */

-	void setModelObject (Object modelObject);

-	

-	/**

-	 * Tells the editor to consider itself clean.

-	 */

-	void markAsClean();

-}

diff --git a/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/expressions/XPathExpressionEditor.java b/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/expressions/XPathExpressionEditor.java
deleted file mode 100644
index 3536708..0000000
--- a/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/expressions/XPathExpressionEditor.java
+++ /dev/null
@@ -1,649 +0,0 @@
-/*******************************************************************************

- * Copyright (c) 2005, 2012 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 Corporation - initial API and implementation

- *******************************************************************************/

-package org.eclipse.bpel.ui.expressions;

-

-import org.eclipse.bpel.common.ui.details.IDetailsAreaConstants;

-import org.eclipse.bpel.fnmeta.model.Function;

-import org.eclipse.bpel.model.util.BPELConstants;

-import org.eclipse.bpel.model.util.BPELUtils;

-import org.eclipse.bpel.ui.BPELUIPlugin;

-import org.eclipse.bpel.ui.IBPELUIConstants;

-import org.eclipse.bpel.ui.IHelpContextIds;

-import org.eclipse.bpel.ui.Messages;

-import org.eclipse.bpel.ui.commands.CompoundCommand;

-import org.eclipse.bpel.ui.commands.SetNamespaceMappingCommand;

-import org.eclipse.bpel.ui.editors.TextEditorInput;

-import org.eclipse.bpel.ui.editors.xpath.XPathTextEditor;

-import org.eclipse.bpel.ui.properties.BPELPropertySection;

-import org.eclipse.bpel.ui.properties.DateTimeSelector;

-import org.eclipse.bpel.ui.properties.DurationSelector;

-import org.eclipse.bpel.ui.util.BPELDateTimeHelpers;

-import org.eclipse.bpel.ui.util.BPELUtil;

-import org.eclipse.core.resources.IMarker;

-import org.eclipse.emf.ecore.EObject;

-import org.eclipse.swt.SWT;

-import org.eclipse.swt.custom.StackLayout;

-import org.eclipse.swt.events.FocusAdapter;

-import org.eclipse.swt.events.FocusEvent;

-import org.eclipse.swt.events.FocusListener;

-import org.eclipse.swt.events.SelectionEvent;

-import org.eclipse.swt.events.SelectionListener;

-import org.eclipse.swt.layout.FillLayout;

-import org.eclipse.swt.layout.FormAttachment;

-import org.eclipse.swt.layout.FormData;

-import org.eclipse.swt.layout.FormLayout;

-import org.eclipse.swt.widgets.Combo;

-import org.eclipse.swt.widgets.Composite;

-import org.eclipse.swt.widgets.Label;

-import org.eclipse.swt.widgets.Layout;

-import org.eclipse.ui.IEditorPart;

-import org.eclipse.ui.IPropertyListener;

-import org.eclipse.ui.PlatformUI;

-import org.eclipse.ui.forms.widgets.FormToolkit;

-

-

-/**

- * Expression language editor for XPath.

- */

-@SuppressWarnings("nls")

-public class XPathExpressionEditor extends AbstractExpressionEditor {

-

-	static final String BOOLEAN_EXPR_DEFAULT = "true()"; //$NON-NLS-1$

-	static final String UNSIGNED_INT_EXPR_DEFAULT = "1"; //$NON-NLS-1$

-	

-	static final String TEXT_STRING = Messages.XPathExpressionEditor_Text_0,

-			LITERAL_STRING = Messages.XPathExpressionEditor_Literal_1;

-

-	static final int TEXT = 0, LITERAL = 1;

-

-	protected static final String DEFAULT_DURATION_VALUE = "\'P0D\'"; //$NON-NLS-1$

-

-	protected Combo combo; // Expression type values

-

-	protected Label comboLabel; // Expression type

-

-	protected Composite mainComposite; // high level composite control

-

-	protected XPathTextEditor textEditor; // expression text

-

-	/** The date/time  selector, alternative to just plain text */

-	protected DateTimeSelector dateTimeSelector;

-

-	/** The duration selector, alternative to just plain text */

-	protected DurationSelector durationSelector;

-

-	protected IPropertyListener propertyListener;

-

-

-	/** This composite holds a stack of editors, only the top one is shown */

-	protected Composite editorComposite;

-

-	/** The text editor composite, a child control of the editorComposite */

-	protected Composite textEditorComposite;

-

-	/** The duration editor composite, a child control of the editorComposiste */

-	protected Composite durationEditorComposite;

-

-	/** The date time editor composite, a child control of the editorComposiste */

-	protected Composite dateTimeEditorComposite;

-

-	// private int comboValue = -1;

-

-	/** The input to the text editor. */

-	protected TextEditorInput textEditorInput;

-	

-	private FocusListener focusListener;

-

-	/**

-	 * Create a brand new shiny XPathExpressionEditor ...

-	 */

-

-	public XPathExpressionEditor() {

-		super();

-	}

-

-	/**

-	 * Create controls ..

-	 */

-	@Override

-	public void createControls(Composite parent, FormToolkit toolkit) {

-		super.createControls(parent, toolkit);

-		createEditor(parent);

-	}

-

-	protected void createEditor(Composite parent) {

-

-		this.mainComposite = wf.createComposite( parent );

-		FormLayout layout = new FormLayout();

-		layout.marginWidth = layout.marginHeight = 0;

-		mainComposite.setLayout(layout);

-		mainComposite.setBackground(BPELUIPlugin.INSTANCE.getColorRegistry()

-				.get(IBPELUIConstants.COLOR_WHITE));

-		comboLabel = wf.createLabel(mainComposite,

-				Messages.XPathExpressionEditor_Expression_Type_2);

-

-		combo = new Combo(mainComposite, SWT.BORDER | SWT.READ_ONLY | SWT.FLAT);

-

-		combo.add(TEXT_STRING);

-		combo.add(LITERAL_STRING);

-

-		combo.addSelectionListener(new SelectionListener() {

-			public void widgetSelected(SelectionEvent e) {

-				updateEditorToType(combo.getSelectionIndex());

-			}

-

-			public void widgetDefaultSelected(SelectionEvent e) {

-			}

-		});

-

-		FormData data = new FormData();

-		data.top = new FormAttachment(combo, 0, SWT.CENTER);

-		data.left = new FormAttachment(0, 0);

-		data.right = new FormAttachment(combo,	-IDetailsAreaConstants.HSPACE);

-		comboLabel.setLayoutData(data);

-

-		data = new FormData();

-		data.top = new FormAttachment(0, IDetailsAreaConstants.VSPACE );

-		data.left = new FormAttachment(0, BPELUtil.calculateLabelWidth(

-				comboLabel, BPELPropertySection.STANDARD_LABEL_WIDTH_LRG));

-		data.right = new FormAttachment(100, 0);

-		combo.setLayoutData(data);

-

-		// Create the editor composite

-		// The editor composite will contain one of N editors.

-		// We use stack layout, because only one editor is visible at a time.

-

-		editorComposite = wf.createComposite(mainComposite);

-		editorComposite.setLayout(new StackLayout());

-

-		data = new FormData();

-		data.top = new FormAttachment(combo,2 * IDetailsAreaConstants.VSPACE);

-		data.left = new FormAttachment(0, 5);

-		data.right = new FormAttachment(100, 0);

-		data.bottom = new FormAttachment(100, 0);

-		editorComposite.setLayoutData(data);

-	}

-

-	protected void rearrangeComboAndEditorComposite() {

-

-		boolean comboVisible = isLiteralType();

-

-		combo.setVisible(comboVisible);

-		comboLabel.setVisible(comboVisible);

-

-		if (editorComposite != null) {

-			FormData data = (FormData) editorComposite.getLayoutData();

-			if (comboVisible) {

-				data.top = new FormAttachment(combo,

-						2 * IDetailsAreaConstants.VSPACE);

-			} else {

-				data.top = new FormAttachment(0,

-						2 * IDetailsAreaConstants.VSPACE);

-			}

-		}

-

-	}

-

-	/**

-	 * Gets the text editor composite, creates it if necessary and makes it

-	 * visible by default.

-	 * 

-	 * @return the composite for the text editor ...

-	 */

-

-	Composite getTextEditorComposite() {

-				

-		if (textEditorComposite != null) {

-			return textEditorComposite;

-		}

-

-				

-		textEditorComposite = wf.createComposite(editorComposite,SWT.BORDER);

-		textEditorComposite.setLayout(new FillLayout());

-		textEditor = (XPathTextEditor) createEditor(

-				XPathTextEditor.XPATH_EDITOR_ID,

-				this.textEditorInput, 

-				textEditorComposite);

-

-		textEditor.addPropertyListener(getPropertyListener());

-		textEditor.addFocusListener(getFocusListener());

-		textEditor.setDecoration(true);

-		

-		return textEditorComposite;

-	}

-

-	protected FocusListener getFocusListener() {

-		if (focusListener == null){

-			focusListener = new FocusAdapter(){

-			public void focusLost(FocusEvent e) {

-				notifyFocusOut();

-			}

-		};}

-		return focusListener;

-	}

-

-	Composite getDateTimeEditor() {

-		if (dateTimeEditorComposite != null) {

-			return dateTimeEditorComposite;

-		}

-

-		dateTimeEditorComposite = wf.createComposite(editorComposite, SWT.NONE);

-

-		FormLayout layout = new FormLayout();

-		layout.marginWidth = layout.marginHeight = 0;

-		dateTimeEditorComposite.setLayout(layout);

-

-		Label label = wf.createLabel(dateTimeEditorComposite,

-				Messages.XPathExpressionEditor_Date_Time_UTC_3);

-		dateTimeSelector = new DateTimeSelector(wf, dateTimeEditorComposite,

-				SWT.NONE, BPELDateTimeHelpers.yearMin,

-				BPELDateTimeHelpers.yearMax);

-

-		String body = (String) textEditorInput.getAdapter(String.class);

-

-		int[] dateTime = BPELDateTimeHelpers.parseXPathDateTime(body, false);

-		dateTimeSelector.setValues(dateTime);

-

-		FormData data = new FormData();

-		data.top = new FormAttachment(0, 10);

-		data.left = new FormAttachment(0, 0);

-		data.right = new FormAttachment(dateTimeSelector,

-				-IDetailsAreaConstants.HSPACE);

-		label.setLayoutData(data);

-

-		data = new FormData();

-		data.top = new FormAttachment(0, 10);

-		data.left = new FormAttachment(0, BPELUtil.calculateLabelWidth(

-				label, BPELPropertySection.STANDARD_LABEL_WIDTH_LRG));

-		// data.right = new FormAttachment(100, 0);

-		dateTimeSelector.setLayoutData(data);

-

-		dateTimeSelector.addSelectionListener(  new SelectionListener() {

-			public void widgetSelected(SelectionEvent e) {

-				// Push new values to the text editor document so that

-				// it is reflected next time we shift

-				// to the text editor.

-				

-				if (textEditorInput != null) {

-					int[] values = dateTimeSelector.getValues();         		        

-					textEditorInput.setEditorContent ( BPELDateTimeHelpers.createXPathDateTime(values, false) , getModelObject() );

-				}

-				notifyChanged();

-			}

-

-			public void widgetDefaultSelected(SelectionEvent e) {

-			}

-		});	

-

-		PlatformUI.getWorkbench().getHelpSystem().setHelp(

-				dateTimeEditorComposite,

-				IHelpContextIds.XPATH_DATE);

-

-		return dateTimeEditorComposite;

-	}

-

-	/**

-	 * Get or create the duration editor.

-	 * 

-	 * @return

-	 */

-

-	Composite getDurationEditor() {

-		

-		if (durationEditorComposite != null) {			

-			return durationEditorComposite;

-		}

-		

-	    durationEditorComposite = wf.createComposite(editorComposite, SWT.NONE);

-	    FormLayout layout = new FormLayout();

-	    layout.marginWidth = layout.marginHeight = 0;

-	    durationEditorComposite.setLayout(layout);

-	    

-	    Label label = wf.createLabel(durationEditorComposite, Messages.XPathExpressionEditor_Duration_4); 

-	    durationSelector = new DurationSelector(wf, durationEditorComposite, SWT.NONE);

-	    

-	    FormData data = new FormData();

-	    data.top = new FormAttachment(0, 10);

-	    data.left = new FormAttachment(0, 0);

-		data.right = new FormAttachment(durationSelector, -IDetailsAreaConstants.HSPACE);	    

-	    label.setLayoutData(data);

-

-	    data = new FormData();

-	    data.top = new FormAttachment(0, 10);

-		data.left = new FormAttachment(0, BPELUtil.calculateLabelWidth(label, BPELPropertySection.STANDARD_LABEL_WIDTH_LRG));

-		// data.right = new FormAttachment(100, 0);

-		durationSelector.setLayoutData(data);

-

-	    durationSelector.addSelectionListener( new SelectionListener() {	    	

-			public void widgetSelected(SelectionEvent e) {

-			 	

-				// Push new values to the text editor document so that

-				// it is reflected next time we shift

-				// to the text editor.

-				

-				if (textEditorInput != null) {

-					int[] duration = durationSelector.getValues();         		        

-					textEditorInput.setEditorContent( BPELDateTimeHelpers.createXPathDuration(duration) , getModelObject() );

-				}

-			

-			 }

-			 public void widgetDefaultSelected(SelectionEvent e) { }

-	    });

-	    

-	    PlatformUI.getWorkbench().getHelpSystem().setHelp(

-	    		durationEditorComposite, IHelpContextIds.XPATH_DURATION);

-	    

-	    return durationEditorComposite;

-	}

-

-	/**

-	 * (non-Javadoc)

-	 * 

-	 * @see org.eclipse.bpel.ui.expressions.IExpressionEditor#dispose()

-	 */

-

-	public void dispose() {

-

-		if (textEditor != null) {

-			getEditorManager().disposeEditor(textEditor);

-			textEditor = null;

-		}

-

-		// This is the main composite of all the editors.

-		if (editorComposite != null && !editorComposite.isDisposed()) {

-			editorComposite.dispose();

-			editorComposite = null;

-		}

-	}

-

-	/**

-	 * This is called from a number of places and we have to be smart to not

-	 * create and re-create the editors every time refresh is called.

-	 * 

-	 */

-

-	@Override

-	public void refresh() {

-

-		int editorType = combo.getSelectionIndex();

-

-		if (editorType < 0) {

-			String body = (String) textEditorInput.getAdapter(String.class);

-

-			// TODO: try literal widgets!

-			editorType = TEXT;

-			if (BPELDateTimeHelpers.parseXPathDuration(body) != null) {

-				editorType = LITERAL;

-			} else if (BPELDateTimeHelpers.parseXPathDateTime(body, false) != null) {

-				editorType = LITERAL;

-			}

-			// update the editor type

-			combo.select(editorType);

-		}

-

-		updateEditorToType(editorType);

-	}

-

-	/**

-	 * Update the editor to the right type.

-	 * 

-	 * @param editorType

-	 */

-

-	void updateEditorToType(int editorType) {

-

-		String body = (String) textEditorInput.getAdapter(String.class);

-

-		switch (editorType) {

-		case TEXT:

-			restackEditorComposite(getTextEditorComposite());

-			break;

-		case LITERAL:

-			if (IEditorConstants.ET_DURATION.equals(getExprType())) {

-				restackEditorComposite(getDurationEditor());

-

-				int[] duration = BPELDateTimeHelpers.parseXPathDuration(body);

-				if (duration != null) {

-					durationSelector.setValues(duration);

-				}

-			} else {

-

-				restackEditorComposite(getDateTimeEditor());

-

-				int[] dateTime = BPELDateTimeHelpers.parseXPathDateTime(body,

-						false);

-				if (dateTime != null) {

-					dateTimeSelector.setValues(dateTime);

-				}

-			}

-			break;

-		}

-	}

-

-	/**

-	 * We re-stack the editors and have stack layout only show the top child

-	 * control.

-	 * 

-	 * @param c

-	 *            the editor composite for one of our editors.

-	 */

-

-	void restackEditorComposite(Composite c) {

-

-		Layout layout = c.getParent().getLayout();

-

-		if (layout instanceof StackLayout) {

-			StackLayout stackLayout = (StackLayout) layout;

-			if (c != stackLayout.topControl) {

-				stackLayout.topControl = c;

-

-				rearrangeComboAndEditorComposite();

-

-				c.getParent().layout(true);

-			}

-		}

-	}

-

-	/**

-	 * About to be hidden.

-	 */

-

-	public void aboutToBeHidden() {

-

-	}

-

-	/**

-	 * The editor is about to be shown.

-	 * 

-	 * @see org.eclipse.bpel.ui.expressions.IExpressionEditor#aboutToBeShown()

-	 */

-

-	public void aboutToBeShown() {

-		refresh();

-	}

-

-	/**

-	 * If the editor is dirty it registers an ongoing change.

-	 */

-	protected IPropertyListener getPropertyListener() {

-

-		if (propertyListener == null) {

-			propertyListener = new IPropertyListener() {

-				public void propertyChanged(Object source, int propId) {

-					if (propId == IEditorPart.PROP_DIRTY) {

-						boolean isEditorDirty = false;

-						if (textEditor != null) {

-							isEditorDirty = textEditor.isDirty();

-						}

-						if (isEditorDirty) {

-							notifyChanged();

-						}

-					}

-				}

-			};

-		}

-		return propertyListener;

-	}

-

-	/**

-	 * @see org.eclipse.bpel.ui.expressions.IExpressionEditor#getUserContext()

-	 */

-	public Object getUserContext() {

-		return null;

-	}

-

-	/**

-	 * @see org.eclipse.bpel.ui.expressions.IExpressionEditor#restoreUserContext(java.lang.Object)

-	 */

-	public void restoreUserContext(Object userContext) {

-

-		// TODO! this is bogus

-		if (textEditor != null) {

-			textEditor.setFocus();

-		}

-	}

-

-	/**

-	 * Return the body of the editor.

-	 * 

-	 * @see org.eclipse.bpel.ui.expressions.AbstractExpressionEditor#getEditorContent()

-	 */

-	@Override

-	public String getEditorContent() {

-

-		int editorType = combo.getSelectionIndex();

-

-		if (editorType == LITERAL) {

-			if (IEditorConstants.ET_DURATION.equals(getExprType())) {

-				int[] duration = durationSelector.getValues();

-				return BPELDateTimeHelpers.createXPathDuration(duration);

-			}

-			int[] dateTime = dateTimeSelector.getValues();

-			return BPELDateTimeHelpers.createXPathDateTime(dateTime, false);

-		}

-		return textEditor.getContents();

-	}

-

-	/**

-	 * @see org.eclipse.bpel.ui.expressions.AbstractExpressionEditor#setEditorContent(java.lang.String)

-	 */

-	@Override

-	public void setEditorContent (String body) {		

-		this.textEditorInput = new TextEditorInput(body, getModelObject(), getExprType() );

-		// Refresh the text editor input, if not set

-		if (textEditor != null) {

-			textEditor.setInput(this.textEditorInput);

-		}

-	}

-

-	/**

-	 * Answer if the editor edits literal type expressions. These have their own

-	 * editor UI to deal with that.

-	 * 

-	 * @return

-	 */

-

-	boolean isLiteralType() {

-		return IEditorConstants.ET_DURATION.equals(getExprType())

-				|| IEditorConstants.ET_DATETIME.equals(getExprType());

-	}

-

-	/**

-	 * Return the default body for the given edit UI type.

-	 * 

-	 * @return the default body to throw into the editor.

-	 */

-

-	public String getDefaultContent() {

-

-		if (isLiteralType()) {

-			return getDefaultBody(LITERAL);

-		}

-		return getDefaultBody(TEXT);

-	}

-

-	protected String getDefaultBody(int comboValue) {

-		String exprType = getExprType();

-		switch (comboValue) {

-		case TEXT: {

-			if (exprType.indexOf(IEditorConstants.ET_BOOLEAN) >= 0) {

-				return BOOLEAN_EXPR_DEFAULT;

-			} else if (exprType.indexOf(IEditorConstants.ET_UNSIGNED_INT) >= 0) {

-				return UNSIGNED_INT_EXPR_DEFAULT;

-			}

-			return ""; //$NON-NLS-1$

-		}

-		case LITERAL: {

-			if (exprType.indexOf(IEditorConstants.ET_DURATION) >= 0) {

-				return DEFAULT_DURATION_VALUE;

-			}

-			int[] dateTime = BPELDateTimeHelpers.getCurrentLocalDateTime();

-			BPELDateTimeHelpers.convertLocalToGMT(dateTime);

-			return BPELDateTimeHelpers.createXPathDateTime(dateTime, false);

-		}

-		}

-		return ""; //$NON-NLS-1$

-	}

-

-	/**

-	 * @see org.eclipse.bpel.ui.expressions.IExpressionEditor#gotoTextMarker(org.eclipse.core.resources.IMarker, java.lang.String, java.lang.Object)

-	 */

-	public void gotoTextMarker(IMarker marker, String codeType,

-			Object modelObject) {

-		// TODO

-	}

-

-	/**

-	 * @see org.eclipse.bpel.ui.expressions.IExpressionEditor#supportsExpressionType(java.lang.String)

-	 */

-	

-	public boolean supportsExpressionType ( String exprType ) {

-		return true;

-	}

-

-	/**

-	 * 

-	 * @see org.eclipse.bpel.ui.expressions.IExpressionEditor#markAsClean()

-	 */

-

-	public void markAsClean() {

-		if (textEditor != null) {

-			textEditor.markAsClean();

-		}

-	}

-

-	

-	/**

-	 * This is probably not the best place to do this, but we do need to do this someplace ...

-	 * 

-	 * @see org.eclipse.bpel.ui.expressions.AbstractExpressionEditor#addExtraStoreCommands(org.eclipse.gef.commands.CompoundCommand)

-	 */	

-	@Override

-	public void addExtraStoreCommands (CompoundCommand compoundCommand) {

-		

-		EObject eObj = (EObject) getModelObject();

-		

-		for(Function fn : Functions.getInstance(BPELConstants.XMLNS_XPATH_EXPRESSION_LANGUAGE_2007).getFunctions().values()) {

-			

-			if (BPELUtils.isEmptyOrWhitespace(fn.getNamespace()) || BPELConstants.XMLNS_XPATH_EXPRESSION_LANGUAGE.equals(fn.getNamespace())) {

-				continue;

-			}

-			

-			String pfx = BPELUtils.getNamespacePrefix( eObj, fn.getNamespace());

-			

-			if (pfx == null) {

-				compoundCommand.add(new SetNamespaceMappingCommand(eObj, fn.getNamespace(), fn.getPrefix() )) ;

-			}

-		}

-		

-	}

-

-}

diff --git a/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/extensions/BPELUIRegistry.java b/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/extensions/BPELUIRegistry.java
index cb760cb..7a9f377 100644
--- a/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/extensions/BPELUIRegistry.java
+++ b/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/extensions/BPELUIRegistry.java
@@ -11,25 +11,17 @@
 package org.eclipse.bpel.ui.extensions;

 

 import java.util.ArrayList;

-import java.util.HashMap;

 import java.util.List;

-import java.util.Map;

 

 import org.eclipse.bpel.ui.BPELUIPlugin;

-import org.eclipse.bpel.ui.IBPELUIConstants;

 import org.eclipse.bpel.ui.IHoverHelper;

-import org.eclipse.bpel.ui.Messages;

 import org.eclipse.bpel.ui.bpelactions.AbstractBPELAction;

-import org.eclipse.bpel.ui.expressions.DefaultExpressionEditor;

-import org.eclipse.bpel.ui.expressions.IExpressionEditor;

 import org.eclipse.bpel.ui.factories.AbstractUIObjectFactory;

 import org.eclipse.bpel.ui.util.BPELUtil;

 import org.eclipse.core.runtime.CoreException;

 import org.eclipse.core.runtime.IConfigurationElement;

 import org.eclipse.core.runtime.IExtensionPoint;

-import org.eclipse.core.runtime.IStatus;

 import org.eclipse.core.runtime.Platform;

-import org.eclipse.core.runtime.Status;

 import org.eclipse.emf.common.notify.AdapterFactory;

 import org.eclipse.emf.ecore.EClass;

 

@@ -41,7 +33,6 @@
 

 	static final String EXTPT_HOVERHELPERS = "hoverHelpers"; //$NON-NLS-1$

 	static final String ELEMENT_HOVERHELPER = "hoverHelper"; //$NON-NLS-1$

-	static final String EXTPT_EXPRESSION_EDITORS = "expressionEditors"; //$NON-NLS-1$

 	static final String ELEMENT_EDITOR = "editor"; //$NON-NLS-1$

 	static final String ATT_EXPRESSION_LANGUAGE = "expressionLanguage"; //$NON-NLS-1$

 	static final String ATT_CLASS = "class"; //$NON-NLS-1$

@@ -56,20 +47,16 @@
 	static final String ELEMENT_LISTENER = "listener"; //$NON-NLS-1$

 	static final String ATT_SPEC_COMPLIANT = "specCompliant"; //$NON-NLS-1$

 

-	static final ExpressionEditorDescriptor[] EMPTY_EDITOR_DESCRIPTORS = {};

-	

 	private static BPELUIRegistry instance;

 

-	private Map<String,ExpressionEditorDescriptor> fLanguageToEditorDescriptor;

 	private HoverHelperDescriptor hoverHelperDescriptor;

 	private ActionCategoryDescriptor[] fActionCategoryDescriptors;

 	private ActionDescriptor[] fActionDescriptors;

 	private ListenerDescriptor[] fListenerDescriptors;

 	private UIObjectFactoryDescriptor[] uiObjectFactoryDescriptor;

 	private IHoverHelper hoverHelper;

-	

+

 	private BPELUIRegistry() {

-		readExpressionLanguageEditors();

 		readHoverHelpers();

 		readActions();

 		readListeners();

@@ -79,7 +66,7 @@
 	/**

 	 * @return the singleton instance of this regitry.

 	 */

-	

+

 	public static BPELUIRegistry getInstance() {

 		if (instance == null) {

 			instance = new BPELUIRegistry();

@@ -87,131 +74,82 @@
 		return instance;

 	}

 

-	

+

 	/**

 	 * Return the hover helper.

 	 * @return the hover helper extension.

 	 * @throws CoreException

 	 */

 	public IHoverHelper getHoverHelper() throws CoreException {

-		

-		if (hoverHelperDescriptor == null) {

+

+		if (this.hoverHelperDescriptor == null) {

 			return null;

 		}

-		if (hoverHelper == null) {

-			hoverHelper = hoverHelperDescriptor.createHoverHelper();			

+		if (this.hoverHelper == null) {

+			this.hoverHelper = this.hoverHelperDescriptor.createHoverHelper();

 		}

-		return hoverHelper;		

-	}

-	

-	/**

-	 * Returns an expression editor for the given expression language.

-	 * @param expressionLanguage 

-	 * @return the IExpression editor for the given expression language.

-	 * @throws CoreException 

-	 */

-	public IExpressionEditor getExpressionEditor (String expressionLanguage) throws CoreException {

-		ExpressionEditorDescriptor descriptor = fLanguageToEditorDescriptor.get(expressionLanguage);

-		if (descriptor == null) {

-			return new DefaultExpressionEditor();

-		}

-		IExpressionEditor editor = descriptor.createEditor();

-		return editor;

-	}

-

-	/**

-	 * Returns an expression editor descriptor for the given expression language.

-	 * 

-	 * @param expressionLanguage 

-	 * @return the expression language descriptor for the given expression language.

-	 */

-	public ExpressionEditorDescriptor getExpressionEditorDescriptor(String expressionLanguage) {

-		return fLanguageToEditorDescriptor.get(expressionLanguage);

-	}

-

-	private void readExpressionLanguageEditors() {

-		fLanguageToEditorDescriptor = new HashMap<String,ExpressionEditorDescriptor>();

-		

-		for(IConfigurationElement editor : getConfigurationElements(EXTPT_EXPRESSION_EDITORS) ) {

-			

-			if (editor.getName().equals(ELEMENT_EDITOR)) {

-				String language = editor.getAttribute(ATT_EXPRESSION_LANGUAGE);

-				String clazz = editor.getAttribute(ATT_CLASS);

-				if (language == null || clazz == null) {

-					String pluginId = BPELUIPlugin.INSTANCE.getBundle().getSymbolicName(); 

-					IStatus status = new Status(IStatus.ERROR, pluginId, IBPELUIConstants.MISSING_ATTRIBUTE, Messages.BPELUIRegistry_Expression_language_editors_must_provide_expressionLanguage_and_class__8, null); 

-					BPELUIPlugin.INSTANCE.getLog().log(status);

-				} else {

-					ExpressionEditorDescriptor descriptor = new ExpressionEditorDescriptor();

-					descriptor.setExpressionLanguage(language);

-					descriptor.setElement(editor);

-					String label = editor.getAttribute(ATT_LABEL);

-					descriptor.setLabel(label);

-					fLanguageToEditorDescriptor.put(language, descriptor);

-				}

-			}

-		}

+		return this.hoverHelper;

 	}

 

     /**

      * Return the UIObjectFactory descriptors

      */

 	public UIObjectFactoryDescriptor[] getUIObjectFactoryDescriptors() {

-        return uiObjectFactoryDescriptor;

+        return this.uiObjectFactoryDescriptor;

     }

-	

+

 	/**

 	 * Return all action descriptors.

 	 * @return Return all action descriptors.

 	 */

 	public ActionDescriptor[] getActionDescriptors() {

-	    return fActionDescriptors;

+	    return this.fActionDescriptors;

 	}

-	

+

 	/**

 	 * Returns the ActionDescriptor for the given EClass.

-	 * @param target the target 

+	 * @param target the target

 	 * @return Returns the ActionDescriptor for the given EClass.

 	 */

 	public ActionDescriptor getActionDescriptor(EClass target) {

-		for(ActionDescriptor descriptor : fActionDescriptors ) {

+		for(ActionDescriptor descriptor : this.fActionDescriptors ) {

 			if (descriptor.getAction().getModelType() == target) {

 				return descriptor;

 			}

 		}

 	    return null;

 	}

-	

+

 	/**

 	 * @return the action category descriptors.

 	 */

 	public ActionCategoryDescriptor[] getActionCategoryDescriptors() {

-	    return fActionCategoryDescriptors;

+	    return this.fActionCategoryDescriptors;

 	}

-	

+

 	/**

 	 * @return the listener descriptors.

 	 */

 	public ListenerDescriptor[] getListenerDescriptors() {

-	    return fListenerDescriptors;

+	    return this.fListenerDescriptors;

 	}

-	

+

 	private void readHoverHelpers() {

-		

+

 		for (IConfigurationElement helper : getConfigurationElements(EXTPT_HOVERHELPERS) ) {

 			if (helper.getName().equals(ELEMENT_HOVERHELPER) == false) {

 				continue;

 			}

-			

+

 			String clazz = helper.getAttribute(ATT_CLASS);

 			if (clazz == null) {

 				continue;

 			}

-			

+

 			HoverHelperDescriptor descriptor = new HoverHelperDescriptor();

 			descriptor.setElement(helper);

 			this.hoverHelperDescriptor = descriptor;

-		}		

+		}

 	}

 

 	/**

@@ -220,9 +158,9 @@
 	private void readActions() {

 	    List<ActionCategoryDescriptor> categories = new ArrayList<ActionCategoryDescriptor>();

 	    List<ActionDescriptor> actions = new ArrayList<ActionDescriptor>();

-	    		

+

 		for (IConfigurationElement element : getConfigurationElements(EXTPT_ACTIONS)) {

-			

+

 			if (element.getName().equals(ELEMENT_CATEGORY)) {

 				String name = element.getAttribute(ATT_NAME);

 				String id = element.getAttribute(ATT_ID);

@@ -242,13 +180,13 @@
 					descriptor.setCategoryId(category);

 					descriptor.setSpecCompliant(Boolean.valueOf(specCompliant).booleanValue());

 					try {

-					    AbstractBPELAction action = (AbstractBPELAction)element.createExecutableExtension(ATT_CLASS);						

+					    AbstractBPELAction action = (AbstractBPELAction)element.createExecutableExtension(ATT_CLASS);

 						descriptor.setAction(action);

 					} catch (CoreException e) {

 						BPELUIPlugin.log(e);

 					}

 					actions.add(descriptor);

-					

+

 					// register AdapterFactory - since it has to be done only once we do it here

 					AdapterFactory factory = descriptor.getAction().getAdapterFactory();

 					if (factory != null) {

@@ -257,11 +195,11 @@
 				}

 			}

 		}

-		

-		fActionCategoryDescriptors = new ActionCategoryDescriptor[categories.size()];

-		categories.toArray(fActionCategoryDescriptors);

-		fActionDescriptors = new ActionDescriptor[actions.size()];

-		actions.toArray(fActionDescriptors);

+

+		this.fActionCategoryDescriptors = new ActionCategoryDescriptor[categories.size()];

+		categories.toArray(this.fActionCategoryDescriptors);

+		this.fActionDescriptors = new ActionDescriptor[actions.size()];

+		actions.toArray(this.fActionDescriptors);

 	}

 

     /**

@@ -271,8 +209,7 @@
 

     	List factories = new ArrayList();

         IConfigurationElement[] extensions = getConfigurationElements("uiObjectFactories");

-        for (int i = 0; i < extensions.length; i++) {

-            IConfigurationElement element = extensions[i];

+        for( IConfigurationElement element : extensions ) {

             if (element.getName().equals("factory")) {

                 String id = element.getAttribute(ATT_ID);

                 String category = element.getAttribute(ATT_CATEGORY_ID);

@@ -294,10 +231,10 @@
             }

         }

 

-        uiObjectFactoryDescriptor = new UIObjectFactoryDescriptor[factories.size()];

-        factories.toArray(uiObjectFactoryDescriptor);

+        this.uiObjectFactoryDescriptor = new UIObjectFactoryDescriptor[factories.size()];

+        factories.toArray(this.uiObjectFactoryDescriptor);

     }

-	

+

 	/**

 	 * Read all the model listeners

 	 */

@@ -320,9 +257,9 @@
 				}

 			}

 		}

-		

-		fListenerDescriptors = new ListenerDescriptor[listeners.size()];

-		listeners.toArray(fListenerDescriptors);

+

+		this.fListenerDescriptors = new ListenerDescriptor[listeners.size()];

+		listeners.toArray(this.fListenerDescriptors);

 	}

 

 	/**

@@ -330,17 +267,10 @@
 	 */

 	private IConfigurationElement[] getConfigurationElements(String extensionPointId) {

 		IExtensionPoint extensionPoint = Platform.getExtensionRegistry().getExtensionPoint(

-			BPELUIPlugin.PLUGIN_ID, extensionPointId); 

+			BPELUIPlugin.PLUGIN_ID, extensionPointId);

 		if (extensionPoint == null) {

 			return null;

 		}

 		return extensionPoint.getConfigurationElements();

 	}

-

-	/**

-	 * @return an array of ExpressionEditorDescriptor values.

-	 */

-	public ExpressionEditorDescriptor[] getExpressionEditorDescriptors() {

-		return fLanguageToEditorDescriptor.values().toArray( EMPTY_EDITOR_DESCRIPTORS );		

-	}

 }

diff --git a/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/extensions/ExpressionEditorDescriptor.java b/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/extensions/ExpressionEditorDescriptor.java
deleted file mode 100644
index 64bf7ec..0000000
--- a/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/extensions/ExpressionEditorDescriptor.java
+++ /dev/null
@@ -1,52 +0,0 @@
-/*******************************************************************************

- * Copyright (c) 2005, 2012 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 Corporation - initial API and implementation

- *******************************************************************************/

-package org.eclipse.bpel.ui.extensions;

-

-import org.eclipse.bpel.ui.expressions.IExpressionEditor;

-import org.eclipse.core.runtime.CoreException;

-import org.eclipse.core.runtime.IConfigurationElement;

-

-

-public class ExpressionEditorDescriptor {

-

-	protected String language;

-	protected String label;

-	protected IConfigurationElement element;

-

-	public IExpressionEditor createEditor() throws CoreException {

-		return (IExpressionEditor) element.createExecutableExtension(BPELUIRegistry.ATT_CLASS);

-	}

-

-	IConfigurationElement getElement() {

-		return element;

-	}

-

-	void setElement(IConfigurationElement element) {

-		this.element = element;

-	}

-

-	void setLabel(String label) {

-		this.label = label;

-	}

-

-	public String getExpressionLanguage() {

-		return language;

-	}

-

-	public String getLabel() {

-		return label;

-	}

-

-	void setExpressionLanguage(String language) {

-		this.language = language;

-	}

-

-}

diff --git a/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/preferences/ExpressionEditorsPreferencePage.java b/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/preferences/ExpressionEditorsPreferencePage.java
deleted file mode 100644
index 6d7d120..0000000
--- a/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/preferences/ExpressionEditorsPreferencePage.java
+++ /dev/null
@@ -1,59 +0,0 @@
-/*******************************************************************************

- * Copyright (c) 2008, 2012 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 Corporation - initial API and implementation

- *******************************************************************************/

-package org.eclipse.bpel.ui.preferences;

-

-import org.eclipse.jface.preference.*;

-import org.eclipse.ui.IWorkbenchPreferencePage;

-import org.eclipse.ui.IWorkbench;

-import org.eclipse.bpel.ui.BPELUIPlugin;

-import org.eclipse.bpel.ui.Messages;

-

-/**

- * This class represents a preference page that

- * is contributed to the Preferences dialog. By 

- * subclassing <samp>FieldEditorPreferencePage</samp>, we

- * can use the field support built into JFace that allows

- * us to create a page that is small and knows how to 

- * save, restore and apply itself.

- * <p>

- * This page is used to modify preferences only. They

- * are stored in the preference store that belongs to

- * the main plug-in class. That way, preferences can

- * be accessed directly via the preference store.

- */

-

-public class ExpressionEditorsPreferencePage

-	extends FieldEditorPreferencePage

-	implements IWorkbenchPreferencePage {

-

-	public ExpressionEditorsPreferencePage() {

-		super(GRID);

-		setPreferenceStore(BPELUIPlugin.INSTANCE.getPreferenceStore());

-		setDescription(Messages.BPELPreferencePage_ExpressionEditorPage_Description);

-	}

-	

-	/**

-	 * Creates the field editors. Field editors are abstractions of

-	 * the common GUI blocks needed to manipulate various types

-	 * of preferences. Each field editor knows how to save and

-	 * restore itself.

-	 */

-	@Override

-	public void createFieldEditors() {

-	}

-

-	/* (non-Javadoc)

-	 * @see org.eclipse.ui.IWorkbenchPreferencePage#init(org.eclipse.ui.IWorkbench)

-	 */

-	public void init(IWorkbench workbench) {

-	}

-	

-}
\ No newline at end of file
diff --git a/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/preferences/PreferenceConstants.java b/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/preferences/PreferenceConstants.java
index e2601a1..a3610a5 100644
--- a/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/preferences/PreferenceConstants.java
+++ b/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/preferences/PreferenceConstants.java
@@ -27,7 +27,7 @@
 	 * Matching brackets enabled

 	 */

 	static final public String EDITOR_MATCHING_BRACKETS = "org.eclipse.bpel.ui.xpath.editor.MatchingBrackets"; //$NON-NLS-1$

-	

+

 	/**

 	 * The matching brackets color.

 	 */

@@ -39,10 +39,10 @@
 	 * <p>

 	 * Value is of type <code>Boolean</code>.

 	 * </p>

-	 * 

+	 *

 	 */

 	static final public String EDITOR_CLOSE_STRINGS = "closeString"; //$NON-NLS-1$

-	

+

 	/**

 	 * A named preference that controls whether the 'close brackets' feature is

 	 * enabled.

@@ -52,9 +52,9 @@
 	 * @since 2.1

 	 */

 	public final static String EDITOR_CLOSE_BRACKETS= "closeBrackets"; //$NON-NLS-1$

-	

-	

-	

+

+

+

 	public final static RGB AXIS = new RGB(0, 136, 0);

 

 	public final static RGB BRACKET = new RGB(0, 0, 0);

@@ -76,296 +76,37 @@
 	public final static RGB FUNCTIONS_XPATH = new RGB(0,0,200);

 

 	public static final RGB VARIABLES = new RGB(10,10,10);

-	

+

 	public static final RGB VARIABLE_PART = new RGB(0xe0,80,0);

-	

-	

-	

+

+

+

 	/**

 	 * Initializes the given preference store with the default values.

-	 * 

+	 *

 	 * @param store the preference store to be initialized

-	 * 

+	 *

 	 * @since 2.1

 	 */

 	public static void initializeDefaultValues(IPreferenceStore store) {

-		

+

 		// set the default values from AbstractDecoratedTextEditor

 		AbstractDecoratedTextEditorPreferenceConstants.initializeDefaultValues(store);

-		

-//		store.setDefault(PreferenceConstants.EDITOR_SHOW_SEGMENTS, false);

-//

-//		// JavaBasePreferencePage

-//		store.setDefault(PreferenceConstants.LINK_PACKAGES_TO_EDITOR, false);

-//		store.setDefault(PreferenceConstants.LINK_TYPEHIERARCHY_TO_EDITOR, false);

-//		store.setDefault(PreferenceConstants.OPEN_TYPE_HIERARCHY, PreferenceConstants.OPEN_TYPE_HIERARCHY_IN_VIEW_PART);

-//		store.setDefault(PreferenceConstants.DOUBLE_CLICK, PreferenceConstants.DOUBLE_CLICK_EXPANDS);

-//		store.setDefault(PreferenceConstants.UPDATE_JAVA_VIEWS, PreferenceConstants.UPDATE_WHILE_EDITING);	

-//		store.setToDefault(PreferenceConstants.UPDATE_JAVA_VIEWS); // clear preference, update on save not supported anymore

-//		

-//		store.setDefault(PreferenceConstants.LINK_BROWSING_PROJECTS_TO_EDITOR, true);

-//		store.setDefault(PreferenceConstants.LINK_BROWSING_PACKAGES_TO_EDITOR, true);

-//		store.setDefault(PreferenceConstants.LINK_BROWSING_TYPES_TO_EDITOR, true);

-//		store.setDefault(PreferenceConstants.LINK_BROWSING_MEMBERS_TO_EDITOR, true);

-//

-//		store.setDefault(PreferenceConstants.SEARCH_USE_REDUCED_MENU, true);

-//		// AppearancePreferencePage

-//		store.setDefault(PreferenceConstants.APPEARANCE_COMPRESS_PACKAGE_NAMES, false);

-//		store.setDefault(PreferenceConstants.APPEARANCE_METHOD_RETURNTYPE, false);

-//		store.setDefault(PreferenceConstants.SHOW_CU_CHILDREN, true);

-//		store.setDefault(PreferenceConstants.BROWSING_STACK_VERTICALLY, false);

-//		store.setDefault(PreferenceConstants.APPEARANCE_PKG_NAME_PATTERN_FOR_PKG_VIEW, ""); //$NON-NLS-1$

-//		store.setDefault(PreferenceConstants.APPEARANCE_FOLD_PACKAGES_IN_PACKAGE_EXPLORER, true);

-//

-//		// ImportOrganizePreferencePage

-//		store.setDefault(PreferenceConstants.ORGIMPORTS_IMPORTORDER, "java;javax;org;com"); //$NON-NLS-1$

-//		store.setDefault(PreferenceConstants.ORGIMPORTS_ONDEMANDTHRESHOLD, 99);

-//		store.setDefault(PreferenceConstants.ORGIMPORTS_IGNORELOWERCASE, true);

-//

-//		// TypeFilterPreferencePage

-//		store.setDefault(PreferenceConstants.TYPEFILTER_ENABLED, ""); //$NON-NLS-1$

-//		store.setDefault(PreferenceConstants.TYPEFILTER_DISABLED, ""); //$NON-NLS-1$

-//		

-//		// ClasspathVariablesPreferencePage

-//		// CodeFormatterPreferencePage

-//		// CompilerPreferencePage

-//		// no initialization needed

-//		

-//		// RefactoringPreferencePage

-//		store.setDefault(PreferenceConstants.REFACTOR_ERROR_PAGE_SEVERITY_THRESHOLD, PreferenceConstants.REFACTOR_ERROR_SEVERITY);

-//		store.setDefault(PreferenceConstants.REFACTOR_SAVE_ALL_EDITORS, false);		

-//

-//		// TemplatePreferencePage

-//		store.setDefault(PreferenceConstants.TEMPLATES_USE_CODEFORMATTER, true);

-//		

-//		// CodeGenerationPreferencePage

-//		// compatibility code

-//		if (store.getBoolean(PreferenceConstants.CODEGEN_USE_GETTERSETTER_PREFIX)) {

-//			String prefix= store.getString(PreferenceConstants.CODEGEN_GETTERSETTER_PREFIX);

-//			if (prefix.length() > 0) {

-//				JavaCore.getPlugin().getPluginPreferences().setValue(JavaCore.CODEASSIST_FIELD_PREFIXES, prefix);

-//				store.setToDefault(PreferenceConstants.CODEGEN_USE_GETTERSETTER_PREFIX);

-//				store.setToDefault(PreferenceConstants.CODEGEN_GETTERSETTER_PREFIX);

-//			}

-//		}

-//		if (store.getBoolean(PreferenceConstants.CODEGEN_USE_GETTERSETTER_SUFFIX)) {

-//			String suffix= store.getString(PreferenceConstants.CODEGEN_GETTERSETTER_SUFFIX);

-//			if (suffix.length() > 0) {

-//				JavaCore.getPlugin().getPluginPreferences().setValue(JavaCore.CODEASSIST_FIELD_SUFFIXES, suffix);

-//				store.setToDefault(PreferenceConstants.CODEGEN_USE_GETTERSETTER_SUFFIX);

-//				store.setToDefault(PreferenceConstants.CODEGEN_GETTERSETTER_SUFFIX);

-//			}

-//		}

-//		store.setDefault(PreferenceConstants.CODEGEN_KEYWORD_THIS, false);

-//		store.setDefault(PreferenceConstants.CODEGEN_IS_FOR_GETTERS, true);

-//		store.setDefault(PreferenceConstants.CODEGEN_EXCEPTION_VAR_NAME, "e"); //$NON-NLS-1$

-//		store.setDefault(PreferenceConstants.CODEGEN_ADD_COMMENTS, true);

-//

-//		// MembersOrderPreferencePage

-//		store.setDefault(PreferenceConstants.APPEARANCE_MEMBER_SORT_ORDER, "T,SF,SI,SM,I,F,C,M"); //$NON-NLS-1$

-//		store.setDefault(PreferenceConstants.APPEARANCE_VISIBILITY_SORT_ORDER, "B,V,R,D"); //$NON-NLS-1$

-//		store.setDefault(PreferenceConstants.APPEARANCE_ENABLE_VISIBILITY_SORT_ORDER, false);

-//		// must add here to guarantee that it is the first in the listener list

-//		store.addPropertyChangeListener(JavaPlugin.getDefault().getMemberOrderPreferenceCache());

-//

-//

-//		// JavaEditorPreferencePage

+

 		store.setDefault(PreferenceConstants.EDITOR_MATCHING_BRACKETS, true);

 		PreferenceConverter.setDefault(store, PreferenceConstants.EDITOR_MATCHING_BRACKETS_COLOR, new RGB(192, 192,192));

-//

-//		store.setDefault(PreferenceConstants.EDITOR_CURRENT_LINE, true);

-//		PreferenceConverter.setDefault(store, PreferenceConstants.EDITOR_CURRENT_LINE_COLOR, new RGB(232, 242, 254));

-//

-//		store.setDefault(PreferenceConstants.EDITOR_PRINT_MARGIN, false);

-//		store.setDefault(PreferenceConstants.EDITOR_PRINT_MARGIN_COLUMN, 80);

-//		PreferenceConverter.setDefault(store, PreferenceConstants.EDITOR_PRINT_MARGIN_COLOR, new RGB(176, 180 , 185));

-//

-//		PreferenceConverter.setDefault(store, PreferenceConstants.EDITOR_FIND_SCOPE_COLOR, new RGB(185, 176 , 180));

-//

-//		store.setDefault(PreferenceConstants.EDITOR_CORRECTION_INDICATION, true);

-//		store.setDefault(PreferenceConstants.EDITOR_SYNC_OUTLINE_ON_CURSOR_MOVE, true);

-//

-//		store.setDefault(PreferenceConstants.EDITOR_EVALUTE_TEMPORARY_PROBLEMS, true);

-//

-//		store.setDefault(PreferenceConstants.EDITOR_OVERVIEW_RULER, true);

-//

-//		store.setDefault(PreferenceConstants.EDITOR_LINE_NUMBER_RULER, false);

-//		PreferenceConverter.setDefault(store, PreferenceConstants.EDITOR_LINE_NUMBER_RULER_COLOR, new RGB(0, 0, 0));

-//

-//		PreferenceConverter.setDefault(store, PreferenceConstants.EDITOR_LINKED_POSITION_COLOR, new RGB(121, 121, 121));

-//		PreferenceConverter.setDefault(store, PreferenceConstants.EDITOR_LINK_COLOR, new RGB(0, 0, 255));

-//

-//		store.setDefault(PreferenceConstants.EDITOR_FOREGROUND_DEFAULT_COLOR, true);

-//

-//		store.setDefault(PreferenceConstants.EDITOR_BACKGROUND_DEFAULT_COLOR, true);

-//

-//		store.setDefault(PreferenceConstants.EDITOR_TAB_WIDTH, 4);

-//		store.setDefault(PreferenceConstants.EDITOR_SPACES_FOR_TABS, false);

-//

-//		PreferenceConverter.setDefault(store, PreferenceConstants.EDITOR_MULTI_LINE_COMMENT_COLOR, new RGB(63, 127, 95));

-//		store.setDefault(PreferenceConstants.EDITOR_MULTI_LINE_COMMENT_BOLD, false);

-//		store.setDefault(PreferenceConstants.EDITOR_MULTI_LINE_COMMENT_ITALIC, false);

-//

-//		PreferenceConverter.setDefault(store, PreferenceConstants.EDITOR_SINGLE_LINE_COMMENT_COLOR, new RGB(63, 127, 95));

-//		store.setDefault(PreferenceConstants.EDITOR_SINGLE_LINE_COMMENT_BOLD, false);

-//		store.setDefault(PreferenceConstants.EDITOR_SINGLE_LINE_COMMENT_ITALIC, false);

-//

-//		PreferenceConverter.setDefault(store, PreferenceConstants.EDITOR_JAVA_KEYWORD_COLOR, new RGB(127, 0, 85));

-//		store.setDefault(PreferenceConstants.EDITOR_JAVA_KEYWORD_BOLD, true);

-//		store.setDefault(PreferenceConstants.EDITOR_JAVA_KEYWORD_ITALIC, false);

-//

-//		PreferenceConverter.setDefault(store, PreferenceConstants.EDITOR_STRING_COLOR, new RGB(42, 0, 255));

-//		store.setDefault(PreferenceConstants.EDITOR_STRING_BOLD, false);

-//		store.setDefault(PreferenceConstants.EDITOR_STRING_ITALIC, false);

-//

-//		PreferenceConverter.setDefault(store, PreferenceConstants.EDITOR_JAVA_DEFAULT_COLOR, new RGB(0, 0, 0));

-//		store.setDefault(PreferenceConstants.EDITOR_JAVA_DEFAULT_BOLD, false);

-//		store.setDefault(PreferenceConstants.EDITOR_JAVA_DEFAULT_ITALIC, false);

-//

-//		PreferenceConverter.setDefault(store, PreferenceConstants.EDITOR_JAVA_METHOD_NAME_COLOR, new RGB(0, 0, 0));

-//		store.setDefault(PreferenceConstants.EDITOR_JAVA_METHOD_NAME_BOLD, false);

-//		store.setDefault(PreferenceConstants.EDITOR_JAVA_METHOD_NAME_ITALIC, false);

-//

-//		PreferenceConverter.setDefault(store, PreferenceConstants.EDITOR_JAVA_KEYWORD_RETURN_COLOR, new RGB(127, 0, 85));

-//		store.setDefault(PreferenceConstants.EDITOR_JAVA_KEYWORD_RETURN_BOLD, true);

-//		store.setDefault(PreferenceConstants.EDITOR_JAVA_KEYWORD_RETURN_ITALIC, false);

-//

-//		PreferenceConverter.setDefault(store, PreferenceConstants.EDITOR_JAVA_OPERATOR_COLOR, new RGB(0, 0, 0));

-//		store.setDefault(PreferenceConstants.EDITOR_JAVA_OPERATOR_BOLD, false);

-//		store.setDefault(PreferenceConstants.EDITOR_JAVA_OPERATOR_ITALIC, false);

-//

-//		PreferenceConverter.setDefault(store, PreferenceConstants.EDITOR_TASK_TAG_COLOR, new RGB(127, 159, 191));

-//		store.setDefault(PreferenceConstants.EDITOR_TASK_TAG_BOLD, true);

-//		store.setDefault(PreferenceConstants.EDITOR_TASK_TAG_ITALIC, false);

-//

-//		PreferenceConverter.setDefault(store, PreferenceConstants.EDITOR_JAVADOC_KEYWORD_COLOR, new RGB(127, 159, 191));

-//		store.setDefault(PreferenceConstants.EDITOR_JAVADOC_KEYWORD_BOLD, true);

-//		store.setDefault(PreferenceConstants.EDITOR_JAVADOC_KEYWORD_ITALIC, false);

-//

-//		PreferenceConverter.setDefault(store, PreferenceConstants.EDITOR_JAVADOC_TAG_COLOR, new RGB(127, 127, 159));

-//		store.setDefault(PreferenceConstants.EDITOR_JAVADOC_TAG_BOLD, false);

-//		store.setDefault(PreferenceConstants.EDITOR_JAVADOC_TAG_ITALIC, false);

-//

-//		PreferenceConverter.setDefault(store, PreferenceConstants.EDITOR_JAVADOC_LINKS_COLOR, new RGB(63, 63, 191));

-//		store.setDefault(PreferenceConstants.EDITOR_JAVADOC_LINKS_BOLD, false);

-//		store.setDefault(PreferenceConstants.EDITOR_JAVADOC_LINKS_ITALIC, false);

-//

-//		PreferenceConverter.setDefault(store, PreferenceConstants.EDITOR_JAVADOC_DEFAULT_COLOR, new RGB(63, 95, 191));

-//		store.setDefault(PreferenceConstants.EDITOR_JAVADOC_DEFAULT_BOLD, false);

-//		store.setDefault(PreferenceConstants.EDITOR_JAVADOC_DEFAULT_ITALIC, false);

-//

-//		store.setDefault(PreferenceConstants.CODEASSIST_AUTOACTIVATION, true);

-//		store.setDefault(PreferenceConstants.CODEASSIST_AUTOACTIVATION_DELAY, 500);

-//

-//		store.setDefault(PreferenceConstants.CODEASSIST_AUTOINSERT, true);

-//		PreferenceConverter.setDefault(store, PreferenceConstants.CODEASSIST_PROPOSALS_BACKGROUND, new RGB(255, 255, 255));

-//		PreferenceConverter.setDefault(store, PreferenceConstants.CODEASSIST_PROPOSALS_FOREGROUND, new RGB(0, 0, 0));

-//		PreferenceConverter.setDefault(store, PreferenceConstants.CODEASSIST_PARAMETERS_BACKGROUND, new RGB(255, 255, 255));

-//		PreferenceConverter.setDefault(store, PreferenceConstants.CODEASSIST_PARAMETERS_FOREGROUND, new RGB(0, 0, 0));

-//		PreferenceConverter.setDefault(store, PreferenceConstants.CODEASSIST_REPLACEMENT_BACKGROUND, new RGB(255, 255, 0));

-//		PreferenceConverter.setDefault(store, PreferenceConstants.CODEASSIST_REPLACEMENT_FOREGROUND, new RGB(255, 0, 0));

-//		store.setDefault(PreferenceConstants.CODEASSIST_AUTOACTIVATION_TRIGGERS_JAVA, "."); //$NON-NLS-1$

-//		store.setDefault(PreferenceConstants.CODEASSIST_AUTOACTIVATION_TRIGGERS_JAVADOC, "@#"); //$NON-NLS-1$

-//		store.setDefault(PreferenceConstants.CODEASSIST_SHOW_VISIBLE_PROPOSALS, true);

-//		store.setDefault(PreferenceConstants.CODEASSIST_CASE_SENSITIVITY, false);

-//		store.setDefault(PreferenceConstants.CODEASSIST_ORDER_PROPOSALS, false);

-//		store.setDefault(PreferenceConstants.CODEASSIST_ADDIMPORT, true);

-//		store.setDefault(PreferenceConstants.CODEASSIST_INSERT_COMPLETION, true);

-//		store.setDefault(PreferenceConstants.CODEASSIST_FILL_ARGUMENT_NAMES, false);

-//		store.setDefault(PreferenceConstants.CODEASSIST_GUESS_METHOD_ARGUMENTS, true);

-//		store.setDefault(PreferenceConstants.CODEASSIST_PREFIX_COMPLETION, false);

-//

-//		store.setDefault(PreferenceConstants.EDITOR_SMART_HOME_END, true);

-//		store.setDefault(PreferenceConstants.EDITOR_SUB_WORD_NAVIGATION, true);

-//		store.setDefault(PreferenceConstants.EDITOR_SMART_PASTE, true);

-//		store.setDefault(PreferenceConstants.EDITOR_IMPORTS_ON_PASTE, true);

-		

+

 		store.setDefault(PreferenceConstants.EDITOR_CLOSE_STRINGS, true);

 		store.setDefault(PreferenceConstants.EDITOR_CLOSE_BRACKETS, true);

-		

-//		store.setDefault(PreferenceConstants.EDITOR_CLOSE_BRACES, true);

-//		store.setDefault(PreferenceConstants.EDITOR_CLOSE_JAVADOCS, true);

-//		store.setDefault(PreferenceConstants.EDITOR_WRAP_STRINGS, true);

-//		store.setDefault(PreferenceConstants.EDITOR_ESCAPE_STRINGS, false);

-//		store.setDefault(PreferenceConstants.EDITOR_ADD_JAVADOC_TAGS, true);

-//		store.setDefault(PreferenceConstants.EDITOR_FORMAT_JAVADOCS, false);

-//		store.setDefault(PreferenceConstants.EDITOR_DISABLE_OVERWRITE_MODE, false);

-//		

-//		String mod1Name= Action.findModifierString(SWT.MOD1);	// SWT.COMMAND on Mac; SWT.CONTROL elsewhere

-//		store.setDefault(PreferenceConstants.EDITOR_TEXT_HOVER_MODIFIERS, "org.eclipse.jdt.ui.BestMatchHover;0;org.eclipse.jdt.ui.JavaSourceHover;" + mod1Name); //$NON-NLS-1$

-//		store.setDefault(PreferenceConstants.EDITOR_TEXT_HOVER_MODIFIER_MASKS, "org.eclipse.jdt.ui.BestMatchHover;0;org.eclipse.jdt.ui.JavaSourceHover;" + SWT.MOD1); //$NON-NLS-1$

-//		store.setDefault(PreferenceConstants.EDITOR_SHOW_TEXT_HOVER_AFFORDANCE, true);

-//		

-//		store.setDefault(PreferenceConstants.EDITOR_BROWSER_LIKE_LINKS, true);

-//		store.setDefault(PreferenceConstants.EDITOR_BROWSER_LIKE_LINKS_KEY_MODIFIER, mod1Name);

-//		store.setDefault(PreferenceConstants.EDITOR_BROWSER_LIKE_LINKS_KEY_MODIFIER_MASK, SWT.MOD1);

-//		

-//		store.setDefault(PreferenceConstants.EDITOR_SMART_TAB, true);

-//		store.setDefault(PreferenceConstants.EDITOR_SMART_BACKSPACE, true);

-//		store.setDefault(PreferenceConstants.EDITOR_ANNOTATION_ROLL_OVER, false);

-//		

-//		store.setDefault(PreferenceConstants.FORMATTER_COMMENT_FORMAT, true);

-//		store.setDefault(PreferenceConstants.FORMATTER_COMMENT_FORMATHEADER, false);

-//		store.setDefault(PreferenceConstants.FORMATTER_COMMENT_FORMATSOURCE, true);

-//		store.setDefault(PreferenceConstants.FORMATTER_COMMENT_INDENTPARAMETERDESCRIPTION, true);

-//		store.setDefault(PreferenceConstants.FORMATTER_COMMENT_INDENTROOTTAGS, true);

-//		store.setDefault(PreferenceConstants.FORMATTER_COMMENT_NEWLINEFORPARAMETER, true);

-//		store.setDefault(PreferenceConstants.FORMATTER_COMMENT_SEPARATEROOTTAGS, true);

-//		store.setDefault(PreferenceConstants.FORMATTER_COMMENT_CLEARBLANKLINES, false);

-//		store.setDefault(PreferenceConstants.FORMATTER_COMMENT_FORMATHTML, true);

-//		store.setDefault(PreferenceConstants.FORMATTER_COMMENT_LINELENGTH, 80);

-//		

-//		store.setDefault(PreferenceConstants.FORMATTER_PROFILE, ProfileManager.JAVA_PROFILE);

-//		ProfileStore.checkCurrentOptionsVersion();

-//		

-//		// mark occurrences

-//		store.setDefault(PreferenceConstants.EDITOR_MARK_OCCURRENCES, false);

-//		store.setDefault(PreferenceConstants.EDITOR_STICKY_OCCURRENCES, true);

-//		store.setDefault(PreferenceConstants.EDITOR_MARK_TYPE_OCCURRENCES, true);

-//		store.setDefault(PreferenceConstants.EDITOR_MARK_METHOD_OCCURRENCES, true);

-//		store.setDefault(PreferenceConstants.EDITOR_MARK_CONSTANT_OCCURRENCES, true);

-//		store.setDefault(PreferenceConstants.EDITOR_MARK_FIELD_OCCURRENCES, true);

-//		store.setDefault(PreferenceConstants.EDITOR_MARK_LOCAL_VARIABLE_OCCURRENCES, true);

-//		store.setDefault(PreferenceConstants.EDITOR_MARK_EXCEPTION_OCCURRENCES, true);

-//		store.setDefault(PreferenceConstants.EDITOR_MARK_METHOD_EXIT_POINTS, true);

-//		

-//		// spell checking

-//		store.setDefault(PreferenceConstants.SPELLING_CHECK_SPELLING, false);

-//		store.setDefault(PreferenceConstants.SPELLING_LOCALE, SpellCheckEngine.getDefaultLocale().toString());

-//		store.setDefault(PreferenceConstants.SPELLING_IGNORE_DIGITS, true);

-//		store.setDefault(PreferenceConstants.SPELLING_IGNORE_MIXED, true);

-//		store.setDefault(PreferenceConstants.SPELLING_IGNORE_SENTENCE, true);

-//		store.setDefault(PreferenceConstants.SPELLING_IGNORE_UPPER, true);

-//		store.setDefault(PreferenceConstants.SPELLING_IGNORE_URLS, true);

-//		store.setDefault(PreferenceConstants.SPELLING_USER_DICTIONARY, ""); //$NON-NLS-1$

-//		store.setDefault(PreferenceConstants.SPELLING_PROPOSAL_THRESHOLD, 20);

-//		store.setDefault(PreferenceConstants.SPELLING_ENABLE_CONTENTASSIST, false);

-//		

-//		// folding

-//		store.setDefault(PreferenceConstants.EDITOR_FOLDING_ENABLED, true);

-//		store.setDefault(PreferenceConstants.EDITOR_FOLDING_PROVIDER, "org.eclipse.jdt.ui.text.defaultFoldingProvider"); //$NON-NLS-1$

-//		store.setDefault(PreferenceConstants.EDITOR_FOLDING_JAVADOC, false);

-//		store.setDefault(PreferenceConstants.EDITOR_FOLDING_INNERTYPES, true);

-//		store.setDefault(PreferenceConstants.EDITOR_FOLDING_METHODS, false);

-//		store.setDefault(PreferenceConstants.EDITOR_FOLDING_IMPORTS, true);

-//		

-//		// override default extended text editor prefs

-//		store.setDefault(AbstractDecoratedTextEditorPreferenceConstants.EDITOR_USE_CUSTOM_CARETS, true);

-//		

-//

-//		SemanticHighlightings.initDefaults(store);

-//

-//		// do more complicated stuff

-//		NewJavaProjectPreferencePage.initDefaults(store);	

 	}

 

 	/**

 	 * Returns the preference store.

-	 * 

+	 *

 	 * @return the preference store

 	 */

 	public static IPreferenceStore getPreferenceStore() {

 		return BPELUIPlugin.INSTANCE.getPreferenceStore();

-	}	

-	

+	}

+

 }

diff --git a/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/preferences/PreferenceInitializer.java b/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/preferences/PreferenceInitializer.java
deleted file mode 100644
index ee694b2..0000000
--- a/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/preferences/PreferenceInitializer.java
+++ /dev/null
@@ -1,37 +0,0 @@
-/*******************************************************************************

- * Copyright (c) 2008, 2012 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 Corporation - initial API and implementation

- *******************************************************************************/

-package org.eclipse.bpel.ui.preferences;

-

-import org.eclipse.core.runtime.preferences.AbstractPreferenceInitializer;

-

-/**

- * Class used to initialize default preference values.

- */

-public class PreferenceInitializer extends AbstractPreferenceInitializer {

-

-	/*

-	 * (non-Javadoc)

-	 * 

-	 * @see org.eclipse.core.runtime.preferences.AbstractPreferenceInitializer#initializeDefaultPreferences()

-	 */

-	@Override

-	public void initializeDefaultPreferences() {

-		/*

-		IPreferenceStore store = BPELUIPlugin.INSTANCE

-				.getPreferenceStore();

-		store.setDefault(PreferenceConstants.P_BOOLEAN, true);

-		store.setDefault(PreferenceConstants.P_CHOICE, "choice2");

-		store.setDefault(PreferenceConstants.P_STRING,

-				"Default value");

-				*/

-	}

-

-}

diff --git a/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/properties/AttributesSection.java b/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/properties/AttributesSection.java
index 36a6cd8..6f59799 100644
--- a/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/properties/AttributesSection.java
+++ b/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/properties/AttributesSection.java
@@ -39,41 +39,42 @@
  * Details section for attributes of a Process

  */

 public class AttributesSection extends BPELPropertySection {

-	

+

 	protected Combo fExpressionLanguageCombo;

 	protected Combo fQueryLanguageCombo;

-	

+

 	protected ComboViewer fExpressionLanguageViewer;

 	protected ComboViewer fQueryLanguageViewer;

-	

+

 	protected EditController fExpressionLanguageController;

 	protected EditController fQueryLanguageController;

-	

+

 	protected IValue fContext;

-	

-	 

+

+

 	@Override

 	protected void basicSetInput(EObject input) {

 		saveUserContextToInput() ;

 		super.basicSetInput(input);

 		restoreUserContextFromInput() ;

-		

+

 		/** We assume it is Process */

-		fQueryLanguageController.setInput(input);

-		fExpressionLanguageController.setInput(input);	

+		this.fQueryLanguageController.setInput(input);

+		this.fExpressionLanguageController.setInput(input);

 	}

-	

+

 	class ExpressionEditorDescriptorIValue extends DelegateIValue {

 		ExpressionEditorDescriptorIValue ( IValue arg ) {

 			super (arg);

-		}		

+		}

 		/**

 		 * @see org.eclipse.bpel.common.ui.details.DelegateIValue#get()

 		 */

 		@Override

 		public Object get() {

-			String result = (String) fDelegate.get();

+			String result = (String) this.fDelegate.get();

 			return result != null ? BPELUIRegistry.getInstance().getExpressionEditorDescriptor( result ) : null;

+			// returns an ExpressionEditorDescriptor

 		}

 

 		/**

@@ -82,85 +83,85 @@
 		@Override

 		public void set (Object object) {

 			ExpressionEditorDescriptor eed = (ExpressionEditorDescriptor) object;

-			fDelegate.set( eed != null ? eed.getExpressionLanguage() : null );

-		}		

+			this.fDelegate.set( eed != null ? eed.getExpressionLanguage() : null );

+		}

 	}

 	protected void createChangeTrackers() {

-		fExpressionLanguageController = createEditController();

-		fExpressionLanguageController.setFeature(BPELPackage.eINSTANCE.getProcess_ExpressionLanguage());

-		fExpressionLanguageController.setViewIValue(new ViewerIValue ( fExpressionLanguageViewer ) );

-		fExpressionLanguageController.setModeIValue(new ExpressionEditorDescriptorIValue ( 

-				fExpressionLanguageController.getModelIValue() ));

-		

-		fExpressionLanguageController.startListeningTo(fExpressionLanguageCombo) ;

+		this.fExpressionLanguageController = createEditController();

+		this.fExpressionLanguageController.setFeature(BPELPackage.eINSTANCE.getProcess_ExpressionLanguage());

+		this.fExpressionLanguageController.setViewIValue(new ViewerIValue ( this.fExpressionLanguageViewer ) );

+		this.fExpressionLanguageController.setModeIValue(new ExpressionEditorDescriptorIValue (

+				this.fExpressionLanguageController.getModelIValue() ));

 

-		fQueryLanguageController = createEditController();

-		fQueryLanguageController.setFeature(BPELPackage.eINSTANCE.getProcess_QueryLanguage() );

-		fQueryLanguageController.setViewIValue(new ViewerIValue ( fQueryLanguageViewer ));

-		fQueryLanguageController.setModeIValue(new ExpressionEditorDescriptorIValue ( 

-				fQueryLanguageController.getModelIValue() ));

-		fQueryLanguageController.startListeningTo(fQueryLanguageCombo) ;

+		this.fExpressionLanguageController.startListeningTo(this.fExpressionLanguageCombo) ;

+

+		this.fQueryLanguageController = createEditController();

+		this.fQueryLanguageController.setFeature(BPELPackage.eINSTANCE.getProcess_QueryLanguage() );

+		this.fQueryLanguageController.setViewIValue(new ViewerIValue ( this.fQueryLanguageViewer ));

+		this.fQueryLanguageController.setModeIValue(new ExpressionEditorDescriptorIValue (

+				this.fQueryLanguageController.getModelIValue() ));

+		this.fQueryLanguageController.startListeningTo(this.fQueryLanguageCombo) ;

 	}

 

 	@SuppressWarnings("nls")

 	protected void createAttributesWidgets(Composite composite) {

 		FlatFormData data;

 

-		Label expressionLanguageLabel = fWidgetFactory.createLabel(composite, Messages.AttributesDetails_Expression_Language__2);

-		fExpressionLanguageCombo = new Combo(composite,SWT.FLAT | SWT.READ_ONLY );

-		fWidgetFactory.adapt(fExpressionLanguageCombo);		

-		fExpressionLanguageCombo.setData(FocusContext.NAME,"expressionLanguage");

-		

+		Label expressionLanguageLabel = this.fWidgetFactory.createLabel(composite, Messages.AttributesDetails_Expression_Language__2);

+		this.fExpressionLanguageCombo = new Combo(composite,SWT.FLAT | SWT.READ_ONLY );

+		this.fWidgetFactory.adapt(this.fExpressionLanguageCombo);

+		this.fExpressionLanguageCombo.setData(FocusContext.NAME,"expressionLanguage");

+

 		// Expression language combo layout

-		fExpressionLanguageViewer = new ComboViewer(fExpressionLanguageCombo);

+		this.fExpressionLanguageViewer = new ComboViewer(this.fExpressionLanguageCombo);

 		data = new FlatFormData();

 		data.left = new FlatFormAttachment(0, BPELUtil.calculateLabelWidth(expressionLanguageLabel, STANDARD_LABEL_WIDTH_LRG));

 		data.right = new FlatFormAttachment(100, (-2) * IDetailsAreaConstants.HSPACE );

 		data.top = new FlatFormAttachment(0, IDetailsAreaConstants.VSPACE);

-		fExpressionLanguageCombo.setLayoutData(data);

+		this.fExpressionLanguageCombo.setLayoutData(data);

 

-		fExpressionLanguageViewer.setContentProvider(new ExpressionEditorDescriptorContentProvider());

-		fExpressionLanguageViewer.setLabelProvider(new ExpressionEditorDescriptorLabelProvider());

-		fExpressionLanguageViewer.setSorter(ModelViewerSorter.getInstance());

+		this.fExpressionLanguageViewer.setContentProvider(new ExpressionEditorDescriptorContentProvider());

+		this.fExpressionLanguageViewer.setLabelProvider(new ExpressionEditorDescriptorLabelProvider());

+		this.fExpressionLanguageViewer.setSorter(ModelViewerSorter.getInstance());

 

 		// Expression language label layout

 		data = new FlatFormData();

 		data.left = new FlatFormAttachment(0, 0);

-		data.right = new FlatFormAttachment(fExpressionLanguageCombo, -IDetailsAreaConstants.HSPACE);

-		data.top = new FlatFormAttachment(fExpressionLanguageCombo, 0, SWT.CENTER);

+		data.right = new FlatFormAttachment(this.fExpressionLanguageCombo, -IDetailsAreaConstants.HSPACE);

+		data.top = new FlatFormAttachment(this.fExpressionLanguageCombo, 0, SWT.CENTER);

 		expressionLanguageLabel.setLayoutData(data);

 

-		fExpressionLanguageViewer.setInput(new Object());

-		

-		Label queryLanguageLabel = fWidgetFactory.createLabel(composite, Messages.AttributesDetails_Query_Language__2);

-		fQueryLanguageCombo = new Combo(composite,SWT.FLAT | SWT.READ_ONLY );

-		fWidgetFactory.adapt( fQueryLanguageCombo );		

-		fQueryLanguageCombo.setData(FocusContext.NAME,"queryLanguage");

-		

+		this.fExpressionLanguageViewer.setInput(new Object());

+

+		Label queryLanguageLabel = this.fWidgetFactory.createLabel(composite, Messages.AttributesDetails_Query_Language__2);

+		this.fQueryLanguageCombo = new Combo(composite,SWT.FLAT | SWT.READ_ONLY );

+		this.fWidgetFactory.adapt( this.fQueryLanguageCombo );

+		this.fQueryLanguageCombo.setData(FocusContext.NAME,"queryLanguage");

+

 		// Query language combo layout

-		fQueryLanguageViewer = new ComboViewer(fQueryLanguageCombo);

+		this.fQueryLanguageViewer = new ComboViewer(this.fQueryLanguageCombo);

 		data = new FlatFormData();

 		data.left = new FlatFormAttachment(0, BPELUtil.calculateLabelWidth(queryLanguageLabel, STANDARD_LABEL_WIDTH_LRG));

 		data.right = new FlatFormAttachment(100, (-2) * IDetailsAreaConstants.HSPACE );

-		data.top = new FlatFormAttachment(fExpressionLanguageCombo, IDetailsAreaConstants.VSPACE);

-		fQueryLanguageCombo.setLayoutData(data);

+		data.top = new FlatFormAttachment(this.fExpressionLanguageCombo, IDetailsAreaConstants.VSPACE);

+		this.fQueryLanguageCombo.setLayoutData(data);

 

-		fQueryLanguageViewer.setLabelProvider(new ExpressionEditorDescriptorLabelProvider());

-		fQueryLanguageViewer.setContentProvider(new ExpressionEditorDescriptorContentProvider());

-		fQueryLanguageViewer.setSorter(ModelViewerSorter.getInstance());

+		this.fQueryLanguageViewer.setLabelProvider(new ExpressionEditorDescriptorLabelProvider());

+		this.fQueryLanguageViewer.setContentProvider(new ExpressionEditorDescriptorContentProvider());

+		this.fQueryLanguageViewer.setSorter(ModelViewerSorter.getInstance());

 //		queryLanguageViewer.addFilter(new ExpressionLanguageFilter(new String[0]));

 

 		// Query language label layout

 		data = new FlatFormData();

 		data.left = new FlatFormAttachment(0, 0);

-		data.right = new FlatFormAttachment(fQueryLanguageCombo, -IDetailsAreaConstants.HSPACE);

-		data.top = new FlatFormAttachment(fQueryLanguageCombo, 0, SWT.CENTER);

+		data.right = new FlatFormAttachment(this.fQueryLanguageCombo, -IDetailsAreaConstants.HSPACE);

+		data.top = new FlatFormAttachment(this.fQueryLanguageCombo, 0, SWT.CENTER);

 		queryLanguageLabel.setLayoutData(data);

 

-		fQueryLanguageViewer.setInput(new Object());

-		

-		

-		fContext = new FocusContext( fExpressionLanguageCombo, fQueryLanguageCombo );

+		this.fQueryLanguageViewer.setInput(new Object());

+

+

+		this.fContext = new FocusContext( this.fExpressionLanguageCombo, this.fQueryLanguageCombo );

 	}

 

 	@Override

@@ -178,14 +179,14 @@
 	 */

 	@Override

 	public Object getUserContext() {

-		return fContext.get();

+		return this.fContext.get();

 	}

-	

+

 	/**

 	 * @see org.eclipse.bpel.ui.properties.BPELPropertySection#restoreUserContext(java.lang.Object)

 	 */

 	@Override

 	public void restoreUserContext(Object userContext) {

-		fContext.set(userContext);

+		this.fContext.set(userContext);

 	}

 }

diff --git a/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/properties/BPELPropertySection.java b/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/properties/BPELPropertySection.java
index 4187174..991d9a4 100644
--- a/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/properties/BPELPropertySection.java
+++ b/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/properties/BPELPropertySection.java
@@ -56,30 +56,30 @@
  * An abstract implementation which provides some adapter support and useful stuff.

  * This was based on the common implementation characteristics of bpel.ui properties

  * pages.

- * 

+ *

  * Implementors may subclass this class, or they could extend AbstractPropertySection directly.

- */ 

+ */

 @SuppressWarnings("nls")

-public abstract class BPELPropertySection extends AbstractPropertySection 	

+public abstract class BPELPropertySection extends AbstractPropertySection

 {

 	protected static final String EMPTY_STRING = ""; //$NON-NLS-1$

-			

+

 	protected static final IMarker EMPTY_MARKERS[] = new IMarker[] {};

-		

+

 	protected static final MultiObjectAdapter[] EMPTY_MULTI_OBJECT_ARRAY = new MultiObjectAdapter[0];

-	

+

 	/** Standard label width */

 	public static final int STANDARD_LABEL_WIDTH_SM = 105;

-	

+

 	/** Standard label width - applying the 25% fudge factor */

 	public static final int STANDARD_LABEL_WIDTH_AVG = STANDARD_LABEL_WIDTH_SM * 5/4;

-	

+

 	/** Standard label width - applying the 50% fudge factor */

 	public static final int STANDARD_LABEL_WIDTH_LRG = STANDARD_LABEL_WIDTH_SM * 3/2;

-	

+

 	/** Standard button width */

 	public static final int STANDARD_BUTTON_WIDTH = 60;

-	

+

 	/** Short button width */

 	public static final int SHORT_BUTTON_WIDTH = 45;

 

@@ -87,21 +87,21 @@
 	protected boolean isCreated;

 	protected boolean isHidden;

 	protected EObject fModelObject;

-	

+

 	protected TabbedPropertySheetWidgetFactory fWidgetFactory;

-	

-	

+

+

 	protected BPELTabbedPropertySheetPage fTabbedPropertySheetPage;

 

-	

-		

+

+

 	final protected ModelContentProposalProvider.ValueProvider inputValueProvider =  new ModelContentProposalProvider.ValueProvider () {

 		@Override

 		public Object value() {

 			return getModel();

-		}		

+		}

 	};

-	

+

 

 	/**

 	 * @see org.eclipse.ui.views.properties.tabbed.AbstractPropertySection#getWidgetFactory()

@@ -116,10 +116,10 @@
 	/**

 	 * Brand new shiny BPELPropertySection

 	 */

-	

+

 	public BPELPropertySection() {

 		super();

-		fAdapters = createAdapters();

+		this.fAdapters = createAdapters();

 	}

 

 	/**

@@ -135,7 +135,7 @@
 	 * Subclasses may override.

 	 */

 	protected void removeAllAdapters() {

-		for (MultiObjectAdapter a : fAdapters) {

+		for (MultiObjectAdapter a : this.fAdapters) {

 			a.removeFromAll();

 		}

 	}

@@ -145,19 +145,19 @@
 	 * Subclasses may override.

 	 */

 	protected void addAllAdapters() {

-		assert isCreated : "Not yet created!" ;

-		

-		if (fAdapters.length > 0) {

+		assert this.isCreated : "Not yet created!" ;

+

+		if (this.fAdapters.length > 0) {

 			if (getModel() != null) {

-				fAdapters[0].addToObject(getModel());

+				this.fAdapters[0].addToObject(getModel());

 			}

 		}

 	}

 

 	/**

-	 * Convenience method for removing and re-adding adapters.  This is a simple and general 

+	 * Convenience method for removing and re-adding adapters.  This is a simple and general

 	 * way to react to model changes that grow or shrink the set of model objects we want our

-	 * adapters to be on.  

+	 * adapters to be on.

 	 */

 	protected void refreshAdapters() {

 		removeAllAdapters();

@@ -168,71 +168,70 @@
 	 * This method is intended to set the input object.  Subclasses may override this

 	 * method to perform necessary cleanup before changing the input object, and/or

 	 * perform initialization after changing the input object.

-	 * 

+	 *

 	 * Subclasses may also override to change the policy of which object is used as

 	 * the input for a particular properties section.

-	 * 

+	 *

 	 * For example: a section for a custom activity, may wish to override this method

 	 * to use the custom activity ExtensibilityElement as the "main" input object.

 	 */

-	@SuppressWarnings("unchecked")

 	protected void basicSetInput(EObject newInput) {

-		fModelObject = newInput;

+		this.fModelObject = newInput;

 	}

-	

+

 	@SuppressWarnings("unchecked")

 	protected void restoreUserContextFromInput () {

-		IProperty<String,Object> prop = BPELUtil.adapt(fModelObject, IProperty.class);

+		IProperty<String,Object> prop = BPELUtil.adapt(this.fModelObject, IProperty.class);

 		if (prop != null) {

-			restoreUserContext( prop.getProperty( getClass().getName() ) );			

+			restoreUserContext( prop.getProperty( getClass().getName() ) );

 		}

 	}

-	

+

 	@SuppressWarnings("unchecked")

 	protected void saveUserContextToInput () {

-		IProperty<String,Object> prop = BPELUtil.adapt(fModelObject, IProperty.class);

+		IProperty<String,Object> prop = BPELUtil.adapt(this.fModelObject, IProperty.class);

 		if (prop != null) {

-			prop.setProperty(getClass().getName(), getUserContext() );			

-		}		

+			prop.setProperty(getClass().getName(), getUserContext() );

+		}

 	}

-	

-	

+

+

 	/**

 	 * @see org.eclipse.ui.views.properties.tabbed.AbstractPropertySection#setInput(org.eclipse.ui.IWorkbenchPart, org.eclipse.jface.viewers.ISelection)

 	 */

 	@Override

 	public final void setInput(IWorkbenchPart part, ISelection selection) {

-		

+

 		super.setInput(part, selection);

-		

+

 		if ((selection instanceof IStructuredSelection) == false) {

 			return ;

 		}

-		

+

 		Object model = ((IStructuredSelection)selection).getFirstElement();

-		if (model == fModelObject) {

+		if (model == this.fModelObject) {

 			return;

 		}

-				

+

 		removeAllAdapters();

-		

+

 		super.setInput(part, selection);

-		

+

 	    basicSetInput((EObject)model);

-	    

+

 		// Careful: don't assume input == newInput.

 		// There are basicSetInput() hacks that violate that assumption  =)

 		// TODO: is this comment related to the custom activities?

-		addAllAdapters();		

+		addAllAdapters();

 	}

 

-	

+

 	/**

 	 * @see org.eclipse.ui.views.properties.tabbed.AbstractPropertySection#aboutToBeHidden()

 	 */

 	@Override

 	public void aboutToBeHidden() {

-		isHidden = true;

+		this.isHidden = true;

 	}

 

 	/**

@@ -240,25 +239,25 @@
 	 */

 	@Override

 	public void aboutToBeShown() {

-		isHidden = false;

+		this.isHidden = false;

 	}

 

 	@SuppressWarnings("unchecked")

 	protected <T extends EObject> T getModel() {

-		return (T) fModelObject;

+		return (T) this.fModelObject;

 	}

 

 	protected final <T extends EObject> T getInput() {

 		return getModel();

 	}

-	

-	

+

+

 	/**

 	 * Refresh the given CComboViewer, and also make sure selectedObject is selected in it.

 	 */

 	protected void refreshCCombo(CComboViewer viewer, Object selectedObject) {

 		viewer.refresh();

-		

+

 		if (selectedObject == null) {

 			viewer.setSelectionNoNotify ( StructuredSelection.EMPTY ,false );

 		} else {

@@ -268,38 +267,38 @@
 

 	/**

 	 * Create the controls.

-	 * 

+	 *

 	 * @see org.eclipse.ui.views.properties.tabbed.AbstractPropertySection#createControls(org.eclipse.swt.widgets.Composite, org.eclipse.ui.views.properties.tabbed.TabbedPropertySheetPage)

 	 */

-	

+

 	@Override

 	public void createControls (final Composite parent, TabbedPropertySheetPage aTabbedPropertySheetPage) {

-		

+

 		super.createControls(parent, aTabbedPropertySheetPage);

-		

+

 		this.fTabbedPropertySheetPage = (BPELTabbedPropertySheetPage)aTabbedPropertySheetPage;

 		this.fWidgetFactory = getWidgetFactory();

-		

-		assert !isCreated : "Not yet created!";

-		

-		Composite marginComposite = fWidgetFactory.createComposite(parent); 

+

+		assert !this.isCreated : "Not yet created!";

+

+		Composite marginComposite = this.fWidgetFactory.createComposite(parent);

 		FillLayout fillLayout = new FillLayout();

 		fillLayout.marginWidth = IDetailsAreaConstants.HMARGIN;

 		fillLayout.marginHeight = IDetailsAreaConstants.VMARGIN/2;

 		marginComposite.setLayout(fillLayout);

 		createClient(marginComposite);

-		isHidden = true;

-		isCreated = true;

-			

+		this.isHidden = true;

+		this.isCreated = true;

+

 		parent.addDisposeListener(new DisposeListener() {

 			public void widgetDisposed(DisposeEvent e) {

 				dispose();

 			}

-			

+

 		});

-		

+

 	}

-	

+

 	/**

 	 * Subclasses should override this to create the child controls of the section.

 	 */

@@ -309,13 +308,13 @@
 	 * @see org.eclipse.ui.views.properties.tabbed.AbstractPropertySection#dispose()

 	 */

 	@Override

-	public void dispose() {		

-		if (isCreated) {

+	public void dispose() {

+		if (this.isCreated) {

 			// TODO HACK: this shouldn't really be here!  But where should it be??

 			getCommandFramework().applyCurrentChange();

 			removeAllAdapters();

 		}

-		isCreated = false;

+		this.isCreated = false;

 	}

 

 	/**

@@ -328,21 +327,21 @@
 	}

 

 	/**

-	 * Subclasses must override this method in order to refresh the status labels 

+	 * Subclasses must override this method in order to refresh the status labels

 	 */

 	protected void updateStatusLabels() {

 	}

 

 	/**

 	 * Gets all IMarker according to the passed input model.

-	 * @see IMarkerHolder.getMarkers 

+	 * @see IMarkerHolder.getMarkers

 	 */

-	

+

 	protected IMarker[] getMarkers (Object input) {

-		

+

 		IMarkerHolder markerHolder = BPELUtil.adapt(input, IMarkerHolder.class);

 		if (markerHolder != null) {

-			ArrayList<IMarker> filteredMarkers = new ArrayList<IMarker>(4);			

+			ArrayList<IMarker> filteredMarkers = new ArrayList<IMarker>(4);

 			for(IMarker m : markerHolder.getMarkers(input)) {

 				if (isValidMarker(m)) {

 					filteredMarkers.add(m);

@@ -354,20 +353,20 @@
 		}

 		return EMPTY_MARKERS;

 	}

-	

-	

-	protected boolean markersHaveChanged  ( Notification n ) {		

-		int eventGroup = n.getEventType() / 100; 

+

+

+	protected boolean markersHaveChanged  ( Notification n ) {

+		int eventGroup = n.getEventType() / 100;

 		return eventGroup == AdapterNotification.NOTIFICATION_MARKERS_CHANGED_GROUP ;

 	}

-	

-	

+

+

 	protected void updateMarkers ( ) {

-		

+

 	}

 

 	protected CompoundCommand makeCompound ( Command command ) {

-		

+

 		if (command == null) {

 			return null;

 		}

@@ -378,12 +377,12 @@
 		cc.add(command);

 		return cc;

 	}

-	

-	

+

+

 	protected void runCommand ( Command command ) {

 		getCommandFramework().execute( wrapInShowContextCommand(command) );

 	}

-	

+

 	protected ICommandFramework getCommandFramework() {

 		BPELEditor editor = getBPELEditor();

 		if (editor != null) {

@@ -395,10 +394,10 @@
 	/**

 	 * @return the BPELEditor

 	 */

-	

+

 	public BPELEditor getBPELEditor() {

-		if (fTabbedPropertySheetPage != null) {

-			return fTabbedPropertySheetPage.getEditor();

+		if (this.fTabbedPropertySheetPage != null) {

+			return this.fTabbedPropertySheetPage.getEditor();

 		}

 		return null;

 	}

@@ -413,13 +412,13 @@
 	protected EditController createEditController ( ) {

 		return new EditController ( getCommandFramework() ) {

 			@Override

-			public Command createApplyCommand() {				

+			public Command createApplyCommand() {

 				return wrapInShowContextCommand( super.createApplyCommand() );

-			}			

+			}

 		};

 	}

-	

-	

+

+

 	/**

 	 * Convenience accessor with default policy (this is overridden in certain subclasses).

 	 */

@@ -429,25 +428,25 @@
 

 	/**

 	 * Create a command that wraps the command passed in the show/restore context commands.

-	 * 

+	 *

 	 * @param inner the inner command to be run.

 	 * @param section the BPEL property section

 	 * @return the command new wrapped command.

 	 */

-	

+

 	protected Command wrapInShowContextCommand(final Command inner, BPELPropertySection section) {

-		

+

 		/**

 		 * Sometimes we have property sections inside property sections.

-		 *  

+		 *

 		 * The owners section's input needs to be saved, because it is used to restore

 		 * the selection later on in the "wrapping" command. The "inner" section's input

 		 * may not be visibly selectable. For example, consider "Variable" property sheet.

-		 * A separate section is used for the "From" part of Variable.  

+		 * A separate section is used for the "From" part of Variable.

 		 */

-		

-		final Object previousInput = section.getInput(); 

-		

+

+		final Object previousInput = section.getInput();

+

 		final TabbedPropertyViewer viewer = getTabbedPropertySheetPage().getTabbedPropertyViewer();

 		final int tabIndex = viewer.getSelectionIndex();

 		// Bug 120110 - found this problem while building the extension activity examples

@@ -456,73 +455,73 @@
 		final int sectionIndex = getTabbedPropertySheetPage().getCurrentTab()==null

 				? -1

 				: getTabbedPropertySheetPage().getCurrentTab().getSectionIndex(section);

-		

+

 		if (!inner.canExecute()) {

 			System.out.println("WARNING: unexecutable command passed to wrapInShowContextCommand():"); //$NON-NLS-1$

 			System.out.println("    "+inner.getDebugLabel()); //$NON-NLS-1$

 		}

-		

+

 		return new AbstractEditModelCommand() {

 			Object beforeContext, afterContext;

-			

+

 			@Override

 			public String getLabel() {

 				return inner.getLabel();

 			}

-			

+

 			@Override

 			public void setLabel(String label) {

 				inner.setLabel(label);

 			}

-			

+

 			@Override

 			public String getDebugLabel() {

 				return "ShowContext wrapper:[" + inner.getDebugLabel() + "]"; //$NON-NLS-1$ //$NON-NLS-2$

 			}

-			

+

 			@Override

 			public boolean canExecute() {

 				return inner.canExecute();

 			}

-			

+

 			@Override

 			public void execute() {

-				BPELPropertySection aSection = getSection(sectionIndex); 

-				beforeContext = (aSection==null)? null : aSection.getUserContext();

+				BPELPropertySection aSection = getSection(sectionIndex);

+				this.beforeContext = (aSection==null)? null : aSection.getUserContext();

 				inner.execute();

-				afterContext = (aSection==null)? null : aSection.getUserContext();

+				this.afterContext = (aSection==null)? null : aSection.getUserContext();

 			}

-			

+

 			@Override

 			public boolean canUndo() {

 				return inner.canUndo();

 			}

-			

+

 			@Override

 			public void undo() {

 				inner.undo();

 				showPropertiesTab();

 				BPELPropertySection aSection = getSection(sectionIndex);

 				if (aSection != null) {

-					aSection.restoreUserContext(beforeContext);

+					aSection.restoreUserContext(this.beforeContext);

 				}

 			}

-			

+

 			@Override

 			public void redo() {

 				inner.redo();

 				showPropertiesTab();

 				BPELPropertySection aSection = getSection(sectionIndex);

 				if (aSection != null) {

-					aSection.restoreUserContext(afterContext);

+					aSection.restoreUserContext(this.afterContext);

 				}

 			}

-			

+

 			@Override

 			public void dispose() {

 				inner.dispose();

 			}

-			

+

 			protected BPELPropertySection getSection (int index) {

 				 TabContents tab = getTabbedPropertySheetPage().getCurrentTab();

 				 if (tab != null) {

@@ -530,12 +529,12 @@
 				 }

 				 return null;

 			}

-			

+

 			protected void showPropertiesTab() {

 				// TODO: Try to avoid selecting the model object all

 				// the time, as it could cause unnecessary flashing.

 				getBPELEditor().selectModelObject(previousInput);

-				

+

 				if (tabIndex != viewer.getSelectionIndex()) {

 					Object selectedTab = viewer.getElementAt(tabIndex);

 					if (selectedTab != null) {

@@ -543,18 +542,18 @@
 					}

 				}

 			}

-			

+

 			// TODO: THIS IS A HACK.. these helpers might belong somewhere else.

 			@Override

-			public Resource[] getResources() { 

-				return EditModelCommandStack.getResources(inner); 

+			public Resource[] getResources() {

+				return EditModelCommandStack.getResources(inner);

 			}

-			

+

 			@Override

-			public Resource[] getModifiedResources() { 

-				return EditModelCommandStack.getModifiedResources(inner); 

+			public Resource[] getModifiedResources() {

+				return EditModelCommandStack.getModifiedResources(inner);

 			}

-			

+

 		};

 	}

 

@@ -562,9 +561,9 @@
 	 * Creates a composite with a flat border around it.

 	 */

 	protected Composite createBorderComposite(Composite parent) {

-	    return BPELUtil.createBorderComposite(parent, fWidgetFactory);

+	    return BPELUtil.createBorderComposite(parent, this.fWidgetFactory);

 	}

-	

+

 	/**

 	 * NOTE: use this method, NOT the method in TabbedPropertySheetWidgetFactory,

 	 * whose semantics were inexplicably changed.

@@ -572,80 +571,80 @@
 	 * 	TODO: We need a new/better story for layouts and borders ??

 	 */

 	protected Composite createFlatFormComposite(Composite parent) {

-		Composite result = fWidgetFactory.createFlatFormComposite(parent);

+		Composite result = this.fWidgetFactory.createFlatFormComposite(parent);

 		FlatFormLayout formLayout = new FlatFormLayout();

-		formLayout.marginWidth = formLayout.marginHeight = 0;		

+		formLayout.marginWidth = formLayout.marginHeight = 0;

 		result.setLayout(formLayout);

 		return result;

 	}

-	

+

 	/**

 	 * @return the BPEL Tabbed Property Sheet page.

 	 */

-	

+

 	public BPELTabbedPropertySheetPage getTabbedPropertySheetPage() {

-		return fTabbedPropertySheetPage;

+		return this.fTabbedPropertySheetPage;

 	}

-	

-	

+

+

 	/**

 	 * @return the IFile that the editor is editing.

 	 */

-	

+

 	public IFile getBPELFile() {

 		return ((IFileEditorInput) getBPELEditor().getEditorInput()).getFile();

 	}

 

-	/** 

+	/**

 	 * Returns a token indicating which widget should have focus.  Note that the token can't

 	 * be tied to this particular instance of the section; after the section is destroyed

 	 * and re-created, the token must still be valid.

-	 * @return the user context 

+	 * @return the user context

 	 */

 	public Object getUserContext() {

 		return null;

 	}

 

-	/** 

+	/**

 	 * Accepts a token created by getUserContext() and gives focus to the widget represented

 	 * by the token.

 	 * @param userContext the user context to restore.

 	 */

 	public void restoreUserContext(Object userContext) {

 	}

-	

+

 	/**

 	 * Shows the given marker.

 	 * @param marker

 	 */

 	public void gotoMarker (IMarker marker) {

-		

+

 	}

-	

+

 	/**

 	 * Returns true if this section knows how to show the given marker.

-	 * 

-	 * @param marker the marker to be checked. 

-	 * @return true if so, false otherwise ... 

+	 *

+	 * @param marker the marker to be checked.

+	 * @return true if so, false otherwise ...

 	 */

-	

+

 	public boolean isValidMarker (IMarker marker) {

 		return true;

 	}

 

-	

+

 	/**

-	 * Return the Context names that allows us to point markers correctly at this 

+	 * Return the Context names that allows us to point markers correctly at this

 	 * section.

-	 * 

-	 * @return an array of context names 

+	 *

+	 * @return an array of context names

 	 */

-	

+

 	public String[] getContextNames () {

-		return new String[] {}; 

+		return new String[] {};

 	}

-	

-	

+

+

 	/**

 	 * Given a model object, selects it in the BPEL Editor and makes sure the

 	 * properties pages are also shown for it.

diff --git a/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/properties/CaseConditionSection.java b/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/properties/CaseConditionSection.java
index 1589341..a327b0e 100644
--- a/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/properties/CaseConditionSection.java
+++ b/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/properties/CaseConditionSection.java
@@ -13,44 +13,39 @@
 import org.eclipse.bpel.model.BPELPackage;

 import org.eclipse.bpel.model.ElseIf;

 import org.eclipse.bpel.model.If;

-import org.eclipse.bpel.ui.Messages;

 import org.eclipse.bpel.ui.expressions.IEditorConstants;

 import org.eclipse.emf.ecore.EObject;

 import org.eclipse.emf.ecore.EStructuralFeature;

-import org.eclipse.swt.widgets.Composite;

-

 

 /**

  * Details section for the CaseCondition of an activity (a boolean expression).

  */

 public class CaseConditionSection extends ExpressionSection {

-	

 

+	/*

+	 * (non-Javadoc)

+	 * @see org.eclipse.bpel.ui.properties.ExpressionSection

+	 * #getExpressionType()

+	 */

 	@Override

-	protected String getExpressionType() { 

-		return IEditorConstants.ET_BOOLEAN ; 

+	protected String getExpressionType() {

+		return IEditorConstants.ET_BOOLEAN ;

 	}

-	

-	

-	@Override

-	protected Composite createNoEditorWidgets(Composite composite) {

-		

-		return createNoEditorWidgetsCreateComposite(composite,			

-				Messages.ElseIfConditionSection_No_condition_specified_1 + NL + NL +

-				Messages.ElseIfConditionSection_Create_condition_text_2 ,				

-				Messages.ElseIfConditionSection_Create_a_New_Condition_2);

-	}

-	

+

+	/*

+	 * (non-Javadoc)

+	 * @see org.eclipse.bpel.ui.properties.ExpressionSection

+	 * #getStructuralFeature(org.eclipse.emf.ecore.EObject)

+	 */

 	@Override

 	protected EStructuralFeature getStructuralFeature (EObject object) {

-		

-		if (object instanceof If) {

-			return BPELPackage.eINSTANCE.getIf_Condition();

-		}

-		if (object instanceof ElseIf) {

-			return BPELPackage.eINSTANCE.getElseIf_Condition();

-		}

-		return super.getStructuralFeature(object);

-	}

 

+		if( object instanceof If )

+			return BPELPackage.eINSTANCE.getIf_Condition();

+

+		if( object instanceof ElseIf )

+			return BPELPackage.eINSTANCE.getElseIf_Condition();

+

+		return null;

+	}

 }

diff --git a/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/properties/ExpressionAssignCategory.java b/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/properties/ExpressionAssignCategory.java
index b84f011..e1d6c2d 100644
--- a/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/properties/ExpressionAssignCategory.java
+++ b/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/properties/ExpressionAssignCategory.java
@@ -37,10 +37,10 @@
  * claim to own it, then we will use whatever combo selection is stored in the transient

  * CopyExtension.  The same procedure is followed when refreshing the contents of the

  * page.

- * 

+ *

  * When you select a *different* category in the combo, we must update the value in the

  * CopyExtension.  We should also replace the existing Copy with an *empty* Copy.

- * 

+ *

  * Categories should become responsible for storing the value into the model themselves.

  */

 public class ExpressionAssignCategory extends ExpressionSection implements IAssignCategory {

@@ -49,36 +49,36 @@
 	 * @see org.eclipse.bpel.ui.properties.IAssignCategory#isHidden()

 	 */

 	public boolean isHidden() {

-		return isHidden; 

+		return this.isHidden;

 	}

-	

+

 	protected BPELPropertySection fOwnerSection;

 

 	protected Composite composite;

-	

+

 	protected Composite fParent;

-		

-	protected ExpressionAssignCategory( BPELPropertySection ownerSection ) {		

+

+	protected ExpressionAssignCategory( BPELPropertySection ownerSection ) {

 		this.fOwnerSection = ownerSection;

 	}

 

-	

+

 	/**

 	 * @see org.eclipse.bpel.ui.properties.BPELPropertySection#createControls(org.eclipse.swt.widgets.Composite, org.eclipse.ui.views.properties.tabbed.TabbedPropertySheetPage)

 	 */

 	@Override

-	public void createControls(Composite parent, TabbedPropertySheetPage aTabbedPropertySheetPage) {		

+	public void createControls(Composite parent, TabbedPropertySheetPage aTabbedPropertySheetPage) {

 		super.createControls(parent, aTabbedPropertySheetPage);

-		fParent = parent;

+		this.fParent = parent;

 	}

 	/**

 	 * @see org.eclipse.bpel.ui.properties.IAssignCategory#getComposite()

 	 */

 	public Composite getComposite() {

-		return fParent;

+		return this.fParent;

 	}

-	

-	

+

+

 	// This is used by changeHelper to determine what shows up in Undo/Redo.

 	// The return value is FlatFormatted with getName() as the only argument.

 	// Subclasses may override.

@@ -87,15 +87,10 @@
 	}

 

 	protected boolean isToOrFromAffected(Notification n) {

-		// hack:

 		return true;

-//		if (isFrom) {

-//			return (n.getFeatureID(Copy.class) == BPELPackage.COPY__FROM);

-//		}

-//		return (n.getFeatureID(Copy.class) == BPELPackage.COPY__TO);

 	}

 

-	

+

 	@Override

 	protected MultiObjectAdapter[] createAdapters() {

 		MultiObjectAdapter adapter = new BatchedMultiObjectAdapter() {

@@ -103,29 +98,29 @@
 			boolean toOrFromAffected = false;

 			@Override

 			public void notify(Notification n) {

-				needRefresh = isBodyAffected(n);

-				

+				this.needRefresh = isBodyAffected(n);

+

 				// if (isBodyAffected(n) && !isExecutingStoreCommand) needRefresh = true;

 				if (isToOrFromAffected(n)) {

-					toOrFromAffected = true;

+					this.toOrFromAffected = true;

 				}

 				refreshAdapters();

 			}

 			@Override

 			public void finish() {

-				if (needRefresh || toOrFromAffected) {

+				if (this.needRefresh || this.toOrFromAffected) {

 					updateWidgets();

 				}

-				if (toOrFromAffected) {

+				if (this.toOrFromAffected) {

 					updateCategoryWidgets();

 				}

-				toOrFromAffected = false;

-				needRefresh = false;

+				this.toOrFromAffected = false;

+				this.needRefresh = false;

 			}

 		};

 		return new MultiObjectAdapter[] { adapter };

 	}

-		

+

 	protected void updateCategoryWidgets() {

 		updateEditor();

 	}

@@ -133,41 +128,40 @@
 	/**

 	 * Policy: wrap the command with contexts from the ownerSection (rather

 	 * than from the category itself).  On undo, the ownerSection will delegate

-	 * to the category's methods. 

+	 * to the category's methods.

 	 */

-	

 	@Override

 	protected Command wrapInShowContextCommand(Command inner) {

-		return super.wrapInShowContextCommand(inner, fOwnerSection);

+		return super.wrapInShowContextCommand(inner, this.fOwnerSection);

 	}

-	

-	/**

-	 * @see org.eclipse.bpel.ui.properties.IAssignCategory#getName()

-	 */

-	public String getName() { 

-		return Messages.ExpressionAssignCategory_Expression_1; 

-	} 

 

-	

-	/**

-	 * @see org.eclipse.bpel.ui.properties.IAssignCategory#isCategoryForModel(org.eclipse.emf.ecore.EObject)

+	/*

+	 * (non-Javadoc)

+	 * @see org.eclipse.bpel.ui.properties.IAssignCategory

+	 * #getName()

+	 */

+	public String getName() {

+		return Messages.ExpressionAssignCategory_Expression_1;

+	}

+

+	/*

+	 * (non-Javadoc)

+	 * @see org.eclipse.bpel.ui.properties.IAssignCategory

+	 * #isCategoryForModel(org.eclipse.emf.ecore.EObject)

 	 */

 	public boolean isCategoryForModel ( EObject aModel ) {

 		IVirtualCopyRuleSide side = BPELUtil.adapt(aModel, IVirtualCopyRuleSide.class);

-		if (side != null) {

-			return side.getExpression() != null;

-		}		

-		return false;

+		return side != null ? side.getExpression() != null : false;

 	}

 

-	

+

 	@Override

 	protected Command newStoreToModelCommand  (Object body) {

 		CompoundCommand result = new CompoundCommand();

 		// If there is no condition, create one.

 		Expression oldExp = getExprFromModel();

 		Expression exp = BPELFactory.eINSTANCE.createExpression();

-		

+

 		// Don't set the language, because if the user has changed the

 		// language, a condition would already exist at this point.

 		if (oldExp != null) {

@@ -175,38 +169,36 @@
 		}

 		exp.setBody(body);

 		result.add(new SetCommand( getExpressionTarget(), exp, getStructuralFeature() ));

-		fEditor.addExtraStoreCommands(result);

+

+		// VZ: fEditor.addExtraStoreCommands(result);

+

 		return result;

 	}

 

-	

+	/*

+	 * (non-Javadoc)

+	 * @see org.eclipse.bpel.ui.properties.ExpressionSection

+	 * #getStructuralFeature(org.eclipse.emf.ecore.EObject)

+	 */

 	@Override

 	protected EStructuralFeature getStructuralFeature(EObject object) {

-		if (object instanceof AbstractAssignBound) {

-			return BPELPackage.eINSTANCE.getAbstractAssignBound_Expression();

-		}

-		return super.getStructuralFeature(object);

+		return object instanceof AbstractAssignBound ? BPELPackage.eINSTANCE.getAbstractAssignBound_Expression() : null;

 	}

 

-

 	/**

 	 * This is just a workaround to keep the AssignCategory from changing too much.

 	 * @param model the model object

 	 */

-	

 	public void setInput (EObject model) {

 		basicSetInput(model);

 		addAllAdapters();

-		

-		

-		Object language = selectedExpressionLanguage ();

-		

-		if (language == NO_EXPRESSION) {

-			doChooseExpressionLanguage ( SAME_AS_PARENT );

-		}		

 	}

-	

-	

+

+	/*

+	 * (non-Javadoc)

+	 * @see org.eclipse.bpel.ui.properties.ExpressionSection

+	 * #createClient(org.eclipse.swt.widgets.Composite)

+	 */

 	@Override

 	protected final void createClient(Composite parent) {

 		// ugly HACK to make subclasses work

@@ -218,6 +210,5 @@
 		parent.setLayout(fillLayout);

 		super.createClient(parent);

 	}

-	

 }

 

diff --git a/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/properties/ExpressionSection.java b/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/properties/ExpressionSection.java
index 48f0866..6daa637 100644
--- a/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/properties/ExpressionSection.java
+++ b/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/properties/ExpressionSection.java
@@ -10,801 +10,350 @@
  *******************************************************************************/

 package org.eclipse.bpel.ui.properties;

 

-import java.util.ArrayList;

-

-import org.eclipse.bpel.common.ui.details.IDetailsAreaConstants;

-import org.eclipse.bpel.common.ui.details.widgets.DecoratedLabel;

-import org.eclipse.bpel.common.ui.details.widgets.StatusLabel2;

+import org.eclipse.bpel.common.ui.details.IOngoingChange;

+import org.eclipse.bpel.common.ui.editmodel.AbstractEditModelCommand;

 import org.eclipse.bpel.common.ui.flatui.FlatFormAttachment;

 import org.eclipse.bpel.common.ui.flatui.FlatFormData;

 import org.eclipse.bpel.model.BPELFactory;

 import org.eclipse.bpel.model.Expression;

-import org.eclipse.bpel.model.util.BPELConstants;

-import org.eclipse.bpel.ui.BPELUIPlugin;

-import org.eclipse.bpel.ui.Messages;

+import org.eclipse.bpel.ui.IBPELUIConstants;

 import org.eclipse.bpel.ui.commands.CompoundCommand;

 import org.eclipse.bpel.ui.commands.SetCommand;

-import org.eclipse.bpel.ui.details.providers.ExpressionEditorDescriptorContentProvider;

+import org.eclipse.bpel.ui.editors.xpath.XPathTextEditor;

 import org.eclipse.bpel.ui.expressions.IEditorConstants;

-import org.eclipse.bpel.ui.expressions.IExpressionEditor;

-import org.eclipse.bpel.ui.extensions.BPELUIRegistry;

-import org.eclipse.bpel.ui.extensions.ExpressionEditorDescriptor;

-import org.eclipse.bpel.ui.util.BPELUtil;

+import org.eclipse.bpel.ui.util.BatchedMultiObjectAdapter;

+import org.eclipse.bpel.ui.util.MultiObjectAdapter;

 import org.eclipse.core.resources.IMarker;

-import org.eclipse.core.runtime.CoreException;

-import org.eclipse.core.runtime.IStatus;

+import org.eclipse.core.runtime.IAdaptable;

 import org.eclipse.emf.common.notify.Notification;

 import org.eclipse.emf.ecore.EObject;

 import org.eclipse.emf.ecore.EStructuralFeature;

+import org.eclipse.emf.ecore.resource.Resource;

 import org.eclipse.gef.commands.Command;

-import org.eclipse.jface.viewers.ComboViewer;

-import org.eclipse.jface.viewers.IStructuredSelection;

-import org.eclipse.jface.viewers.LabelProvider;

-import org.eclipse.jface.viewers.StructuredSelection;

-import org.eclipse.osgi.util.NLS;

 import org.eclipse.swt.SWT;

-import org.eclipse.swt.custom.StackLayout;

-import org.eclipse.swt.events.SelectionEvent;

-import org.eclipse.swt.events.SelectionListener;

 import org.eclipse.swt.graphics.Font;

 import org.eclipse.swt.graphics.FontData;

-import org.eclipse.swt.layout.FillLayout;

-import org.eclipse.swt.widgets.Button;

-import org.eclipse.swt.widgets.Combo;

 import org.eclipse.swt.widgets.Composite;

-import org.eclipse.swt.widgets.Control;

 import org.eclipse.swt.widgets.Label;

-

-

+import org.eclipse.ui.ide.IGotoMarker;

 

 /**

- * Base class with some shared behavior for details panes that edit an expression.

- * 

- * NB: Nov 2nd, 2006

- * 

- * The code used CComboViewer and CCombo to show the expression language drop down. 

- * There used to be a lot of code that dealt with refresh and selection disappearing in the

- * CCombo to the point that the XPath editor was created and destroyed 14 times every time a 

- * object was selected in the process map that required this particular expression section.

- * 

- * I debugged the code, I swear it was this bad.

- * 

- * I had done some cleanup here to make it easier to understand because there is truly a little

- * too much magic for this simple thing. So ...

- * 

- * <ol>

- * <li> The expression language is a Combo, wrapped in a ComboViewer.

- * <li> The ComboViewer has a content provider which it will refresh every time a setInput is 

- * used on the ComboViewer. Any other refresh logic is not necessary.

- * <li> The section is configured when the basicSetInput is called. Then the editor is picked,created, etc.

- * <li> There is a general problem with refresh() method calls, .aboutToBeShown(), etc. many of them simply 

- * used to call refresh() which just destroyed and re-created the views. 

- * 

- * </ol>

- * 

+ * Base class with some shared behavior for details panes that edit a XPath expression.

  * @author Michal Chmielewski (michal.chmielewski@oracle.com)

- * 

+ * @author Vincent Zurczak - EBM WebSourcing (Merge this class with TextSection and simplify it by only using the XPath editor)

  */

-public abstract class ExpressionSection extends TextSection {

-	

-	 

-	protected String editorLanguage;

-	

-	protected ComboViewer expressionLanguageViewer;	

-	

-	protected ExpressionComboContentProvider expressionComboContentProvider;

-	

-	/** The editor area composite, it is used to display editors or the no-editor widgets in it */

-	protected Composite fEditorArea ;

-	

-	

-	// Pseudo-model object to represent no expression at all (in which case no editor

-	// is used).

-	protected static final Object NO_EXPRESSION = new Object();

-	

-	// Pseudo-model object to represent the absence of an expression language within

-	// the expression (i.e. the expression language is inherited from the Process).

-	protected static final Object SAME_AS_PARENT = new Object();

-	

-	/** The composite which holds the no-editor widgets */

-	protected Composite fNoEditorWidgets;

+public abstract class ExpressionSection extends BPELPropertySection {

 

-	/** The parent composite, it owns the expression language combo and the editor area */

-	protected Composite fParentComposite;

+	protected Composite fEditorArea ;

+	protected XPathTextEditor fEditor;

 

 	protected Font boldFont;

-

 	protected String title;

-

 	protected Label titleLabel;

 

-	StackLayout fEditorAreaStackLayout;

-

-	Composite fEditorComposite;

-

-	protected StatusLabel2 expressionLanguageLabel;

-

-	/** The EMF structural feature that is this expression */

 	protected EStructuralFeature fStructuralFeature;

+	protected IOngoingChange change;

 

-	protected Button fCreateExpressionButton;

 

-	Combo expressionLanguageCombo;

+	public ExpressionSection() {

 

-	

-	protected static boolean objectsEqual(Object lhs, Object rhs) {

-		if (lhs == null) return (rhs == null);

-		return lhs.equals(rhs);

-	}

-	

-

-	

-	/**

-	 * A content provider which (1) adds the NO_EXPRESSION and SAME_AS_PARENT elements,

-	 * (2) ensures that the selected object is in the list, and (3) removes any

-	 * elements from the list which are not supported (unless they happen to be

-	 * the selected object at the moment--an error case).

-	 */

-		

-	

-	class ExpressionComboContentProvider extends ExpressionEditorDescriptorContentProvider {

-		Object selectedObject = SAME_AS_PARENT;

-		

-		

-		/**

-		 * @see org.eclipse.bpel.ui.details.providers.AbstractContentProvider#getElements(java.lang.Object)

-		 */

-		@Override

-		public Object[] getElements(Object inputElement) {

-			Object[] descriptors = super.getElements(inputElement);

-			

-			ArrayList<Object> result = new ArrayList<Object>(descriptors.length + 2);

-			if (isExpressionOptional() || selectedObject==NO_EXPRESSION) {

-				result.add(NO_EXPRESSION);

+		this.change = new IOngoingChange() {

+			public String getLabel() {

+				return getCommandLabel();

 			}

-			if (selectedObject==SAME_AS_PARENT || allowItem(SAME_AS_PARENT)) {

-				result.add(SAME_AS_PARENT);

-			}

-			for (Object descriptor : descriptors) {

-				if (objectsEqual(selectedObject, descriptor) ||	allowItem(descriptor)) {

-					result.add(descriptor);

+			public Command createApplyCommand() {

+				if (ExpressionSection.this.fEditor == null) {

+					return null;

 				}

+

+				CompoundCommand result = new CompoundCommand();

+				Expression exp = BPELFactory.eINSTANCE.createCondition();

+				exp.setBody( ExpressionSection.this.fEditor.getContents());

+				result.add( new SetCommand( getExpressionTarget(), getExpression4Target( exp ) , getStructuralFeature()));

+

+				// refresh the editor

+				result.add( new AbstractEditModelCommand() {

+					@Override

+					public void execute() {

+						if (ExpressionSection.this.fEditor != null) {

+							ExpressionSection.this.fEditor.markAsClean();

+						}

+					}

+					// TODO: is this correct?

+					@Override

+					public Resource[] getResources() {

+						return new Resource[ 0 ];

+					}

+					@Override

+					public Resource[] getModifiedResources() {

+						return new Resource[ 0 ];

+					}

+				});

+

+				return wrapInShowContextCommand(result);

 			}

-			if (!result.contains(selectedObject)) {

-				result.add(selectedObject);

+

+			public void restoreOldState() {

+				// updateWidgets();

 			}

-			return result.toArray();

-		}

-		/**

-		 * 

-		 * @param element

-		 * @return true if item is to be allowed, false otherwise.

-		 */

-		public boolean allowItem(Object element) {

-			String language = getEffectiveLanguage(getExpressionLanguage(element));

-			try {

-				IExpressionEditor exEditor = BPELUIRegistry.getInstance().getExpressionEditor(language);

-				return (exEditor == null)? false : isEditorSupported(exEditor);

-			} catch (CoreException e) {

-				BPELUIPlugin.log(e);

-				return false;

-			}

-		}		

+		};

 	}

-	

-	

+

+

+	protected void notifyEditorChanged() {

+		// TODO: why is this method being called before createClient() has finished

+		// when a BuiltInExpressionEditor was selected in the model?

+		if (this.change != null) {

+			getCommandFramework().notifyChangeInProgress(this.change);

+		}

+	}

+

+

+	/**

+	 * @see org.eclipse.bpel.ui.properties.BPELPropertySection#aboutToBeHidden()

+	 */

+	@Override

+	public void aboutToBeHidden() {

+		super.aboutToBeHidden();

+		if (this.change != null)

+			getCommandFramework().notifyChangeDone(this.change);

+

+		// if (this.fEditor != null) this.fEditor.aboutToBeHidden();

+	}

+

+

 	@Override

 	protected void addAllAdapters() {

 		super.addAllAdapters();

 		Expression e = getExprFromModel();

-		if (e != null) {

-			fAdapters[0].addToObject(e);

-		}

+		if (e != null)

+			this.fAdapters[0].addToObject(e);

 	}

 

-	/**

-	 * Get rid of the current editor.

-	 * We do this when the Expression Language changes and we have to replace the editor with the right

-	 * editor for the expression language.

-	 */

-	

+

 	@Override

-	protected void disposeEditor() {		

-	    super.disposeEditor();

-		editorLanguage = null;

-		if (fEditorComposite != null) {

-			fEditorComposite.dispose();

-			fEditorComposite = null;

-		}

-	}

-	

-	

-	protected Object getDefaultBody (String newLanguage, String exprType ) {

-		

-		IExpressionEditor ed = null;

-		try {

-			newLanguage = getEffectiveLanguage(newLanguage);

-			ed = BPELUIRegistry.getInstance().getExpressionEditor(newLanguage);

-		} catch (CoreException e) {

-			BPELUIPlugin.log(e);

-			return EMPTY_STRING;

-		}

-		

-		// TODO: call supportsExpressionType in the right place

-		ed.setExpressionType(exprType);

-		ed.setModelObject( getInput() );

-		return ed.getDefaultContent() ;

-	}

-	

-	

-	protected void createTitleWidgets(Composite composite) {

-		FlatFormData data;

-		titleLabel = fWidgetFactory.createLabel(composite, title);

-		titleLabel.setFont(boldFont);

-		data = new FlatFormData();

-		data.left = new FlatFormAttachment(0, 0);

-		data.top = new FlatFormAttachment(0, 0);

-		data.right = new FlatFormAttachment(100, 0);

-		titleLabel.setLayoutData(data);

-	}

-	

-	protected void createExpressionLanguageWidgets(final Composite composite) {

+	protected MultiObjectAdapter[] createAdapters() {

 

-		FlatFormData data;

-		

-		DecoratedLabel nameLabel = new DecoratedLabel(composite,SWT.LEFT);

-		fWidgetFactory.adapt(nameLabel);		

-		nameLabel.setText( Messages.ExpressionSection_Expression_language_1); 

-		expressionLanguageLabel = new StatusLabel2( nameLabel );				

-		expressionLanguageCombo = new Combo (composite, SWT.FLAT | SWT.READ_ONLY );

-		fWidgetFactory.adapt(expressionLanguageCombo);

-		

-		expressionLanguageViewer = new ComboViewer(expressionLanguageCombo);				

-		

-		data = new FlatFormData();

-		data.left = new FlatFormAttachment(0, BPELUtil.calculateLabelWidth(nameLabel, STANDARD_LABEL_WIDTH_LRG));

-		data.right = new FlatFormAttachment(100, 0);

-		if (this.title != null) {

-			data.top = new FlatFormAttachment(this.titleLabel, IDetailsAreaConstants.VSPACE);

-		} else {

-			data.top = new FlatFormAttachment(0, 0);

-		}

-		expressionLanguageViewer.getControl().setLayoutData(data);

+		MultiObjectAdapter adapter = new BatchedMultiObjectAdapter() {

 

+			boolean needRefresh = false;

 

-		expressionLanguageViewer.setLabelProvider(new LabelProvider() {

 			@Override

-			public String getText(Object element) {

-				if (element == NO_EXPRESSION) {

-					return Messages.ExpressionSection_No_Expression_2; 

-				}

-				

-				if (element == SAME_AS_PARENT) {

-					String text = getBPELEditor().getProcess().getExpressionLanguage();

-					if (text == null) {

-						text = BPELConstants.XMLNS_XPATH_EXPRESSION_LANGUAGE;

-					}

-					ExpressionEditorDescriptor descriptor = BPELUIRegistry.getInstance().getExpressionEditorDescriptor(text);

-					if (descriptor != null) {

-						text = descriptor.getLabel();

-					}

-					return NLS.bind(Messages.ExpressionSection_Same_as_Process_1, (new Object[] { text })); 

-				}

-				if (element instanceof String) {

-					return (String)element;	

-				}

-				ExpressionEditorDescriptor descriptor = (ExpressionEditorDescriptor) element;

-				String text = descriptor.getLabel();

-				return (text != null) ? text : descriptor.getExpressionLanguage();

-			}

-		});

-		

-		expressionComboContentProvider = new ExpressionComboContentProvider();		

-		expressionLanguageViewer.setContentProvider(expressionComboContentProvider);

-		expressionLanguageViewer.setInput( SAME_AS_PARENT );

-		

-		

-		data = new FlatFormData();

-		data.left = new FlatFormAttachment(0, 0);

-		data.right = new FlatFormAttachment(expressionLanguageViewer.getControl(), -IDetailsAreaConstants.HSPACE);

-		data.top = new FlatFormAttachment(expressionLanguageViewer.getControl(), 0, SWT.CENTER);

-		expressionLanguageLabel.setLayoutData(data);

-		

-		// Selection on the combo.

-		expressionLanguageCombo.addSelectionListener(new SelectionListener() {

+			public void notify (Notification n) {

 

-			public void widgetDefaultSelected(SelectionEvent e) {

-				widgetSelected(e);				

+				if (markersHaveChanged(n)) {

+					updateMarkers();

+					return ;

+				}

+				this.needRefresh = this.needRefresh || isBodyAffected(n);

+				refreshAdapters();

 			}

 

-			public void widgetSelected(SelectionEvent e) {								

-				updateFromSelection ( selectedExpressionLanguage() );

+			@Override

+			public void finish() {

+				if (this.needRefresh) {

+					// updateWidgets();

+				}

+

+				this.needRefresh = false;

 			}

-		

-		});			

-	}

-	

-	protected void updateFromSelection ( Object elm ) {

+		};

 

-		Command cmd; 

-		

-		if (elm == NO_EXPRESSION || elm == null ) {

-			cmd = new SetCommand(getExpressionTarget(), null, getStructuralFeature() );

-		} else {					

-			

-			String language = getExpressionLanguage(elm);											

-			Expression exp = BPELFactory.eINSTANCE.createCondition();					

-			exp.setExpressionLanguage(language);

+		return new MultiObjectAdapter[] { adapter };

+	}

 

-			Object newDefaultBody = getDefaultBody(language, getExpressionType()  );

-			

-			// Figure out what the new default value should be for this expression,

-			// 	and install it in the model.  It is necessary to do this before we

-			// 	properly create the editor (which happens when we update widgets in

-			// response to the model change).

-			exp.setBody(newDefaultBody);

-								

-			cmd = new SetCommand(getExpressionTarget(), getExpression4Target (exp), getStructuralFeature()) ;

-		}

-		

-		getCommandFramework().execute( wrapInShowContextCommand(cmd) ); 

-	}

-	

-	/**

-	 * Return the currently selected expression language.

-	 * 

-	 * @return the currently selected expression language

-	 */

-	

-	protected Object selectedExpressionLanguage () {

-		IStructuredSelection selection = (IStructuredSelection) expressionLanguageViewer.getSelection();

-		return selection.getFirstElement();		

-	}

-	

-	/**

-	 * This method is used by subclasses who need to select a language programmatically.

-	 * 

-	 */

-	

-	protected void doChooseExpressionLanguage (Object model) {

-		

-		Object selection = selectedExpressionLanguage();

-		if (selection == model) {

-			return ;

-		}

-		

-		// By setting the selection on the combo box, we are kicking off a selection changed event.

-		// This is intentional, because we are emulating the a user interface command.

-		

-		expressionLanguageViewer.setSelection(new StructuredSelection( model ), true);

-		updateFromSelection( selectedExpressionLanguage() );

-	}

-	

-	

-	protected void updateExpressionLanguageWidgets() {

-        

-		Object model = NO_EXPRESSION;

-        if (getExprFromModel() != null) {

-			String language = getExpressionLanguageFromModel();

-	        if (language == null) {

-	            model = SAME_AS_PARENT;

-	        } else {

-	            model = BPELUIRegistry.getInstance().getExpressionEditorDescriptor(language);

-	            if (model == null) {

-	            	model = language;

-	            }

-	        }

-        }

-        

-		expressionLanguageViewer.setSelection( new StructuredSelection( model ), true );				

-		

-		// Reflect the model in the editor

-		updateEditor();

-		

-		// Markers

-		updateMarkers();

-    }

-	

-	

+

 	/**

 	 *  When this method is called, the section has already been created.

-	 *  

+	 *

 	 *  The widgets are available to be configured, however, the section may not be shown yet.

-	 *  

+	 *

 	 *  The concept here is that we are reflecting the input selected in the UI. So the path that is taken

 	 *  by this code must not create any re-doable commands, just set the widgets to what they are supposed to

 	 *  be based on the model.

 	 */

-	

-	

 	@Override

 	protected void basicSetInput (EObject newInput) {

-		

+

 		super.basicSetInput(newInput);

-		

+

 		/** Figure out based in the input, what EMF structural feature we are setting */

-		setStructuralFeature ( getStructuralFeature (newInput) );

-		

-		// A different input may have different expression language settings.

-		expressionLanguageViewer.refresh(true);

-				 

-		// Reveal the right selection in the widget.

-		updateExpressionLanguageWidgets();		

+		this.fStructuralFeature = getStructuralFeature( newInput );

 	}

-	

 

-	protected void setStructuralFeature ( EStructuralFeature feature ) {

-		fStructuralFeature = feature;

-	}

-	

+

 	/**

-	 * Get the structural feature of this input object.

-	 * This will be something like BPELPackage.eINSTANCE.getWait_Until()

-	 *  

-	 * @param eObject

-	 * @return the structural feature that we will be setting.

-	 */

-	

-	protected EStructuralFeature getStructuralFeature ( EObject eObject ) {

-		return null;

-	}

-	

-	

-	/** 

-	 * Return the previously computed structural feature of the input object.

-	 * @return

-	 */

-	protected EStructuralFeature getStructuralFeature () {

-		return fStructuralFeature;

-	}

-	

-	protected boolean isExpressionOptional() { 

-		return true; 

-	}

-

-	

-	protected String getExpressionType() { 

-		return IEditorConstants.ET_ANY ; 

-	}

-	

-		

-	/** 

 	 * The expression target is the target object on which we can execute

 	 * the SetCommand(target,object,structural-feature).

-	 * 

+	 *

 	 * In most cases, it is just the input of the section. But in some cases

 	 * the input if the section does not match the target, so sub-classes

 	 * may override this method.

-	 * 

+	 *

 	 * @return

 	 */

 	protected EObject getExpressionTarget () {

 		return getInput();

 	}

-	

-	

-	/**

-	 * Returns the expressionLanguage string underlying the given combo element.  For

-	 * cases other than NO_EXPRESSION, this is the proper value to store into the model.

-	 */

-	protected String getExpressionLanguage (Object comboElement) {

-		if (comboElement == NO_EXPRESSION || comboElement == SAME_AS_PARENT) {

-			return null;

-		}

-		String language = null;

-		if (comboElement instanceof ExpressionEditorDescriptor) {

-		    language = ((ExpressionEditorDescriptor)comboElement).getExpressionLanguage();

-		} else if (comboElement instanceof String) {

-			language = (String)comboElement;

-		}

-		if (EMPTY_STRING.equals(language)) {

-			language = null; 

-		}

-		return language;

+

+	protected String getExpressionType() {

+		return IEditorConstants.ET_ANY ;

 	}

-	

+

+

 	/**

-	 * Returns the expression language which will be in effect if this language is

-	 * read from/stored into the model.  (i.e. if language is null, the value is

-	 * inherited from the process or the default, XPath). 

+	 * Return the previously computed structural feature of the input object.

+	 * @return

 	 */

-	protected String getEffectiveLanguage(String language) {

-		if (language == null) {

-			language = getBPELEditor().getProcess().getExpressionLanguage();

-			if (language == null) {

-				language = BPELConstants.XMLNS_XPATH_EXPRESSION_LANGUAGE;

-			}

-		}

-		return language;

+	protected final EStructuralFeature getStructuralFeature() {

+		return this.fStructuralFeature;

 	}

-	

+

+

+	/**

+	 * @param object

+	 * @return the structural feature to update on the model object

+	 */

+	protected abstract EStructuralFeature getStructuralFeature( EObject object );

+

+

 	/**

 	 * Return the actual namespace from the expression, or null if not set.

 	 */

 	protected String getExpressionLanguageFromModel() {

 		Expression expression = getExprFromModel();

-		if (expression == null) {

-			return null;

-		}

-		return expression.getExpressionLanguage();

+		return expression != null ? expression.getExpressionLanguage() : null;

 	}

-	

-	

-	

+

+

+

 	protected Expression getExprFromModel() {

-		

-		EObject target = getExpressionTarget();		

+

+		EObject target = getExpressionTarget();

 		if (target != null) {

-			Object result = target.eGet( getStructuralFeature() );		

+			Object result = target.eGet( getStructuralFeature());

 			if (result instanceof Expression) {

 				return (Expression) result;

 			}

-		}		

+		}

 		return null;

 	}

-	

-	

+

+

 	protected Expression getExpression4Target ( Expression expression ) {

 		return expression;

 	}

-	

-	

-	

-	@Override

-	protected boolean isBodyAffected(Notification n) {

-		

-		if (n.getOldValue() instanceof Expression ||

-			n.getNewValue() instanceof Expression ||

-			n.getNotifier() instanceof Expression) {

-			

-			return true;

-		}

-		return n.getFeature() == getStructuralFeature();			

+

+

+	/**

+	 * Determines whether a notification affects this section.

+	 * @param n a notification

+	 * @return true if it affects this section, false otherwise

+	 */

+	protected boolean isBodyAffected( Notification n ) {

+

+		return n.getOldValue() instanceof Expression

+				|| n.getNewValue() instanceof Expression

+				|| n.getNotifier() instanceof Expression

+				|| n.getFeature() == getStructuralFeature();

 	}

 

-	

+

+	/*

+	 * (non-Javadoc)

+	 * @see org.eclipse.bpel.ui.properties.BPELPropertySection

+	 * #isValidMarker(org.eclipse.core.resources.IMarker)

+	 */

 	@Override

-	protected Command newStoreToModelCommand (Object body) {

-		

-		CompoundCommand result = new CompoundCommand();		

-		Expression oldExp = getExprFromModel();

-		

-		Expression exp = BPELFactory.eINSTANCE.createCondition();

-		

-		// Don't set the language, because if the user has changed the

-		// language, a condition would already exist at this point.

-		

-		if (oldExp != null) {

-			exp.setExpressionLanguage(oldExp.getExpressionLanguage());

+	public final boolean isValidMarker( IMarker marker ) {

+

+		// FIXME: the implementation may not be valid for all the sub-classes

+		boolean result = false;

+		try {

+			String context = (String) marker.getAttribute( "href.context" );

+			result = "name".equals ( context );

+

+		} catch( Exception ex ) {

+			// nothing

 		}

-		exp.setBody(body);

-		

-		result.add (new SetCommand(getExpressionTarget(), getExpression4Target(exp) , getStructuralFeature() ));

-		fEditor.addExtraStoreCommands (result);

-		

+

 		return result;

 	}

-	

-	

+

+

+	protected String getCommandLabel() {

+		return IBPELUIConstants.CMD_EDIT_EXPRESSION;

+	}

+

+

 	/**

 	 * Create the client area. This is just done once.

 	 */

-	

+

 	@Override

-	protected void createClient (Composite parent) {

-		

-		fParentComposite =  createFlatFormComposite(parent);

-		

-		if (this.title != null) {

-			createBoldFont(fParentComposite);

-			createTitleWidgets(fParentComposite);

+	protected void createClient( Composite parent ) {

+

+		// The top

+		this.fEditorArea =  createFlatFormComposite( parent );

+		if( this.title != null ) {

+

+			// The font

+			FontData[] fontData = parent.getDisplay().getSystemFont().getFontData();

+			fontData[ 0 ].setStyle( SWT.BOLD );

+			this.boldFont = new Font( parent.getDisplay(), fontData[ 0 ]);

+

+			// The title

+			FlatFormData data;

+			this.titleLabel = this.fWidgetFactory.createLabel( this.fEditorArea, this.title);

+			this.titleLabel.setFont(this.boldFont);

+			data = new FlatFormData();

+			data.left = new FlatFormAttachment(0, 0);

+			data.top = new FlatFormAttachment(0, 0);

+			data.right = new FlatFormAttachment(100, 0);

+			this.titleLabel.setLayoutData(data);

 		}

-		

-		createExpressionLanguageWidgets(fParentComposite);

-		

-		FlatFormData data = new FlatFormData();

-		

-		data.top = new FlatFormAttachment(expressionLanguageViewer.getControl(),IDetailsAreaConstants.VSPACE);

-		data.left = new FlatFormAttachment(0,0);

-		data.right = new FlatFormAttachment(100,0);

-		data.bottom = new FlatFormAttachment(100,0);

-					

-		fEditorArea = fWidgetFactory.createComposite(fParentComposite);			

-		

-		fEditorAreaStackLayout = new StackLayout();

-		fEditorArea.setLayout( fEditorAreaStackLayout );		

-		fEditorArea.setLayoutData(data);

-		

-		fNoEditorWidgets = createNoEditorWidgets(fEditorArea);

-		

-		fEditorAreaStackLayout.topControl = fNoEditorWidgets;			

-		

-		createChangeHelper();

+

+		// The expression editor

+		this.fEditor.createPartControl( this.fEditorArea );

 	}

-		

-	

-	protected Composite createNoEditorWidgets (Composite composite) {

-		return fWidgetFactory.createComposite(composite);

-	}

-	

-	protected Composite createNoEditorWidgetsCreateComposite (Composite composite, String message, String buttonMessage ) {

-			    	    

-		FlatFormData ffdata;

-		

-		Composite section = createFlatFormComposite(composite);		

-				

-		Label label = fWidgetFactory.createLabel(section,EMPTY_STRING, SWT.WRAP | SWT.READ_ONLY  );

-		

-		ffdata = new FlatFormData();

-		ffdata.left = new FlatFormAttachment(0, IDetailsAreaConstants.VSPACE );

-		ffdata.top = new FlatFormAttachment(0, IDetailsAreaConstants.VSPACE * 2);

-		ffdata.right = new FlatFormAttachment(100, 0);

-		label.setLayoutData(ffdata);

-		

-		

-		fCreateExpressionButton = fWidgetFactory.createButton(section, buttonMessage , SWT.PUSH); 

-		ffdata = new FlatFormData();

-		ffdata.left = new FlatFormAttachment(0, IDetailsAreaConstants.VSPACE);

-		ffdata.top = new FlatFormAttachment(label, IDetailsAreaConstants.VSPACE * 2);

-		fCreateExpressionButton.setLayoutData(ffdata);

-		

-		fCreateExpressionButton.addSelectionListener(new SelectionListener() {

-			public void widgetSelected(SelectionEvent e) {

-				doChooseExpressionLanguage(SAME_AS_PARENT);

-			}

-			public void widgetDefaultSelected(SelectionEvent e) { }

-		});

-		

-		label.setText(message);

-		

-		return section;

-	}

-	

-	

-	/** 

-	 * Create the editor.

-	 * 

+

+

+	/*

+	 * (non-Javadoc)

+	 * @see org.eclipse.bpel.ui.properties.TextSection

+	 * #dispose()

 	 */

-	

-	@Override

-	protected void createEditor (Composite parent) {

-									

-		String language = getEffectiveLanguage(getExpressionLanguageFromModel());

-		

-		try {

-			fEditor = BPELUIRegistry.getInstance().getExpressionEditor(language);

-		} catch (CoreException e) {

-			BPELUIPlugin.log(e);			

-			return ;

-		}

-			

-		editorLanguage = language;

-		fEditor.createControls(parent, getWidgetFactory());

-		

-		fEditor.addListener(new IExpressionEditor.Listener() {

-			public void notifyChanged() {

-				if (!updating) { // && !isExecutingStoreCommand()) {

-					notifyEditorChanged();

-				}

-			}

-			public void focusOut() {

-				// If expression editor has lost focus then apply current changes

-				getCommandFramework().applyCurrentChange();

-			}

-			public void focusIn() {

-				// TODO Auto-generated method stub

-			}

-		});

-	}

-	

-	/**

-	 * We update the editor from the model. This is a model-to-ui operation.

-	 * 

-	 */

-	@Override

-	protected void updateEditor() {		

-		Expression expr = getExprFromModel();

-		

-		Control previousTop = fEditorAreaStackLayout.topControl;

-		

-		if (expr == null) {

-			fEditorAreaStackLayout.topControl = fNoEditorWidgets;			

-		} else {

-			String newLanguage = getEffectiveLanguage(getExpressionLanguageFromModel());

-			

-			if ( newLanguage.equals(editorLanguage) == false || hasEditor() == false) {

-				// get rid of the old editor

-				// The "old" editorComposite will be buried in the stack layout				

-				disposeEditor();				

-				

-				fEditorComposite = fWidgetFactory.createComposite(fEditorArea);	

-				fEditorComposite.setLayout( new FillLayout() );

-				createEditor (fEditorComposite);

-				

-			}

-			fEditorAreaStackLayout.topControl = fEditorComposite;		

-		

-			// we update our editor with the model, since something may have changed

-			// in it that needs to be reflected in the editor.

-			fEditor.setExpressionType( getExpressionType() );

-			// editor.setExpressionType(getExpressionType(), getExpressionContext());

-			fEditor.setModelObject(getInput());

-			

-			// TODO: WTF ?

-			fEditor.setEditorContent( (String) expr.getBody());

-			fEditor.aboutToBeShown();

-		}

-		

-		

-		if ( previousTop != fEditorAreaStackLayout.topControl ) {

-			// Layout is necessary after swapping the top element in the stack layout

-			fEditorArea.layout(new Control[] { fEditorAreaStackLayout.topControl } );			

-		}				

-	}

-	

-	/**

-	 * This is used by the Expression Language combo to filter out editors that

-	 * can't be used with the current type/context.

-	 */

-	protected boolean isEditorSupported(IExpressionEditor exEditor) {

-		return exEditor.supportsExpressionType( getExpressionType() );

-	}

-	

-	/**

-	 * Whether the marker use type is useful for this section. 

-	 */

-	protected boolean isValidClientUseType (String useType) {

-		return false;

-	}

-	

-	/**

-	 * Answer if we have an editor visible. 

-	 * 

-	 * @return true if visible, false otherwise.

-	 */

-	

-	public boolean hasEditor () {

-		return (fEditor != null && fEditorAreaStackLayout.topControl != fNoEditorWidgets) ;

-	}

-	

-	private void createBoldFont (Composite parent) {

-		FontData[] data = parent.getDisplay().getSystemFont().getFontData();

-		FontData data0 = data[0];

-		data0.setStyle(SWT.BOLD);

-		boldFont = new Font(parent.getDisplay(), data0);

-	}

-	

-	/** (non-Javadoc)

-	 * @see org.eclipse.bpel.ui.properties.TextSection#dispose()

-	 */

-	

 	@Override

 	public void dispose() {

-		if (boldFont != null) {

-			boldFont.dispose();

-		}

+

+		this.fEditor.dispose();

+		if( this.boldFont != null && ! this.boldFont.isDisposed())

+			this.boldFont.dispose();

+

 		super.dispose();

 	}

-	

+

+

+	/*

+	 * (non-Javadoc)

+	 * @see org.eclipse.bpel.ui.properties.BPELPropertySection

+	 * #updateMarkers()

+	 */

 	@Override

-	protected void updateMarkers () {				

-		expressionLanguageLabel.clear();		

-		for(IMarker m : getMarkers(getInput())) {

-			if (expressionLanguageLabel.getControl().isDisposed() == false) {

-				expressionLanguageLabel.addStatus( BPELUtil.adapt(m, IStatus.class) );

-			} else {

-				new Throwable("FixMe: Why is update markers being called ?").printStackTrace();

-			}

-			

-		}		

-	}	

-	

-	

-	

-//	public void aboutToBeHidden() {

-//		super.aboutToBeHidden();

-//		if (expressionChangeHelper != null) {

-//			getCommandFramework().notifyChangeDone(expressionChangeHelper);

-//		}

-//	}

+	protected void updateMarkers () {

+		// TODO: implement it

+	}

+

+

+	/*

+	 * (non-Javadoc)

+	 * @see org.eclipse.bpel.ui.properties.BPELPropertySection

+	 * #gotoMarker(org.eclipse.core.resources.IMarker)

+	 */

+	@Override

+	public void gotoMarker( IMarker marker ) {

+		IGotoMarker gotoMarker = (IGotoMarker) ((IAdaptable) this.fEditor).getAdapter( IGotoMarker.class );

+		if( gotoMarker != null )

+			gotoMarker.gotoMarker( marker );

+	}

 }
\ No newline at end of file
diff --git a/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/properties/ForEachCompletionSection.java b/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/properties/ForEachCompletionSection.java
index bf01b37..b3e9692 100644
--- a/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/properties/ForEachCompletionSection.java
+++ b/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/properties/ForEachCompletionSection.java
@@ -16,87 +16,86 @@
 import org.eclipse.bpel.model.CompletionCondition;

 import org.eclipse.bpel.model.Expression;

 import org.eclipse.bpel.model.ForEach;

-import org.eclipse.bpel.ui.IBPELUIConstants;

-import org.eclipse.bpel.ui.Messages;

 import org.eclipse.bpel.ui.expressions.IEditorConstants;

 import org.eclipse.emf.ecore.EObject;

 import org.eclipse.emf.ecore.EStructuralFeature;

-import org.eclipse.swt.widgets.Composite;

-

 

 /**

  * Details section for the CompletionCondition of an forEach activity (a unsignedInteger expression).

  */

 public class ForEachCompletionSection extends ExpressionSection {

 

+	/*

+	 * (non-Javadoc)

+	 * @see org.eclipse.bpel.ui.properties.ExpressionSection

+	 * #getExpressionType()

+	 */

 	@Override

-	protected String getExpressionType() { 

-		return IEditorConstants.ET_UNSIGNED_INT; 

-	}	

-	

+	protected String getExpressionType() {

+		return IEditorConstants.ET_UNSIGNED_INT;

+	}

+

+	/*

+	 * (non-Javadoc)

+	 * @see org.eclipse.bpel.ui.properties.ExpressionSection

+	 * #addAllAdapters()

+	 */

 	@Override

 	protected void addAllAdapters() {

-		super.addAllAdapters();		

-		fAdapters[0].addToObject( getExpressionTarget() );		

+		super.addAllAdapters();

+		this.fAdapters[0].addToObject( getExpressionTarget() );

 	}

-	

-	@Override

-	protected Composite createNoEditorWidgets(Composite composite) {

-		

-		return createNoEditorWidgetsCreateComposite(composite,			

-				Messages.ForEachCompletionConditionSection_No_condition_specified_1 + NL + NL +

-				Messages.ForEachCompletionConditionSection_Optional_condition_text_2 ,

-				

-				Messages.ForEachCompletionConditionSection_Create_a_New_Condition_3);			

-	}

-	

+

+	/*

+	 * (non-Javadoc)

+	 * @see org.eclipse.bpel.ui.properties.ExpressionSection

+	 * #getStructuralFeature(org.eclipse.emf.ecore.EObject)

+	 */

 	@Override

 	protected EStructuralFeature getStructuralFeature (EObject object) {

-		if (object instanceof ForEach) {

-			return BPELPackage.eINSTANCE.getCompletionCondition_Branches() ;

-		}

-		return super.getStructuralFeature(object);

+		return object instanceof ForEach ? BPELPackage.eINSTANCE.getCompletionCondition_Branches() : null;

 	}

-	

-	

+

+	/*

+	 * (non-Javadoc)

+	 * @see org.eclipse.bpel.ui.properties.ExpressionSection

+	 * #getExpressionTarget()

+	 */

 	@Override

 	protected EObject getExpressionTarget() {

-		

+

 		EObject obj = getInput();

-		

-		if (obj instanceof ForEach) {

-			

+		if( obj instanceof ForEach ) {

+

 			ForEach _for = (ForEach) obj;

 			CompletionCondition target = _for.getCompletionCondition();

 			if (target == null) {

 				target = BPELFactory.eINSTANCE.createCompletionCondition();

 				_for.setCompletionCondition( target );

 			}

+

 			return target;

-			

 		}

-		

+

 		return super.getExpressionTarget();

 	}

 

+	/*

+	 * (non-Javadoc)

+	 * @see org.eclipse.bpel.ui.properties.ExpressionSection

+	 * #getExpression4Target(org.eclipse.bpel.model.Expression)

+	 */

 	@Override

 	protected Expression getExpression4Target ( Expression expression ) {

-		

+

 		if (expression instanceof Branches) {

 			return expression;

 		}

-		

-		Branches branches = BPELFactory.eINSTANCE.createBranches();

-		

-		branches.setBody( expression.getBody() );

-		branches.setExpressionLanguage( expression.getExpressionLanguage() );

-		

-		return branches;

-	}

-	

 

-	@Override

-	protected boolean isValidClientUseType(String useType) {

-		return IBPELUIConstants.USE_TYPE_CONDITION.equals(useType);

+		Branches branches = BPELFactory.eINSTANCE.createBranches();

+		branches.setBody( expression.getBody());

+		branches.setExpressionLanguage( expression.getExpressionLanguage());

+

+		return branches;

 	}

 }

diff --git a/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/properties/ForEachFinalCounterValueSection.java b/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/properties/ForEachFinalCounterValueSection.java
index c1d3213..87beea9 100644
--- a/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/properties/ForEachFinalCounterValueSection.java
+++ b/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/properties/ForEachFinalCounterValueSection.java
@@ -14,57 +14,39 @@
 import org.eclipse.bpel.model.ForEach;

 import org.eclipse.bpel.ui.Messages;

 import org.eclipse.bpel.ui.expressions.IEditorConstants;

-import org.eclipse.core.resources.IMarker;

 import org.eclipse.emf.ecore.EObject;

 import org.eclipse.emf.ecore.EStructuralFeature;

-import org.eclipse.swt.widgets.Composite;

-

 

 /**

- * @author IBM

  * @author Michal Chmielewski (michal.chmielewski@oracle.com)

- * @date Jul 13, 2007

- *

  */

 public class ForEachFinalCounterValueSection extends ExpressionSection {

 

-	@Override

-	protected String getExpressionType() { 

-		return IEditorConstants.ET_UNSIGNED_INT; 

-	}

-	

-	

-	@Override

-	protected Composite createNoEditorWidgets(Composite composite) {

-			    	    

-		return super.createNoEditorWidgetsCreateComposite(composite,			

-			Messages.ForEachFinalCounterValuesSection_No_Expression_specified_1 + NL + NL +

-			Messages.ForEachCounterValuesSection_Mandatory_Expression_2 ,

-			

-			Messages.ForEachCounterValuesSection_Create_a_New_Expression_3);		

+	/**

+	 * Constructor.

+	 */

+	public ForEachFinalCounterValueSection() {

+		super();

+		this.title = Messages.ForEachFinalCounterValuesSection_TITLE_3;

 	}

 

-	@Override

-	protected EStructuralFeature getStructuralFeature (EObject object) {

-		if (object instanceof ForEach) {

-			return BPELPackage.eINSTANCE.getForEach_FinalCounterValue();

-		}

-		return super.getStructuralFeature(object);

-	}

-		

-	/**

-	 * Return true if the marker is valid for this section.

-	 * @return true if so, false otherwise.

+	/*

+	 * (non-Javadoc)

+	 * @see org.eclipse.bpel.ui.properties.ExpressionSection

+	 * #getExpressionType()

 	 */

 	@Override

-	public boolean isValidMarker (IMarker marker ) {

-		

-		return false;

+	protected String getExpressionType() {

+		return IEditorConstants.ET_UNSIGNED_INT;

 	}

-	

+

+	/*

+	 * (non-Javadoc)

+	 * @see org.eclipse.bpel.ui.properties.ExpressionSection

+	 * #getStructuralFeature(org.eclipse.emf.ecore.EObject)

+	 */

 	@Override

-	protected void createClient(Composite parent) {

-		this.title = Messages.ForEachFinalCounterValuesSection_TITLE_3;	

-		super.createClient(parent);

+	protected EStructuralFeature getStructuralFeature (EObject object) {

+		return object instanceof ForEach ? BPELPackage.eINSTANCE.getForEach_FinalCounterValue() : null;

 	}

 }

diff --git a/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/properties/ForEachStartCounterValueSection.java b/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/properties/ForEachStartCounterValueSection.java
index ba371d1..bb1d289 100644
--- a/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/properties/ForEachStartCounterValueSection.java
+++ b/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/properties/ForEachStartCounterValueSection.java
@@ -16,45 +16,37 @@
 import org.eclipse.bpel.ui.expressions.IEditorConstants;

 import org.eclipse.emf.ecore.EObject;

 import org.eclipse.emf.ecore.EStructuralFeature;

-import org.eclipse.swt.widgets.Composite;

-

 

 /**

- * @author IBM

  * @author Michal Chmielewski (michal.chmielewski@oracle.com)

- * @date Jul 13, 2007

- *

  */

 public class ForEachStartCounterValueSection extends ExpressionSection {

 

-	@Override

-	protected String getExpressionType() { 

-		return IEditorConstants.ET_UNSIGNED_INT; 

-	}	

-	

-	@Override

-	protected Composite createNoEditorWidgets(Composite composite) {

-		

-		return super.createNoEditorWidgetsCreateComposite(composite,			

-				Messages.ForEachStartCounterValuesSection_No_Expression_specified_1 + NL + NL +

-				Messages.ForEachCounterValuesSection_Mandatory_Expression_2 ,

-				

-				Messages.ForEachCounterValuesSection_Create_a_New_Expression_3);

+	/**

+	 * Constructor.

+	 */

+	public ForEachStartCounterValueSection() {

+		super();

+		this.title = Messages.ForEachStartCounterValuesSection_TITLE_3;

 	}

-	

+

+	/*

+	 * (non-Javadoc)

+	 * @see org.eclipse.bpel.ui.properties.ExpressionSection

+	 * #getExpressionType()

+	 */

+	@Override

+	protected String getExpressionType() {

+		return IEditorConstants.ET_UNSIGNED_INT;

+	}

+

+	/*

+	 * (non-Javadoc)

+	 * @see org.eclipse.bpel.ui.properties.ExpressionSection

+	 * #getStructuralFeature(org.eclipse.emf.ecore.EObject)

+	 */

 	@Override

 	protected EStructuralFeature getStructuralFeature(EObject object) {

-		if (object instanceof ForEach) {

-			return BPELPackage.eINSTANCE.getForEach_StartCounterValue();

-		}

-		return super.getStructuralFeature(object);

+		return object instanceof ForEach ? BPELPackage.eINSTANCE.getForEach_StartCounterValue() : null;

 	}

-	

-	@Override

-	protected void createClient(Composite parent) {

-		this.title = Messages.ForEachStartCounterValuesSection_TITLE_3;

-		super.createClient(parent);

-	}

-	

-	

 }

diff --git a/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/properties/IGetExpressionEditor.java b/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/properties/IGetExpressionEditor.java
deleted file mode 100644
index 0db6f51..0000000
--- a/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/properties/IGetExpressionEditor.java
+++ /dev/null
@@ -1,20 +0,0 @@
-/*******************************************************************************

- * Copyright (c) 2005, 2012 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 Corporation - initial API and implementation

- *******************************************************************************/

-package org.eclipse.bpel.ui.properties;

-

-import org.eclipse.bpel.ui.expressions.IExpressionEditor;

-

-/**

- * Interface for property sections to implement to support gotoMarker

- */

-public interface IGetExpressionEditor {

-	public IExpressionEditor getExpressionEditor();

-}

diff --git a/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/properties/JoinConditionSection.java b/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/properties/JoinConditionSection.java
index 55e7c21..af506ba 100644
--- a/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/properties/JoinConditionSection.java
+++ b/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/properties/JoinConditionSection.java
@@ -13,143 +13,79 @@
 import org.eclipse.bpel.model.Activity;

 import org.eclipse.bpel.model.BPELPackage;

 import org.eclipse.bpel.model.Targets;

-import org.eclipse.bpel.ui.IBPELUIConstants;

-import org.eclipse.bpel.ui.Messages;

 import org.eclipse.bpel.ui.expressions.IEditorConstants;

 import org.eclipse.core.resources.IMarker;

 import org.eclipse.emf.ecore.EObject;

 import org.eclipse.emf.ecore.EStructuralFeature;

-import org.eclipse.swt.widgets.Composite;

-

 

 /**

  * Details section for the JoinCondition of an activity (a boolean expression).

  */

 public class JoinConditionSection extends ExpressionSection {

 

-	

+	/*

+	 * (non-Javadoc)

+	 * @see org.eclipse.bpel.ui.properties.ExpressionSection

+	 * #addAllAdapters()

+	 */

 	@Override

 	protected void addAllAdapters() {

 		super.addAllAdapters();

+

 		Activity activity = getModel();

 		Targets targets = activity.getTargets();

-		if (targets != null) {

-			fAdapters[0].addToObject(targets);

-		}

-	}

-	

-	@Override

-	protected String getExpressionType() { 

-		return IEditorConstants.ET_JOIN; 

-	}

-	

-	

-	@Override

-	protected boolean isExpressionOptional() { 

-		return true; 

-	}

-	

-	

-	@Override

-	protected Composite createNoEditorWidgets(Composite composite) {

-	

-		return createNoEditorWidgetsCreateComposite(composite,			

-				Messages.JoinConditionSection_No_condition_specified_1 + NL + NL +

-				Messages.JoinConditionSection_Optional_condition_text_2 ,				

-				Messages.JoinConditionSection_Create_a_New_Condition_3);

-	}

-	

-	

-	@Override

-	protected EObject getExpressionTarget() {		

-		Activity activity = getModel();

-		return activity.getTargets();		

+		if( targets != null )

+			this.fAdapters[0].addToObject( targets );

 	}

 

-	

-	@Override

-	protected EStructuralFeature getStructuralFeature (EObject object) {		

-		if (object instanceof Activity) {

-			return BPELPackage.eINSTANCE.getTargets_JoinCondition() ;

-		}

-		return super.getStructuralFeature(object);

-	}

-	

-	/**

-	 * Update the widgets based on the last input set.

-	 * 

+	/*

+	 * (non-Javadoc)

+	 * @see org.eclipse.bpel.ui.properties.ExpressionSection

+	 * #getExpressionType()

 	 */

 	@Override

-	protected void updateWidgets() {

-		

-		super.updateWidgets();

-		

-		Activity activity = getModel ();

-		Targets targets = activity.getTargets();

-		boolean enable = (targets != null);

-				

-		expressionLanguageViewer.getControl().setEnabled(enable);

-		

-		if (hasEditor() == false && fCreateExpressionButton != null ) {					

-			fCreateExpressionButton.setEnabled(enable);

-		}

+	protected String getExpressionType() {

+		return IEditorConstants.ET_JOIN;

 	}

 

-	

+	/*

+	 * (non-Javadoc)

+	 * @see org.eclipse.bpel.ui.properties.ExpressionSection

+	 * #getExpressionTarget()

+	 */

 	@Override

-	protected void basicSetInput(EObject newInput) {		

-		super.basicSetInput(newInput);

-		

-		// update the widgets

-		updateWidgets();

+	protected EObject getExpressionTarget() {

+		Activity activity = getModel();

+		return activity.getTargets();

 	}

 

-	

+	/*

+	 * (non-Javadoc)

+	 * @see org.eclipse.bpel.ui.properties.ExpressionSection

+	 * #getStructuralFeature(org.eclipse.emf.ecore.EObject)

+	 */

 	@Override

-	protected boolean isValidClientUseType(String useType) {

-		return IBPELUIConstants.USE_TYPE_JOIN_CONDITION.equals(useType);

+	protected EStructuralFeature getStructuralFeature (EObject object) {

+		return object instanceof Activity ? BPELPackage.eINSTANCE.getTargets_JoinCondition() : null;

 	}

-	

 

-	/**

-	 * @see org.eclipse.bpel.ui.properties.BPELPropertySection#getMarkers(java.lang.Object)

+	/*

+	 * (non-Javadoc)

+	 * @see org.eclipse.bpel.ui.properties.BPELPropertySection

+	 * #getMarkers(java.lang.Object)

 	 */

 	@Override

 	protected IMarker[] getMarkers (Object input) {

-		

-		if ( input instanceof Activity ) {

+

+		IMarker[] result = EMPTY_MARKERS;

+		if( input instanceof Activity ) {

 			Activity activity = (Activity) input;

 			Targets targets = activity.getTargets();

-			if (targets != null) {

-				return super.getMarkers( targets.getJoinCondition() );	

-			}			

+			if( targets != null )

+				result = super.getMarkers( targets.getJoinCondition());

 		}

-		

-		return EMPTY_MARKERS;

+

+		return result;

 	}

 

-

-	/**

-	 * Return true if the marker is valid for this section.

-	 * @return true if so, false otherwise.

-	 */

-	

-

-	/**

-	 * @see org.eclipse.bpel.ui.properties.BPELPropertySection#isValidMarker(org.eclipse.core.resources.IMarker)

-	 */

-	@SuppressWarnings("nls")

-	@Override

-	public boolean isValidMarker (IMarker marker) {

-		String context = null;

-		try {

-			context = (String) marker.getAttribute("href.context");

-		} catch (Exception ex) {

-			return false;

-		}

-		

-		return "name".equals (context) == false ;

-	}	

-	

-	

 }

diff --git a/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/properties/RepeatingAlarmConditionSection.java b/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/properties/RepeatingAlarmConditionSection.java
index 38f259b..58b71eb 100644
--- a/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/properties/RepeatingAlarmConditionSection.java
+++ b/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/properties/RepeatingAlarmConditionSection.java
@@ -10,137 +10,34 @@
  *******************************************************************************/

 package org.eclipse.bpel.ui.properties;

 

-import org.eclipse.bpel.common.ui.details.IDetailsAreaConstants;

-import org.eclipse.bpel.common.ui.flatui.FlatFormAttachment;

-import org.eclipse.bpel.common.ui.flatui.FlatFormData;

-import org.eclipse.bpel.common.ui.flatui.FlatFormLayout;

 import org.eclipse.bpel.model.BPELPackage;

-import org.eclipse.bpel.model.EventHandler;

 import org.eclipse.bpel.model.OnAlarm;

-import org.eclipse.bpel.ui.IBPELUIConstants;

-import org.eclipse.bpel.ui.IHelpContextIds;

-import org.eclipse.bpel.ui.Messages;

 import org.eclipse.bpel.ui.expressions.IEditorConstants;

 import org.eclipse.emf.ecore.EObject;

 import org.eclipse.emf.ecore.EStructuralFeature;

-import org.eclipse.swt.SWT;

-import org.eclipse.swt.events.SelectionEvent;

-import org.eclipse.swt.events.SelectionListener;

-import org.eclipse.swt.widgets.Button;

-import org.eclipse.swt.widgets.Composite;

-import org.eclipse.swt.widgets.Label;

-import org.eclipse.ui.PlatformUI;

 

 /**

- * @author IBM Original contribution.

- * 

  * @author Michal Chmielewski (michal.chmielewski@oracle.com)

- * @date Jul 16, 2007

- *

  */

 public class RepeatingAlarmConditionSection extends ExpressionSection {

 

-	protected Label label1, label2, label3;

-

-	protected Button createDefaultButton;

-

+	/*

+	 * (non-Javadoc)

+	 * @see org.eclipse.bpel.ui.properties.ExpressionSection

+	 * #getExpressionType()

+	 */

 	@Override

 	protected String getExpressionType() {

 		return IEditorConstants.ET_DURATION;

 	}

 

-	@Override

-	protected Composite createNoEditorWidgets(Composite composite) {

-

-		Composite section = fWidgetFactory.createComposite(composite);

-		section.setLayout(new FlatFormLayout());

-

-		FlatFormData ffdata;

-

-		label1 = fWidgetFactory

-				.createLabel(

-						section,

-						Messages.RepeatingAlarmConditionSection_No_condition_specified_1);

-		ffdata = new FlatFormData();

-		ffdata.left = new FlatFormAttachment(0, 0);

-		ffdata.top = new FlatFormAttachment(0, 0);

-		ffdata.right = new FlatFormAttachment(100, 0);

-		label1.setLayoutData(ffdata);

-

-		label2 = fWidgetFactory.createLabel(section,

-				Messages.RepeatingAlarmConditionSection_Choose_type_text_2);

-		ffdata = new FlatFormData();

-		ffdata.left = new FlatFormAttachment(0, 0);

-		ffdata.top = new FlatFormAttachment(label1,

-				IDetailsAreaConstants.VSPACE);

-		ffdata.right = new FlatFormAttachment(100, 0);

-		label2.setLayoutData(ffdata);

-

-		label3 = fWidgetFactory

-				.createLabel(

-						section,

-						Messages.RepeatingAlarmConditionSection_Not_supported_in_Pick_text_3);

-		ffdata = new FlatFormData();

-		ffdata.left = new FlatFormAttachment(0, 0);

-		ffdata.top = new FlatFormAttachment(0, 0);

-		ffdata.right = new FlatFormAttachment(100, 0);

-		label3.setLayoutData(ffdata);

-

-		createDefaultButton = fWidgetFactory

-				.createButton(

-						section,

-						Messages.RepeatingAlarmConditionSection_Create_a_New_Repeat_Condition_3,

-						SWT.PUSH);

-		ffdata = new FlatFormData();

-		ffdata.left = new FlatFormAttachment(0, 0);

-		ffdata.top = new FlatFormAttachment(label2,

-				IDetailsAreaConstants.VSPACE);

-		createDefaultButton.setLayoutData(ffdata);

-

-		createDefaultButton.addSelectionListener(new SelectionListener() {

-			public void widgetSelected(SelectionEvent e) {

-				doChooseExpressionLanguage(SAME_AS_PARENT);

-			}

-

-			public void widgetDefaultSelected(SelectionEvent e) {

-			}

-		});

-		return section;

-	}

-

-	@Override

-	protected void basicSetInput(EObject newInput) {		

-		super.basicSetInput(newInput);

-				

-		boolean enable = (newInput.eContainer() instanceof EventHandler);

-		expressionLanguageViewer.getControl().setEnabled(enable);	

-		

-		expressionLanguageViewer.getControl().setEnabled(enable);

-		label1.setVisible(enable);

-		label2.setVisible(enable);

-		label3.setVisible(!enable);

-		createDefaultButton.setVisible(enable);

-		createDefaultButton.setEnabled(enable);		

-	}

-

+	/*

+	 * (non-Javadoc)

+	 * @see org.eclipse.bpel.ui.properties.ExpressionSection

+	 * #getStructuralFeature(org.eclipse.emf.ecore.EObject)

+	 */

 	@Override

 	protected EStructuralFeature getStructuralFeature(EObject object) {

-		if (object instanceof OnAlarm) {

-			return BPELPackage.eINSTANCE.getOnAlarm_RepeatEvery();

-		}

-		return super.getStructuralFeature(object);

-	}

-

-	

-	@Override	

-	protected boolean isValidClientUseType(String useType) {

-		return IBPELUIConstants.USE_TYPE_DURATION_CONDITION.equals(useType);

-	}

-

-	@Override

-	protected void createClient(Composite parent) {

-		super.createClient(parent);

-		PlatformUI.getWorkbench().getHelpSystem().setHelp(fParentComposite,

-				IHelpContextIds.PROPERTY_PAGE_REPEAT_ALARM);

+		return object instanceof OnAlarm ? BPELPackage.eINSTANCE.getOnAlarm_RepeatEvery() : null;

 	}

 }

diff --git a/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/properties/TextSection.java b/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/properties/TextSection.java
deleted file mode 100644
index 8952cf8..0000000
--- a/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/properties/TextSection.java
+++ /dev/null
@@ -1,265 +0,0 @@
-/*******************************************************************************

- * Copyright (c) 2005, 2012 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 Corporation - initial API and implementation

- *******************************************************************************/

-package org.eclipse.bpel.ui.properties;

-

-import org.eclipse.bpel.common.ui.details.IOngoingChange;

-import org.eclipse.bpel.common.ui.editmodel.AbstractEditModelCommand;

-import org.eclipse.bpel.ui.IBPELUIConstants;

-import org.eclipse.bpel.ui.Policy;

-import org.eclipse.bpel.ui.commands.CompoundCommand;

-import org.eclipse.bpel.ui.expressions.IExpressionEditor;

-import org.eclipse.bpel.ui.util.BatchedMultiObjectAdapter;

-import org.eclipse.bpel.ui.util.MultiObjectAdapter;

-import org.eclipse.core.resources.IMarker;

-import org.eclipse.emf.common.notify.Notification;

-import org.eclipse.emf.ecore.resource.Resource;

-import org.eclipse.gef.commands.Command;

-import org.eclipse.swt.widgets.Composite;

-

-

-/**

- * 

- * @author Michal Chmielewski (michal.chmielewski@oracle.com)

- * @date Nov 15, 2006

- *

- */

-@SuppressWarnings("nls")

-

-public abstract class TextSection extends BPELPropertySection implements IGetExpressionEditor {

-

-	static protected final String NL = "\n";

-	

-	protected IExpressionEditor fEditor;

-	// protected boolean isExecutingStoreCommand = false;

-	protected boolean updating = false;

-	protected IOngoingChange change;

-	

-	protected void disposeEditor() {

-		if (fEditor != null) {

-			fEditor.dispose();

-			fEditor = null;

-		}

-	}

-	

-	@Override

-	protected MultiObjectAdapter[] createAdapters() {

-		

-		MultiObjectAdapter adapter = new BatchedMultiObjectAdapter() {

-			

-			boolean needRefresh = false;

-			

-			@Override

-			public void notify (Notification n) {

-				

-				if (markersHaveChanged(n)) {

-					updateMarkers();

-					return ;

-				}				

-				needRefresh = needRefresh || isBodyAffected(n);

-				refreshAdapters();

-			}

-			

-			@Override

-			public void finish() {

-				if (needRefresh) {

-					updateWidgets();

-				}

-				needRefresh = false;

-			}

-		};

-		

-		return new MultiObjectAdapter[] { adapter };

-	}

-

-	

-	

-	protected String getCommandLabel() {

-		return IBPELUIConstants.CMD_EDIT_EXPRESSION;

-	}

-	

-	protected void createChangeHelper() {

-		change = new IOngoingChange() {

-			public String getLabel() {

-				return getCommandLabel();

-			}

-			public Command createApplyCommand() {

-				if (fEditor == null) {

-					return null;

-				}

-							

-				CompoundCommand result = makeCompound ( newStoreToModelCommand( fEditor.getEditorContent()  )) ;

-				if (result == null) {

-					return null;

-				}

-				

-				// refresh the editor

-				result.add(new AbstractEditModelCommand() {

-					@Override

-					public void execute() { 

-						if (fEditor != null) {

-							fEditor.markAsClean(); 

-						}

-						}

-					// TODO: is this correct?

-					@Override

-					public Resource[] getResources() { 

-						return EMPTY_RESOURCE_ARRAY; 

-					}

-					@Override

-					public Resource[] getModifiedResources() { 

-						return EMPTY_RESOURCE_ARRAY; 

-					}

-				});

-				

-				return wrapInShowContextCommand(result);				

-			}

-			

-			public void restoreOldState() {

-				updateWidgets();

-			}

-		};

-	}

-	

-	/**

-	 * @see org.eclipse.ui.views.properties.tabbed.AbstractPropertySection#shouldUseExtraSpace()

-	 */

-	@Override

-	public boolean shouldUseExtraSpace() {

-		return true;

-	}

-	

-	

-	@Override

-	protected void createClient(Composite parent) {

-		createEditor(parent);

-		createChangeHelper();

-	}

-

-	

-	protected abstract void createEditor(Composite parent);

-	

-	protected void notifyEditorChanged() {

-		// TODO: why is this method being called before createClient() has finished

-		// when a BuiltInExpressionEditor was selected in the model?

-		if (change != null) {

-			getCommandFramework().notifyChangeInProgress(change);

-		}

-	}

-	

-	protected abstract void updateEditor();

-

-	/**

-	 * @see org.eclipse.bpel.ui.properties.BPELPropertySection#aboutToBeHidden()

-	 */

-	@Override

-	public void aboutToBeHidden() {

-		if (Policy.DEBUG) System.out.println("exprdetails.aboutToBeHidden() - "+this); //$NON-NLS-1$

-		super.aboutToBeHidden();

-		if (change != null) {

-			getCommandFramework().notifyChangeDone(change);

-		}

-		if (fEditor != null) fEditor.aboutToBeHidden();

-	}

-

-	

-	/**

-	 * @see org.eclipse.bpel.ui.properties.BPELPropertySection#aboutToBeShown()

-	 */

-	@Override

-	public void aboutToBeShown() {

-		if (Policy.DEBUG) {

-			System.out.println("exprdetails.aboutToBeShown() - "+this); //$NON-NLS-1$

-		}

-		

-		// TODO: can't remove the following line because we rely on this event

-		// in some places.

-		// updateEditor();

-		

-		super.aboutToBeShown();

-		if (fEditor != null) {

-			fEditor.aboutToBeShown();

-		}

-		

-//		if (Platform.getWS().equals(Platform.WS_GTK)) {

-//			((DetailsArea)detailsArea).getDetailsAreaComposite().getScrolledComposite().pack(true);

-//			((DetailsArea)detailsArea).getDetailsAreaComposite().getScrolledComposite().pack(true);

-//		}

-	}

-

-	/**

-	 * @see org.eclipse.bpel.ui.properties.BPELPropertySection#dispose()

-	 */

-	

-	@Override

-	public void dispose() {

-		super.dispose();

-	    disposeEditor();

-	}

-

-	

-	protected void updateWidgets() {		

-		

-		assert getInput() != null;

-		

-		if (!updating) {

-			updating = true;

-			try {

-				updateEditor();

-			} finally {

-				updating = false;

-			}

-		}

-	}

-    

-

-	/**

-	 * @see org.eclipse.bpel.ui.properties.BPELPropertySection#getUserContext()

-	 */

-	@Override

-	public Object getUserContext() {		

-    	return (fEditor==null)? null : fEditor.getUserContext();

-    }

-

-    /**

-     * @see org.eclipse.bpel.ui.properties.BPELPropertySection#restoreUserContext(java.lang.Object)

-     */

-    @Override

-	public void restoreUserContext(Object userContext) {

-    	if (fEditor != null) {

-    		fEditor.restoreUserContext(userContext);

-    	}

-    }

-    

-	/**

-	 * @see org.eclipse.bpel.ui.properties.IGetExpressionEditor#getExpressionEditor()

-	 */

-	public IExpressionEditor getExpressionEditor() {

-		return fEditor;

-	}

-	

-	protected abstract Command newStoreToModelCommand(Object body);

-	protected abstract boolean isBodyAffected(Notification n);

-

-	/**

-	 * @see org.eclipse.bpel.ui.properties.BPELPropertySection#gotoMarker(org.eclipse.core.resources.IMarker)

-	 */

-	@Override

-	public void gotoMarker(IMarker marker) {

-		// TODO: Look up the use type.

-		String useType = null;

-		IExpressionEditor editor = getExpressionEditor();

-		// may have not been created yet

-		if (editor == null) {

-			return ;

-		}

-		editor.gotoTextMarker(marker, useType, fModelObject);

-	}

-}

diff --git a/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/properties/TransitionConditionSection.java b/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/properties/TransitionConditionSection.java
index 9d3fb6e..ff9727b 100644
--- a/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/properties/TransitionConditionSection.java
+++ b/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/properties/TransitionConditionSection.java
@@ -15,70 +15,59 @@
 import org.eclipse.bpel.model.BPELPackage;

 import org.eclipse.bpel.model.Link;

 import org.eclipse.bpel.model.Source;

-import org.eclipse.bpel.ui.IBPELUIConstants;

-import org.eclipse.bpel.ui.Messages;

 import org.eclipse.bpel.ui.expressions.IEditorConstants;

 import org.eclipse.emf.ecore.EObject;

 import org.eclipse.emf.ecore.EStructuralFeature;

-import org.eclipse.swt.widgets.Composite;

-

 

 /**

  * Details section for the TransitionCondition of a link source (a boolean expression).

  */

 public class TransitionConditionSection extends ExpressionSection {

-	

+

+	/*

+	 * (non-Javadoc)

+	 * @see org.eclipse.bpel.ui.properties.ExpressionSection

+	 * #addAllAdapters()

+	 */

 	@Override

 	protected void addAllAdapters() {

 		super.addAllAdapters();

+

 		Link link = getModel();

 		for(Object next : link.getSources()) {

 			Source source = (Source) next;

-			fAdapters[0].addToObject(source);		

-		}		

-	}

-	

-	@Override

-	protected String getExpressionType() { 

-		return IEditorConstants.ET_TRANSITION; 

+			this.fAdapters[0].addToObject( source );

+		}

 	}

 

-	

+	/*

+	 * (non-Javadoc)

+	 * @see org.eclipse.bpel.ui.properties.ExpressionSection

+	 * #getExpressionType()

+	 */

 	@Override

-	protected boolean isExpressionOptional() { 

-		return true; 

-	}	

-	

-	@Override

-	protected Composite createNoEditorWidgets(Composite composite) {

-	

-		return createNoEditorWidgetsCreateComposite(composite,

-				

-				Messages.TransitionConditionSection_No_condition_specified_1 + NL + NL +

-				Messages.TransitionConditionSection_Optional_condition_text_2 ,

-				

-				Messages.TransitionConditionSection_Create_a_New_Condition_3);

+	protected String getExpressionType() {

+		return IEditorConstants.ET_TRANSITION;

 	}

 

-

+	/*

+	 * (non-Javadoc)

+	 * @see org.eclipse.bpel.ui.properties.ExpressionSection

+	 * #getStructuralFeature(org.eclipse.emf.ecore.EObject)

+	 */

 	@Override

 	protected EStructuralFeature getStructuralFeature (EObject object) {

-		return BPELPackage.eINSTANCE.getSource_TransitionCondition() ;		

+		return BPELPackage.eINSTANCE.getSource_TransitionCondition() ;

 	}

-	

-	

+

+	/*

+	 * (non-Javadoc)

+	 * @see org.eclipse.bpel.ui.properties.ExpressionSection

+	 * #getExpressionTarget()

+	 */

 	@Override

 	protected EObject getExpressionTarget() {

-		Link link = getModel();

-		List<?> sources = link.getSources();

-		if (sources.size() > 0) {

-			return (Source) sources.get(0);

-		}

-		return  null;			

-	}

-	

-	@Override

-	protected boolean isValidClientUseType(String useType) {		

-		return IBPELUIConstants.USE_TYPE_TRANSITION_CONDITION.equals(useType);

+		List<Source> sources = ((Link) getModel()).getSources();

+		return sources.size() > 0 ? sources.get( 0 ) : null;

 	}

 }

diff --git a/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/properties/WaitConditionSection.java b/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/properties/WaitConditionSection.java
index 37621e2..2aff2e6 100644
--- a/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/properties/WaitConditionSection.java
+++ b/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/properties/WaitConditionSection.java
@@ -31,33 +31,19 @@
 import org.eclipse.swt.widgets.Composite;

 import org.eclipse.ui.PlatformUI;

 

-

 /**

- * Details section for the duration/date of a Wait activity and of the OnAlarm 

- * activity.

- * 

+ * Details section for the duration/date of a Wait activity and of the OnAlarm activity.

+ * <p>

  * This is a little more involved, because "until" and "for" are mutually exclusive in the model.

- *   

+ * </p>

  */

-

 public class WaitConditionSection extends RadioChoiceExpressionSection {

-	

-	@Override

-	protected Composite createNoEditorWidgets(Composite composite) {

-		return createNoEditorWidgetsCreateComposite(composite,

-				

-				Messages.WaitConditionSection_No_condition_specified_1 + NL + NL +

-				Messages.WaitConditionSection_Create_condition_text_2 ,

-				

-				Messages.WaitConditionSection_Create_a_New_Condition_2);		

-	}

-		

-	 

+

 	@Override

 	protected String[] getButtonLabels() {

 		return gLabels;

 	}

-	

+

 

 	@Override

 	protected String getButtonExprType (int buttonIndex) {

@@ -69,74 +55,74 @@
 		}

 		throw new IllegalArgumentException();

 	}

-	

-	

+

+

 	@Override

 	protected void radioButtonSelected (int index, Button button) {

-			

+

 		if (button.getSelection() == false) {

 			return ;

 		}

-		

-		/** Mark the current radio button selection */		

-		fCurrentButtonIndex = index;	

-		

-		runCommand(newStoreToModelCommand( getDefaultBody(editorLanguage,getButtonExprType(index) ) ) ) ;		

+

+		/** Mark the current radio button selection */

+		this.fCurrentButtonIndex = index;

+

+		runCommand(newStoreToModelCommand( getDefaultBody(editorLanguage,getButtonExprType(index) ) ) ) ;

 	}

 

 

 	/**

 	 * This is a map between classes (Wait, OnAlarm)

 	 * and the structural features that they support (For and Until).

-	 * 

-	 * Pay particular attention to the indices of the arrays because they are ... 

+	 *

+	 * Pay particular attention to the indices of the arrays because they are ...

 	 * let's just say "connected"

 	 */

-	

-	static final String[] gLabels = 

-		{ 

-			Messages.WaitConditionSection_Date_1, 

-			Messages.WaitConditionSection_Duration_2 

+

+	static final String[] gLabels =

+		{

+			Messages.WaitConditionSection_Date_1,

+			Messages.WaitConditionSection_Duration_2

 		};

-	

-	/** 

+

+	/**

 	 * Button 0 is for "until" (date time)

 	 * Button 1 is for "for"   (duration)

 	 */

-	

+

 	static Map<EClass, EStructuralFeature[]> CLASS2FEATURES  = new HashMap<EClass, EStructuralFeature[]>();

 	static {

-		CLASS2FEATURES.put( BPELPackage.eINSTANCE.getWait() , 

+		CLASS2FEATURES.put( BPELPackage.eINSTANCE.getWait() ,

 				new EStructuralFeature [] {

 					BPELPackage.eINSTANCE.getWait_Until(),

 			 		BPELPackage.eINSTANCE.getWait_For()

-			 		

+

 				});

-		CLASS2FEATURES.put( BPELPackage.eINSTANCE.getOnAlarm() , 

+		CLASS2FEATURES.put( BPELPackage.eINSTANCE.getOnAlarm() ,

 				new EStructuralFeature [] {

 					BPELPackage.eINSTANCE.getOnAlarm_Until(),

-			 		BPELPackage.eINSTANCE.getOnAlarm_For()			 		

-				});		

+			 		BPELPackage.eINSTANCE.getOnAlarm_For()

+				});

 	}

-	

-	

+

+

 	@Override

-	protected Expression getExprFromModel() {	

-	

+	protected Expression getExprFromModel() {

+

 		EObject input = getInput();

-		

+

 		EStructuralFeature feature = getStructuralFeature (input);

 		if (feature == null) {

 			return null;

 		}

-		

+

 		Object result = input.eGet(feature);

 		if (result != null && result instanceof Expression) {

-			return (Expression) result;		

+			return (Expression) result;

 		}

-		return null; 

+		return null;

 	}

-	

+

 	@SuppressWarnings("nls")

 	@Override

 	protected int getButtonIndexFromModel() {

@@ -144,34 +130,34 @@
 		EStructuralFeature feature = getStructuralFeature(input);

 		if (feature == null) {

 			return 1;

-		}				

+		}

 		if (feature.getName().indexOf("until") >= 0) {

 			return 0;

-		}		

+		}

 		return 1;

 	}

 

-	

+

 	@Override

 	protected boolean isValidClientUseType (String useType) {

 		return IBPELUIConstants.USE_TYPE_DEADLINE_CONDITION.equals(useType)

 			|| IBPELUIConstants.USE_TYPE_DURATION_CONDITION.equals(useType);

 	}

-	

+

 	@Override

 	protected void createClient (Composite parent) {

 		super.createClient(parent);

-		

+

 		PlatformUI.getWorkbench().getHelpSystem().setHelp(

-			fParentComposite, IHelpContextIds.PROPERTY_PAGE_WAIT);

+			this.fParentComposite, IHelpContextIds.PROPERTY_PAGE_WAIT);

 	}

-	

-	

+

+

 	/**

 	 * Return true if the marker is valid for this section.

 	 * @return true if so, false otherwise.

 	 */

-		

+

 	@Override

 	public boolean isValidMarker (IMarker marker ) {

 		return false;

@@ -180,75 +166,75 @@
 	/**

 	 * We override this parameter-less method since the feature changes as the button selection changes.

 	 * The target of this structural feature (for the SetCommand model mutation change) is the target itself,

-	 * that is the Wait activity.  

+	 * that is the Wait activity.

 	 */

-	

+

 	@Override

 	protected EStructuralFeature getStructuralFeature (  ) {

-		return getStructuralFeature ( fCurrentButtonIndex );

+		return getStructuralFeature ( this.fCurrentButtonIndex );

 	}

-	

+

 	protected EStructuralFeature getStructuralFeature ( int index ) {

-		EStructuralFeature features []  = CLASS2FEATURES.get( getInput().eClass() );		

+		EStructuralFeature features []  = CLASS2FEATURES.get( getInput().eClass() );

 		assert (features != null) : "Features cannot be null";

 		return features[ index ];

 	}

-	

-	

+

+

 	@Override

 	protected EStructuralFeature getStructuralFeature ( EObject eObj ) {

-						

-		EStructuralFeature features [] = CLASS2FEATURES.get(eObj.eClass() );		

+

+		EStructuralFeature features [] = CLASS2FEATURES.get(eObj.eClass() );

 		for (EStructuralFeature f : features) {

 			Object result = eObj.eGet(f);

 			if (result != null) {

 				return f;

 			}

 		}

-		

+

 		return super.getStructuralFeature(eObj);

 	}

-	

+

 	/**

 	 * Here we have to set the feature that we are setting and unset all

-	 * the other mutually exclusive features. 

-	 * 

-	 * 

+	 * the other mutually exclusive features.

+	 *

+	 *

 	 */

 	@Override

 	protected Command newStoreToModelCommand (Object body) {

-		

-		CompoundCommand result = new CompoundCommand();		

+

+		CompoundCommand result = new CompoundCommand();

 		Expression oldExp = getExprFromModel();

-		

+

 		Expression exp = BPELFactory.eINSTANCE.createExpression();

-		

+

 		// Don't set the language, because if the user has changed the

 		// language, a condition would already exist at this point.

-		

+

 		if (oldExp != null) {

 			exp.setExpressionLanguage(oldExp.getExpressionLanguage());

 		}

 		exp.setBody(body);

-		

-		

+

+

 		/** Be nice and unset the features that should not be set. */

-		

+

 		EStructuralFeature aFeature = getStructuralFeature();

 		EObject target = getExpressionTarget();

-		

+

 		/** Set the feature being edited */

 		result.add (new SetCommand(target, exp, aFeature));

-		

+

 		// Unset others, if set

 		for (EStructuralFeature feature : CLASS2FEATURES.get( getInput().eClass() ) ) {

 			if (feature.equals(aFeature) || target.eIsSet(feature) == false ) {

 				continue;

-			}			

+			}

 			result.add( new SetCommand(target,null,feature)) ;

 		}

-		

+

 		return result;

 	}

-	

+

 }

diff --git a/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/properties/WhileConditionSection.java b/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/properties/WhileConditionSection.java
index 3af0d56..d047984 100644
--- a/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/properties/WhileConditionSection.java
+++ b/plugins/org.eclipse.bpel.ui/src/org/eclipse/bpel/ui/properties/WhileConditionSection.java
@@ -13,94 +13,51 @@
 import org.eclipse.bpel.model.BPELPackage;

 import org.eclipse.bpel.model.RepeatUntil;

 import org.eclipse.bpel.model.While;

-import org.eclipse.bpel.ui.IBPELUIConstants;

-import org.eclipse.bpel.ui.Messages;

 import org.eclipse.bpel.ui.expressions.IEditorConstants;

 import org.eclipse.core.resources.IMarker;

 import org.eclipse.emf.ecore.EObject;

 import org.eclipse.emf.ecore.EStructuralFeature;

-import org.eclipse.swt.widgets.Composite;

-

 

 /**

  * Details section for the WhileCondition of an activity (a boolean expression).

  */

 public class WhileConditionSection extends ExpressionSection {

 

+	/*

+	 * (non-Javadoc)

+	 * @see org.eclipse.bpel.ui.properties.ExpressionSection

+	 * #getExpressionType()

+	 */

 	@Override

-	protected String getExpressionType() { 

-		return IEditorConstants.ET_BOOLEAN; 

-	}

-	

-	

-	@Override

-	protected Composite createNoEditorWidgets (Composite composite) {

-			    	    

-		return super.createNoEditorWidgetsCreateComposite(composite,

-				

-				Messages.WhileConditionSection_No_condition_specified_1 + NL + NL +

-				Messages.WhileConditionSection_Mandatory_condition_text_2 ,

-				

-				Messages.WhileConditionSection_Create_a_New_Condition_3);

+	protected String getExpressionType() {

+		return IEditorConstants.ET_BOOLEAN;

 	}

 

+	/*

+	 * (non-Javadoc)

+	 * @see org.eclipse.bpel.ui.properties.ExpressionSection

+	 * #getStructuralFeature(org.eclipse.emf.ecore.EObject)

+	 */

 	@Override

 	protected EStructuralFeature getStructuralFeature (EObject object) {

-		

-		if (object instanceof While) {

+

+		if( object instanceof While )

 			return BPELPackage.eINSTANCE.getWhile_Condition() ;

-		}

-		if (object instanceof RepeatUntil) {

+

+		if( object instanceof RepeatUntil )

 			return BPELPackage.eINSTANCE.getRepeatUntil_Condition();

-		}

-		

-		return super.getStructuralFeature(object);

+

+		return null;

 	}

 

 

-	@Override

-	protected boolean isValidClientUseType (String useType) {

-		return IBPELUIConstants.USE_TYPE_CONDITION.equals(useType);

-	}

-	

-	

-	

-	

-	

-	/**

-	 * @see org.eclipse.bpel.ui.properties.BPELPropertySection#getMarkers(java.lang.Object)

+	/*

+	 * (non-Javadoc)

+	 * @see org.eclipse.bpel.ui.properties.BPELPropertySection

+	 * #getMarkers(java.lang.Object)

 	 */

 	@Override

 	protected IMarker[] getMarkers (Object input) {

-		

-		if ( input instanceof While ) {

-			While _while = (While) input;

-			return super.getMarkers( _while.getCondition() );

-		}

-		

-		return EMPTY_MARKERS;

+		return input instanceof While ? super.getMarkers(((While) input).getCondition()) : EMPTY_MARKERS;

 	}

-

-

-	/**

-	 * Return true if the marker is valid for this section.

-	 * @return true if so, false otherwise.

-	 */

-	

-

-	/**

-	 * @see org.eclipse.bpel.ui.properties.BPELPropertySection#isValidMarker(org.eclipse.core.resources.IMarker)

-	 */

-	@Override

-	public boolean isValidMarker (IMarker marker) {

-		String context = null;

-		try {

-			context = (String) marker.getAttribute("href.context");

-		} catch (Exception ex) {

-			return false;

-		}

-		

-		return "name".equals (context) == false ;

-	}	

-	

 }