[522658] Regenerating based on changes in EMF.
diff --git a/plugins/org.eclipse.uml2.uml.editor/META-INF/MANIFEST.MF b/plugins/org.eclipse.uml2.uml.editor/META-INF/MANIFEST.MF
index 3eebe9b..7383360 100644
--- a/plugins/org.eclipse.uml2.uml.editor/META-INF/MANIFEST.MF
+++ b/plugins/org.eclipse.uml2.uml.editor/META-INF/MANIFEST.MF
@@ -2,7 +2,7 @@
 Bundle-ManifestVersion: 2
 Bundle-Name: %pluginName
 Bundle-SymbolicName: org.eclipse.uml2.uml.editor; singleton:=true
-Bundle-Version: 5.2.0.qualifier
+Bundle-Version: 5.4.0.qualifier
 Bundle-ClassPath: .
 Bundle-Activator: org.eclipse.uml2.uml.editor.UMLEditorPlugin$Implementation
 Bundle-Vendor: %providerName
diff --git a/plugins/org.eclipse.uml2.uml.editor/src/org/eclipse/uml2/uml/editor/presentation/UMLActionBarContributor.java b/plugins/org.eclipse.uml2.uml.editor/src/org/eclipse/uml2/uml/editor/presentation/UMLActionBarContributor.java
index 9178815..97fe11a 100644
--- a/plugins/org.eclipse.uml2.uml.editor/src/org/eclipse/uml2/uml/editor/presentation/UMLActionBarContributor.java
+++ b/plugins/org.eclipse.uml2.uml.editor/src/org/eclipse/uml2/uml/editor/presentation/UMLActionBarContributor.java
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2005, 2013 IBM Corporation, CEA, and others.
+ * Copyright (c) 2005, 2017 IBM Corporation, CEA, 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
@@ -7,7 +7,7 @@
  *
  * Contributors:
  *   IBM - initial API and implementation
- *   Kenn Hussey - 323181
+ *   Kenn Hussey - 323181, 522658
  *   Kenn Hussey (CEA) - 281326
  *
  */
@@ -114,8 +114,8 @@
 	 * @generated
 	 */
 	protected IAction showPropertiesViewAction = new Action(
-		UMLEditorPlugin.INSTANCE.getString("_UI_ShowPropertiesView_menu_item")) //$NON-NLS-1$
-	{
+		UMLEditorPlugin.INSTANCE
+			.getString("_UI_ShowPropertiesView_menu_item")) { //$NON-NLS-1$
 
 		@Override
 		public void run() {
@@ -135,8 +135,7 @@
 	 * @generated
 	 */
 	protected IAction refreshViewerAction = new Action(
-		UMLEditorPlugin.INSTANCE.getString("_UI_RefreshViewer_menu_item")) //$NON-NLS-1$
-	{
+		UMLEditorPlugin.INSTANCE.getString("_UI_RefreshViewer_menu_item")) { //$NON-NLS-1$
 
 		@Override
 		public boolean isEnabled() {
@@ -244,7 +243,8 @@
 		super.contributeToMenu(menuManager);
 
 		IMenuManager submenuManager = new MenuManager(
-			UMLEditorPlugin.INSTANCE.getString("_UI_UMLEditor_menu"), "org.eclipse.uml2.umlMenuID"); //$NON-NLS-1$ //$NON-NLS-2$
+			UMLEditorPlugin.INSTANCE.getString("_UI_UMLEditor_menu"), //$NON-NLS-1$
+			"org.eclipse.uml2.umlMenuID"); //$NON-NLS-1$
 		menuManager.insertAfter("additions", submenuManager); //$NON-NLS-1$
 		submenuManager.add(new Separator("settings")); //$NON-NLS-1$
 		submenuManager.add(new Separator("actions")); //$NON-NLS-1$
@@ -318,7 +318,8 @@
 		// Remove any menu items for old selection.
 		//
 		if (createChildMenuManager != null) {
-			depopulateManager(createChildMenuManager, createChildSubmenuActions);
+			depopulateManager(createChildMenuManager,
+				createChildSubmenuActions);
 			depopulateManager(createChildMenuManager, createChildActions);
 		}
 		if (createSiblingMenuManager != null) {
@@ -352,7 +353,8 @@
 		createChildSubmenuActions = extractSubmenuActions(createChildActions);
 		createSiblingActions = generateCreateSiblingActions(
 			newSiblingDescriptors, selection);
-		createSiblingSubmenuActions = extractSubmenuActions(createSiblingActions);
+		createSiblingSubmenuActions = extractSubmenuActions(
+			createSiblingActions);
 
 		if (createChildMenuManager != null) {
 			populateManager(createChildMenuManager, createChildSubmenuActions,
@@ -397,8 +399,8 @@
 			new Comparator<IAction>() {
 
 				public int compare(IAction a1, IAction a2) {
-					return CommonPlugin.INSTANCE.getComparator().compare(
-						a1.getText(), a2.getText());
+					return CommonPlugin.INSTANCE.getComparator()
+						.compare(a1.getText(), a2.getText());
 				}
 			});
 
@@ -417,8 +419,8 @@
 		Collection<IAction> actions = new ArrayList<IAction>();
 		if (descriptors != null) {
 			for (Object descriptor : descriptors) {
-				actions.add(new CreateSiblingAction(activeEditorPart,
-					selection, descriptor));
+				actions.add(new CreateSiblingAction(activeEditorPart, selection,
+					descriptor));
 			}
 		}
 		return actions;
@@ -433,8 +435,8 @@
 			new Comparator<IAction>() {
 
 				public int compare(IAction a1, IAction a2) {
-					return CommonPlugin.INSTANCE.getComparator().compare(
-						a1.getText(), a2.getText());
+					return CommonPlugin.INSTANCE.getComparator()
+						.compare(a1.getText(), a2.getText());
 				}
 			});
 
@@ -654,7 +656,7 @@
 
 			for (TreeIterator<EObject> allProperContents = EcoreUtil
 				.getAllProperContents(eObject, true); allProperContents
-				.hasNext();) {
+					.hasNext();) {
 
 				EObject content = allProperContents.next();
 
@@ -682,8 +684,8 @@
 				return false;
 			}
 
-			Object object = AdapterFactoryEditingDomain.unwrap(selection
-				.getFirstElement());
+			Object object = AdapterFactoryEditingDomain
+				.unwrap(selection.getFirstElement());
 			boolean result = domain.isControllable(object);
 			eObject = result
 				? (EObject) object
@@ -705,8 +707,8 @@
 						EMFEditUIPlugin.INSTANCE
 							.getString("_UI_UncontrolCommand_label")); //$NON-NLS-1$		        		
 
-					compoundCommand.append(new RemoveCommand(domain, eObject
-						.eResource().getContents(), eObject));
+					compoundCommand.append(new RemoveCommand(domain,
+						eObject.eResource().getContents(), eObject));
 
 					final List<EObject> allStereotypeApplications = collectAllStereotypeApplications(
 						eObject, new ArrayList<EObject>());
@@ -720,10 +722,11 @@
 								public void run() {
 
 									for (EObject stereotypeApplication : allStereotypeApplications) {
-										UMLUtil.StereotypeApplicationHelper.INSTANCE.addToContainmentList(
-											UMLUtil
-												.getBaseElement(stereotypeApplication),
-											stereotypeApplication);
+										UMLUtil.StereotypeApplicationHelper.INSTANCE
+											.addToContainmentList(
+												UMLUtil.getBaseElement(
+													stereotypeApplication),
+												stereotypeApplication);
 									}
 								}
 							});
@@ -758,8 +761,8 @@
 					EMFEditUIPlugin.INSTANCE
 						.getString("_UI_ControlCommand_label")); //$NON-NLS-1$		        		
 
