Bug 242789 [Markers]If you hit escape on the delete markers dialog it deletes them anyway
Right click on a problem marker in the problems view and select delete. You get the confirmation dialog. Hit escape. The marker is deleted anyway. The problem looks to be in org.eclipse.ui.internal.views.markers.DeleteHandler.execute(ExecutionEvent): if (dialog.open() == Window.CANCEL) { return view; } It should probably be if (dialog.open() != Window.OK) { return view; }
bundles/org.eclipse.jface/src/org/eclipse/jface/dialogs/MessageDialog.java
message, QUESTION, new String[] { IDialogConstants.OK_LABEL,
                        IDialogConstants.CANCEL_LABEL }, 0); 
        
        return dialog.open() == 0;
    }
    /**
     * Convenience method to open a standard error dialog.
     * 
     * @param parent
     *            the parent shell of the dialog, or <code>null</code> if none
     * @param title
     *            the dialog's title, or <code>null</code> if none
     * @param message
     *            the message
     */
    public static void openError(Shell parent, String title, String message) {
        MessageDialog dialog = new MessageDialog(parent, title, null, 
                
                
                
                
                message, ERROR, new String[] { IDialogConstants.OK_LABEL }, 0); 
        
        
        
        dialog.open();
        return;