forked from qt-creator/qt-creator
Make BaseFileWizard async
The side-effect is that WizardEventLoop can go! Change-Id: I0eae0e0fa91a48e2a5010b47cc0de86758969904 Reviewed-by: Eike Ziller <eike.ziller@theqtcompany.com>
This commit is contained in:
@@ -57,10 +57,8 @@ CustomWidgetWizard::CustomWidgetWizard()
|
||||
|
||||
Core::BaseFileWizard *CustomWidgetWizard::create(QWidget *parent, const Core::WizardDialogParameters ¶meters) const
|
||||
{
|
||||
CustomWidgetWizardDialog *rc = new CustomWidgetWizardDialog(displayName(),
|
||||
icon(),
|
||||
parent,
|
||||
parameters);
|
||||
CustomWidgetWizardDialog *rc = new CustomWidgetWizardDialog(this, displayName(),
|
||||
icon(), parent, parameters);
|
||||
rc->setProjectName(CustomWidgetWizardDialog::uniqueProjectName(parameters.defaultPath()));
|
||||
rc->setFileNamingParameters(FileNamingParameters(headerSuffix(), sourceSuffix(), QtWizard::lowerCaseFiles()));
|
||||
return rc;
|
||||
|
||||
@@ -42,11 +42,11 @@ namespace Internal {
|
||||
|
||||
enum { IntroPageId = 0};
|
||||
|
||||
CustomWidgetWizardDialog::CustomWidgetWizardDialog(const QString &templateName,
|
||||
const QIcon &icon,
|
||||
QWidget *parent,
|
||||
CustomWidgetWizardDialog::CustomWidgetWizardDialog(const Core::BaseFileWizardFactory *factory,
|
||||
const QString &templateName,
|
||||
const QIcon &icon, QWidget *parent,
|
||||
const Core::WizardDialogParameters ¶meters) :
|
||||
BaseQmakeProjectWizardDialog(false, parent, parameters),
|
||||
BaseQmakeProjectWizardDialog(factory, false, parent, parameters),
|
||||
m_widgetsPage(new CustomWidgetWidgetsWizardPage),
|
||||
m_pluginPage(new CustomWidgetPluginWizardPage)
|
||||
{
|
||||
@@ -61,7 +61,7 @@ CustomWidgetWizardDialog::CustomWidgetWizardDialog(const QString &templateName,
|
||||
addPage(m_widgetsPage);
|
||||
m_pluginPageId = addPage(m_pluginPage);
|
||||
|
||||
addExtensionPages(parameters.extensionPages());
|
||||
addExtensionPages(extensionPages());
|
||||
connect(this, SIGNAL(currentIdChanged(int)), this, SLOT(slotCurrentIdChanged(int)));
|
||||
}
|
||||
|
||||
|
||||
@@ -47,8 +47,8 @@ class CustomWidgetWizardDialog : public BaseQmakeProjectWizardDialog
|
||||
{
|
||||
Q_OBJECT
|
||||
public:
|
||||
explicit CustomWidgetWizardDialog(const QString &templateName,
|
||||
const QIcon &icon,
|
||||
explicit CustomWidgetWizardDialog(const Core::BaseFileWizardFactory *factory,
|
||||
const QString &templateName, const QIcon &icon,
|
||||
QWidget *parent,
|
||||
const Core::WizardDialogParameters ¶meters);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user