Utils: Initialize all members of ShellCommandPage

Change-Id: I6f6d06f4e6be8b6a8c3b5f7c4b2072660b099699
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
This commit is contained in:
Tim Jenssen
2016-12-05 20:01:41 +01:00
parent c163240611
commit f061c8a53a
3 changed files with 6 additions and 8 deletions

View File

@@ -48,9 +48,7 @@ namespace Utils {
ShellCommandPage::ShellCommandPage(QWidget *parent) :
WizardPage(parent),
m_startedStatus(tr("Command started...")),
m_overwriteOutput(false),
m_state(Idle)
m_startedStatus(tr("Command started..."))
{
resize(264, 200);
auto verticalLayout = new QVBoxLayout(this);

View File

@@ -68,11 +68,11 @@ private:
OutputFormatter *m_formatter;
QLabel *m_statusLabel;
ShellCommand *m_command;
ShellCommand *m_command = nullptr;
QString m_startedStatus;
bool m_overwriteOutput;
bool m_overwriteOutput = false;
State m_state;
State m_state = Idle;
};
} // namespace Utils

View File

@@ -117,7 +117,7 @@ void JsonKitsPage::setupProjectFiles(const JsonWizard::GeneratorFiles &files)
continue;
auto manager = Utils::findOrDefault(managerList, Utils::equal(&IProjectManager::mimeType, mt.name()));
project = manager ? manager->openProject(path, &errorMessage) : 0;
project = manager ? manager->openProject(path, &errorMessage) : nullptr;
if (project) {
if (setupProject(project))
project->saveSettings();
@@ -166,7 +166,7 @@ QVector<JsonKitsPage::ConditionalFeature> JsonKitsPage::parseFeatures(const QVar
if (feature.isEmpty()) {
if (errorMessage) {
*errorMessage = tr("No \"%1\" key found in feature list object.")
.arg(QLatin1String(KEY_FEATURE));
.arg(QLatin1String(KEY_FEATURE));
}
return QVector<ConditionalFeature>();
}