Issue 124652 - css::ui::dialogs::XWizard: enableButton and setDefaultButton work only after the dialog is executed
Summary: css::ui::dialogs::XWizard: enableButton and setDefaultButton work only after ...
Status: CONFIRMED
Alias: None
Product: App Dev
Classification: Unclassified
Component: api (show other issues)
Version: 3.3.0 or older (OOo)
Hardware: All All
: P3 Normal
Target Milestone: ---
Assignee: AOO issues mailing list
QA Contact:
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-04-10 16:10 UTC by Ariel Constenla-Haile
Modified: 2014-04-10 16:10 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Latest Confirmation in: ---
Developer Difficulty: ---


Attachments

Note You need to log in before you can comment on or make changes to this issue.
Description Ariel Constenla-Haile 2014-04-10 16:10:18 UTC
enableButton and setDefaultButton work only after the dialog is executed, this doesn't make sense, as client code is likely to use these methods after dialog construction.

The bug is in the implementation, the UNO dialog implantation only works when its VCL dialog is already created:

WizardShell* pWizardImpl = dynamic_cast< WizardShell* >( m_pDialog );
ENSURE_OR_RETURN_VOID( pWizardImpl, "Wizard::setDefaultButton: invalid dialog implementation!" );

http://svn.apache.org/viewvc/openoffice/trunk/main/svtools/source/uno/wizard/unowizard.cxx?revision=1586340&view=markup#l327

http://svn.apache.org/viewvc/openoffice/trunk/main/svtools/source/uno/wizard/unowizard.cxx?revision=1586340&view=markup#l339

but this should be treated like the HelpURL attribute: if there is no VCL dialog, store the information in member variables and then set it when the VCL dialog is created.