summaryrefslogtreecommitdiff
path: root/src/plugins/coreplugin/basefilewizardfactory.cpp
diff options
context:
space:
mode:
authorTobias Hunger <tobias.hunger@digia.com>2014-05-27 12:23:38 +0200
committerTobias Hunger <tobias.hunger@digia.com>2014-06-06 09:34:52 +0200
commit5b5bea0c142064f88ad65220730e04ebb33623ca (patch)
tree7ce5d99e9a65ecd103f7d1ddcba8f0e2937c0692 /src/plugins/coreplugin/basefilewizardfactory.cpp
parenta34b0b90cd3554c1407497409a02c06936052ca6 (diff)
downloadqt-creator-5b5bea0c142064f88ad65220730e04ebb33623ca.tar.gz
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>
Diffstat (limited to 'src/plugins/coreplugin/basefilewizardfactory.cpp')
-rw-r--r--src/plugins/coreplugin/basefilewizardfactory.cpp30
1 files changed, 14 insertions, 16 deletions
diff --git a/src/plugins/coreplugin/basefilewizardfactory.cpp b/src/plugins/coreplugin/basefilewizardfactory.cpp
index 3e8ddd308d..2ee671f13d 100644
--- a/src/plugins/coreplugin/basefilewizardfactory.cpp
+++ b/src/plugins/coreplugin/basefilewizardfactory.cpp
@@ -164,7 +164,7 @@ void WizardEventLoop::rejected()
The following abstract functions must be implemented:
\list
- \li createWizardDialog(): Called to create the QWizard dialog to be shown.
+ \li create(): Called to create the QWizard dialog to be shown.
\li generateFiles(): Generates file content.
\endlist
@@ -214,12 +214,12 @@ void BaseFileWizardFactory::runWizard(const QString &path, QWidget *parent, cons
if (flags().testFlag(ForceCapitalLetterForFileName))
dialogParameterFlags |= WizardDialogParameters::ForceCapitalLetterForFileName;
- const QScopedPointer<QWizard> wizard(createWizardDialog(parent, WizardDialogParameters(path,
- allExtensionPages,
- platform,
- requiredFeatures(),
- dialogParameterFlags,
- extraValues)));
+ const QScopedPointer<QWizard> wizard(create(parent, WizardDialogParameters(path,
+ allExtensionPages,
+ platform,
+ requiredFeatures(),
+ dialogParameterFlags,
+ extraValues)));
QTC_ASSERT(!wizard.isNull(), return);
GeneratedFiles files;
@@ -300,11 +300,10 @@ void BaseFileWizardFactory::runWizard(const QString &path, QWidget *parent, cons
}
/*!
- \fn virtual QWizard *Core::BaseFileWizard::createWizardDialog(QWidget *parent,
- const WizardDialogParameters &wizardDialogParameters) const
+ \fn virtual QWizard *Core::BaseFileWizard::create(QWidget *parent,
+ const WizardDialogParameters &parameters) const
- Creates the wizard dialog on the \a parent with the
- \a wizardDialogParameters.
+ Creates the wizard on the \a parent with the \a parameters.
*/
/*!
@@ -525,15 +524,14 @@ QString BaseFileWizardFactory::preferredSuffix(const QString &mimeType)
Creates a Utils::FileWizardDialog.
*/
-QWizard *StandardFileWizardFactory::createWizardDialog(QWidget *parent,
- const WizardDialogParameters &wizardDialogParameters) const
+QWizard *StandardFileWizardFactory::create(QWidget *parent, const WizardDialogParameters &parameters) const
{
Utils::FileWizardDialog *standardWizardDialog = new Utils::FileWizardDialog(parent);
- if (wizardDialogParameters.flags().testFlag(WizardDialogParameters::ForceCapitalLetterForFileName))
+ if (parameters.flags().testFlag(WizardDialogParameters::ForceCapitalLetterForFileName))
standardWizardDialog->setForceFirstCapitalLetterForFileName(true);
standardWizardDialog->setWindowTitle(tr("New %1").arg(displayName()));
- standardWizardDialog->setPath(wizardDialogParameters.defaultPath());
- foreach (QWizardPage *p, wizardDialogParameters.extensionPages())
+ standardWizardDialog->setPath(parameters.defaultPath());
+ foreach (QWizardPage *p, parameters.extensionPages())
BaseFileWizardFactory::applyExtensionPageShortTitle(standardWizardDialog, standardWizardDialog->addPage(p));
return standardWizardDialog;
}