diff --git a/share/qtcreator/templates/wizards/projects/plainc/wizard.json b/share/qtcreator/templates/wizards/projects/plainc/wizard.json index 5e1828351a5b86bde413b16913c1b7e02351f7b9..fd4188c83cfc19e671f05749e85b29674026dacc 100644 --- a/share/qtcreator/templates/wizards/projects/plainc/wizard.json +++ b/share/qtcreator/templates/wizards/projects/plainc/wizard.json @@ -24,8 +24,7 @@ { "trDisplayName": "Project Location", "trShortTitle": "Location", - "typeId": "Project", - "data": { "trDescription": "This wizard creates an empty .pro file." } + "typeId": "Project" }, { "trDisplayName": "Define Build System", diff --git a/share/qtcreator/templates/wizards/projects/qmake/qtquickapplication/wizard.json b/share/qtcreator/templates/wizards/projects/qmake/qtquickapplication/wizard.json index 841873a91d5a00ccd4e4ab711c28a9b1fc4ef97b..32f6c9d4b90c95e291b07b5249cc31dd92a247e7 100644 --- a/share/qtcreator/templates/wizards/projects/qmake/qtquickapplication/wizard.json +++ b/share/qtcreator/templates/wizards/projects/qmake/qtquickapplication/wizard.json @@ -23,8 +23,7 @@ { "trDisplayName": "Project Location", "trShortTitle": "Location", - "typeId": "Project", - "data": { "trDescription": "Creates a deployable Qt Quick 2 application." } + "typeId": "Project" }, { "trDisplayName": "Define Project Details", diff --git a/share/qtcreator/templates/wizards/projects/qmake/qtquickcontrolsapplication/wizard.json b/share/qtcreator/templates/wizards/projects/qmake/qtquickcontrolsapplication/wizard.json index 562fb15ff19ab3901bdb36b17897b25ba9e4a2fe..b73dca5261a3ce0e92a75e4685673e7ea91b0990 100644 --- a/share/qtcreator/templates/wizards/projects/qmake/qtquickcontrolsapplication/wizard.json +++ b/share/qtcreator/templates/wizards/projects/qmake/qtquickcontrolsapplication/wizard.json @@ -25,8 +25,7 @@ { "trDisplayName": "Project Location", "trShortTitle": "Location", - "typeId": "Project", - "data": { "trDescription": "Creates a deployable Qt Quick 2 application using Qt Quick Controls." } + "typeId": "Project" }, { "trDisplayName": "Define Project Details", diff --git a/share/qtcreator/templates/wizards/projects/qmlproject/qtquickapplication/wizard.json b/share/qtcreator/templates/wizards/projects/qmlproject/qtquickapplication/wizard.json index 30d885eb00a3d64e5c5b725c1ed5289b5df9f338..71004c93c8217b95b385cafdb799faacc467bda8 100644 --- a/share/qtcreator/templates/wizards/projects/qmlproject/qtquickapplication/wizard.json +++ b/share/qtcreator/templates/wizards/projects/qmlproject/qtquickapplication/wizard.json @@ -23,8 +23,7 @@ { "trDisplayName": "Project Location", "trShortTitle": "Location", - "typeId": "Project", - "data": { "trDescription": "Creates a Qt Quick UI project." } + "typeId": "Project" }, { "trDisplayName": "Define Project Details", diff --git a/share/qtcreator/templates/wizards/projects/qmlproject/qtquickcontrolsapplication/wizard.json b/share/qtcreator/templates/wizards/projects/qmlproject/qtquickcontrolsapplication/wizard.json index ead3eaf47c8de1dafc0666217b99d4d173c9efe6..c1978acdeaf5eb15ae8176fe24007681c7d066aa 100644 --- a/share/qtcreator/templates/wizards/projects/qmlproject/qtquickcontrolsapplication/wizard.json +++ b/share/qtcreator/templates/wizards/projects/qmlproject/qtquickcontrolsapplication/wizard.json @@ -25,8 +25,7 @@ { "trDisplayName": "Project Location", "trShortTitle": "Location", - "typeId": "Project", - "data": { "trDescription": "Creates a Qt Quick UI project using Qt Quick Controls." } + "typeId": "Project" }, { "trDisplayName": "Define Project Details", diff --git a/src/plugins/projectexplorer/jsonwizard/jsonwizardfactory.cpp b/src/plugins/projectexplorer/jsonwizard/jsonwizardfactory.cpp index a80f7404b769c30523641f4cec3b9fe8673403b5..ba5cc0bcf04f2ec1c1e00346e6d51dadb1015ab7 100644 --- a/src/plugins/projectexplorer/jsonwizard/jsonwizardfactory.cpp +++ b/src/plugins/projectexplorer/jsonwizard/jsonwizardfactory.cpp @@ -388,6 +388,12 @@ void JsonWizardFactory::runWizard(const QString &path, QWidget *parent, const QS kindStr = QLatin1String(Core::Constants::WIZARD_KIND_PROJECT); wizard.setValue(QStringLiteral("kind"), kindStr); + wizard.setValue(QStringLiteral("trDescription"), description()); + wizard.setValue(QStringLiteral("trDisplayName"), displayName()); + wizard.setValue(QStringLiteral("trCategory"), displayCategory()); + wizard.setValue(QStringLiteral("category"), category()); + wizard.setValue(QStringLiteral("id"), id().toString()); + for (auto i = m_options.constBegin(); i != m_options.constEnd(); ++i) wizard.setValue(i.key(), i.value()); diff --git a/src/plugins/projectexplorer/jsonwizard/jsonwizardpagefactory_p.cpp b/src/plugins/projectexplorer/jsonwizard/jsonwizardpagefactory_p.cpp index bca42a7f5275629a8227d6da9ba607d6ba5eecfe..46c7bfe27bcc59ba2633276f2ad37715553380a6 100644 --- a/src/plugins/projectexplorer/jsonwizard/jsonwizardpagefactory_p.cpp +++ b/src/plugins/projectexplorer/jsonwizard/jsonwizardpagefactory_p.cpp @@ -182,8 +182,9 @@ Utils::WizardPage *ProjectPageFactory::create(JsonWizard *wizard, Core::Id typeI JsonProjectPage *page = new JsonProjectPage; QVariantMap tmp = data.isNull() ? QVariantMap() : data.toMap(); - QString description = tmp.value(QLatin1String("trDescription")).toString(); - page->setDescription(description); + QString description + = tmp.value(QLatin1String("trDescription"), QLatin1String("%{trDescription}")).toString(); + page->setDescription(wizard->expander()->expand(description)); return page; }