Community
Participate
Working Groups
Build Identifier: I20110613-1736 Hi, I got the Wiget is Disposed error when trying override The WizardDialog Class and invoke a wizard from the customized one. And I would like to suggest few changes as below. WizardDialog API and line no 1179: protected void setWizard(IWizard newWizard) { wizard = newWizard; wizard.setContainer(this); if (!createdWizards.contains(wizard)) { createdWizards.add(wizard); // New wizard so just add it to the end of our nested list nestedWizards.add(wizard); if (pageContainer != null) { // Dialog is already open // Allow the wizard pages to precreate their page controls // This allows the wizard to open to the correct size createPageControls(); // Ensure the dialog is large enough for the wizard updateSizeForWizard(wizard); pageContainer.layout(true); } } else { // We have already seen this wizard, if it is the previous wizard // on the nested list then we assume we have gone back and remove // the last wizard from the list int size = nestedWizards.size(); if (size >= 2 && nestedWizards.get(size - 2) == wizard) { nestedWizards.remove(size - 1); } else { // Assume we are going forward to revisit a wizard nestedWizards.add(wizard); } } } Should be if (pageContainer != null !&& pageContainer .isDiposed()) { Also further there needs a handle of PageContainer, the Help Button Bar in Wizard Dialog etc. Regards, Sandip Reproducible: Always Steps to Reproduce: 1. Dummy Wizard through extension 2. Override SetContiner() method try to invoke Another wizard using Custom Wizard Dialog 3.
Sorry little mistake: Should be if (pageContainer != null && !pageContainer .isDiposed()) {
Why is your page container disposed anyway?
(In reply to comment #2) > Why is your page container disposed anyway? As I mentioned, I am trying to invoke Wizard2 from setContainer(IWizardContainer container) of Wizard1's after disposing its container. So when Wizard2 is closed, the control comes back to Wizard1 setContainer(IWizardContainer container), then control enters into setWizard(), as container is already disposed, it gives Widget is disposed error.
This bug hasn't had any activity in quite some time. Maybe the problem got resolved, was a duplicate of something else, or became less pressing for some reason - or maybe it's still relevant but just hasn't been looked at yet. As such, we're closing this bug. If you have further information on the current state of the bug, please add it and reopen this bug. The information can be, for example, that the problem still occurs, that you still want the feature, that more information is needed, or that the bug is (for whatever reason) no longer relevant. -- The automated Eclipse Genie.