Example usage for org.eclipse.jface.wizard WizardDialog removePageChangedListener

List of usage examples for org.eclipse.jface.wizard WizardDialog removePageChangedListener

Introduction

In this page you can find the example usage for org.eclipse.jface.wizard WizardDialog removePageChangedListener.

Prototype

@Override
    public void removePageChangedListener(IPageChangedListener listener) 

Source Link

Usage

From source file:org.ect.codegen.wizards.GenerateCodeWizard.java

License:Open Source License

/**
 * Set the dialog where the wizard is displayed in.
 * @param dialog WizardDialog./*  ww w. j a  va2s  .  com*/
 */
public void setDialog(WizardDialog dialog) {

    if (this.dialog != null) {
        dialog.removePageChangedListener(this);
    }
    if (dialog != null) {
        dialog.addPageChangedListener(this);
    }

    this.dialog = dialog;

}

From source file:org.kalypso.ui.layoutwizard.LayoutWizardActivationHandler.java

License:Open Source License

private void unhookWizard(final IWizard oldWizard) {
    if (oldWizard == null)
        return;//from w  w w .ja va2s  . c  o m

    final ICommandService cmdService = (ICommandService) m_page.getWizardContext()
            .getService(ICommandService.class);
    if (cmdService != null)
        cmdService.removeExecutionListener(m_cmdExecutionListener);

    final IWizardContainer container = oldWizard.getContainer();
    if (container instanceof WizardView) {
        final WizardView view = (WizardView) container;
        view.removePageChangingListener(m_pageChangingListener);
        view.removePageChangedListener(m_pageChangedListener);
    } else if (container instanceof WizardDialog) {
        final WizardDialog dialog = (WizardDialog) container;
        dialog.removePageChangingListener(m_pageChangingListener);
        dialog.removePageChangedListener(m_pageChangedListener);
    }
}