Bug 65095 MessageDialogWithToggle returns wrong value for yes_to_all
I'm using MessageDialogWithToggle class with 4 buttons: MessageDialogWithToggle dialog = new MessageDialogWithToggle( Display.getCurrent().getActiveShell(), RSCCoreUIPlugin.getString("ConfirmDeleteDialog.title_UI_"), null, message, MessageDialog.QUESTION, new String[] { IDialogConstants.YES_LABEL, IDialogConstants.YES_TO_ALL_LABEL, IDialogConstants.NO_LABEL, IDialogConstants.CANCEL_LABEL}, 1, SUBuilderPlugin.getString("CONFIRM_DELETE_DESC"), checkbox ); The following values 2, 1, 3, 1 are being returned for YES, YES_TO_ALL, NO, CANCEL buttons respectively. The YES_TO_ALL value is wrong, according to IDialogConstants it should be YES_TO_ALL_ID = 4.
bundles/org.eclipse.jface/src/org/eclipse/jface/dialogs/MessageDialogWithToggle.java
* </p>
 * <p>
 * This type of dialog should be used whenever you want to user to be able to
 * avoid being prompted in the future. It is <strong>strongly </strong>
 * recommended that a cancel option be provided, so that the user has the option
 * of making the decision at a later point in time. The semantic for a cancel
 * button should be to cancel the operation (if it has not yet started), or stop
 * the operation (if it has already started).
 * </p>
 * <p>
 * It is the responsibility of the developer to provide a mechanism for the user
 * to change this preference at some later point in time (e.g., through a
 * preference page).
 * </p>
 * 
 * @since 3.0
 */
public class MessageDialogWithToggle extends MessageDialog {
    /**
     * The value of the preference when the user has asked that the answer to
     * the question always be "okay" or "yes".
     */
    public static final String ALWAYS = "always"; 
    /**
     * The value of the preference when the user has asked that the answer to
     * the question always be "no".
     */
    public static final String NEVER = "never"; 
    /**
     * The value of the preference when the user wishes to prompted for an