-				compoundCommand.append(new AddCommand(domain, resource
-					.getContents(), eObject));
+				compoundCommand.append(
+					new AddCommand(domain, resource.getContents(), eObject));
 
 				final List<EObject> allStereotypeApplications = collectAllStereotypeApplications(
 					eObject, new ArrayList<EObject>());
@@ -773,10 +776,11 @@
 							public void run() {
 
 								for (EObject stereotypeApplication : allStereotypeApplications) {
-									UMLUtil.StereotypeApplicationHelper.INSTANCE.addToContainmentList(
-										UMLUtil
-											.getBaseElement(stereotypeApplication),
-										stereotypeApplication);
+									UMLUtil.StereotypeApplicationHelper.INSTANCE
+										.addToContainmentList(
+											UMLUtil.getBaseElement(
+												stereotypeApplication),
+											stereotypeApplication);
 								}
 							}
 						});
@@ -864,13 +868,14 @@
 
 				@Override
 				protected boolean doValidateContents(EObject eObject,
-						DiagnosticChain diagnostics, Map<Object, Object> context) {
+						DiagnosticChain diagnostics,
+						Map<Object, Object> context) {
 					boolean result = doValidateStereotypeApplications(eObject,
 						diagnostics, context);
 
 					if (result || diagnostics != null) {
-						result &= super.doValidateContents(eObject,
-							diagnostics, context);
+						result &= super.doValidateContents(eObject, diagnostics,
+							context);
 					}
 
 					return result;
@@ -878,15 +883,16 @@
 
 				@Override
 				public boolean validate(EClass eClass, EObject eObject,
-						DiagnosticChain diagnostics, Map<Object, Object> context) {
+						DiagnosticChain diagnostics,
+						Map<Object, Object> context) {
 					progressMonitor.worked(1);
-					return super
-						.validate(eClass, eObject, diagnostics, context);
+					return super.validate(eClass, eObject, diagnostics,
+						context);
 				}
 			};
 
