Commit 2631ffab authored by Tim Jenssen's avatar Tim Jenssen

Remove spaces in initializer lists

Format initializer lists code style like.

Change-Id: Ib82c235e4ba7dc75ee96a7abc0c47eff7b0a9013
Reviewed-by: default avatarhjk <hjk@qt.io>
parent 005ca71c
...@@ -102,7 +102,7 @@ static bool insertQuote(const QChar ch, const BackwardsScanner &tk) ...@@ -102,7 +102,7 @@ static bool insertQuote(const QChar ch, const BackwardsScanner &tk)
return tk.text(index) == "operator"; return tk.text(index) == "operator";
// Insert matching quote after identifier when identifier is a known literal prefixes // Insert matching quote after identifier when identifier is a known literal prefixes
static const QStringList stringLiteralPrefixes = { "L", "U", "u", "u8", "R"}; static const QStringList stringLiteralPrefixes = {"L", "U", "u", "u8", "R"};
return token.kind() == CPlusPlus::T_IDENTIFIER return token.kind() == CPlusPlus::T_IDENTIFIER
&& stringLiteralPrefixes.contains(tk.text(index)); && stringLiteralPrefixes.contains(tk.text(index));
} }
......
...@@ -840,7 +840,7 @@ void Preprocessor::handleDefined(PPToken *tk) ...@@ -840,7 +840,7 @@ void Preprocessor::handleDefined(PPToken *tk)
void Preprocessor::pushToken(Preprocessor::PPToken *tk) void Preprocessor::pushToken(Preprocessor::PPToken *tk)
{ {
const PPToken currentTokenBuffer[] = { *tk }; const PPToken currentTokenBuffer[] = {*tk};
m_state.pushTokenBuffer(currentTokenBuffer, currentTokenBuffer + 1, 0); m_state.pushTokenBuffer(currentTokenBuffer, currentTokenBuffer + 1, 0);
} }
......
...@@ -313,19 +313,19 @@ void DiagramSceneController::dropNewElement(const QString &newElementId, const Q ...@@ -313,19 +313,19 @@ void DiagramSceneController::dropNewElement(const QString &newElementId, const Q
auto package = new MPackage(); auto package = new MPackage();
newName = tr("New Package"); newName = tr("New Package");
if (!stereotype.isEmpty()) if (!stereotype.isEmpty())
package->setStereotypes({ stereotype }); package->setStereotypes({stereotype});
newObject = package; newObject = package;
} else if (newElementId == QLatin1String(ELEMENT_TYPE_COMPONENT)) { } else if (newElementId == QLatin1String(ELEMENT_TYPE_COMPONENT)) {
auto component = new MComponent(); auto component = new MComponent();
newName = tr("New Component"); newName = tr("New Component");
if (!stereotype.isEmpty()) if (!stereotype.isEmpty())
component->setStereotypes({ stereotype }); component->setStereotypes({stereotype});
newObject = component; newObject = component;
} else if (newElementId == QLatin1String(ELEMENT_TYPE_CLASS)) { } else if (newElementId == QLatin1String(ELEMENT_TYPE_CLASS)) {
auto klass = new MClass(); auto klass = new MClass();
newName = tr("New Class"); newName = tr("New Class");
if (!stereotype.isEmpty()) if (!stereotype.isEmpty())
klass->setStereotypes({ stereotype }); klass->setStereotypes({stereotype});
newObject = klass; newObject = klass;
} else if (newElementId == QLatin1String(ELEMENT_TYPE_ITEM)) { } else if (newElementId == QLatin1String(ELEMENT_TYPE_ITEM)) {
auto item = new MItem(); auto item = new MItem();
......
...@@ -492,34 +492,34 @@ private: ...@@ -492,34 +492,34 @@ private:
class IdsThatShouldNotBeUsedInDesigner : public QStringList class IdsThatShouldNotBeUsedInDesigner : public QStringList
{ {
public: public:
IdsThatShouldNotBeUsedInDesigner() : QStringList({ "top", IdsThatShouldNotBeUsedInDesigner() : QStringList({"top",
"bottom", "bottom",
"left", "left",
"right", "right",
"width", "width",
"height", "height",
"x", "x",
"y", "y",
"opacity", "opacity",
"parent", "parent",
"item", "item",
"flow", "flow",
"color", "color",
"margin", "margin",
"padding", "padding",
"border", "border",
"font", "font",
"text", "text",
"source", "source",
"state", "state",
"visible", "visible",
"focus", "focus",
"data", "data",
"clip", "clip",
"layer", "layer",
"scale", "scale",
"enabled", "enabled",
"anchors"}) "anchors"})
{ {
} }
...@@ -550,13 +550,13 @@ class UnsupportedTypesByVisualDesigner : public QStringList ...@@ -550,13 +550,13 @@ class UnsupportedTypesByVisualDesigner : public QStringList
{ {
public: public:
UnsupportedTypesByVisualDesigner() : QStringList({"Transform", UnsupportedTypesByVisualDesigner() : QStringList({"Transform",
"Timer", "Timer",
"Rotation", "Rotation",
"Scale", "Scale",
"Translate", "Translate",
"Package", "Package",
"Particles", "Particles",
"Dialog"}) "Dialog"})
{ {
} }
...@@ -566,18 +566,18 @@ class UnsupportedTypesByQmlUi : public QStringList ...@@ -566,18 +566,18 @@ class UnsupportedTypesByQmlUi : public QStringList
{ {
public: public:
UnsupportedTypesByQmlUi() : QStringList({"Binding", UnsupportedTypesByQmlUi() : QStringList({"Binding",
"ShaderEffect", "ShaderEffect",
"ShaderEffectSource", "ShaderEffectSource",
"Component", "Component",
"Loader", "Loader",
"Transition", "Transition",
"PropertyAnimation", "PropertyAnimation",
"SequentialAnimation", "SequentialAnimation",
"PropertyAnimation", "PropertyAnimation",
"SequentialAnimation", "SequentialAnimation",
"ParallelAnimation", "ParallelAnimation",
"NumberAnimation", "NumberAnimation",
"Drawer"}) "Drawer"})
{ {
append(UnsupportedTypesByVisualDesigner()); append(UnsupportedTypesByVisualDesigner());
} }
...@@ -1627,8 +1627,8 @@ bool Check::visit(CallExpression *ast) ...@@ -1627,8 +1627,8 @@ bool Check::visit(CallExpression *ast)
// We have to allow the translation functions // We have to allow the translation functions
const QStringList translationFunctions = { "qsTr", "qsTrId", "qsTranslate", const QStringList translationFunctions = {"qsTr", "qsTrId", "qsTranslate",
"qsTrNoOp", "qsTrIdNoOp", "qsTranslateNoOp" }; "qsTrNoOp", "qsTrIdNoOp", "qsTranslateNoOp"};
const bool isTranslationFunction = translationFunctions.contains(name); const bool isTranslationFunction = translationFunctions.contains(name);
......
...@@ -647,10 +647,10 @@ QString PluginDumper::resolvePlugin(const QDir &qmldirPath, const QString &qmldi ...@@ -647,10 +647,10 @@ QString PluginDumper::resolvePlugin(const QDir &qmldirPath, const QString &qmldi
QString prefix; QString prefix;
if (Utils::HostOsInfo::isWindowsHost()) { if (Utils::HostOsInfo::isWindowsHost()) {
// try a qmake-style debug build first // try a qmake-style debug build first
validSuffixList = QStringList({ "d.dll", ".dll" }); validSuffixList = QStringList({"d.dll", ".dll"});
} else if (Utils::HostOsInfo::isMacHost()) { } else if (Utils::HostOsInfo::isMacHost()) {
// try a qmake-style debug build first // try a qmake-style debug build first
validSuffixList = QStringList({ "_debug.dylib", ".dylib", ".so", ".bundle", "lib" }); validSuffixList = QStringList({"_debug.dylib", ".dylib", ".so", ".bundle", "lib"});
} else { } else {
// Examples of valid library names: // Examples of valid library names:
// libfoo.so // libfoo.so
......
...@@ -58,13 +58,13 @@ const struct { ...@@ -58,13 +58,13 @@ const struct {
SshRemoteProcess::Signal signalEnum; SshRemoteProcess::Signal signalEnum;
const char * const signalString; const char * const signalString;
} signalMap[] = { } signalMap[] = {
{ SshRemoteProcess::AbrtSignal, "ABRT" }, { SshRemoteProcess::AlrmSignal, "ALRM" }, {SshRemoteProcess::AbrtSignal, "ABRT"}, {SshRemoteProcess::AlrmSignal, "ALRM"},
{ SshRemoteProcess::FpeSignal, "FPE" }, { SshRemoteProcess::HupSignal, "HUP" }, {SshRemoteProcess::FpeSignal, "FPE"}, {SshRemoteProcess::HupSignal, "HUP"},
{ SshRemoteProcess::IllSignal, "ILL" }, { SshRemoteProcess::IntSignal, "INT" }, {SshRemoteProcess::IllSignal, "ILL"}, {SshRemoteProcess::IntSignal, "INT"},
{ SshRemoteProcess::KillSignal, "KILL" }, { SshRemoteProcess::PipeSignal, "PIPE" }, {SshRemoteProcess::KillSignal, "KILL"}, {SshRemoteProcess::PipeSignal, "PIPE"},
{ SshRemoteProcess::QuitSignal, "QUIT" }, { SshRemoteProcess::SegvSignal, "SEGV" }, {SshRemoteProcess::QuitSignal, "QUIT"}, {SshRemoteProcess::SegvSignal, "SEGV"},
{ SshRemoteProcess::TermSignal, "TERM" }, { SshRemoteProcess::Usr1Signal, "USR1" }, {SshRemoteProcess::TermSignal, "TERM"}, {SshRemoteProcess::Usr1Signal, "USR1"},
{ SshRemoteProcess::Usr2Signal, "USR2" } {SshRemoteProcess::Usr2Signal, "USR2"}
}; };
SshRemoteProcess::SshRemoteProcess(const QByteArray &command, quint32 channelId, SshRemoteProcess::SshRemoteProcess(const QByteArray &command, quint32 channelId,
......
...@@ -137,7 +137,7 @@ int TimelineNotesModel::add(int modelId, int timelineIndex, const QString &text) ...@@ -137,7 +137,7 @@ int TimelineNotesModel::add(int modelId, int timelineIndex, const QString &text)
Q_D(TimelineNotesModel); Q_D(TimelineNotesModel);
const TimelineModel *model = d->timelineModels.value(modelId); const TimelineModel *model = d->timelineModels.value(modelId);
int typeId = model->typeId(timelineIndex); int typeId = model->typeId(timelineIndex);
TimelineNotesModelPrivate::Note note = { text, modelId, timelineIndex }; TimelineNotesModelPrivate::Note note = {text, modelId, timelineIndex};
d->data << note; d->data << note;
d->modified = true; d->modified = true;
emit changed(typeId, modelId, timelineIndex); emit changed(typeId, modelId, timelineIndex);
......
...@@ -101,7 +101,7 @@ bool ConsoleProcess::start(const QString &program, const QString &args) ...@@ -101,7 +101,7 @@ bool ConsoleProcess::start(const QString &program, const QString &args)
} }
pcmd = QLatin1String("/bin/sh"); pcmd = QLatin1String("/bin/sh");
pargs = QtcProcess::Arguments::createUnixArgs( pargs = QtcProcess::Arguments::createUnixArgs(
QStringList({ "-c", (QtcProcess::quoteArg(program) + ' ' + args) })); QStringList({"-c", (QtcProcess::quoteArg(program) + ' ' + args)}));
} }
QtcProcess::SplitError qerr; QtcProcess::SplitError qerr;
......
...@@ -475,9 +475,9 @@ FileSaver::FileSaver(const QString &filename, QIODevice::OpenMode mode) ...@@ -475,9 +475,9 @@ FileSaver::FileSaver(const QString &filename, QIODevice::OpenMode mode)
if (HostOsInfo::isWindowsHost()) { if (HostOsInfo::isWindowsHost()) {
// Taken from: https://msdn.microsoft.com/en-us/library/windows/desktop/aa365247(v=vs.85).aspx // Taken from: https://msdn.microsoft.com/en-us/library/windows/desktop/aa365247(v=vs.85).aspx
static const QStringList reservedNames static const QStringList reservedNames
= { "CON", "PRN", "AUX", "NUL", = {"CON", "PRN", "AUX", "NUL",
"COM1", "COM2", "COM3", "COM4", "COM5", "COM6", "COM7", "COM8", "COM9", "COM1", "COM2", "COM3", "COM4", "COM5", "COM6", "COM7", "COM8", "COM9",
"LPT1", "LPT2", "LPT3", "LPT4", "LPT5", "LPT6", "LPT7", "LPT8", "LPT9" }; "LPT1", "LPT2", "LPT3", "LPT4", "LPT5", "LPT6", "LPT7", "LPT8", "LPT9"};
const QString fn = QFileInfo(filename).baseName().toUpper(); const QString fn = QFileInfo(filename).baseName().toUpper();
for (const QString &rn : reservedNames) { for (const QString &rn : reservedNames) {
if (fn == rn) { if (fn == rn) {
......
...@@ -660,7 +660,7 @@ bool QtcProcess::prepareCommand(const QString &command, const QString &arguments ...@@ -660,7 +660,7 @@ bool QtcProcess::prepareCommand(const QString &command, const QString &arguments
return false; return false;
*outCmd = QLatin1String("/bin/sh"); *outCmd = QLatin1String("/bin/sh");
*outArgs = Arguments::createUnixArgs( *outArgs = Arguments::createUnixArgs(
QStringList({ "-c", (quoteArg(command) + ' ' + arguments) })); QStringList({"-c", (quoteArg(command) + ' ' + arguments)}));
} }
} }
return true; return true;
...@@ -1039,7 +1039,7 @@ bool QtcProcess::expandMacros(QString *cmd, AbstractMacroExpander *mx, OsType os ...@@ -1039,7 +1039,7 @@ bool QtcProcess::expandMacros(QString *cmd, AbstractMacroExpander *mx, OsType os
} }
} else { } else {
// !Windows // !Windows
MxState state = { MxBasic, false }; MxState state = {MxBasic, false};
QStack<MxState> sstack; QStack<MxState> sstack;
QStack<MxSave> ostack; QStack<MxSave> ostack;
...@@ -1085,7 +1085,7 @@ bool QtcProcess::expandMacros(QString *cmd, AbstractMacroExpander *mx, OsType os ...@@ -1085,7 +1085,7 @@ bool QtcProcess::expandMacros(QString *cmd, AbstractMacroExpander *mx, OsType os
if (str.unicode()[pos + 1].unicode() == '(') { if (str.unicode()[pos + 1].unicode() == '(') {
// $(( starts a math expression. This may also be a $( ( in fact, // $(( starts a math expression. This may also be a $( ( in fact,
// so we push the current string and offset on a stack so we can retry. // so we push the current string and offset on a stack so we can retry.
MxSave sav = { str, pos + 2, varPos }; MxSave sav = {str, pos + 2, varPos};
ostack.push(sav); ostack.push(sav);
state.current = MxMath; state.current = MxMath;
pos += 2; pos += 2;
...@@ -1315,7 +1315,7 @@ bool QtcProcess::ArgIterator::next() ...@@ -1315,7 +1315,7 @@ bool QtcProcess::ArgIterator::next()
} }
} }
} else { } else {
MxState state = { MxBasic, false }; MxState state = {MxBasic, false};
QStack<MxState> sstack; QStack<MxState> sstack;
QStack<int> ostack; QStack<int> ostack;
bool hadWord = false; bool hadWord = false;
......
...@@ -700,7 +700,7 @@ static QString checkBinary(const QDir &dir, const QString &binary) ...@@ -700,7 +700,7 @@ static QString checkBinary(const QDir &dir, const QString &binary)
case OsTypeOther: case OsTypeOther:
break; break;
case OsTypeWindows: { case OsTypeWindows: {
static const char *windowsExtensions[] = {".cmd", ".bat", ".exe", ".com" }; static const char *windowsExtensions[] = {".cmd", ".bat", ".exe", ".com"};
// Check the Windows extensions using the order // Check the Windows extensions using the order
const int windowsExtensionCount = sizeof(windowsExtensions)/sizeof(const char*); const int windowsExtensionCount = sizeof(windowsExtensions)/sizeof(const char*);
for (int e = 0; e < windowsExtensionCount; e ++) { for (int e = 0; e < windowsExtensionCount; e ++) {
......
...@@ -272,44 +272,44 @@ QPalette Theme::palette() const ...@@ -272,44 +272,44 @@ QPalette Theme::palette() const
QPalette::ColorGroup paletteColorGroup; QPalette::ColorGroup paletteColorGroup;
bool setColorRoleAsBrush; bool setColorRoleAsBrush;
} mapping[] = { } mapping[] = {
{ PaletteWindow, QPalette::Window, QPalette::All, false}, {PaletteWindow, QPalette::Window, QPalette::All, false},
{ PaletteWindowDisabled, QPalette::Window, QPalette::Disabled, false}, {PaletteWindowDisabled, QPalette::Window, QPalette::Disabled, false},
{ PaletteWindowText, QPalette::WindowText, QPalette::All, true}, {PaletteWindowText, QPalette::WindowText, QPalette::All, true},
{ PaletteWindowTextDisabled, QPalette::WindowText, QPalette::Disabled, true}, {PaletteWindowTextDisabled, QPalette::WindowText, QPalette::Disabled, true},
{ PaletteBase, QPalette::Base, QPalette::All, false}, {PaletteBase, QPalette::Base, QPalette::All, false},
{ PaletteBaseDisabled, QPalette::Base, QPalette::Disabled, false}, {PaletteBaseDisabled, QPalette::Base, QPalette::Disabled, false},
{ PaletteAlternateBase, QPalette::AlternateBase, QPalette::All, false}, {PaletteAlternateBase, QPalette::AlternateBase, QPalette::All, false},
{ PaletteAlternateBaseDisabled, QPalette::AlternateBase, QPalette::Disabled, false}, {PaletteAlternateBaseDisabled, QPalette::AlternateBase, QPalette::Disabled, false},
{ PaletteToolTipBase, QPalette::ToolTipBase, QPalette::All, true}, {PaletteToolTipBase, QPalette::ToolTipBase, QPalette::All, true},
{ PaletteToolTipBaseDisabled, QPalette::ToolTipBase, QPalette::Disabled, true}, {PaletteToolTipBaseDisabled, QPalette::ToolTipBase, QPalette::Disabled, true},
{ PaletteToolTipText, QPalette::ToolTipText, QPalette::All, false}, {PaletteToolTipText, QPalette::ToolTipText, QPalette::All, false},
{ PaletteToolTipTextDisabled, QPalette::ToolTipText, QPalette::Disabled, false}, {PaletteToolTipTextDisabled, QPalette::ToolTipText, QPalette::Disabled, false},
{ PaletteText, QPalette::Text, QPalette::All, true}, {PaletteText, QPalette::Text, QPalette::All, true},
{ PaletteTextDisabled, QPalette::Text, QPalette::Disabled, true}, {PaletteTextDisabled, QPalette::Text, QPalette::Disabled, true},
{ PaletteButton, QPalette::Button, QPalette::All, false}, {PaletteButton, QPalette::Button, QPalette::All, false},
{ PaletteButtonDisabled, QPalette::Button, QPalette::Disabled, false}, {PaletteButtonDisabled, QPalette::Button, QPalette::Disabled, false},
{ PaletteButtonText, QPalette::ButtonText, QPalette::All, true}, {PaletteButtonText, QPalette::ButtonText, QPalette::All, true},
{ PaletteButtonTextDisabled, QPalette::ButtonText, QPalette::Disabled, true}, {PaletteButtonTextDisabled, QPalette::ButtonText, QPalette::Disabled, true},
{ PaletteBrightText, QPalette::BrightText, QPalette::All, false}, {PaletteBrightText, QPalette::BrightText, QPalette::All, false},
{ PaletteBrightTextDisabled, QPalette::BrightText, QPalette::Disabled, false}, {PaletteBrightTextDisabled, QPalette::BrightText, QPalette::Disabled, false},
{ PaletteHighlight, QPalette::Highlight, QPalette::All, true}, {PaletteHighlight, QPalette::Highlight, QPalette::All, true},
{ PaletteHighlightDisabled, QPalette::Highlight, QPalette::Disabled, true}, {PaletteHighlightDisabled, QPalette::Highlight, QPalette::Disabled, true},
{ PaletteHighlightedText, QPalette::HighlightedText, QPalette::All, true}, {PaletteHighlightedText, QPalette::HighlightedText, QPalette::All, true},
{ PaletteHighlightedTextDisabled, QPalette::HighlightedText, QPalette::Disabled, true}, {PaletteHighlightedTextDisabled, QPalette::HighlightedText, QPalette::Disabled, true},
{ PaletteLink, QPalette::Link, QPalette::All, false}, {PaletteLink, QPalette::Link, QPalette::All, false},
{ PaletteLinkDisabled, QPalette::Link, QPalette::Disabled, false}, {PaletteLinkDisabled, QPalette::Link, QPalette::Disabled, false},
{ PaletteLinkVisited, QPalette::LinkVisited, QPalette::All, false}, {PaletteLinkVisited, QPalette::LinkVisited, QPalette::All, false},
{ PaletteLinkVisitedDisabled, QPalette::LinkVisited, QPalette::Disabled, false}, {PaletteLinkVisitedDisabled, QPalette::LinkVisited, QPalette::Disabled, false},
{ PaletteLight, QPalette::Light, QPalette::All, false}, {PaletteLight, QPalette::Light, QPalette::All, false},
{ PaletteLightDisabled, QPalette::Light, QPalette::Disabled, false}, {PaletteLightDisabled, QPalette::Light, QPalette::Disabled, false},
{ PaletteMidlight, QPalette::Midlight, QPalette::All, false}, {PaletteMidlight, QPalette::Midlight, QPalette::All, false},
{ PaletteMidlightDisabled, QPalette::Midlight, QPalette::Disabled, false}, {PaletteMidlightDisabled, QPalette::Midlight, QPalette::Disabled, false},
{ PaletteDark, QPalette::Dark, QPalette::All, false}, {PaletteDark, QPalette::Dark, QPalette::All, false},
{ PaletteDarkDisabled, QPalette::Dark, QPalette::Disabled, false}, {PaletteDarkDisabled, QPalette::Dark, QPalette::Disabled, false},
{ PaletteMid, QPalette::Mid, QPalette::All, false}, {PaletteMid, QPalette::Mid, QPalette::All, false},
{ PaletteMidDisabled, QPalette::Mid, QPalette::Disabled, false}, {PaletteMidDisabled, QPalette::Mid, QPalette::Disabled, false},
{ PaletteShadow, QPalette::Shadow, QPalette::All, false}, {PaletteShadow, QPalette::Shadow, QPalette::All, false},
{ PaletteShadowDisabled, QPalette::Shadow, QPalette::Disabled, false} {PaletteShadowDisabled, QPalette::Shadow, QPalette::Disabled, false}
}; };
for (auto entry: mapping) { for (auto entry: mapping) {
......
...@@ -355,8 +355,8 @@ QAbstractItemModel *AndroidBuildApkStep::keystoreCertificates() ...@@ -355,8 +355,8 @@ QAbstractItemModel *AndroidBuildApkStep::keystoreCertificates()
CertificatesModel *model = nullptr; CertificatesModel *model = nullptr;
QStringList params QStringList params
= { QLatin1String("-list"), QLatin1String("-v"), QLatin1String("-keystore"), = {QLatin1String("-list"), QLatin1String("-v"), QLatin1String("-keystore"),
m_keystorePath.toUserOutput(), QLatin1String("-storepass") }; m_keystorePath.toUserOutput(), QLatin1String("-storepass")};
params << m_keystorePasswd; params << m_keystorePasswd;
params << QLatin1String("-J-Duser.language=en"); params << QLatin1String("-J-Duser.language=en");
......
...@@ -378,7 +378,7 @@ void AndroidConfig::updateAvailableSdkPlatforms() const ...@@ -378,7 +378,7 @@ void AndroidConfig::updateAvailableSdkPlatforms() const
proc.setProcessEnvironment(androidToolEnvironment().toProcessEnvironment()); proc.setProcessEnvironment(androidToolEnvironment().toProcessEnvironment());
SynchronousProcessResponse response SynchronousProcessResponse response
= proc.runBlocking(androidToolPath().toString(), = proc.runBlocking(androidToolPath().toString(),
QStringList({ "list", "target" })); // list available AVDs QStringList({"list", "target"})); // list available AVDs
if (response.result != SynchronousProcessResponse::Finished) if (response.result != SynchronousProcessResponse::Finished)
return; return;
...@@ -668,7 +668,7 @@ bool AndroidConfig::removeAVD(const QString &name) const ...@@ -668,7 +668,7 @@ bool AndroidConfig::removeAVD(const QString &name) const
proc.setTimeoutS(5); proc.setTimeoutS(5);
proc.setProcessEnvironment(androidToolEnvironment().toProcessEnvironment()); proc.setProcessEnvironment(androidToolEnvironment().toProcessEnvironment());
SynchronousProcessResponse response SynchronousProcessResponse response
= proc.runBlocking(androidToolPath().toString(), QStringList({ "delete", "avd", "-n", name })); = proc.runBlocking(androidToolPath().toString(), QStringList({"delete", "avd", "-n", name}));
return response.result == SynchronousProcessResponse::Finished && response.exitCode == 0; return response.result == SynchronousProcessResponse::Finished && response.exitCode == 0;
} }
...@@ -684,7 +684,7 @@ QVector<AndroidDeviceInfo> AndroidConfig::androidVirtualDevices(const QString &a ...@@ -684,7 +684,7 @@ QVector<AndroidDeviceInfo> AndroidConfig::androidVirtualDevices(const QString &a
SynchronousProcess proc; SynchronousProcess proc;
proc.setTimeoutS(20); proc.setTimeoutS(20);
proc.setProcessEnvironment(environment.toProcessEnvironment()); proc.setProcessEnvironment(environment.toProcessEnvironment());
SynchronousProcessResponse response = proc.run(androidTool, { "list", "avd" }); // list available AVDs SynchronousProcessResponse response = proc.run(androidTool, {"list", "avd"}); // list available AVDs
if (response.result != SynchronousProcessResponse::Finished) if (response.result != SynchronousProcessResponse::Finished)
return devices; return devices;
...@@ -1350,7 +1350,7 @@ QStringList AndroidDeviceInfo::adbSelector(const QString &serialNumber) ...@@ -1350,7 +1350,7 @@ QStringList AndroidDeviceInfo::adbSelector(const QString &serialNumber)
{ {
if (serialNumber.startsWith(QLatin1String("????"))) if (serialNumber.startsWith(QLatin1String("????")))
return QStringList("-d"); return QStringList("-d");
return QStringList({ "-s", serialNumber }); return QStringList({"-s",