Bug 309447 Possibility to take out editor as standalone shell
Build Identifier: M20100211-1343 I would like to have possiblity to drag editor outside workbench and to have standalone editor (similar to firefox or chrome tab behaviour). Reproducible: Always
bundles/org.eclipse.e4.ui.workbench/src/org/eclipse/e4/ui/internal/workbench/ModelServiceImpl.java
}
	}
	public void resetPerspectiveModel(MPerspective persp, MWindow window) {
		if (persp == null)
			return;
		
		for (MWindow win : persp.getWindows()) {
			win.setToBeRendered(false);
		}
		persp.getWindows().clear();
		
		List<MTrimBar> bars = findElements(window, null, MTrimBar.class, null);
		List<MToolControl> toRemove = new ArrayList<MToolControl>();
		for (MTrimBar bar : bars) {
			for (MUIElement barKid : bar.getChildren()) {
				if (!(barKid instanceof MToolControl))
					continue;
				String id = barKid.getElementId();
				if (id != null && id.contains(persp.getElementId())) {
					toRemove.add((MToolControl) barKid);
				}
			}
		}
		for (MToolControl toolControl : toRemove) {
			
			if (toolControl.getObject() != null
					&& toolControl.getObject().getClass().getName().contains("TrimStack")) { 
				IEclipseContext ctxt = EclipseContextFactory.create();
				ctxt.set("show", false); 
				ContextInjectionFactory.invoke(toolControl.getObject(), Execute.class, ctxt);