forked from qt-creator/qt-creator
BaseFileWizardFactory: rename createWizardDialog method to create
Unify name of parameters object that gets passed into the method while at it anyway. Change-Id: I9cfdfe3b7dcdbd5e083b3b91922053be3a63b081 Reviewed-by: Orgad Shaneh <orgads@gmail.com>
This commit is contained in:
@@ -55,15 +55,13 @@ ClassWizard::ClassWizard()
|
||||
setDescription(ClassWizard::tr(Constants::EN_PY_CLASS_DESCRIPTION));
|
||||
}
|
||||
|
||||
QWizard *ClassWizard::createWizardDialog(
|
||||
QWidget *parent,
|
||||
const Core::WizardDialogParameters ¶ms) const
|
||||
QWizard *ClassWizard::create(QWidget *parent, const Core::WizardDialogParameters ¶meters) const
|
||||
{
|
||||
ClassWizardDialog *wizard = new ClassWizardDialog(parent);
|
||||
foreach (QWizardPage *p, params.extensionPages())
|
||||
foreach (QWizardPage *p, parameters.extensionPages())
|
||||
BaseFileWizardFactory::applyExtensionPageShortTitle(wizard, wizard->addPage(p));
|
||||
wizard->setPath(params.defaultPath());
|
||||
wizard->setExtraValues(params.extraValues());
|
||||
wizard->setPath(parameters.defaultPath());
|
||||
wizard->setExtraValues(parameters.extraValues());
|
||||
return wizard;
|
||||
}
|
||||
|
||||
|
||||
@@ -49,8 +49,7 @@ public:
|
||||
ClassWizard();
|
||||
|
||||
private:
|
||||
QWizard *createWizardDialog(QWidget *parent,
|
||||
const Core::WizardDialogParameters ¶ms) const;
|
||||
QWizard *create(QWidget *parent, const Core::WizardDialogParameters ¶meters) const;
|
||||
|
||||
Core::GeneratedFiles generateFiles(const QWizard *w,
|
||||
QString *errorMessage) const;
|
||||
|
||||
@@ -61,13 +61,12 @@ FileWizard::FileWizard()
|
||||
* @param params
|
||||
* @return
|
||||
*/
|
||||
QWizard *FileWizard::createWizardDialog(QWidget *parent,
|
||||
const Core::WizardDialogParameters ¶ms) const
|
||||
QWizard *FileWizard::create(QWidget *parent, const Core::WizardDialogParameters ¶meters) const
|
||||
{
|
||||
Utils::FileWizardDialog *pDialog = new Utils::FileWizardDialog(parent);
|
||||
pDialog->setWindowTitle(tr("New %1").arg(displayName()));
|
||||
pDialog->setPath(params.defaultPath());
|
||||
foreach (QWizardPage *p, params.extensionPages())
|
||||
pDialog->setPath(parameters.defaultPath());
|
||||
foreach (QWizardPage *p, parameters.extensionPages())
|
||||
applyExtensionPageShortTitle(pDialog, pDialog->addPage(p));
|
||||
|
||||
return pDialog;
|
||||
|
||||
@@ -42,8 +42,7 @@ public:
|
||||
FileWizard();
|
||||
|
||||
protected:
|
||||
QWizard *createWizardDialog(QWidget *parent,
|
||||
const Core::WizardDialogParameters ¶ms) const;
|
||||
QWizard *create(QWidget *parent, const Core::WizardDialogParameters ¶meters) const;
|
||||
|
||||
Core::GeneratedFiles generateFiles(const QWizard *dialog, QString *errorMessage) const;
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user