Bug 314685 EModelService's findElements(MUIElement, String, Class<T>, List<String>) method can return duplicates
I'm getting two editors in the returned list that's pointing at the same thing. The returned collection is a List and not a Set but this feels wrong.
bundles/org.eclipse.e4.ui.workbench/src/org/eclipse/e4/workbench/ui/internal/ModelServiceImpl.java
phParent.getChildren().add(phIndex, element);
	}
	public void selectStackElement(MGenericStack<MUIElement> stack, MUIElement element) {
		assert (stack.getChildren().indexOf(element) >= 0);
		
		List<MUIElement> goingHidden = new ArrayList<MUIElement>();
		MUIElement curSel = stack.getSelectedElement();
		hideElementRecursive(curSel, goingHidden);
		
		List<MUIElement> becomingVisible = new ArrayList<MUIElement>();
		showElementRecursive(element, becomingVisible);
	}
	private void hideElementRecursive(MUIElement element, List<MUIElement> goingHidden) {
		if (element.getWidget() == null)
			return;
		
		if (element instanceof MWindow && element.getWidget() != null) {
			element.setVisible(false);
		}
		goingHidden.add(element);
		if (element instanceof MGenericTile<?>) {
			MGenericTile<?> container = (MGenericTile<?>) element;
			for (MUIElement childElement : container.getChildren()) {
				hideElementRecursive(childElement, goingHidden);
			}
		} else if (element instanceof MGenericStack<?>) {
			
			MGenericStack<?> container = (MGenericStack<?>) element;
			MUIElement curSel = container.getSelectedElement();
			hideElementRecursive(curSel, goingHidden);