diff options
author | Eike Ziller <eike.ziller@qt.io> | 2018-08-07 09:42:02 +0200 |
---|---|---|
committer | Eike Ziller <eike.ziller@qt.io> | 2018-08-07 09:42:02 +0200 |
commit | 847787f146b2583167f9d4bdbfb912c075b4af15 (patch) | |
tree | 822cac1939880b28b90ab78cf9c7aad8bccea6ce /src | |
parent | 141f19a65283d3b2ac5677068cd858e1ace10623 (diff) | |
parent | ff10f8c3a58c2c57e221e294d5c4829c3fd05c15 (diff) | |
download | qt-creator-847787f146b2583167f9d4bdbfb912c075b4af15.tar.gz |
Merge remote-tracking branch 'origin/4.7'
Conflicts:
src/plugins/debugger/debuggerruncontrol.cpp
Change-Id: I72882df605bc3fc8a8d20118fd4e49207ac92664
Diffstat (limited to 'src')
-rw-r--r-- | src/libs/utils/environment.cpp | 6 | ||||
-rw-r--r-- | src/plugins/autotest/testrunner.cpp | 13 | ||||
-rw-r--r-- | src/plugins/autotest/testrunner.h | 2 | ||||
-rw-r--r-- | src/plugins/cpptools/cppvirtualfunctionassistprovider.h | 1 | ||||
-rw-r--r-- | src/plugins/debugger/gdb/gdbengine.cpp | 8 | ||||
-rw-r--r-- | src/plugins/qmakeprojectmanager/wizards/guiappwizard.cpp | 3 | ||||
-rw-r--r-- | src/plugins/qmakeprojectmanager/wizards/guiappwizarddialog.cpp | 1 | ||||
-rw-r--r-- | src/plugins/texteditor/codeassist/codeassistant.cpp | 2 | ||||
m--------- | src/shared/qbs | 0 |
9 files changed, 25 insertions, 11 deletions
diff --git a/src/libs/utils/environment.cpp b/src/libs/utils/environment.cpp index d7eb1e7c1d..9b77a8b71e 100644 --- a/src/libs/utils/environment.cpp +++ b/src/libs/utils/environment.cpp @@ -49,8 +49,10 @@ public: toReplace.append(':'); toReplace.append(lib.path()); - if (ldLibraryPath.startsWith(toReplace)) - set("LD_LIBRARY_PATH", ldLibraryPath.remove(0, toReplace.length())); + if (ldLibraryPath.startsWith(toReplace + ':')) + set("LD_LIBRARY_PATH", ldLibraryPath.remove(0, toReplace.length() + 1)); + else if (ldLibraryPath == toReplace) + unset("LD_LIBRARY_PATH"); } } }; diff --git a/src/plugins/autotest/testrunner.cpp b/src/plugins/autotest/testrunner.cpp index ce3afcffa7..e77533431d 100644 --- a/src/plugins/autotest/testrunner.cpp +++ b/src/plugins/autotest/testrunner.cpp @@ -238,7 +238,8 @@ void TestRunner::cancelCurrent(TestRunner::CancelReason reason) void TestRunner::onProcessFinished() { - if (m_currentConfig) { + if (m_executingTests && QTC_GUARD(m_currentConfig)) { + QTC_CHECK(m_fakeFutureInterface); m_fakeFutureInterface->setProgressValue(m_fakeFutureInterface->progressValue() + m_currentConfig->testCaseCount()); if (!m_fakeFutureInterface->isCanceled()) { @@ -257,6 +258,10 @@ void TestRunner::onProcessFinished() } resetInternalPointers(); + if (!m_fakeFutureInterface) { + QTC_ASSERT(!m_executingTests, m_executingTests = false); + return; + } if (!m_selectedTests.isEmpty() && !m_fakeFutureInterface->isCanceled()) scheduleNext(); else @@ -552,8 +557,9 @@ void TestRunner::debugTests() outputreader, &QObject::deleteLater); } - connect(this, &TestRunner::requestStopTestRun, runControl, - &ProjectExplorer::RunControl::initiateStop); + m_stopDebugConnect = connect(this, &TestRunner::requestStopTestRun, + runControl, &ProjectExplorer::RunControl::initiateStop); + connect(runControl, &ProjectExplorer::RunControl::stopped, this, &TestRunner::onFinished); ProjectExplorer::ProjectExplorerPlugin::startRunControl(runControl); } @@ -611,6 +617,7 @@ void TestRunner::onFinished() qDeleteAll(m_selectedTests); m_selectedTests.clear(); + disconnect(m_stopDebugConnect); disconnect(m_targetConnect); m_fakeFutureInterface = nullptr; m_executingTests = false; diff --git a/src/plugins/autotest/testrunner.h b/src/plugins/autotest/testrunner.h index c73d857505..f6cc708dcb 100644 --- a/src/plugins/autotest/testrunner.h +++ b/src/plugins/autotest/testrunner.h @@ -98,6 +98,8 @@ private: // temporarily used if building before running is necessary QMetaObject::Connection m_buildConnect; + // temporarily used when debugging + QMetaObject::Connection m_stopDebugConnect; // temporarily used for handling of switching the current target QMetaObject::Connection m_targetConnect; }; diff --git a/src/plugins/cpptools/cppvirtualfunctionassistprovider.h b/src/plugins/cpptools/cppvirtualfunctionassistprovider.h index 52734bd71b..83de52594b 100644 --- a/src/plugins/cpptools/cppvirtualfunctionassistprovider.h +++ b/src/plugins/cpptools/cppvirtualfunctionassistprovider.h @@ -40,6 +40,7 @@ namespace CppTools { class CPPTOOLS_EXPORT VirtualFunctionAssistProvider : public TextEditor::IAssistProvider { + Q_OBJECT public: VirtualFunctionAssistProvider(); diff --git a/src/plugins/debugger/gdb/gdbengine.cpp b/src/plugins/debugger/gdb/gdbengine.cpp index 2551b43177..d16121f22c 100644 --- a/src/plugins/debugger/gdb/gdbengine.cpp +++ b/src/plugins/debugger/gdb/gdbengine.cpp @@ -2603,9 +2603,13 @@ void GdbEngine::changeBreakpoint(Breakpoint bp) cmd.callback = [this, bp](const DebuggerResponse &r) { handleBreakLineNumber(r, bp); }; } else if (data.command != response.command) { cmd.function = "-break-commands " + bpnr; - foreach (const QString &command, data.command.split(QLatin1String("\n"))) { - if (!command.isEmpty()) + for (QString command : data.command.split('\n')) { + if (!command.isEmpty()) { + // escape backslashes and quotes + command.replace('\\', "\\\\"); + command.replace('"', "\\\""); cmd.function += " \"" + command + '"'; + } } cmd.callback = [this, bp](const DebuggerResponse &r) { handleBreakIgnore(r, bp); }; } else if (!data.conditionsMatch(response.condition)) { diff --git a/src/plugins/qmakeprojectmanager/wizards/guiappwizard.cpp b/src/plugins/qmakeprojectmanager/wizards/guiappwizard.cpp index a4df0287b1..907964b6fe 100644 --- a/src/plugins/qmakeprojectmanager/wizards/guiappwizard.cpp +++ b/src/plugins/qmakeprojectmanager/wizards/guiappwizard.cpp @@ -78,8 +78,7 @@ GuiAppWizard::GuiAppWizard() "Includes a Qt Designer-based main window.\n\n" "Preselects a desktop Qt for building the application if available.")); setIcon(QIcon(QLatin1String(":/wizards/images/gui.png"))); - auto qt5 = Core::Id::fromString(QString(QtSupport::Constants::FEATURE_QT_PREFIX).append(".5")); - setRequiredFeatures({QtSupport::Constants::FEATURE_QWIDGETS, qt5}); + setRequiredFeatures({QtSupport::Constants::FEATURE_QWIDGETS}); } Core::BaseFileWizard *GuiAppWizard::create(QWidget *parent, const Core::WizardDialogParameters ¶meters) const diff --git a/src/plugins/qmakeprojectmanager/wizards/guiappwizarddialog.cpp b/src/plugins/qmakeprojectmanager/wizards/guiappwizarddialog.cpp index 0bdf1a3a7d..5f12fdc41a 100644 --- a/src/plugins/qmakeprojectmanager/wizards/guiappwizarddialog.cpp +++ b/src/plugins/qmakeprojectmanager/wizards/guiappwizarddialog.cpp @@ -84,7 +84,6 @@ QtProjectParameters GuiAppWizardDialog::projectParameters() const rc.path = path(); rc.selectedModules = selectedModulesList(); rc.deselectedModules = deselectedModulesList(); - rc.qtVersionSupport = QtProjectParameters::SupportQt5Only; return rc; } diff --git a/src/plugins/texteditor/codeassist/codeassistant.cpp b/src/plugins/texteditor/codeassist/codeassistant.cpp index 06b488d282..e94cb5e8d6 100644 --- a/src/plugins/texteditor/codeassist/codeassistant.cpp +++ b/src/plugins/texteditor/codeassist/codeassistant.cpp @@ -512,7 +512,7 @@ bool CodeAssistantPrivate::isDestroyEvent(int key, const QString &keyText) { if (keyText.isEmpty()) return key != Qt::LeftArrow && key != Qt::RightArrow && key != Qt::Key_Shift; - else if (auto *provider = dynamic_cast<CompletionAssistProvider *>(m_requestProvider)) + if (auto *provider = qobject_cast<CompletionAssistProvider *>(m_requestProvider)) return !provider->isContinuationChar(keyText.at(0)); return false; } diff --git a/src/shared/qbs b/src/shared/qbs -Subproject 2440b19b288096e1601674de2ac15c560af469c +Subproject 66131652f178cd1605b8a2c0ba7023392e13ad5 |