Bug 303322 Enable view toolbars and menus
bundles/org.eclipse.e4.ui.workbench.renderers.swt/src/org/eclipse/e4/workbench/ui/renderers/swt/StackRenderer.java
if (stack.getSelectedElement() != null) {
			CTabItem selCTI = findItemForPart(stack, stack.getSelectedElement());
			if (selCTI != null && selCTI != ctf.getSelection())
				ctf.setSelection(selCTI);
		}
	}
	private int calcIndexFor(MElementContainer<MUIElement> stack,
			final MUIElement part) {
		int index = 0;
		
		for (MUIElement mPart : stack.getChildren()) {
			if (mPart == part)
				return index;
			if (mPart.isToBeRendered())
				index++;
		}
		return index;
	}
	@Override
	public void childRendered(
			final MElementContainer<MUIElement> parentElement,
			MUIElement element) {
		super.childRendered(parentElement, element);
		if (!(((MUIElement) parentElement) instanceof MPartStack)
				|| !(element instanceof MPart))
			return;
		showChild(parentElement, element);
		
		
		Control ctrl = (Control) element.getWidget();