Bug 44181 Source->delegate works only for public methods [code manipulation]
Hi, Generate Delegate methods display only public methods for target class. For classes in the same package also default and protected methods should be shown. And for subclasses in other packages protected should be shown (I think more for completeness than for usefulness). Bye
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/actions/AddDelegateMethodsAction.java
public void addListener(ILabelProviderListener listener) {
			fMethodLabel.addListener(listener);
		}
		public void dispose() {
			fMethodLabel.dispose();
		}
		public boolean isLabelProperty(Object element, String property) {
			return fMethodLabel.isLabelProperty(element, property);
		}
		public void removeListener(ILabelProviderListener listener) {
			fMethodLabel.removeListener(listener);
		}
	}
	
	private static class Methods2FieldSorter extends ViewerSorter {
		JavaElementSorter fSorter = new JavaElementSorter();
		public int category(Object element) {
			if (element instanceof Methods2Field)
				element = ((Methods2Field) element).fMethod;
			return fSorter.category(element);
		}
		public int compare(Viewer viewer, Object e1, Object e2) {
			if (e1 instanceof Methods2Field)
				e1 = ((Methods2Field) e1).fMethod;
			if (e2 instanceof Methods2Field)
				e2 = ((Methods2Field) e2).fMethod;
			return fSorter.compare(viewer, e1, e2);
		}
		public Collator getCollator() {
			return fSorter.getCollator();