-			progressMonitor.setTaskName(EMFEditUIPlugin.INSTANCE.getString(
-				"_UI_Validating_message", new Object[]{diagnostician //$NON-NLS-1$
+			progressMonitor.setTaskName(EMFEditUIPlugin.INSTANCE
+				.getString("_UI_Validating_message", new Object[]{diagnostician //$NON-NLS-1$
 					.getObjectLabel(eObject)}));
 
 			return diagnostician.validate(eObject);
diff --git a/plugins/org.eclipse.uml2.uml.editor/src/org/eclipse/uml2/uml/editor/presentation/UMLEditor.java b/plugins/org.eclipse.uml2.uml.editor/src/org/eclipse/uml2/uml/editor/presentation/UMLEditor.java
index 04016c9..697a9ea 100644
--- a/plugins/org.eclipse.uml2.uml.editor/src/org/eclipse/uml2/uml/editor/presentation/UMLEditor.java
+++ b/plugins/org.eclipse.uml2.uml.editor/src/org/eclipse/uml2/uml/editor/presentation/UMLEditor.java
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2005, 2015 IBM Corporation, Embarcadero Technologies, CEA, and others.
+ * Copyright (c) 2005, 2017 IBM Corporation, Embarcadero Technologies, CEA, 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
@@ -8,7 +8,7 @@
  * Contributors:
  *   IBM - initial API and implementation
  *   Kenn Hussey (Embarcadero Technologies) - 204200, 215418, 156879, 227392, 226178, 232332, 247980
- *   Kenn Hussey - 286329, 323181
+ *   Kenn Hussey - 286329, 323181, 522658
  *   Kenn Hussey (CEA) - 327039, 351774, 364419, 292633, 397324, 204658, 173565, 408612, 414970, 427833, 433216, 443017, 434958, 433768
  *   Christian W. Damus - 355218
  *   Christian W. Damus (CEA) - 286444
@@ -165,6 +165,7 @@
 import org.eclipse.swt.graphics.Image;
 import org.eclipse.swt.graphics.Point;
 
+import org.eclipse.swt.graphics.Rectangle;
 import org.eclipse.swt.widgets.Composite;
 import org.eclipse.swt.widgets.Menu;
 import org.eclipse.swt.widgets.Tree;
@@ -342,14 +343,15 @@
 
 		public void partActivated(IWorkbenchPart p) {
 			if (p instanceof ContentOutline) {
-				if (((ContentOutline) p).getCurrentPage() == contentOutlinePage) {
+				if (((ContentOutline) p)
+					.getCurrentPage() == contentOutlinePage) {
 					getActionBarContributor().setActiveEditor(UMLEditor.this);
 
 					setCurrentViewer(contentOutlineViewer);
 				}
 			} else if (p instanceof PropertySheet) {
-				if (propertySheetPages.contains(((PropertySheet) p)
-					.getCurrentPage())) {
+				if (propertySheetPages
+					.contains(((PropertySheet) p).getCurrentPage())) {
 					getActionBarContributor().setActiveEditor(UMLEditor.this);
 					handleActivate();
 				}
@@ -417,6 +419,8 @@
 	 */
 	protected EContentAdapter problemIndicationAdapter = new EContentAdapter() {
 
+		protected boolean dispatching;
+
 		@Override
 		public void notifyChanged(Notification notification) {
 			if (notification.getNotifier() instanceof Resource) {
@@ -433,16 +437,7 @@
 						} else {
 							resourceToDiagnosticMap.remove(resource);
 						}
-
-						if (updateProblemIndication) {
-							getSite().getShell().getDisplay()
-								.asyncExec(new Runnable() {
-
-									public void run() {
-										updateProblemIndication();
-									}
-								});
-						}
+						dispatchUpdateProblemIndication();
 						break;
 					}
 				}
@@ -451,6 +446,19 @@
 			}
 		}
 
+		protected void dispatchUpdateProblemIndication() {
+			if (updateProblemIndication && !dispatching) {
+				dispatching = true;
+				getSite().getShell().getDisplay().asyncExec(new Runnable() {
+
+					public void run() {
+						dispatching = false;
+						updateProblemIndication();
+					}
+				});
+			}
+		}
+
 		@Override
 		protected void setTarget(Resource target) {
 			basicSetTarget(target);
@@ -460,14 +468,7 @@
 		protected void unsetTarget(Resource target) {
 			basicUnsetTarget(target);
 			resourceToDiagnosticMap.remove(target);
-			if (updateProblemIndication) {
-				getSite().getShell().getDisplay().asyncExec(new Runnable() {
-
-					public void run() {
-						updateProblemIndication();
-					}
-				});
-			}
+			dispatchUpdateProblemIndication();
 		}
 	};
 
@@ -501,18 +502,23 @@
 										delta.getFullPath().toString(), true),
 										false);
 								if (resource != null) {
-									if (delta.getKind() == IResourceDelta.REMOVED) {
+									if (delta
+										.getKind() == IResourceDelta.REMOVED) {
 										removedResources.add(resource);
 									} else {
-										if ((delta.getFlags() & IResourceDelta.MARKERS) != 0) {
+										if ((delta.getFlags()
+											& IResourceDelta.MARKERS) != 0) {
 											DiagnosticDecorator.DiagnosticAdapter
-												.update(resource, markerHelper
-													.getMarkerDiagnostics(
-														resource, (IFile) delta
-															.getResource(),
-														false));
+												.update(resource,
+													markerHelper
+														.getMarkerDiagnostics(
+															resource,
+															(IFile) delta
+																.getResource(),
+															false));
 										}
-										if ((delta.getFlags() & IResourceDelta.CONTENT) != 0) {
+										if ((delta.getFlags()
+											& IResourceDelta.CONTENT) != 0) {
 											if (!savedResources
 												.remove(resource)) {
 												changedResources.add(resource);
@@ -543,8 +549,8 @@
 					getSite().getShell().getDisplay().asyncExec(new Runnable() {
 
 						public void run() {
-							removedResources.addAll(visitor
-								.getRemovedResources());
+							removedResources
+								.addAll(visitor.getRemovedResources());
 							if (!isDirty()) {
 								getSite().getPage().closeEditor(UMLEditor.this,
 									false);
@@ -557,9 +563,10 @@
 					getSite().getShell().getDisplay().asyncExec(new Runnable() {
 
 						public void run() {
-							changedResources.addAll(visitor
-								.getChangedResources());
-							if (getSite().getPage().getActiveEditor() == UMLEditor.this) {
+							changedResources
+								.addAll(visitor.getChangedResources());
+							if (getSite().getPage()
+								.getActiveEditor() == UMLEditor.this) {
 								handleActivate();
 							}
 						}
@@ -589,8 +596,8 @@
 						.getSource()).getMostRecentCommand();
 
 					if (mostRecentCommand != null) {
-						setSelectionToViewer(mostRecentCommand
-							.getAffectedObjects());
+						setSelectionToViewer(
+							mostRecentCommand.getAffectedObjects());
 					}
 
 					for (Iterator<PropertySheetPage> i = propertySheetPages
@@ -620,11 +627,13 @@
 			if (!msg.isTouch() && (getViewer() != null)
 				&& !getViewer().getControl().isDisposed()) {
 				if (msg.getNotifier() instanceof Resource) {
-					if (msg.getFeatureID(Resource.class) == Resource.RESOURCE__IS_LOADED) {
+					if (msg.getFeatureID(
+						Resource.class) == Resource.RESOURCE__IS_LOADED) {
 						refreshViewer();
 					}
 				} else if (msg.getNotifier() instanceof ResourceSet) {
-					if (msg.getFeatureID(ResourceSet.class) == ResourceSet.RESOURCE_SET__RESOURCES) {
+					if (msg.getFeatureID(
+						ResourceSet.class) == ResourceSet.RESOURCE_SET__RESOURCES) {
 						switch (msg.getEventType()) {
 							case Notification.ADD :
 								handleResource((Resource) msg.getNewValue());
@@ -637,7 +646,8 @@
 								break;
 							case Notification.SET :
 								if (msg.getNewValue() != null) {
-									handleResource((Resource) msg.getNewValue());
+									handleResource(
+										(Resource) msg.getNewValue());
 								}
 								break;
 						}
@@ -737,8 +747,8 @@
 		if (!changedResources.isEmpty()
 			&& (!isDirty() || handleDirtyConflict())) {
 			if (isDirty()) {
-				changedResources.addAll(editingDomain.getResourceSet()
-					.getResources());
+				changedResources
+					.addAll(editingDomain.getResourceSet().getResources());
 			}
 			editingDomain.getCommandStack().flush();
 
@@ -777,7 +787,8 @@
 			BasicDiagnostic diagnostic = new BasicDiagnostic(Diagnostic.OK,
 				"org.eclipse.uml2.uml.editor", //$NON-NLS-1$
 				0, null, new Object[]{editingDomain.getResourceSet()});
-			for (Diagnostic childDiagnostic : resourceToDiagnosticMap.values()) {
+			for (Diagnostic childDiagnostic : resourceToDiagnosticMap
+				.values()) {
 				if (childDiagnostic.getSeverity() != Diagnostic.OK) {
 					diagnostic.add(childDiagnostic);
 				}
@@ -798,7 +809,8 @@
 				try {
 					addPage(++lastEditorPage, problemEditorPart,
 						getEditorInput());
-					setPageText(lastEditorPage, problemEditorPart.getPartName());
+					setPageText(lastEditorPage,
+						problemEditorPart.getPartName());
 					setActivePage(lastEditorPage);
 					showTabs();
 				} catch (PartInitException exception) {
@@ -807,13 +819,10 @@
 			}
 
 			if (markerHelper.hasMarkers(editingDomain.getResourceSet())) {
-				markerHelper.deleteMarkers(editingDomain.getResourceSet());
-				if (diagnostic.getSeverity() != Diagnostic.OK) {
-					try {
-						markerHelper.createMarkers(diagnostic);
-					} catch (CoreException exception) {
-						UMLEditorPlugin.INSTANCE.log(exception);
-					}
+				try {
+					markerHelper.updateMarkers(diagnostic);
+				} catch (CoreException exception) {
+					UMLEditorPlugin.INSTANCE.log(exception);
 				}
 			}
 		}
@@ -941,8 +950,9 @@
 					// Try to select the items in the current content viewer of the editor.
 					//
 					if (currentViewer != null) {
-						currentViewer.setSelection(new StructuredSelection(
-							theSelection.toArray()), true);
+						currentViewer.setSelection(
+							new StructuredSelection(theSelection.toArray()),
+							true);
 					}
 				}
 			};
@@ -1082,8 +1092,8 @@
 		int dndOperations = DND.DROP_COPY | DND.DROP_MOVE | DND.DROP_LINK;
 		Transfer[] transfers = new Transfer[]{LocalTransfer.getInstance(),
 			LocalSelectionTransfer.getTransfer(), FileTransfer.getInstance()};
-		viewer.addDragSupport(dndOperations, transfers, new ViewerDragAdapter(
-			viewer));
+		viewer.addDragSupport(dndOperations, transfers,
+			new ViewerDragAdapter(viewer));
 		viewer.addDropSupport(dndOperations, transfers,
 			new EditingDomainViewerDropAdapter(editingDomain, viewer));
 	}
@@ -1095,8 +1105,8 @@
 	 * @generated
 	 */
 	public void createModelGen() {
-		URI resourceURI = EditUIUtil.getURI(getEditorInput(), editingDomain
-			.getResourceSet().getURIConverter());
+		URI resourceURI = EditUIUtil.getURI(getEditorInput(),
+			editingDomain.getResourceSet().getURIConverter());
 		Exception exception = null;
 		Resource resource = null;
 		try {
@@ -1135,11 +1145,11 @@
 
 			if (uriMap.containsKey(uri)) {
 				uri = uriMap.get(uri);
-			} else if (UML22UMLResource.FILE_EXTENSION.equals(uri
-				.fileExtension())) {
+			} else if (UML22UMLResource.FILE_EXTENSION
+				.equals(uri.fileExtension())) {
 
-				uri = uri.trimFileExtension().appendFileExtension(
-					UMLResource.FILE_EXTENSION);
+				uri = uri.trimFileExtension()
+					.appendFileExtension(UMLResource.FILE_EXTENSION);
 
 				if (i == 0) {
 					setInputWithNotify(new URIEditorInput(uri));
@@ -1161,8 +1171,9 @@
 		if (saveNeeded) {
 			IProgressMonitor progressMonitor = getActionBars()
 				.getStatusLineManager() != null
-				? getActionBars().getStatusLineManager().getProgressMonitor()
-				: new NullProgressMonitor();
+					? getActionBars().getStatusLineManager()
+						.getProgressMonitor()
+					: new NullProgressMonitor();
 			doSave(progressMonitor);
 		}
 
@@ -1184,21 +1195,17 @@
 		if (hasErrors || !resource.getWarnings().isEmpty()) {
 			BasicDiagnostic basicDiagnostic = new BasicDiagnostic(hasErrors
 				? Diagnostic.ERROR
-				: Diagnostic.WARNING,
-				"org.eclipse.uml2.uml.editor", //$NON-NLS-1$
-				0,
-				getString("_UI_CreateModelError_message", resource.getURI()), //$NON-NLS-1$
+				: Diagnostic.WARNING, "org.eclipse.uml2.uml.editor", //$NON-NLS-1$
+				0, getString("_UI_CreateModelError_message", resource.getURI()), //$NON-NLS-1$
 				new Object[]{exception == null
 					? (Object) resource
 					: exception});
 			basicDiagnostic.merge(EcoreUtil.computeDiagnostic(resource, true));
 			return basicDiagnostic;
 		} else if (exception != null) {
-			return new BasicDiagnostic(
-				Diagnostic.ERROR,
+			return new BasicDiagnostic(Diagnostic.ERROR,
 				"org.eclipse.uml2.uml.editor", //$NON-NLS-1$
-				0,
-				getString("_UI_CreateModelError_message", resource.getURI()), //$NON-NLS-1$
+				0, getString("_UI_CreateModelError_message", resource.getURI()), //$NON-NLS-1$
 				new Object[]{exception});
 		} else {
 			return Diagnostic.OK_INSTANCE;
@@ -1226,16 +1233,19 @@
 			selectionViewer = new TreeViewer(tree);
 			setCurrentViewer(selectionViewer);
 
-			selectionViewer
-				.setContentProvider(new AdapterFactoryContentProvider(
-					adapterFactory));
+			selectionViewer.setUseHashlookup(true);
+			selectionViewer.setContentProvider(
+				new AdapterFactoryContentProvider(adapterFactory));
 			selectionViewer.setLabelProvider(new DecoratingColumLabelProvider(
 				new AdapterFactoryLabelProvider.FontAndColorProvider(
-					adapterFactory, selectionViewer), new DiagnosticDecorator(
-					editingDomain.getResourceSet(), selectionViewer)));
+					adapterFactory, selectionViewer),
+				new DiagnosticDecorator(editingDomain.getResourceSet(),
+					selectionViewer)));
 			selectionViewer.setInput(editingDomain.getResourceSet());
-			selectionViewer.setSelection(new StructuredSelection(editingDomain
-				.getResourceSet().getResources().get(0)), true);
+			selectionViewer.setSelection(
+				new StructuredSelection(
+					editingDomain.getResourceSet().getResources().get(0)),
+				true);
 
 			new AdapterFactoryTreeEditor(selectionViewer.getTree(),
 				adapterFactory);
@@ -1250,7 +1260,9 @@
 			getSite().getShell().getDisplay().asyncExec(new Runnable() {
 
 				public void run() {
-					setActivePage(0);
+					if (!getContainer().isDisposed()) {
+						setActivePage(0);
+					}
 				}
 			});
 		}
@@ -1291,9 +1303,10 @@
 		if (getPageCount() <= 1) {
 			setPageText(0, ""); //$NON-NLS-1$
 			if (getContainer() instanceof CTabFolder) {
-				((CTabFolder) getContainer()).setTabHeight(1);
 				Point point = getContainer().getSize();
-				getContainer().setSize(point.x, point.y + 6);
+				Rectangle clientArea = getContainer().getClientArea();
+				getContainer().setSize(point.x,
+					2 * point.y - clientArea.height - clientArea.y);
 			}
 		}
 	}
@@ -1309,9 +1322,10 @@
 		if (getPageCount() > 1) {
 			setPageText(0, getString("_UI_SelectionPage_label")); //$NON-NLS-1$
 			if (getContainer() instanceof CTabFolder) {
-				((CTabFolder) getContainer()).setTabHeight(SWT.DEFAULT);
 				Point point = getContainer().getSize();
-				getContainer().setSize(point.x, point.y - 6);
+				Rectangle clientArea = getContainer().getClientArea();
+				getContainer().setSize(point.x,
+					clientArea.height + clientArea.y);
 			}
 		}
 	}
@@ -1339,15 +1353,15 @@
 	 */
 	@SuppressWarnings("rawtypes")
 	@Override
-	public Object getAdapter(Class key) {
+	public <T> T getAdapter(Class<T> key) {
 		if (key.equals(IContentOutlinePage.class)) {
 			return showOutlineView()
-				? getContentOutlinePage()
+				? key.cast(getContentOutlinePage())
 				: null;
 		} else if (key.equals(IPropertySheetPage.class)) {
-			return getPropertySheetPage();
+			return key.cast(getPropertySheetPage());
 		} else if (key.equals(IGotoMarker.class)) {
-			return this;
+			return key.cast(this);
 		} else {
 			return super.getAdapter(key);
 		}
@@ -1374,17 +1388,18 @@
 
 					// Set up the tree viewer.
 					//
-					contentOutlineViewer
-						.setContentProvider(new AdapterFactoryContentProvider(
-							adapterFactory));
+					contentOutlineViewer.setUseHashlookup(true);
+					contentOutlineViewer.setContentProvider(
+						new AdapterFactoryContentProvider(adapterFactory));
 					contentOutlineViewer
 						.setLabelProvider(new DecoratingColumLabelProvider(
 							new AdapterFactoryLabelProvider.FontAndColorProvider(
 								adapterFactory, contentOutlineViewer),
-							new DiagnosticDecorator(editingDomain
-								.getResourceSet(), contentOutlineViewer)));
-					contentOutlineViewer.setInput(editingDomain
-						.getResourceSet());
+							new DiagnosticDecorator(
+								editingDomain.getResourceSet(),
+								contentOutlineViewer)));
+					contentOutlineViewer
+						.setInput(editingDomain.getResourceSet());
 
 					new ColumnViewerInformationControlToolTipSupport(
 						contentOutlineViewer,
@@ -1399,9 +1414,11 @@
 						.isEmpty()) {
 						// Select the root object in the view.
 						//
-						contentOutlineViewer.setSelection(
-							new StructuredSelection(editingDomain
-								.getResourceSet().getResources().get(0)), true);
+						contentOutlineViewer
+							.setSelection(
+								new StructuredSelection(editingDomain
+									.getResourceSet().getResources().get(0)),
+							true);
 					}
 				}
 
@@ -1448,7 +1465,8 @@
 	 */
 	public IPropertySheetPage getPropertySheetPageGen() {
 		PropertySheetPage propertySheetPage = new ExtendedPropertySheetPage(
-			editingDomain, ExtendedPropertySheetPage.Decoration.MANUAL) {
+			editingDomain, ExtendedPropertySheetPage.Decoration.MANUAL, null, 0,
+			false) {
 
 			@Override
 			public void setSelectionToViewer(List<?> selection) {
@@ -1462,9 +1480,8 @@
 				getActionBarContributor().shareGlobalActions(this, actionBars);
 			}
 		};
-		propertySheetPage
-			.setPropertySourceProvider(new AdapterFactoryContentProvider(
-				adapterFactory));
+		propertySheetPage.setPropertySourceProvider(
+			new AdapterFactoryContentProvider(adapterFactory));
 		propertySheetPages.add(propertySheetPage);
 
 		return propertySheetPage;
@@ -1487,9 +1504,8 @@
 			}
 		};
 
-		propertySheetPage
-			.setPropertySourceProvider(new UMLAdapterFactoryContentProvider(
-				adapterFactory));
+		propertySheetPage.setPropertySourceProvider(
+			new UMLAdapterFactoryContentProvider(adapterFactory));
 		propertySheetPages.add(propertySheetPage);
 
 		return propertySheetPage;
@@ -1519,8 +1535,8 @@
 
 				// Set the selection to the widget.
 				//
-				selectionViewer.setSelection(new StructuredSelection(
-					selectionList));
+				selectionViewer
+					.setSelection(new StructuredSelection(selectionList));
 			}
 		}
 	}
@@ -1570,7 +1586,8 @@
 				for (int i = 0; i < resources.size(); i++) {
 					Resource resource = resources.get(i);
 
-					if ((first || !resource.getContents().isEmpty() || isPersisted(resource))
+					if ((first || !resource.getContents().isEmpty()
+						|| isPersisted(resource))
 						&& !editingDomain.isReadOnly(resource)) {
 						try {
 							long timeStamp = resource.getTimeStamp();
@@ -1658,7 +1675,8 @@
 		Map<Element, List<EObject>> allExternalStereotypeApplications = new HashMap<Element, List<EObject>>();
 
 		for (TreeIterator<EObject> allProperContents = EcoreUtil
-			.getAllProperContents(resource, true); allProperContents.hasNext();) {
+			.getAllProperContents(resource, true); allProperContents
+				.hasNext();) {
 
 			EObject properContent = allProperContents.next();
 
@@ -1690,8 +1708,8 @@
 			}
 		}
 
-		for (Iterator<EObject> contents = resource.getContents().iterator(); contents
-			.hasNext();) {
+		for (Iterator<EObject> contents = resource.getContents()
+			.iterator(); contents.hasNext();) {
 
 			EObject eObject = contents.next();
 			contents.remove();
@@ -1731,8 +1749,8 @@
 			IFile file = ResourcesPlugin.getWorkspace().getRoot().getFile(path);
 
 			if (file != null) {
-				URI newURI = URI.createPlatformResourceURI(file.getFullPath()
-					.toString(), true);
+				URI newURI = URI.createPlatformResourceURI(
+					file.getFullPath().toString(), true);
 
 				ResourceSet resourceSet = editingDomain.getResourceSet();
 				EList<Resource> resources = resourceSet.getResources();
@@ -1746,13 +1764,11 @@
 				if (!UML2Util.safeEquals(fileExtension, newFileExtension)) {
 					copyResource(resourceSet, resource, newURI);
 
-					if (MessageDialog
-						.openQuestion(
-							getSite().getShell(),
-							getTitle(),
-							UMLEditorPlugin.INSTANCE
-								.getString(
-									"_UI_Save_All_Resources_As", new Object[]{fileExtension, newFileExtension}))) { //$NON-NLS-1$
+					if (MessageDialog.openQuestion(getSite().getShell(),
+						getTitle(),
+						UMLEditorPlugin.INSTANCE.getString(
+							"_UI_Save_All_Resources_As", //$NON-NLS-1$
+							new Object[]{fileExtension, newFileExtension}))) {
 
 						for (int i = 1; i < resources.size(); i++) {
 							resource = resources.get(i);
@@ -1760,7 +1776,8 @@
 
 							if (UML2Util.safeEquals(uri.fileExtension(),
 								fileExtension)
-								&& (!resource.getContents().isEmpty() || isPersisted(resource))
+								&& (!resource.getContents().isEmpty()
+									|| isPersisted(resource))
 								&& !editingDomain.isReadOnly(resource)) {
 
 								copyResource(resourceSet, resource,
@@ -1787,8 +1804,8 @@
 		setPartName(editorInput.getName());
 		IProgressMonitor progressMonitor = getActionBars()
 			.getStatusLineManager() != null
-			? getActionBars().getStatusLineManager().getProgressMonitor()
-			: new NullProgressMonitor();
+				? getActionBars().getStatusLineManager().getProgressMonitor()
+				: new NullProgressMonitor();
 		doSave(progressMonitor);
 	}
 
@@ -1800,8 +1817,8 @@
 	public void gotoMarker(IMarker marker) {
 		try {
 			if (marker.isSubtypeOf((EValidator.MARKER))) {
-				String uriAttribute = marker.getAttribute(
-					EValidator.URI_ATTRIBUTE, null);
+				String uriAttribute = marker
+					.getAttribute(EValidator.URI_ATTRIBUTE, null);
 				if (uriAttribute != null) {
 					URI uri = URI.createURI(uriAttribute);
 					EObject eObject = editingDomain.getResourceSet()
@@ -1850,7 +1867,8 @@
 	 * <!-- end-user-doc -->
 	 * @generated
 	 */
-	public void addSelectionChangedListener(ISelectionChangedListener listener) {
+	public void addSelectionChangedListener(
+			ISelectionChangedListener listener) {
 		selectionChangedListeners.add(listener);
 	}
 
@@ -1900,8 +1918,8 @@
 	public void setStatusLineManager(ISelection selection) {
 		IStatusLineManager statusLineManager = currentViewer != null
 			&& currentViewer == contentOutlineViewer
-			? contentOutlineStatusLineManager
-			: getActionBars().getStatusLineManager();
+				? contentOutlineStatusLineManager
+				: getActionBars().getStatusLineManager();
 
 		if (statusLineManager != null) {
 			if (selection instanceof IStructuredSelection) {
@@ -1915,16 +1933,16 @@
 					}
 					case 1 : {
 						String text = new AdapterFactoryItemDelegator(
-							adapterFactory).getText(collection.iterator()
-							.next());
-						statusLineManager.setMessage(getString(
-							"_UI_SingleObjectSelected", text)); //$NON-NLS-1$
+							adapterFactory)
+								.getText(collection.iterator().next());
+						statusLineManager.setMessage(
+							getString("_UI_SingleObjectSelected", text)); //$NON-NLS-1$
 						break;
 					}
 					default : {
 						statusLineManager
-							.setMessage(getString(
-								"_UI_MultiObjectSelected", Integer.toString(collection.size()))); //$NON-NLS-1$
+							.setMessage(getString("_UI_MultiObjectSelected", //$NON-NLS-1$
+								Integer.toString(collection.size())));
 						break;
 					}
 				}
@@ -2001,8 +2019,8 @@
 	public void disposeGen() {
 		updateProblemIndication = false;
 
-		ResourcesPlugin.getWorkspace().removeResourceChangeListener(
-			resourceChangeListener);
+		ResourcesPlugin.getWorkspace()
+			.removeResourceChangeListener(resourceChangeListener);
 
 		getSite().getPage().removePartListener(partListener);
 
@@ -2034,13 +2052,14 @@
 		}
 
 		if (commandStackListener != null && editingDomain != null) {
-			editingDomain.getCommandStack().removeCommandStackListener(
-				commandStackListener);
+			editingDomain.getCommandStack()
+				.removeCommandStackListener(commandStackListener);
 		}
 
 		disposeGen();
 
-		for (Resource resource : editingDomain.getResourceSet().getResources()) {
+		for (Resource resource : editingDomain.getResourceSet()
+			.getResources()) {
 			resource.unload();
 		}
 	}
@@ -2058,7 +2077,8 @@
 	protected static class UMLAdapterFactoryContentProvider
 			extends AdapterFactoryContentProvider {
 
-		protected UMLAdapterFactoryContentProvider(AdapterFactory adapterFactory) {
+		protected UMLAdapterFactoryContentProvider(
+				AdapterFactory adapterFactory) {
 			super(adapterFactory);
 		}
 
@@ -2108,8 +2128,8 @@
 				if (stereotypeApplicationItemPropertyDescriptors != null) {
 
 					for (IItemPropertyDescriptor itemPropertyDescriptor : stereotypeApplicationItemPropertyDescriptors) {
-						propertyDescriptors
-							.add(createPropertyDescriptor(itemPropertyDescriptor));
+						propertyDescriptors.add(
+							createPropertyDescriptor(itemPropertyDescriptor));
 					}
 				}
 			}
@@ -2125,16 +2145,16 @@
 
 			return itemPropertyDescriptor == null
 				&& itemPropertySource instanceof ElementItemProvider
-				? ((ElementItemProvider) itemPropertySource)
-					.getStereotypeApplicationPropertyDescriptor(object,
-						propertyId)
-				: itemPropertyDescriptor;
+					? ((ElementItemProvider) itemPropertySource)
+						.getStereotypeApplicationPropertyDescriptor(object,
+							propertyId)
+					: itemPropertyDescriptor;
 		}
 
 		@Override
 		public Object getPropertyValue(Object propertyId) {
-			return getItemPropertyDescriptor(propertyId).getPropertyValue(
-				object);
+			return getItemPropertyDescriptor(propertyId)
+				.getPropertyValue(object);
 		}
 
 		@Override
@@ -2155,7 +2175,8 @@
 
 		@Override
 		public boolean isPropertyResettable(Object propertyId) {
-			IItemPropertyDescriptor propertyDescriptor = getItemPropertyDescriptor(propertyId);
+			IItemPropertyDescriptor propertyDescriptor = getItemPropertyDescriptor(
+				propertyId);
 			return propertyDescriptor.canSetProperty(object)
 				&& propertyDescriptor.isPropertySet(object);
 		}
@@ -2202,8 +2223,8 @@
 
 				@Override
 				public Image getImage(Object object) {
-					return ExtendedImageRegistry.getInstance().getImage(
-						itemLabelProvider.getImage(object));
+					return ExtendedImageRegistry.getInstance()
+						.getImage(itemLabelProvider.getImage(object));
 				}
 			};
 		}
@@ -2225,8 +2246,8 @@
 			}
 		}
 
-		for (TreeIterator<EObject> allContents = EcoreUtil.getAllContents(
-			eObject, true); allContents.hasNext();) {
+		for (TreeIterator<EObject> allContents = EcoreUtil
+			.getAllContents(eObject, true); allContents.hasNext();) {
 
 			EObject content = allContents.next();
 
@@ -2276,7 +2297,8 @@
 	protected static class UMLCutToClipboardCommand
 			extends CutToClipboardCommand {
 
-		protected UMLCutToClipboardCommand(EditingDomain domain, Command command) {
+		protected UMLCutToClipboardCommand(EditingDomain domain,
+				Command command) {
 			super(domain, command);
 		}
 
@@ -2293,8 +2315,8 @@
 						final List<EObject> allStereotypeApplications = collectAllStereotypeApplications(
 							(EObject) object, new ArrayList<EObject>());
 
-						compoundCommand.append(new ChangeCommand(domain,
-							new Runnable() {
+						compoundCommand
+							.append(new ChangeCommand(domain, new Runnable() {
 
 								public void run() {
 
@@ -2302,15 +2324,15 @@
 										UMLUtil.StereotypeApplicationHelper
 											.getInstance(null)
 											.removeFromContainmentList(
-												UMLUtil
-													.getBaseElement(stereotypeApplication),
+												UMLUtil.getBaseElement(
+													stereotypeApplication),
 												stereotypeApplication);
 									}
 								}
 							}));
 
-						compoundCommand.append(new IdentityCommand(
-							allStereotypeApplications));
+						compoundCommand.append(
+							new IdentityCommand(allStereotypeApplications));
 					}
 				}
 			}
@@ -2338,8 +2360,8 @@
 						: null);
 			}
 
-			private static Element getBaseElement(
-					EObject stereotypeApplication, Object context) {
+			private static Element getBaseElement(EObject stereotypeApplication,
+					Object context) {
 				return getStereotype(stereotypeApplication, context) != null
 					? getBaseElement(stereotypeApplication.eClass(),
 						stereotypeApplication)
@@ -2432,7 +2454,8 @@
 										baseElement.getNearestPackage(),
 										stereotype) == definition
 										|| getAppliedDefinition(
-											ownerNearestPackage, stereotype) == definition) {
+											ownerNearestPackage,
+											stereotype) == definition) {
 
 										stereotypeApplicationsToAdd
 											.add(stereotypeApplication);
@@ -2457,20 +2480,20 @@
 								return new ChangeCommand(domain,
 									new Runnable() {
 
-										public void run() {
+									public void run() {
 
-											for (EObject stereotypeApplication : stereotypeApplicationsToAdd) {
-												UMLUtil.StereotypeApplicationHelper
-													.getInstance(null)
-													.addToContainmentList(
-														PrivateUMLUtil
-															.getBaseElement(
-																stereotypeApplication,
-																owner),
-														stereotypeApplication);
-											}
+										for (EObject stereotypeApplication : stereotypeApplicationsToAdd) {
+											UMLUtil.StereotypeApplicationHelper
+												.getInstance(null)
+												.addToContainmentList(
+													PrivateUMLUtil
+														.getBaseElement(
+															stereotypeApplication,
+															owner),
+													stereotypeApplication);
 										}
-									});
+									}
+								});
 							}
 						});
 					}
@@ -2529,9 +2552,8 @@
 
 				for (Object object : clipboard) {
 
-					if (object instanceof EObject
-						&& PrivateUMLUtil
-							.getStereotype((EObject) object, owner) != null) {
+					if (object instanceof EObject && PrivateUMLUtil
+						.getStereotype((EObject) object, owner) != null) {
 
 						continue;
 					}
diff --git a/plugins/org.eclipse.uml2.uml.editor/src/org/eclipse/uml2/uml/editor/presentation/UMLModelWizard.java b/plugins/org.eclipse.uml2.uml.editor/src/org/eclipse/uml2/uml/editor/presentation/UMLModelWizard.java
index f29a31c..09c1606 100644
--- a/plugins/org.eclipse.uml2.uml.editor/src/org/eclipse/uml2/uml/editor/presentation/UMLModelWizard.java
+++ b/plugins/org.eclipse.uml2.uml.editor/src/org/eclipse/uml2/uml/editor/presentation/UMLModelWizard.java
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2005, 2010 IBM Corporation and others.
+ * Copyright (c) 2005, 2017 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
@@ -8,9 +8,8 @@
  * Contributors:
  *   IBM - initial API and implementation
  *   Kenn Hussey (Embarcadero Technologies) - 227392, 204200
- *   Kenn Hussey - 323181
+ *   Kenn Hussey - 323181, 522658
  *
- * $Id: UMLModelWizard.java,v 1.12 2010/09/28 20:59:43 khussey Exp $
  */
 package org.eclipse.uml2.uml.editor.presentation;
 
@@ -113,8 +112,8 @@
 	 * @generated
 	 */
 	public static final List<String> FILE_EXTENSIONS = Collections
-		.unmodifiableList(Arrays.asList(UMLEditorPlugin.INSTANCE.getString(
-			"_UI_UMLEditorFilenameExtensions").split("\\s*,\\s*"))); //$NON-NLS-1$ //$NON-NLS-2$
+		.unmodifiableList(Arrays.asList(UMLEditorPlugin.INSTANCE
+			.getString("_UI_UMLEditorFilenameExtensions").split("\\s*,\\s*"))); //$NON-NLS-1$ //$NON-NLS-2$
 
 	/**
 	 * A formatted list of supported file extensions, suitable for display.
@@ -123,8 +122,8 @@
 	 * @generated
 	 */
 	public static final String FORMATTED_FILE_EXTENSIONS = UMLEditorPlugin.INSTANCE
-		.getString("_UI_UMLEditorFilenameExtensions").replaceAll("\\s*,\\s*",
-			", ");
+		.getString("_UI_UMLEditorFilenameExtensions")
+		.replaceAll("\\s*,\\s*", ", ");
 
 	/**
 	 * This caches an instance of the model package.
@@ -192,9 +191,9 @@
 		this.workbench = workbench;
 		this.selection = selection;
 		setWindowTitle(UMLEditorPlugin.INSTANCE.getString("_UI_Wizard_label")); //$NON-NLS-1$
-		setDefaultPageImageDescriptor(ExtendedImageRegistry.INSTANCE
-			.getImageDescriptor(UMLEditorPlugin.INSTANCE
-				.getImage("full/wizban/NewUML"))); //$NON-NLS-1$
+		setDefaultPageImageDescriptor(
+			ExtendedImageRegistry.INSTANCE.getImageDescriptor(
+				UMLEditorPlugin.INSTANCE.getImage("full/wizban/NewUML"))); //$NON-NLS-1$
 	}
 
 	/**
@@ -271,8 +270,8 @@
 
 						// Get the URI of the model file.
 						//
-						URI fileURI = URI.createPlatformResourceURI(modelFile
-							.getFullPath().toString(), true);
+						URI fileURI = URI.createPlatformResourceURI(
+							modelFile.getFullPath().toString(), true);
 
 						// Create a resource for this file.
 						//
@@ -323,20 +322,17 @@
 			// Open an editor on the new file.
 			//
 			try {
-				page.openEditor(
-					new FileEditorInput(modelFile),
-					workbench
-						.getEditorRegistry()
-						.getDefaultEditor(
-							modelFile.getFullPath().toString(),
-							Platform.getContentTypeManager().getContentType(
-								UMLPackage.eCONTENT_TYPE)).getId());
+				page.openEditor(new FileEditorInput(modelFile),
+					workbench.getEditorRegistry()
+						.getDefaultEditor(modelFile.getFullPath().toString(),
+							Platform.getContentTypeManager()
+								.getContentType(UMLPackage.eCONTENT_TYPE))
+					.getId());
 			} catch (PartInitException exception) {
-				MessageDialog
-					.openError(
-						workbenchWindow.getShell(),
-						UMLEditorPlugin.INSTANCE
-							.getString("_UI_OpenEditorError_label"), exception.getMessage()); //$NON-NLS-1$
+				MessageDialog.openError(
+					workbenchWindow.getShell(), UMLEditorPlugin.INSTANCE
+						.getString("_UI_OpenEditorError_label"), //$NON-NLS-1$
+					exception.getMessage());
 				return false;
 			}
 
@@ -379,7 +375,8 @@
 				String extension = new Path(getFileName()).getFileExtension();
 				if (extension == null || !FILE_EXTENSIONS.contains(extension)) {
 					String key = FILE_EXTENSIONS.size() > 1
-						? "_WARN_FilenameExtensions" : "_WARN_FilenameExtension"; //$NON-NLS-1$ //$NON-NLS-2$
+						? "_WARN_FilenameExtensions" //$NON-NLS-1$
+						: "_WARN_FilenameExtension"; //$NON-NLS-1$
 					setErrorMessage(UMLEditorPlugin.INSTANCE.getString(key,
 						new Object[]{FORMATTED_FILE_EXTENSIONS}));
 					return false;
@@ -462,8 +459,8 @@
 
 			Label containerLabel = new Label(composite, SWT.LEFT);
 			{
-				containerLabel.setText(UMLEditorPlugin.INSTANCE
-					.getString("_UI_ModelObject")); //$NON-NLS-1$
+				containerLabel.setText(
+					UMLEditorPlugin.INSTANCE.getString("_UI_ModelObject")); //$NON-NLS-1$
 
 				GridData data = new GridData();
 				data.horizontalAlignment = GridData.FILL;
@@ -489,8 +486,8 @@
 
 			Label encodingLabel = new Label(composite, SWT.LEFT);
 			{
-				encodingLabel.setText(UMLEditorPlugin.INSTANCE
-					.getString("_UI_XMLEncoding")); //$NON-NLS-1$
+				encodingLabel.setText(
+					UMLEditorPlugin.INSTANCE.getString("_UI_XMLEncoding")); //$NON-NLS-1$
 
 				GridData data = new GridData();
 				data.horizontalAlignment = GridData.FILL;
@@ -607,8 +604,8 @@
 				encodings = new ArrayList<String>();
 				for (StringTokenizer stringTokenizer = new StringTokenizer(
 					UMLEditorPlugin.INSTANCE
-						.getString("_UI_XMLEncodingChoices")); stringTokenizer.hasMoreTokens();) //$NON-NLS-1$
-				{
+						.getString("_UI_XMLEncodingChoices")); stringTokenizer //$NON-NLS-1$
+							.hasMoreTokens();) {
 					encodings.add(stringTokenizer.nextToken());
 				}
 			}
@@ -626,15 +623,14 @@
 	public void addPages() {
 		// Create a page, set the title, and the initial model file name.
 		//
-		newFileCreationPage = new UMLModelWizardNewFileCreationPage(
-			"Whatever", selection); //$NON-NLS-1$
-		newFileCreationPage.setTitle(UMLEditorPlugin.INSTANCE
-			.getString("_UI_UMLModelWizard_label")); //$NON-NLS-1$
+		newFileCreationPage = new UMLModelWizardNewFileCreationPage("Whatever", //$NON-NLS-1$
+			selection);
+		newFileCreationPage.setTitle(
+			UMLEditorPlugin.INSTANCE.getString("_UI_UMLModelWizard_label")); //$NON-NLS-1$
 		newFileCreationPage.setDescription(UMLEditorPlugin.INSTANCE
 			.getString("_UI_UMLModelWizard_description")); //$NON-NLS-1$
-		newFileCreationPage
-			.setFileName(UMLEditorPlugin.INSTANCE
-				.getString("_UI_UMLEditorFilenameDefaultBase") + "." + FILE_EXTENSIONS.get(0)); //$NON-NLS-1$ //$NON-NLS-2$
+		newFileCreationPage.setFileName(UMLEditorPlugin.INSTANCE.getString(
+			"_UI_UMLEditorFilenameDefaultBase") + "." + FILE_EXTENSIONS.get(0)); //$NON-NLS-1$ //$NON-NLS-2$
 		addPage(newFileCreationPage);
 
 		// Try and get the resource selection to determine a current directory for the file dialog.
@@ -657,8 +653,8 @@
 					|| selectedResource instanceof IProject) {
 					// Set this for the container.
 					//
-					newFileCreationPage.setContainerFullPath(selectedResource
-						.getFullPath());
+					newFileCreationPage
+						.setContainerFullPath(selectedResource.getFullPath());
 
 					// Make up a unique new name here.
 					//
@@ -666,12 +662,12 @@
 						.getString("_UI_UMLEditorFilenameDefaultBase"); //$NON-NLS-1$
 					String defaultModelFilenameExtension = FILE_EXTENSIONS
 						.get(0);
-					String modelFilename = defaultModelBaseFilename
-						+ "." + defaultModelFilenameExtension; //$NON-NLS-1$
+					String modelFilename = defaultModelBaseFilename + "." //$NON-NLS-1$
+						+ defaultModelFilenameExtension;
 					for (int i = 1; ((IContainer) selectedResource)
 						.findMember(modelFilename) != null; ++i) {
-						modelFilename = defaultModelBaseFilename + i
-							+ "." + defaultModelFilenameExtension; //$NON-NLS-1$
+						modelFilename = defaultModelBaseFilename + i + "." //$NON-NLS-1$
+							+ defaultModelFilenameExtension;
 					}
 					newFileCreationPage.setFileName(modelFilename);
 				}
@@ -679,8 +675,8 @@
 		}
 		initialObjectCreationPage = new UMLModelWizardInitialObjectCreationPage(
 			"Whatever2"); //$NON-NLS-1$
-		initialObjectCreationPage.setTitle(UMLEditorPlugin.INSTANCE
-			.getString("_UI_UMLModelWizard_label")); //$NON-NLS-1$
+		initialObjectCreationPage.setTitle(
+			UMLEditorPlugin.INSTANCE.getString("_UI_UMLModelWizard_label")); //$NON-NLS-1$
 		initialObjectCreationPage.setDescription(UMLEditorPlugin.INSTANCE
 			.getString("_UI_Wizard_initial_object_description")); //$NON-NLS-1$
 		addPage(initialObjectCreationPage);