Bug 66292 [Dialogs] InputDialog NPE when invoking setErrorMessage(...) too early
06081200 build Setting the error message this early is probably not anticipated, but it shouldn't throw an exception... public class Main { public static void main(String[] args) { Display display = new Display(); Shell shell = new Shell(display); InputDialog dialog = new InputDialog (shell, "TEST", "value", "test", null); dialog.setErrorMessage("error"); dialog.open(); shell.open(); } }
bundles/org.eclipse.jface/src/org/eclipse/jface/dialogs/InputDialog.java
private String title;
    /**
     * The message to display, or <code>null</code> if none.
     */
    private String message;
    /**
     * The input value; the empty string by default.
     */
    private String value = "";
    /**
     * The input validator, or <code>null</code> if none.
     */
    private IInputValidator validator;
    /**
     * Ok button widget.
     */
    private Button okButton;
    /**
     * Input text widget.
     */
    private Text text;
    /**
     * Error message label widget.
     */
    private Text errorMessageText;
    /**
     * Creates an input dialog with OK and Cancel buttons. Note that the dialog
     * will have no visual representation (no widgets) until it is told to open.
     * <p>
     * Note that the <code>open</code> method blocks for input dialogs.