Bug 142172 [Wizards] Small overhead in WizardDialog
Here is code of method WizardDialog.updateDescriptionMessage: private void updateDescriptionMessage() { pageDescription = currentPage.getDescription(); setMessage(currentPage.getDescription()); } As you can see, it access currentPage.getDescription() two times, but value of this method is already in field pageDescription.
bundles/org.eclipse.jface/src/org/eclipse/jface/wizard/WizardDialog.java
}
    /**
     * The <code>WizardDialog</code> implementation of this <code>Window</code>
     * method calls call <code>IWizard.addPages</code> to allow the current
     * wizard to add extra pages, then <code>super.createContents</code> to create
     * the controls. It then calls <code>IWizard.createPageControls</code>
     * to allow the wizard to pre-create their page controls prior to opening,
     * so that the wizard opens to the correct size. And finally it
     * shows the first page.
     */
    protected Control createContents(Composite parent) {
        
        
        
        wizard.addPages();
        Control contents = super.createContents(parent);
        
        createPageControls();
        
        showStartingPage();
        return contents;
    }
    /* (non-Javadoc)
     * Method declared on Dialog.
     */
    protected Control createDialogArea(Composite parent) {
        Composite composite = (Composite) super.createDialogArea(parent);
        
        pageContainer = createPageContainer(composite);
        GridData gd = new GridData(GridData.FILL_BOTH);