Bug 33040 No single Undo for generate delegate methods
RC 1 - JUnit setup - open TestCase - select fName - generate delegate methods for all String methods - press Ctrl+Z Observe: only one method is removed.
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/actions/AddDelegateMethodsAction.java
return;
			}
			Object firstElement = selection.getFirstElement();
			if (firstElement instanceof IType)
				run((IType) firstElement, new IField[0], false);
			else if (firstElement instanceof ICompilationUnit)
				run(JavaElementUtil.getMainType((ICompilationUnit) firstElement), new IField[0], false);
		} catch (CoreException e) {
			ExceptionHandler.handle(e, getShell(), DIALOG_TITLE, ActionMessages.getString("AddDelegateMethodsAction.error.actionfailed")); 
		}
	}
	private boolean canEnable(IStructuredSelection selection) throws JavaModelException {
		if (canEnableOn(getSelectedFields(selection)))
			return true;
		if ((selection.size() == 1) && (selection.getFirstElement() instanceof IType))
			return canEnableOn((IType) selection.getFirstElement());
		if ((selection.size() == 1) && (selection.getFirstElement() instanceof ICompilationUnit))
			return canEnableOn(JavaElementUtil.getMainType((ICompilationUnit) selection.getFirstElement()));
		return false;
	}
	private static boolean canEnableOn(IType type) throws JavaModelException {
		if (type == null || type.getCompilationUnit() == null)
			return false;
		return canEnableOn(type.getFields());
	}
	private static boolean canEnableOn(IField[] fields) throws JavaModelException {
		if (fields == null) {
			return false;
		}
		int count = 0;