Skip to content
Snippets Groups Projects
Commit bcc3cc99 authored by Tobias Hunger's avatar Tobias Hunger
Browse files

JsonWizard: Make description on projects page default to the wizard description


Change-Id: Icb8a4856dda4298b3ee901bc7a5c22190ddca5a6
Reviewed-by: default avatarAlessandro Portale <alessandro.portale@theqtcompany.com>
parent f68704f8
No related branches found
No related tags found
No related merge requests found
......@@ -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",
......
......@@ -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",
......
......@@ -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",
......
......@@ -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",
......
......@@ -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",
......
......@@ -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());
......
......@@ -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;
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment