Bug 58696 Override/Implement Methods dialog: better labels for insertion position [code manipulation]
The Override/Implement Methods dialog says: Insertion Point: - First Method - Last Method - a() - b() ... I *never* know whether that means before or after the selected method. Better labels would be: Insert after: - Class Declaration Header - a() - b() ... or Insert Before: - a() - b() ... - End of Class
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/dialogs/SourceActionDialog.java
fVisibilityModifier= StringConverter.asInt(fSettings.get(VISIBILITY_MODIFIER), Modifier.PUBLIC);
		fFinal= StringConverter.asBoolean(fSettings.get(FINAL_MODIFIER), false);
		fSynchronized= StringConverter.asBoolean(fSettings.get(SYNCHRONIZED_MODIFIER), false);
		fCurrentPositionIndex= StringConverter.asInt(fSettings.get(SETTINGS_INSERTPOSITION), insertionDefault);
		
		fInsertPositions= new ArrayList();
		fLabels= new ArrayList(); 
		
		IJavaElement[] members= fType.getChildren();
		IMethod[] methods= fType.getMethods();
		
		fInsertPositions.add(methods.length > 0 ? methods[0]: null); 
		fInsertPositions.add(null); 
		
		fLabels.add(ActionMessages.getString("SourceActionDialog.first_method")); 
		fLabels.add(ActionMessages.getString("SourceActionDialog.last_method")); 
		if (hasCursorPositionElement(fEditor, members, fInsertPositions)) {
			fLabels.add(ActionMessages.getString("SourceActionDialog.cursor")); 
			fCurrentPositionIndex= 2;
		}
		
		for (int i = 0; i < methods.length; i++) {
			IMethod curr= methods[i];
			fLabels.add(JavaElementLabels.getElementLabel(curr, JavaElementLabels.M_PARAMETER_TYPES));
			fInsertPositions.add(findSibling(curr, members));
		}
		fInsertPositions.add(null);
	}
	
	private IJavaElement findSibling(IMethod curr, IJavaElement[] members) throws JavaModelException {