Bug 109562 [code manipulation] "Sort Members" reorders the enum constants in enums.
Irrespective of the settings of preferences controlling Sort Members, it should not reorder enum constants because their order has semantic significance.
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/dialogs/OptionalMessageDialog.java
import org.eclipse.swt.layout.GridLayout;
import org.eclipse.swt.widgets.Button;
import org.eclipse.swt.widgets.Composite;
import org.eclipse.swt.widgets.Control;
import org.eclipse.swt.widgets.Shell;
import org.eclipse.jface.dialogs.IDialogConstants;
import org.eclipse.jface.dialogs.IDialogSettings;
import org.eclipse.jface.dialogs.MessageDialog;
import org.eclipse.jdt.internal.ui.JavaPlugin;
import org.eclipse.jdt.internal.ui.JavaUIMessages;
/**
 * This is a <code>MessageDialog</code> which allows the user
 * to choose that the dialog isn't shown again the next time.
 */ 
public class OptionalMessageDialog extends MessageDialog {
	
	
	private static final String CHECKBOX_TEXT= JavaUIMessages.OptionalMessageDialog_dontShowAgain; 
	
	private static final String STORE_ID= "OptionalMessageDialog.hide."; 
	public static final int NOT_SHOWN= IDialogConstants.CLIENT_ID + 1;
	
	private Button fHideDialogCheckBox;
	private String fId;
	/**
	 * Opens the dialog but only if the user hasn't choosen to hide it.
	 * Returns <code>NOT_SHOWN</code> if the dialog was not shown.
	 */
	public static int open(String id, Shell parent, String title, Image titleImage, String message, int dialogType, String[] buttonLabels, int defaultButtonIndex) {
		if (!isDialogEnabled(id))