From a6d4d50172a01fc700187d8d06cf9e6359ebb26d Mon Sep 17 00:00:00 2001 From: Thomas Hartmann Date: Tue, 13 Jan 2015 11:04:56 +0100 Subject: [PATCH 01/34] Use always black as the foreground color in HelpViewer Our css styling assumes black as the background color. Task-number: QTCREATORBUG-13660 Change-Id: Ia8d76c39c970b436a0ae038191d8d0f8f8728ded Reviewed-by: Eike Ziller --- src/plugins/help/qtwebkithelpviewer.cpp | 1 + src/plugins/help/textbrowserhelpviewer.cpp | 1 + 2 files changed, 2 insertions(+) diff --git a/src/plugins/help/qtwebkithelpviewer.cpp b/src/plugins/help/qtwebkithelpviewer.cpp index a2c264b42e7..242bd2cc041 100644 --- a/src/plugins/help/qtwebkithelpviewer.cpp +++ b/src/plugins/help/qtwebkithelpviewer.cpp @@ -404,6 +404,7 @@ QtWebKitHelpViewer::QtWebKitHelpViewer(qreal zoom, QWidget *parent) QPalette p = palette(); p.setColor(QPalette::Base, Qt::white); + p.setColor(QPalette::Text, Qt::black); setPalette(p); connect(m_webView, SIGNAL(urlChanged(QUrl)), this, SIGNAL(sourceChanged(QUrl))); diff --git a/src/plugins/help/textbrowserhelpviewer.cpp b/src/plugins/help/textbrowserhelpviewer.cpp index fad3d1bff5e..145be95be86 100644 --- a/src/plugins/help/textbrowserhelpviewer.cpp +++ b/src/plugins/help/textbrowserhelpviewer.cpp @@ -64,6 +64,7 @@ TextBrowserHelpViewer::TextBrowserHelpViewer(qreal zoom, QWidget *parent) p.setColor(QPalette::Inactive, QPalette::HighlightedText, p.color(QPalette::Active, QPalette::HighlightedText)); p.setColor(QPalette::Base, Qt::white); + p.setColor(QPalette::Text, Qt::black); setPalette(p); connect(m_textBrowser, SIGNAL(sourceChanged(QUrl)), this, SIGNAL(titleChanged())); From bd91f82a73d452a10d606d29799f6978325a3096 Mon Sep 17 00:00:00 2001 From: Thomas Hartmann Date: Mon, 19 Jan 2015 16:21:18 +0100 Subject: [PATCH 02/34] Doc: Mention limitation for .ui.qml files in the Open Source version. Change-Id: I8b4e4853072dccb95d3313837e6fa83e7bb76021 Reviewed-by: Leena Miettinen --- doc/src/qtquick/qtquick-ui-forms.qdoc | 3 +++ 1 file changed, 3 insertions(+) diff --git a/doc/src/qtquick/qtquick-ui-forms.qdoc b/doc/src/qtquick/qtquick-ui-forms.qdoc index 2c9a309ba65..1aa46f38275 100644 --- a/doc/src/qtquick/qtquick-ui-forms.qdoc +++ b/doc/src/qtquick/qtquick-ui-forms.qdoc @@ -34,6 +34,9 @@ You can use \QC wizards to create UI forms that have the filename extension \e .ui.qml. The UI forms contain a purely declarative subset of the QML language. It is recommended that you edit the forms in the \uicontrol Design mode. + However, exporting items as alias properties is a commercial only feature, + and therefore you must use the \uicontrol Edit mode to do it if you are + using the open source version of \QC. \QC enforces the use of the supported QML features by displaying error messages. From 3cf2a633e93855fa1af3d63439c672ff08b3ca64 Mon Sep 17 00:00:00 2001 From: David Schulz Date: Mon, 19 Jan 2015 13:47:51 +0100 Subject: [PATCH 03/34] WinRT: Fix occasional crash when debugging WinRT application. Change-Id: Ie7d54e49d67450395bf6161e9b71d00a9bf52e23 Reviewed-by: Oliver Wolff --- src/plugins/winrt/winrtdebugsupport.cpp | 5 +++++ src/plugins/winrt/winrtdebugsupport.h | 1 + src/plugins/winrt/winrtrunnerhelper.cpp | 2 +- 3 files changed, 7 insertions(+), 1 deletion(-) diff --git a/src/plugins/winrt/winrtdebugsupport.cpp b/src/plugins/winrt/winrtdebugsupport.cpp index eb401b9849b..655e11312b2 100644 --- a/src/plugins/winrt/winrtdebugsupport.cpp +++ b/src/plugins/winrt/winrtdebugsupport.cpp @@ -58,6 +58,11 @@ WinRtDebugSupport::WinRtDebugSupport(RunControl *runControl, WinRtRunnerHelper * connect(m_debugRunControl, SIGNAL(finished()), this, SLOT(finish())); } +WinRtDebugSupport::~WinRtDebugSupport() +{ + delete m_runner; +} + void WinRtDebugSupport::finish() { m_runner->stop(); diff --git a/src/plugins/winrt/winrtdebugsupport.h b/src/plugins/winrt/winrtdebugsupport.h index 04475eb1f0c..4b5d8d5cf3e 100644 --- a/src/plugins/winrt/winrtdebugsupport.h +++ b/src/plugins/winrt/winrtdebugsupport.h @@ -49,6 +49,7 @@ public: static ProjectExplorer::RunControl *createDebugRunControl(WinRtRunConfiguration *runConfig, ProjectExplorer::RunMode mode, QString *errorMessage); + ~WinRtDebugSupport(); private: WinRtDebugSupport(ProjectExplorer::RunControl *runControl, WinRtRunnerHelper *runner); diff --git a/src/plugins/winrt/winrtrunnerhelper.cpp b/src/plugins/winrt/winrtrunnerhelper.cpp index eb35cdb6a7e..7a0dc238e2a 100644 --- a/src/plugins/winrt/winrtrunnerhelper.cpp +++ b/src/plugins/winrt/winrtrunnerhelper.cpp @@ -52,7 +52,7 @@ using namespace WinRt; using namespace WinRt::Internal; WinRtRunnerHelper::WinRtRunnerHelper(WinRtRunConfiguration *runConfiguration, QString *errormessage) - : QObject(runConfiguration) + : QObject() , m_messenger(0) , m_runConfiguration(runConfiguration) , m_process(0) From 8211a849e1c754a976574ec66316b26e8f1f1da9 Mon Sep 17 00:00:00 2001 From: Orgad Shaneh Date: Sun, 11 Jan 2015 10:23:04 +0200 Subject: [PATCH 04/34] Utils: Remove outdated warnings exclusions on MSVC Change-Id: I89d440f4ba781f4b2e5f9cbf84cc638a56a743dc Reviewed-by: Friedemann Kleint Reviewed-by: Christian Kandeler --- src/libs/utils/utils-lib.pri | 5 ----- 1 file changed, 5 deletions(-) diff --git a/src/libs/utils/utils-lib.pri b/src/libs/utils/utils-lib.pri index f339efdb8a2..d9593e46693 100644 --- a/src/libs/utils/utils-lib.pri +++ b/src/libs/utils/utils-lib.pri @@ -8,11 +8,6 @@ QT += script network CONFIG += exceptions # used by portlist.cpp, textfileformat.cpp, and ssh/* -win32-msvc* { - # disable warnings caused by botan headers - QMAKE_CXXFLAGS += -wd4250 -wd4290 -} - SOURCES += $$PWD/environment.cpp \ $$PWD/environmentmodel.cpp \ $$PWD/qtcprocess.cpp \ From 64cc15bca4f6e91917dea28387c39706a40805f3 Mon Sep 17 00:00:00 2001 From: Daniel Teske Date: Tue, 20 Jan 2015 12:43:46 +0100 Subject: [PATCH 05/34] Kit: Fix crash on removing android kits that were autodetected To reproduce: In the Android settings, enabled "Automatically create kits" -> This creates kits with autodetected set to true Switch to the kits page to get the KitPage filled, those kits now appear under the autodetected node. Switch to the Android settings and disable "Automatically create kits", -> This doesn't want to delete the old kits, to not throw away user settings, so the kits are marked as manual by calling setAutoDetected Switch to the Kit page and notice the kits still listed under the autodetected node. Clicking apply enables the remove button and on removing Creator crashes. Add the necessary signal emissions to setAutoDetected and several other methods and fix the KitModel to cope with changes to autodetected. Task-number: QTCREATORBUG-13736 Change-Id: I3d0ff247a6bfff8ace53df8535749db5c736d54b Reviewed-by: Tobias Hunger --- src/plugins/projectexplorer/kit.cpp | 6 ++++ .../kitmanagerconfigwidget.cpp | 5 +++- .../projectexplorer/kitmanagerconfigwidget.h | 1 + src/plugins/projectexplorer/kitmodel.cpp | 28 +++++++++++++++++++ src/plugins/projectexplorer/kitmodel.h | 1 + 5 files changed, 40 insertions(+), 1 deletion(-) diff --git a/src/plugins/projectexplorer/kit.cpp b/src/plugins/projectexplorer/kit.cpp index 7fae069f369..b1247fd2eb4 100644 --- a/src/plugins/projectexplorer/kit.cpp +++ b/src/plugins/projectexplorer/kit.cpp @@ -582,16 +582,19 @@ QString Kit::toHtml(const QList &additional) const void Kit::setAutoDetected(bool detected) { d->m_autodetected = detected; + kitUpdated(); } void Kit::setAutoDetectionSource(const QString &autoDetectionSource) { d->m_autoDetectionSource = autoDetectionSource; + kitUpdated(); } void Kit::setSdkProvided(bool sdkProvided) { d->m_sdkProvided = sdkProvided; + kitUpdated(); } void Kit::makeSticky() @@ -608,11 +611,13 @@ void Kit::setSticky(Core::Id id, bool b) d->m_sticky.insert(id); else d->m_sticky.remove(id); + kitUpdated(); } void Kit::makeUnSticky() { d->m_sticky.clear(); + kitUpdated(); } void Kit::setMutable(Id id, bool b) @@ -621,6 +626,7 @@ void Kit::setMutable(Id id, bool b) d->m_mutable.insert(id); else d->m_mutable.remove(id); + kitUpdated(); } bool Kit::isMutable(Id id) const diff --git a/src/plugins/projectexplorer/kitmanagerconfigwidget.cpp b/src/plugins/projectexplorer/kitmanagerconfigwidget.cpp index 408a567aa7d..375b0fb3933 100644 --- a/src/plugins/projectexplorer/kitmanagerconfigwidget.cpp +++ b/src/plugins/projectexplorer/kitmanagerconfigwidget.cpp @@ -354,8 +354,11 @@ void KitManagerConfigWidget::workingCopyWasUpdated(Kit *k) void KitManagerConfigWidget::kitWasUpdated(Kit *k) { - if (m_kit == k) + if (m_kit == k) { + bool emitSignal = m_kit->isAutoDetected() != m_modifiedKit->isAutoDetected(); discard(); + emit isAutoDetectedChanged(); + } updateVisibility(); } diff --git a/src/plugins/projectexplorer/kitmanagerconfigwidget.h b/src/plugins/projectexplorer/kitmanagerconfigwidget.h index 28879d97672..750ed14eab4 100644 --- a/src/plugins/projectexplorer/kitmanagerconfigwidget.h +++ b/src/plugins/projectexplorer/kitmanagerconfigwidget.h @@ -77,6 +77,7 @@ public: signals: void dirty(); + void isAutoDetectedChanged(); private slots: void setIcon(); diff --git a/src/plugins/projectexplorer/kitmodel.cpp b/src/plugins/projectexplorer/kitmodel.cpp index f484be85589..69df6f362e8 100644 --- a/src/plugins/projectexplorer/kitmodel.cpp +++ b/src/plugins/projectexplorer/kitmodel.cpp @@ -279,6 +279,31 @@ void KitModel::setDirty() } } +void KitModel::isAutoDetectedChanged() +{ + KitManagerConfigWidget *w = qobject_cast(sender()); + int idx = -1; + idx = Utils::indexOf(m_manualRoot->childNodes, [w](KitNode *node) { return node->widget == w; }); + KitNode *oldParent = 0; + KitNode *newParent = w->workingCopy()->isAutoDetected() ? m_autoRoot : m_manualRoot; + if (idx != -1) { + oldParent = m_manualRoot; + } else { + idx = Utils::indexOf(m_autoRoot->childNodes, [w](KitNode *node) { return node->widget == w; }); + if (idx != -1) { + oldParent = m_autoRoot; + } + } + + if (oldParent && oldParent != newParent) { + beginMoveRows(index(oldParent), idx, idx, index(newParent), newParent->childNodes.size()); + KitNode *n = oldParent->childNodes.takeAt(idx); + n->parent = newParent; + newParent->childNodes.append(n); + endMoveRows(); + } +} + void KitModel::validateKitNames() { QList nodes = m_manualRoot->childNodes; @@ -395,6 +420,9 @@ KitNode *KitModel::createNode(KitNode *parent, Kit *k) KitNode *node = new KitNode(parent, k); m_parentLayout->addWidget(node->widget); connect(node->widget, SIGNAL(dirty()), this, SLOT(setDirty())); + connect(node->widget, SIGNAL(isAutoDetectedChanged()), + this, SLOT(isAutoDetectedChanged())); + return node; } diff --git a/src/plugins/projectexplorer/kitmodel.h b/src/plugins/projectexplorer/kitmodel.h index 2cde469b3f2..772a5ed3835 100644 --- a/src/plugins/projectexplorer/kitmodel.h +++ b/src/plugins/projectexplorer/kitmodel.h @@ -97,6 +97,7 @@ private slots: void changeDefaultKit(); void setDirty(); void validateKitNames(); + void isAutoDetectedChanged(); private: QModelIndex index(KitNode *, int column = 0) const; From 9dee300b6731248cff37ef384d1905338875fa67 Mon Sep 17 00:00:00 2001 From: Christian Kandeler Date: Tue, 20 Jan 2015 18:12:13 +0100 Subject: [PATCH 06/34] Debugger: Fix scoping bug in watch handler. Found by clang static analyzer. Change-Id: Ib25232b26c314d4da4707f7903f1b75b907b241d Reviewed-by: hjk --- src/plugins/debugger/watchhandler.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/plugins/debugger/watchhandler.cpp b/src/plugins/debugger/watchhandler.cpp index a45a9dee197..d89f2ef9bc1 100644 --- a/src/plugins/debugger/watchhandler.cpp +++ b/src/plugins/debugger/watchhandler.cpp @@ -2042,7 +2042,7 @@ int WatchHandler::format(const QByteArray &iname) const { int result = AutomaticFormat; if (const WatchData *item = m_model->findItem(iname)) { - int result = theIndividualFormats.value(item->iname, AutomaticFormat); + result = theIndividualFormats.value(item->iname, AutomaticFormat); if (result == AutomaticFormat) result = theTypeFormats.value(stripForFormat(item->type), AutomaticFormat); } From f78479014f65f00bbd7a614c1066d90c395ff77f Mon Sep 17 00:00:00 2001 From: Robert Loehning Date: Tue, 20 Jan 2015 12:10:08 +0100 Subject: [PATCH 07/34] Squish: Disable pastebin.ca for now. "Server is at capacity" Change-Id: I440dca1e2d6bfab13b2fe59662691df4fa724ba7 Reviewed-by: Christian Stenger --- tests/system/suite_tools/tst_codepasting/test.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/system/suite_tools/tst_codepasting/test.py b/tests/system/suite_tools/tst_codepasting/test.py index c8d7d2c4be0..00ba1335981 100644 --- a/tests/system/suite_tools/tst_codepasting/test.py +++ b/tests/system/suite_tools/tst_codepasting/test.py @@ -41,7 +41,7 @@ def main(): startApplication("qtcreator" + SettingsPath) if not startedWithoutPluginError(): return - protocolsToTest = ["Paste.KDE.Org", "Pastebin.Ca"] + protocolsToTest = ["Paste.KDE.Org"] # , "Pastebin.Ca"] # Be careful with Pastebin.Com, there are only 10 pastes per 24h # for all machines using the same IP-address like you. # protocolsToTest += ["Pastebin.Com"] From 83c69fe6e80fd4d9e317ab2f7406e2697db4ed64 Mon Sep 17 00:00:00 2001 From: Thomas Hartmann Date: Thu, 22 Jan 2015 10:08:38 +0100 Subject: [PATCH 08/34] QmlDesigner.PropertyEditor: Increase maximum SpinBox size This fixes glitches for numbers > 9999. Change-Id: Ib49ff4c3a8da3caaf19b713fa309563349e48501 Reviewed-by: Tim Jenssen --- .../HelperWidgets/CustomSpinBoxStyle.qml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/share/qtcreator/qmldesigner/propertyEditorQmlSources/HelperWidgets/CustomSpinBoxStyle.qml b/share/qtcreator/qmldesigner/propertyEditorQmlSources/HelperWidgets/CustomSpinBoxStyle.qml index ecfccea4ff3..02503f3fe46 100644 --- a/share/qtcreator/qmldesigner/propertyEditorQmlSources/HelperWidgets/CustomSpinBoxStyle.qml +++ b/share/qtcreator/qmldesigner/propertyEditorQmlSources/HelperWidgets/CustomSpinBoxStyle.qml @@ -67,7 +67,7 @@ SpinBoxStyle { } background: Rectangle { - implicitWidth: Math.max(60, styleData.contentWidth) + implicitWidth: Math.max(64, styleData.contentWidth) implicitHeight: 23 border.color: borderColor radius: 3 From e421b348bb7b9d9e3bc46d6e927257327b9fd9bb Mon Sep 17 00:00:00 2001 From: Thomas Hartmann Date: Thu, 22 Jan 2015 10:09:10 +0100 Subject: [PATCH 09/34] QmlDesigner.PropertyEditor: Fix minimum value of PathView dragMargin Change-Id: I597ebdef0797a3184b9480215b85b59797aa59d8 Reviewed-by: Tim Jenssen --- .../propertyEditorQmlSources/QtQuick/PathViewSpecifics.qml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/share/qtcreator/qmldesigner/propertyEditorQmlSources/QtQuick/PathViewSpecifics.qml b/share/qtcreator/qmldesigner/propertyEditorQmlSources/QtQuick/PathViewSpecifics.qml index db91eba92e6..1a26b97ebad 100644 --- a/share/qtcreator/qmldesigner/propertyEditorQmlSources/QtQuick/PathViewSpecifics.qml +++ b/share/qtcreator/qmldesigner/propertyEditorQmlSources/QtQuick/PathViewSpecifics.qml @@ -51,7 +51,7 @@ Column { SecondColumnLayout { SpinBox { backendValue: backendValues.dragMargin - minimumValue: 100; + minimumValue: 0; maximumValue: 100; decimals: 0 } From 39107ca29832c009f39c4c811d7288f64a0cad7d Mon Sep 17 00:00:00 2001 From: Thomas Hartmann Date: Thu, 22 Jan 2015 10:12:23 +0100 Subject: [PATCH 10/34] QmlDesigner.PropertyEditor: Remove Slider from SpinBox The integrated slider in a SpinBox did not work well. Sliders do crash on Yosemite if maximumValue and minimumValue are the same. Change-Id: If1a5fe5109591bc8198c5659f10e73ebaeb8c636 Task-number: QTCREATORBUG-13842 Reviewed-by: Tim Jenssen --- .../HelperWidgets/SliderSpinBox.qml | 73 ------------------- .../HelperWidgets/SpinBox.qml | 19 ----- 2 files changed, 92 deletions(-) diff --git a/share/qtcreator/qmldesigner/propertyEditorQmlSources/HelperWidgets/SliderSpinBox.qml b/share/qtcreator/qmldesigner/propertyEditorQmlSources/HelperWidgets/SliderSpinBox.qml index c0d6b92efe4..7e25e7c81bf 100644 --- a/share/qtcreator/qmldesigner/propertyEditorQmlSources/HelperWidgets/SliderSpinBox.qml +++ b/share/qtcreator/qmldesigner/propertyEditorQmlSources/HelperWidgets/SliderSpinBox.qml @@ -39,79 +39,6 @@ SpinBox { property color highlightColor: "orange" property color textColor: "#eee" - function showSlider() { - timer.stop() - timer2.start() - slider.opacity = 1; - } - - onHoveredChanged: { - if (hovered) - showSlider(); - } - - Slider { - id: slider - - anchors.left: parent.left - anchors.right: parent.right - anchors.top: parent.bottom - height: 10; - //opacity: 0 - - maximumValue: spinBox.maximumValue - minimumValue: spinBox.minimumValue - - value: spinBox.value - visible: false - - onValueChanged: { - spinBox.value = value - } - - Behavior on opacity { - PropertyAnimation { - duration: 100 - } - } - - onHoveredChanged: { - if (!hovered) { - timer.startTimer(); - } else { - timer2.stop() - timer.stop() - } - } - } - - Timer { - id: timer - repeat: false - function startTimer() { - if (!timer.running) - timer.start() - } - interval: 600 - - onTriggered: { - return - if (!slider.hovered) - slider.opacity = 0; - } - } - - Timer { - id: timer2 - repeat: false - interval: 1000 - onTriggered: { - return - if (!slider.hovered) - slider.opacity = 0; - } - } - style: CustomSpinBoxStyle { } diff --git a/share/qtcreator/qmldesigner/propertyEditorQmlSources/HelperWidgets/SpinBox.qml b/share/qtcreator/qmldesigner/propertyEditorQmlSources/HelperWidgets/SpinBox.qml index 01c5adc5f63..b9963ecae88 100644 --- a/share/qtcreator/qmldesigner/propertyEditorQmlSources/HelperWidgets/SpinBox.qml +++ b/share/qtcreator/qmldesigner/propertyEditorQmlSources/HelperWidgets/SpinBox.qml @@ -63,25 +63,6 @@ Controls.SpinBox { backendValue.value = value; } - Controls.Slider { - id: slider - - anchors.left: parent.left - anchors.right: parent.right - anchors.top: parent.bottom - height: 10 - visible: false - - maximumValue: spinBox.maximumValue - minimumValue: spinBox.minimumValue - - value: spinBox.value - - onValueChanged: { - spinBox.value = value - } - } - style: CustomSpinBoxStyle { } } From e1da2d8d9850f278cbe799fa97b3fc62482e64f6 Mon Sep 17 00:00:00 2001 From: Daniel Teske Date: Wed, 21 Jan 2015 12:15:27 +0100 Subject: [PATCH 11/34] KitConfigWidget: Only emit autodetectionChanged if itactually changed Ups. I verified that the crash is still fixed. Change-Id: Ibb3a72bab79eb433ff426c90a60b33cc6a6d873b Reviewed-by: Tobias Hunger --- src/plugins/projectexplorer/kitmanagerconfigwidget.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/plugins/projectexplorer/kitmanagerconfigwidget.cpp b/src/plugins/projectexplorer/kitmanagerconfigwidget.cpp index 375b0fb3933..06f33d3f5b4 100644 --- a/src/plugins/projectexplorer/kitmanagerconfigwidget.cpp +++ b/src/plugins/projectexplorer/kitmanagerconfigwidget.cpp @@ -357,7 +357,8 @@ void KitManagerConfigWidget::kitWasUpdated(Kit *k) if (m_kit == k) { bool emitSignal = m_kit->isAutoDetected() != m_modifiedKit->isAutoDetected(); discard(); - emit isAutoDetectedChanged(); + if (emitSignal) + emit isAutoDetectedChanged(); } updateVisibility(); } From 73a9bea51df2c797f877cc1752578042bd40ff45 Mon Sep 17 00:00:00 2001 From: Fawzi Mohamed Date: Thu, 4 Dec 2014 13:20:18 +0100 Subject: [PATCH 12/34] qmljs: do not rely on future.isCanceled to be sticky Change-Id: I92f32b9cbea1ddb1660895264f853068c31af4cd Reviewed-by: Tim Jenssen Reviewed-by: Eike Ziller --- src/libs/qmljs/qmljsmodelmanagerinterface.cpp | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/libs/qmljs/qmljsmodelmanagerinterface.cpp b/src/libs/qmljs/qmljsmodelmanagerinterface.cpp index 34224193ddd..6dfad591d7b 100644 --- a/src/libs/qmljs/qmljsmodelmanagerinterface.cpp +++ b/src/libs/qmljs/qmljsmodelmanagerinterface.cpp @@ -1007,7 +1007,8 @@ void ModelManagerInterface::importScan(QFutureInterface &future, future.setProgressRange(0, progressRange); // update max length while iterating? const bool libOnly = true; // FIXME remove when tested more const Snapshot snapshot = modelManager->snapshot(); - while (!pathsToScan.isEmpty() && !future.isCanceled()) { + bool isCanceled = future.isCanceled(); + while (!pathsToScan.isEmpty() && !isCanceled) { ScanItem toScan = pathsToScan.last(); pathsToScan.pop_back(); int pathBudget = (1 << (maxScanDepth + 2 - toScan.depth)); @@ -1044,9 +1045,10 @@ void ModelManagerInterface::importScan(QFutureInterface &future, workDone += pathBudget * 3 / 4; } future.setProgressValue(progressRange * workDone / totalWork); + isCanceled = future.isCanceled(); } future.setProgressValue(progressRange); - if (future.isCanceled()) { + if (isCanceled) { // assume no work has been done QMutexLocker l(&modelManager->m_mutex); for (int i = 0; i < paths.size(); ++i) From 7af11ebaf9aeeeee5075a429c349dcc7e3f9153f Mon Sep 17 00:00:00 2001 From: Thomas Hartmann Date: Fri, 23 Jan 2015 10:23:28 +0100 Subject: [PATCH 13/34] Fix for import management If we add a new import we have to scan for new item library entries in the directory belonging to the import. Without this patch e.g. the commercial controls were not added to the item library. The user had to switch to edit mode and back to trigger and update. Change-Id: Ie145aea53fbd57ffac976725b6c1fd5553ddf22e Reviewed-by: BogDan Vatra --- .../qmldesigner/components/importmanager/importmanagerview.cpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/plugins/qmldesigner/components/importmanager/importmanagerview.cpp b/src/plugins/qmldesigner/components/importmanager/importmanagerview.cpp index 3c92e73e061..841f18a5364 100644 --- a/src/plugins/qmldesigner/components/importmanager/importmanagerview.cpp +++ b/src/plugins/qmldesigner/components/importmanager/importmanagerview.cpp @@ -32,6 +32,7 @@ #include "importswidget.h" #include +#include namespace QmlDesigner { @@ -264,6 +265,8 @@ void ImportManagerView::addImport(const Import &import) catch (RewritingException &e) { e.showException(); } + + QmlDesignerPlugin::instance()->currentDesignDocument()->updateSubcomponentManager(); } } // namespace QmlDesigner From 309d38c8f0434c551fe6a4161dab5614ce0419ea Mon Sep 17 00:00:00 2001 From: BogDan Vatra Date: Fri, 23 Jan 2015 11:06:54 +0200 Subject: [PATCH 14/34] Sort the possible import list. Change-Id: Iaa77273ebaf0867119f06c6ee3c2d29a61168933 Reviewed-by: Thomas Hartmann --- .../importmanager/importswidget.cpp | 55 ++++++++++--------- .../components/importmanager/importswidget.h | 2 +- 2 files changed, 29 insertions(+), 28 deletions(-) diff --git a/src/plugins/qmldesigner/components/importmanager/importswidget.cpp b/src/plugins/qmldesigner/components/importmanager/importswidget.cpp index 4102b965239..df5d94b78a5 100644 --- a/src/plugins/qmldesigner/components/importmanager/importswidget.cpp +++ b/src/plugins/qmldesigner/components/importmanager/importswidget.cpp @@ -64,33 +64,6 @@ static bool isImportAlreadyUsed(const Import &import, QList import return false; } -void ImportsWidget::setPossibleImports(const QList &possibleImports) -{ - m_addImportComboBox->clear(); - foreach (const Import &possibleImport, possibleImports) { - if (!isImportAlreadyUsed(possibleImport, m_importLabels)) - m_addImportComboBox->addItem(possibleImport.toString(true), QVariant::fromValue(possibleImport)); - } -} - -void ImportsWidget::removePossibleImports() -{ - m_addImportComboBox->clear(); -} - -void ImportsWidget::setUsedImports(const QList &usedImports) -{ - foreach (ImportLabel *importLabel, m_importLabels) - importLabel->setReadOnly(usedImports.contains(importLabel->import())); - -} - -void ImportsWidget::removeUsedImports() -{ - foreach (ImportLabel *importLabel, m_importLabels) - importLabel->setEnabled(true); -} - static bool importLess(const Import &firstImport, const Import &secondImport) { if (firstImport.url() == secondImport.url()) @@ -117,6 +90,34 @@ static bool importLess(const Import &firstImport, const Import &secondImport) return false; } +void ImportsWidget::setPossibleImports(QList possibleImports) +{ + Utils::sort(possibleImports, importLess); + m_addImportComboBox->clear(); + foreach (const Import &possibleImport, possibleImports) { + if (!isImportAlreadyUsed(possibleImport, m_importLabels)) + m_addImportComboBox->addItem(possibleImport.toString(true), QVariant::fromValue(possibleImport)); + } +} + +void ImportsWidget::removePossibleImports() +{ + m_addImportComboBox->clear(); +} + +void ImportsWidget::setUsedImports(const QList &usedImports) +{ + foreach (ImportLabel *importLabel, m_importLabels) + importLabel->setReadOnly(usedImports.contains(importLabel->import())); + +} + +void ImportsWidget::removeUsedImports() +{ + foreach (ImportLabel *importLabel, m_importLabels) + importLabel->setEnabled(true); +} + void ImportsWidget::setImports(const QList &imports) { qDeleteAll(m_importLabels); diff --git a/src/plugins/qmldesigner/components/importmanager/importswidget.h b/src/plugins/qmldesigner/components/importmanager/importswidget.h index 5716f239158..c0a1920bc54 100644 --- a/src/plugins/qmldesigner/components/importmanager/importswidget.h +++ b/src/plugins/qmldesigner/components/importmanager/importswidget.h @@ -52,7 +52,7 @@ public: void setImports(const QList &imports); void removeImports(); - void setPossibleImports(const QList &possibleImports); + void setPossibleImports(QList possibleImports); void removePossibleImports(); void setUsedImports(const QList &possibleImports); From 56dab9e9313a85d5b148bdf80e2871d6a55aabee Mon Sep 17 00:00:00 2001 From: Nikolai Kosjar Date: Tue, 20 Jan 2015 12:33:51 +0100 Subject: [PATCH 15/34] C++: Check for cycled parents In the struct _Wrap_alloc (see test code) the rebind struct has _Wrap_alloc as parent. However, within rebind the typedef of type _Wrap_alloc has rebind as parent. We will refactor that in master by introducing a "parent iterator" class checking for cycles, so the client code looks less noisy. Task-number: QTCREATORBUG-13703 Change-Id: I7b6cf819ea869139d2403e15ba085d8fba19763e Reviewed-by: Cristian Adam Reviewed-by: Przemyslaw Gorszkowski Reviewed-by: Eike Ziller Reviewed-by: Erik Verbruggen --- src/libs/cplusplus/LookupContext.cpp | 11 +- .../checksymbols/tst_checksymbols.cpp | 103 +++++++++++++----- 2 files changed, 86 insertions(+), 28 deletions(-) diff --git a/src/libs/cplusplus/LookupContext.cpp b/src/libs/cplusplus/LookupContext.cpp index fdbbf744449..7dd5bcf43ce 100644 --- a/src/libs/cplusplus/LookupContext.cpp +++ b/src/libs/cplusplus/LookupContext.cpp @@ -631,10 +631,15 @@ QList ClassOrNamespace::lookup_helper(const Name *name, bool searchI // a qualified name. For instance, a nested class which is forward declared // in the class but defined outside it - we should capture both. Symbol *match = 0; + QSet processed; for (ClassOrNamespace *parentBinding = binding->parent(); parentBinding && !match; - parentBinding = parentBinding->parent()) + parentBinding = parentBinding->parent()) { + if (processed.contains(parentBinding)) + break; + processed.insert(parentBinding); match = parentBinding->lookupInScope(fullName); + } if (match) { LookupItem item; @@ -648,8 +653,12 @@ QList ClassOrNamespace::lookup_helper(const Name *name, bool searchI } QSet processed; + QSet processedOwnParents; ClassOrNamespace *binding = this; do { + if (processedOwnParents.contains(binding)) + break; + processedOwnParents.insert(binding); lookup_helper(name, binding, &result, &processed, /*templateId = */ 0); binding = binding->_parent; } while (searchInEnclosingScope && binding); diff --git a/tests/auto/cplusplus/checksymbols/tst_checksymbols.cpp b/tests/auto/cplusplus/checksymbols/tst_checksymbols.cpp index 3b1e2024d88..7125d459b92 100644 --- a/tests/auto/cplusplus/checksymbols/tst_checksymbols.cpp +++ b/tests/auto/cplusplus/checksymbols/tst_checksymbols.cpp @@ -193,6 +193,7 @@ private slots: void test_checksymbols_macroUses(); void test_checksymbols_macroUses_data(); + void test_checksymbols_infiniteLoop_data(); void test_checksymbols_infiniteLoop(); }; @@ -1756,36 +1757,12 @@ void tst_CheckSymbols::test_checksymbols_macroUses_data() void tst_CheckSymbols::test_checksymbols_infiniteLoop() { - const QByteArray source1 = - "#include \"file2.h\"\n" - "\n" - "template\n" - "class basic_ios {\n" - " typedef basic_ostream<_Elem, _Traits> _Myos;\n" - "};\n" - "\n" - "template\n" - "class basic_ostream {\n" - " typedef basic_ostream<_Elem, _Traits> _Myt;\n" - " typedef ostreambuf_iterator<_Elem, _Traits> _Iter;\n" - "};\n" - ; + QFETCH(QByteArray, source1); + QFETCH(QByteArray, source2); + const QString filePath1 = QDir::tempPath() + QLatin1String("/file1.h"); CppTools::Tests::TestCase::writeFile(filePath1, source1); - const QByteArray source2 = - "template\n" - "class basic_streambuf {\n" - " typedef basic_streambuf<_Elem, _Traits> _Myt;\n" - "};\n" - "\n" - "template\n" - "class ostreambuf_iterator {\n" - " typedef _Traits traits_type;\n" - " typedef basic_streambuf<_Elem, _Traits> streambuf_type;\n" - " typedef basic_ostream<_Elem, _Traits> ostream_type;\n" - "};\n" - ; const QString filePath2 = QDir::tempPath() + QLatin1String("/file2.h"); CppTools::Tests::TestCase::writeFile(filePath2, source2); @@ -1798,5 +1775,77 @@ void tst_CheckSymbols::test_checksymbols_infiniteLoop() TestCase::runCheckSymbols(document1, snapshot); } +void tst_CheckSymbols::test_checksymbols_infiniteLoop_data() +{ + QTest::addColumn("source1"); + QTest::addColumn("source2"); + + QTest::newRow("1") + << + _("#include \"file2.h\"\n" + "\n" + "template\n" + "class basic_ios {\n" + " typedef basic_ostream<_Elem, _Traits> _Myos;\n" + "};\n" + "\n" + "template\n" + "class basic_ostream {\n" + " typedef basic_ostream<_Elem, _Traits> _Myt;\n" + " typedef ostreambuf_iterator<_Elem, _Traits> _Iter;\n" + "};\n") + << + _("template\n" + "class basic_streambuf {\n" + " typedef basic_streambuf<_Elem, _Traits> _Myt;\n" + "};\n" + "\n" + "template\n" + "class ostreambuf_iterator {\n" + " typedef _Traits traits_type;\n" + " typedef basic_streambuf<_Elem, _Traits> streambuf_type;\n" + " typedef basic_ostream<_Elem, _Traits> ostream_type;\n" + "};\n") + ; + + QTest::newRow("2") + << + _("#include \"file2.h\"\n" + "\n" + "template\n" + "struct _List_base_types\n" + "{\n" + " typedef typename _Wrap_alloc<_Alloc>::template rebind<_Ty>::other _Alty;\n" + " typedef typename _Alty::template rebind<_Node>::other _Alnod_type;\n" + "};\n" + "\n" + "template\n" + "struct _List_alloc \n" + "{\n" + " const _Alloc_types::_Alnod_type& _Getal() const {}\n" + "};\n" + "\n" + "template\n" + "struct _List_buy : public _List_alloc< _List_base_types<_Ty> >\n" + "{\n" + " void foo()\n" + " {\n" + " this->_Getal().construct(1, 2);\n" + " this->_Getal().deallocate(0, 1);\n" + " }\n" + "};\n") + << + _("template\n" + "struct _Wrap_alloc : public _Alloc\n" + "{\n" + " typedef _Alloc _Mybase;\n" + " template struct rebind { typedef _Wrap_alloc<_Other_alloc> other; };\n" + "\n" + " void deallocate(pointer _Ptr, size_type _Count) {}\n" + " void construct(value_type *_Ptr) {}\n" + "};\n") + ; +} + QTEST_APPLESS_MAIN(tst_CheckSymbols) #include "tst_checksymbols.moc" From f23a5fc41d6d961db1174ffb27c051a4c4792133 Mon Sep 17 00:00:00 2001 From: BogDan Vatra Date: Thu, 22 Jan 2015 17:36:53 +0200 Subject: [PATCH 16/34] Set QML[2]_IMPORT_PATH evn variable when running qml[2]puppet qml[2]puppet can't use any QML plugin that are defined in your .pro file (using QML_IMPORT_PATH) unless we don't specify it. Change-Id: I0fffb8a5da1023565fa9fce5cd4cf38f098a0df1 Reviewed-by: Tim Jenssen --- .../instances/nodeinstanceserverproxy.cpp | 15 +++++------- .../designercore/instances/puppetcreator.cpp | 24 +++++++++++++------ .../designercore/instances/puppetcreator.h | 10 ++++---- 3 files changed, 29 insertions(+), 20 deletions(-) diff --git a/src/plugins/qmldesigner/designercore/instances/nodeinstanceserverproxy.cpp b/src/plugins/qmldesigner/designercore/instances/nodeinstanceserverproxy.cpp index 442bcc4c776..3f3eb9ae0a7 100644 --- a/src/plugins/qmldesigner/designercore/instances/nodeinstanceserverproxy.cpp +++ b/src/plugins/qmldesigner/designercore/instances/nodeinstanceserverproxy.cpp @@ -123,32 +123,29 @@ NodeInstanceServerProxy::NodeInstanceServerProxy(NodeInstanceView *nodeInstanceV m_runModus(runModus), m_synchronizeId(-1) { - PuppetCreator puppetCreator(kit, QString()); - QString socketToken(QUuid::createUuid().toString()); m_localServer->listen(socketToken); m_localServer->setMaxPendingConnections(3); PuppetCreator::QmlPuppetVersion puppetVersion = hasQtQuick1(nodeInstanceView) ? PuppetCreator::Qml1Puppet : PuppetCreator::Qml2Puppet; + PuppetCreator puppetCreator(kit, QString(), nodeInstanceView->model(), puppetVersion); - puppetCreator.createPuppetExecutableIfMissing(puppetVersion); - m_qmlPuppetEditorProcess = puppetCreator.createPuppetProcess(puppetVersion, - "editormode", + puppetCreator.createPuppetExecutableIfMissing(); + + m_qmlPuppetEditorProcess = puppetCreator.createPuppetProcess("editormode", socketToken, this, SLOT(printEditorProcessOutput()), SLOT(processFinished(int,QProcess::ExitStatus))); if (runModus == NormalModus) { - m_qmlPuppetRenderProcess = puppetCreator.createPuppetProcess(puppetVersion, - "rendermode", + m_qmlPuppetRenderProcess = puppetCreator.createPuppetProcess("rendermode", socketToken, this, SLOT(printRenderProcessOutput()), SLOT(processFinished(int,QProcess::ExitStatus))); - m_qmlPuppetPreviewProcess = puppetCreator.createPuppetProcess(puppetVersion, - "previewmode", + m_qmlPuppetPreviewProcess = puppetCreator.createPuppetProcess("previewmode", socketToken, this, SLOT(printPreviewProcessOutput()), diff --git a/src/plugins/qmldesigner/designercore/instances/puppetcreator.cpp b/src/plugins/qmldesigner/designercore/instances/puppetcreator.cpp index 258a4d62d18..075b3f8b3c5 100644 --- a/src/plugins/qmldesigner/designercore/instances/puppetcreator.cpp +++ b/src/plugins/qmldesigner/designercore/instances/puppetcreator.cpp @@ -114,10 +114,12 @@ bool PuppetCreator::useOnlyFallbackPuppet() const || !qgetenv("USE_ONLY_FALLBACK_PUPPET").isEmpty() || m_kit == 0 || !m_kit->isValid(); } -PuppetCreator::PuppetCreator(ProjectExplorer::Kit *kit, const QString &qtCreatorVersion) +PuppetCreator::PuppetCreator(ProjectExplorer::Kit *kit, const QString &qtCreatorVersion, const Model *model, QmlPuppetVersion puppetVersion) : m_qtCreatorVersion(qtCreatorVersion), m_kit(kit), - m_availablePuppetType(FallbackPuppet) + m_availablePuppetType(FallbackPuppet), + m_model(model), + m_puppetVersion(puppetVersion) { } @@ -125,18 +127,18 @@ PuppetCreator::~PuppetCreator() { } -void PuppetCreator::createPuppetExecutableIfMissing(PuppetCreator::QmlPuppetVersion puppetVersion) +void PuppetCreator::createPuppetExecutableIfMissing() { - if (puppetVersion == Qml1Puppet) + if (m_puppetVersion == Qml1Puppet) createQml1PuppetExecutableIfMissing(); else createQml2PuppetExecutableIfMissing(); } -QProcess *PuppetCreator::createPuppetProcess(PuppetCreator::QmlPuppetVersion puppetVersion, const QString &puppetMode, const QString &socketToken, QObject *handlerObject, const char *outputSlot, const char *finishSlot) const +QProcess *PuppetCreator::createPuppetProcess(const QString &puppetMode, const QString &socketToken, QObject *handlerObject, const char *outputSlot, const char *finishSlot) const { QString puppetPath; - if (puppetVersion == Qml1Puppet) + if (m_puppetVersion == Qml1Puppet) puppetPath = qmlPuppetPath(m_availablePuppetType); else puppetPath = qml2PuppetPath(m_availablePuppetType); @@ -332,13 +334,21 @@ QString PuppetCreator::qmlPuppetPath(PuppetType puppetType) const QProcessEnvironment PuppetCreator::processEnvironment() const { +#if defined(Q_OS_WIN) + static QLatin1String pathSep(";"); +#else + static QLatin1String pathSep(":"); +#endif Utils::Environment environment = Utils::Environment::systemEnvironment(); if (!useOnlyFallbackPuppet()) m_kit->addToEnvironment(environment); environment.set("QML_BAD_GUI_RENDER_LOOP", "true"); environment.set("QML_USE_MOCKUPS", "true"); environment.set("QML_PUPPET_MODE", "true"); - + if (m_puppetVersion == Qml1Puppet) + environment.appendOrSet("QML_IMPORT_PATH", m_model->importPaths().join(pathSep), pathSep); + else + environment.appendOrSet("QML2_IMPORT_PATH", m_model->importPaths().join(pathSep), pathSep); return environment.toProcessEnvironment(); } diff --git a/src/plugins/qmldesigner/designercore/instances/puppetcreator.h b/src/plugins/qmldesigner/designercore/instances/puppetcreator.h index b8ef4e68ba0..ab27deb6d90 100644 --- a/src/plugins/qmldesigner/designercore/instances/puppetcreator.h +++ b/src/plugins/qmldesigner/designercore/instances/puppetcreator.h @@ -41,6 +41,7 @@ class Kit; namespace QmlDesigner { +class Model; class PuppetBuildProgressDialog; class PuppetCreator @@ -56,13 +57,12 @@ public: Qml2Puppet }; - PuppetCreator(ProjectExplorer::Kit *kit, const QString &qtCreatorVersion); + PuppetCreator(ProjectExplorer::Kit *kit, const QString &qtCreatorVersion, const Model *model, QmlPuppetVersion puppetVersion); ~PuppetCreator(); - void createPuppetExecutableIfMissing(QmlPuppetVersion puppetVersion); + void createPuppetExecutableIfMissing(); - QProcess *createPuppetProcess(QmlPuppetVersion puppetVersion, - const QString &puppetMode, + QProcess *createPuppetProcess(const QString &puppetMode, const QString &socketToken, QObject *handlerObject, const char *outputSlot, @@ -120,6 +120,8 @@ private: PuppetType m_availablePuppetType; static QHash m_qml1PuppetForKitPuppetHash; static QHash m_qml2PuppetForKitPuppetHash; + const Model *m_model; + QmlPuppetVersion m_puppetVersion; }; } // namespace QmlDesigner From 52f45f307b258343a8b6cdbd35cd24ec221c1865 Mon Sep 17 00:00:00 2001 From: Christian Kandeler Date: Fri, 23 Jan 2015 16:39:14 +0100 Subject: [PATCH 17/34] Update qbs submodule. To HEAD of 1.3 branch. Change-Id: Id9c9635edeec3a3bff145087f5e296f1141fc202 Reviewed-by: Christian Kandeler --- src/shared/qbs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/shared/qbs b/src/shared/qbs index 86e872bd991..ff18f6944be 160000 --- a/src/shared/qbs +++ b/src/shared/qbs @@ -1 +1 @@ -Subproject commit 86e872bd99184fe862bfe30ef43acd9806e34bc5 +Subproject commit ff18f6944becdfb77f3294af80d5b7e9f8688fef From 0d86ea4a1c40ab19c5154ab84b4baff63dea9e0e Mon Sep 17 00:00:00 2001 From: Christian Kandeler Date: Wed, 28 Jan 2015 13:43:14 +0100 Subject: [PATCH 18/34] Update qbs submodule. To HEAD of 1.3 branch. Change-Id: I1ec44fb51dc18bb9e72e10c1c5811ef52ffdc363 Reviewed-by: Joerg Bornemann --- src/shared/qbs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/shared/qbs b/src/shared/qbs index ff18f6944be..d4010ce8423 160000 --- a/src/shared/qbs +++ b/src/shared/qbs @@ -1 +1 @@ -Subproject commit ff18f6944becdfb77f3294af80d5b7e9f8688fef +Subproject commit d4010ce842360d0fa5ba67f8dcb3267aae49092c From 4780f0edbfd6b26977c4ae65b449a4be9842cc40 Mon Sep 17 00:00:00 2001 From: Christian Stenger Date: Thu, 29 Jan 2015 12:52:22 +0100 Subject: [PATCH 19/34] Tests: Fix offsets test for Qt5.4 Change-Id: I1517bfbde852af5db7088fa21b33a27e20f2db61 Reviewed-by: hjk --- tests/auto/debugger/tst_offsets.cpp | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/tests/auto/debugger/tst_offsets.cpp b/tests/auto/debugger/tst_offsets.cpp index a6e1d9255fe..a8eb0d15470 100644 --- a/tests/auto/debugger/tst_offsets.cpp +++ b/tests/auto/debugger/tst_offsets.cpp @@ -83,7 +83,17 @@ void tst_offsets::offsets_data() QFilePrivate *p = 0; QTestData &data = QTest::newRow("QFilePrivate::fileName") << int((char *)&p->fileName - (char *)p); - if (qtVersion > 0x50200) + if (qtVersion >= 0x50400) +#ifdef Q_OS_WIN +# ifdef Q_CC_MSVC + data << 196 << 272; +# else // MinGW + data << 188 << 272; +# endif +#else + data << 180 << 272; +#endif + else if (qtVersion > 0x50200) #ifdef Q_OS_WIN # ifdef Q_CC_MSVC data << 184 << 272; From 110392ad183466c746550720fc72eef45d248010 Mon Sep 17 00:00:00 2001 From: Leena Miettinen Date: Thu, 29 Jan 2015 10:29:46 +0100 Subject: [PATCH 20/34] Doc: fix bug in doc building instructions And add a note about the new online style. Change-Id: I4d16ea45dd121a27c5c8d8c0fe5e5b971f8c2d05 Reviewed-by: Eike Ziller --- doc/api/qtcreator-documentation.qdoc | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/doc/api/qtcreator-documentation.qdoc b/doc/api/qtcreator-documentation.qdoc index 2ec78a2c4df..32cb491f589 100644 --- a/doc/api/qtcreator-documentation.qdoc +++ b/doc/api/qtcreator-documentation.qdoc @@ -258,7 +258,7 @@ changed over time, so they differ between Qt and \QC versions. Since \QC version 3.3, only Qt 5 is supported for building documentation. The templates to use are defined by the - \c qt5\qtbase\doc\global\qt-html-templates-offline.qdocconf} and + \c {qt5\qtbase\doc\global\qt-html-templates-offline.qdocconf} and \c {qt5\qtbase\doc\global\qt-html-templates-online.qdocconf} configuration file. They are fetched from Qt sources by adding the following lines to the qdocconf file: @@ -266,11 +266,14 @@ \list \li \c {include ($QT_INSTALL_DOCS/global/qt-html-templates-offline.qdocconf)} - for publishing on the web - \li \c {include ($QT_INSTALL_DOCS/global/qt-html-templates-online.qdocconf)} for help files + \li \c {include ($QT_INSTALL_DOCS/global/qt-html-templates-online.qdocconf)} + for publishing on the web \endlist + \note To have the correct fonts loaded for the online version, you must be + running it on a web server. + \note If the styles look wrong to you when reading help files in \QC or \QA, you might be looking at them in the QTextBrowser instead of the WebKit browser. This happens if you build \QC and \QA with a self-built Qt and did From 40ba5f947bd489002430d7ae2bef62cd403cdeac Mon Sep 17 00:00:00 2001 From: Kai Koehne Date: Fri, 30 Jan 2015 16:44:32 +0100 Subject: [PATCH 21/34] Disable broken debugger tooltips for QML Looks like the proper handling of tooltips while debugging a QML app is broken since commit 7f09d0b756ff3f9 . Just disable the functionality for now. Task-number: QTCREATORBUG-13854 Change-Id: I346058f6f9753475ec209ec8befdd5425bbd83d0 Reviewed-by: hjk --- src/plugins/debugger/qml/qmlengine.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/plugins/debugger/qml/qmlengine.cpp b/src/plugins/debugger/qml/qmlengine.cpp index 4924fce386c..34a620d9b98 100644 --- a/src/plugins/debugger/qml/qmlengine.cpp +++ b/src/plugins/debugger/qml/qmlengine.cpp @@ -524,7 +524,7 @@ void QmlEngine::serviceConnectionError(const QString &serviceName) bool QmlEngine::canDisplayTooltip() const { - return state() == InferiorRunOk || state() == InferiorStopOk; + return false; } void QmlEngine::filterApplicationMessage(const QString &output, int /*channel*/) From 09ad56a67b8c0ff4fbf78c802450c51646b11021 Mon Sep 17 00:00:00 2001 From: Kai Koehne Date: Fri, 30 Jan 2015 15:03:45 +0100 Subject: [PATCH 22/34] V8Debugger: Don't send watcher requests if qml engine has not stopped This fixes a regression introduced in a8ebf535b829dac. We shouldn't send watcher evaluation commands while the QML engine hasn't actually stopped, because this might lead to an assert on the server side. Task-number: QTCREATORBUG-13916 Change-Id: I300e2f73c0a1a03e0e6187a5357abeba408f72a0 Reviewed-by: Christian Stenger --- src/plugins/debugger/qml/qmlv8debuggerclient.cpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/plugins/debugger/qml/qmlv8debuggerclient.cpp b/src/plugins/debugger/qml/qmlv8debuggerclient.cpp index f4c08164507..c28166ef269 100644 --- a/src/plugins/debugger/qml/qmlv8debuggerclient.cpp +++ b/src/plugins/debugger/qml/qmlv8debuggerclient.cpp @@ -954,6 +954,9 @@ void QmlV8DebuggerClient::executeDebuggerCommand(const QString &command) void QmlV8DebuggerClient::synchronizeWatchers(const QStringList &watchers) { SDEBUG(watchers); + if (d->engine->state() != InferiorStopOk) + return; + foreach (const QString &exp, watchers) { StackHandler *stackHandler = d->engine->stackHandler(); if (stackHandler->isContentsValid() && stackHandler->currentFrame().isUsable()) { From 26972ade65a1b256da707b87138ae1a2d67901b5 Mon Sep 17 00:00:00 2001 From: Robert Loehning Date: Mon, 2 Feb 2015 14:33:14 +0100 Subject: [PATCH 23/34] Squish: Stabilize tst_qml_editor Avoid false fails with Squish 5.1.3 and Qt 5.4.0 on Windows Change-Id: I4d330627ed7d93ad7e327aebd9c9d3173e34a8e1 Reviewed-by: Christian Stenger --- tests/system/shared/editor_utils.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/tests/system/shared/editor_utils.py b/tests/system/shared/editor_utils.py index 27dd588e4bf..f3811af5270 100644 --- a/tests/system/shared/editor_utils.py +++ b/tests/system/shared/editor_utils.py @@ -153,9 +153,12 @@ def verifyHoveringOnEditor(editor, lines, additionalKeyPresses, expectedTypes, e for ty in additionalKeyPresses: type(editor, ty) rect = editor.cursorRect(editor.textCursor()) + expectedToolTip = "{type='%s' visible='1'}" % expectedType + # wait for similar tooltips to disappear + checkIfObjectExists(expectedToolTip, False, 1000, True) sendEvent("QMouseEvent", editor, QEvent.MouseMove, rect.x+rect.width/2, rect.y+rect.height/2, Qt.NoButton, 0) try: - tip = waitForObject("{type='%s' visible='1'}" % expectedType) + tip = waitForObject(expectedToolTip) except: tip = None if tip == None: From d7e5d41494597ceaf7422f4b6a918d024c31caad Mon Sep 17 00:00:00 2001 From: David Schulz Date: Mon, 2 Feb 2015 15:00:19 +0100 Subject: [PATCH 24/34] Editor: Fix crash in generic highlighter. Make sure that the progress data object is deleted before the rule. Task-number: QTCREATORBUG-13883 Change-Id: Ie0d1825e695f0bfa7d46ee6dd807a94c95a08cd7 Reviewed-by: Eike Ziller --- src/plugins/texteditor/generichighlighter/highlighter.cpp | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/src/plugins/texteditor/generichighlighter/highlighter.cpp b/src/plugins/texteditor/generichighlighter/highlighter.cpp index ca46a2d3d8c..ed5ca095097 100644 --- a/src/plugins/texteditor/generichighlighter/highlighter.cpp +++ b/src/plugins/texteditor/generichighlighter/highlighter.cpp @@ -164,16 +164,17 @@ void Highlighter::highlightBlock(const QString &text) handleContextChange(m_currentContext->lineBeginContext(), m_currentContext->definition()); - ProgressData progress; + ProgressData *progress = new ProgressData; const int length = text.length(); - while (progress.offset() < length) - iterateThroughRules(text, length, &progress, false, m_currentContext->rules()); + while (progress->offset() < length) + iterateThroughRules(text, length, progress, false, m_currentContext->rules()); if (extractObservableState(currentBlockState()) != WillContinue) { handleContextChange(m_currentContext->lineEndContext(), m_currentContext->definition(), false); } + delete progress; m_contexts.clear(); if (m_indentationBasedFolding) { From 75a943ef57da0179e742c7d396fb28f909e1add1 Mon Sep 17 00:00:00 2001 From: Orgad Shaneh Date: Tue, 3 Feb 2015 09:10:37 +0200 Subject: [PATCH 25/34] C++: Fix crash when #if[def] nesting is deeper than 512 levels Change-Id: I5e86da3a36514545834f554470b147ad8be43344 Reviewed-by: Eike Ziller Reviewed-by: Nikolai Kosjar --- src/libs/cplusplus/pp-engine.cpp | 27 +++++++++++++++---- .../preprocessor/tst_preprocessor.cpp | 18 +++++++++++++ 2 files changed, 40 insertions(+), 5 deletions(-) diff --git a/src/libs/cplusplus/pp-engine.cpp b/src/libs/cplusplus/pp-engine.cpp index c0e6e3e827a..9cafea26f2d 100644 --- a/src/libs/cplusplus/pp-engine.cpp +++ b/src/libs/cplusplus/pp-engine.cpp @@ -140,6 +140,12 @@ static bool isQtReservedWord(const char *name, int size) return false; } +static void nestingTooDeep() +{ +#ifndef NO_DEBUG + std::cerr << "*** WARNING #if / #ifdef nesting exceeded the max level " << MAX_LEVEL << std::endl; +#endif +} } // anonymous namespace @@ -1819,6 +1825,12 @@ void Preprocessor::handleIfDirective(PPToken *tk) lex(tk); // consume "if" token Value result; const PPToken lastExpressionToken = evalExpression(tk, result); + + if (m_state.m_ifLevel >= MAX_LEVEL - 1) { + nestingTooDeep(); + return; + } + const bool value = !result.is_zero(); const bool wasSkipping = m_state.m_skipping[m_state.m_ifLevel]; @@ -1945,12 +1957,17 @@ void Preprocessor::handleIfDefDirective(bool checkUndefined, PPToken *tk) value = !value; const bool wasSkipping = m_state.m_skipping[m_state.m_ifLevel]; - ++m_state.m_ifLevel; - m_state.m_trueTest[m_state.m_ifLevel] = value; - m_state.m_skipping[m_state.m_ifLevel] = wasSkipping ? wasSkipping : !value; - if (m_client && !wasSkipping && !value) - startSkippingBlocks(*tk); + if (m_state.m_ifLevel < MAX_LEVEL - 1) { + ++m_state.m_ifLevel; + m_state.m_trueTest[m_state.m_ifLevel] = value; + m_state.m_skipping[m_state.m_ifLevel] = wasSkipping ? wasSkipping : !value; + + if (m_client && !wasSkipping && !value) + startSkippingBlocks(*tk); + } else { + nestingTooDeep(); + } lex(tk); // consume the identifier #ifndef NO_DEBUG diff --git a/tests/auto/cplusplus/preprocessor/tst_preprocessor.cpp b/tests/auto/cplusplus/preprocessor/tst_preprocessor.cpp index ee326c3d666..3bc5c8eb0d3 100644 --- a/tests/auto/cplusplus/preprocessor/tst_preprocessor.cpp +++ b/tests/auto/cplusplus/preprocessor/tst_preprocessor.cpp @@ -390,6 +390,7 @@ private slots: void empty_trailing_lines_data(); void undef(); void concat(); + void excessive_nesting(); }; // Remove all #... lines, and 'simplify' string, to allow easily comparing the result @@ -1895,6 +1896,23 @@ void tst_Preprocessor::concat() QCOMPARE(prep.constData(), output.constData()); } +void tst_Preprocessor::excessive_nesting() +{ + Environment env; + Preprocessor preprocess(0, &env); + QByteArray input; + const QByteArray output = + "# 1 \"\"\n" + "# 2001 \"\"\n"; + for (int i = 0; i < 1000; ++i) + input += "#if FOO\n"; + for (int i = 0; i < 1000; ++i) + input += "#endif\n"; + QByteArray prep = preprocess.run(QLatin1String(""), input); + // Output cannot be precisely determined, but it shouldn't crash. + QCOMPARE(prep, output); +} + void tst_Preprocessor::compare_input_output(bool keepComments) { QFETCH(QByteArray, input); From 99c8992aed00f3ed3c40ba4899a3c056bd666cf6 Mon Sep 17 00:00:00 2001 From: Christian Kandeler Date: Thu, 29 Jan 2015 14:56:23 +0100 Subject: [PATCH 26/34] QbsPM: Remove existing qbs profile before recreating from kit. Otherwise, "remove" operations on a kit such as clearing out the sysroot or removing the Qt version will leave the old entries in the profile. Change-Id: I70be926472c8d290b80e3479fc49286113f71380 Reviewed-by: Joerg Bornemann --- src/plugins/qbsprojectmanager/qbsprojectmanager.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/src/plugins/qbsprojectmanager/qbsprojectmanager.cpp b/src/plugins/qbsprojectmanager/qbsprojectmanager.cpp index 83f50538ab2..3c6c61f4c5a 100644 --- a/src/plugins/qbsprojectmanager/qbsprojectmanager.cpp +++ b/src/plugins/qbsprojectmanager/qbsprojectmanager.cpp @@ -187,6 +187,7 @@ void QbsManager::addQtProfileFromKit(const QString &profileName, const ProjectEx void QbsManager::addProfileFromKit(const ProjectExplorer::Kit *k) { const QString name = QString::fromLatin1("qtc_") + k->fileSystemFriendlyName(); + qbs::Profile(name, settings()).removeProfile(); setProfileForKit(name, k); addQtProfileFromKit(name, k); From cb5806d014b345feff57d8277f055c87f67eb8ad Mon Sep 17 00:00:00 2001 From: Kai Koehne Date: Fri, 30 Jan 2015 14:56:24 +0100 Subject: [PATCH 27/34] V8Debugger: Remove unused member Change-Id: Ieaea81203cad0170d638dcee8b91b73bb3bc7144 Reviewed-by: hjk --- src/plugins/debugger/qml/qmlv8debuggerclient.cpp | 1 - 1 file changed, 1 deletion(-) diff --git a/src/plugins/debugger/qml/qmlv8debuggerclient.cpp b/src/plugins/debugger/qml/qmlv8debuggerclient.cpp index c28166ef269..d48b5522632 100644 --- a/src/plugins/debugger/qml/qmlv8debuggerclient.cpp +++ b/src/plugins/debugger/qml/qmlv8debuggerclient.cpp @@ -127,7 +127,6 @@ public: QScriptValue parser; QScriptValue stringifier; - QStringList scriptSourceRequests; QHash evaluatingExpression; QHash localsAndWatchers; From d95775a54cc100b3c2b9522653885f3c51dd8e1c Mon Sep 17 00:00:00 2001 From: Christian Kandeler Date: Fri, 6 Feb 2015 15:16:42 +0100 Subject: [PATCH 28/34] Update qbs submodule. To HEAD of 1.3 branch. Change-Id: I5409cd497e2380a5c1ea78e4c5de8e5d28fab97b Reviewed-by: Joerg Bornemann --- src/shared/qbs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/shared/qbs b/src/shared/qbs index d4010ce8423..aec6c77bb8c 160000 --- a/src/shared/qbs +++ b/src/shared/qbs @@ -1 +1 @@ -Subproject commit d4010ce842360d0fa5ba67f8dcb3267aae49092c +Subproject commit aec6c77bb8ce33b6535106c78eeb9cd755398953 From 59fc0fe8f2f5843d961ea5ae8967eb15850e9231 Mon Sep 17 00:00:00 2001 From: Orgad Shaneh Date: Sun, 23 Nov 2014 14:58:54 +0200 Subject: [PATCH 29/34] Theming: Fix highlighting of focused widget in target selector Change-Id: I477a409ed231a291fb9320ce9014853a7e21274c Reviewed-by: Alessandro Portale --- src/libs/utils/theme/theme.cpp | 1 + src/plugins/projectexplorer/miniprojecttargetselector.cpp | 8 ++++---- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/src/libs/utils/theme/theme.cpp b/src/libs/utils/theme/theme.cpp index 3fd18c77c69..2e85c8c0846 100644 --- a/src/libs/utils/theme/theme.cpp +++ b/src/libs/utils/theme/theme.cpp @@ -354,6 +354,7 @@ QPalette Theme::palette() const pal.setBrush(QPalette::ButtonText, color(Theme::TextColorNormal)); pal.setBrush(QPalette::ToolTipBase, color(Theme::BackgroundColorSelected)); pal.setColor(QPalette::Highlight, color(Theme::BackgroundColorSelected)); + pal.setColor(QPalette::Dark, color(Theme::BackgroundColorDark)); pal.setColor(QPalette::HighlightedText, Qt::white); pal.setColor(QPalette::ToolTipText, color(Theme::TextColorNormal)); return pal; diff --git a/src/plugins/projectexplorer/miniprojecttargetselector.cpp b/src/plugins/projectexplorer/miniprojecttargetselector.cpp index b65d128c7e9..da885b141aa 100644 --- a/src/plugins/projectexplorer/miniprojecttargetselector.cpp +++ b/src/plugins/projectexplorer/miniprojecttargetselector.cpp @@ -135,12 +135,12 @@ void TargetSelectorDelegate::paint(QPainter *painter, selectionGradient.load(QLatin1String(":/projectexplorer/images/targetpanel_gradient.png")); if (option.state & QStyle::State_Selected) { + const QColor color = (option.state & QStyle::State_HasFocus) ? + option.palette.highlight().color() : + option.palette.dark().color(); if (creatorTheme()->widgetStyle() == Theme::StyleFlat) { - painter->fillRect(option.rect, creatorTheme()->color(Theme::BackgroundColorSelected)); + painter->fillRect(option.rect, color); } else { - QColor color =(option.state & QStyle::State_HasFocus) ? - option.palette.highlight().color() : - option.palette.dark().color(); painter->fillRect(option.rect, color.darker(140)); Utils::StyleHelper::drawCornerImage(selectionGradient, painter, option.rect.adjusted(0, 0, 0, -1), 5, 5, 5, 5); painter->setPen(QColor(255, 255, 255, 60)); From 8d27ec664a2dbdd3a4941965dbf3883e671b7bcc Mon Sep 17 00:00:00 2001 From: Eskil Abrahamsen Blomfeldt Date: Wed, 11 Feb 2015 10:01:56 +0100 Subject: [PATCH 30/34] Android: Fix debugging applications that link many modules When debugging an application we will add a few arguments to the command line for launching the application. We would do the same for every library etc. required by the modules linked to the application. At some point, the command line would become too long and fail to execute. Passing the libraries, libs_prefix, etc. on the command line is not necessary, since the parameters are already included in the AndroidManifest.xml, otherwise it would not be possible to launch the application from the device itself. Change-Id: I93a7f64a4ce32ebb2b25c54b0d17ae2b23706e24 Task-number: QTCREATORBUG-13691 Reviewed-by: Daniel Teske --- src/plugins/android/androidrunner.cpp | 8 -------- 1 file changed, 8 deletions(-) diff --git a/src/plugins/android/androidrunner.cpp b/src/plugins/android/androidrunner.cpp index 5e017f20f92..d833578a795 100644 --- a/src/plugins/android/androidrunner.cpp +++ b/src/plugins/android/androidrunner.cpp @@ -390,14 +390,6 @@ void AndroidRunner::asyncStart() args << _("-e") << _("qml_debug") << _("true"); args << _("-e") << _("qmljsdebugger") << QString::fromLatin1("port:%1,block").arg(m_qmlPort); } - if (m_useLocalQtLibs) { - args << _("-e") << _("use_local_qt_libs") << _("true"); - args << _("-e") << _("libs_prefix") << _("/data/local/tmp/qt/"); - args << _("-e") << _("load_local_libs") << m_localLibs; - args << _("-e") << _("load_local_jars") << m_localJars; - if (!m_localJarsInitClasses.isEmpty()) - args << _("-e") << _("static_init_classes") << m_localJarsInitClasses; - } QProcess adb; adb.start(m_adb, args); From f2c9cd655e9b87a408d504ca3f5830aa76f22187 Mon Sep 17 00:00:00 2001 From: Robert Loehning Date: Wed, 11 Feb 2015 12:02:52 +0100 Subject: [PATCH 31/34] Squish: Prepare help tests for Qt 5.4 Change-Id: I38568b325ae37d8b75ad3481ef0cc6ced0a99488 Reviewed-by: Christian Stenger --- tests/system/shared/qtcreator.py | 2 ++ tests/system/suite_HELP/tst_HELP06/test.py | 8 +++++++- tests/system/suite_WELP/tst_WELP01/test.py | 5 ++++- 3 files changed, 13 insertions(+), 2 deletions(-) diff --git a/tests/system/shared/qtcreator.py b/tests/system/shared/qtcreator.py index 559334ea3f2..5190f1b3759 100644 --- a/tests/system/shared/qtcreator.py +++ b/tests/system/shared/qtcreator.py @@ -39,6 +39,8 @@ import sys import errno; from datetime import datetime,timedelta; +isQt53Build = os.getenv("SYSTEST_ISQT53BUILD") != "0" + srcPath = '' SettingsPath = '' tmpSettingsDir = '' diff --git a/tests/system/suite_HELP/tst_HELP06/test.py b/tests/system/suite_HELP/tst_HELP06/test.py index 7f79a046865..3d5a96b0d63 100755 --- a/tests/system/suite_HELP/tst_HELP06/test.py +++ b/tests/system/suite_HELP/tst_HELP06/test.py @@ -45,7 +45,13 @@ def invokeContextMenuItemOnBookmarkFolder(view, item, menuItem): "window=':Add Bookmark_BookmarkDialog'}" % aboveWidget), menuItem) def textForQtVersion(text): - return text + " | QtCreator" + if isQt53Build: + return text + " | QtCreator" + else: + suffix = "Qt Creator Manual" + if text != suffix: + text += " | " + suffix + return text def main(): startApplication("qtcreator" + SettingsPath) diff --git a/tests/system/suite_WELP/tst_WELP01/test.py b/tests/system/suite_WELP/tst_WELP01/test.py index 5b8208b7104..fd19e479b42 100755 --- a/tests/system/suite_WELP/tst_WELP01/test.py +++ b/tests/system/suite_WELP/tst_WELP01/test.py @@ -83,7 +83,10 @@ def main(): test.verify(checkIfObjectExists(gettingStartedText), "Verifying: Qt Creator displays Welcome Page with 'Get Started Now' button.") - expectedText = "(QtCreator : Qt Creator Manual)|(Qt Creator Manual [|] QtCreator)" + if isQt53Build: + expectedText = "(QtCreator : Qt Creator Manual)|(Qt Creator Manual [|] QtCreator)" + else: + expectedText = "Qt Creator Manual" testDetails = "Verifying: Help with Creator Documentation is being opened." clickItemVerifyHelpCombo(gettingStartedText, expectedText, testDetails) From e11caa793a28b53d7a13c5b990a89f900be5f535 Mon Sep 17 00:00:00 2001 From: Robert Loehning Date: Wed, 11 Feb 2015 16:22:24 +0100 Subject: [PATCH 32/34] Squish: Remove outdated code Change-Id: I765374645bb6176028416e7ad8e4ce69df65723d Reviewed-by: Christian Stenger --- tests/system/shared/utils.py | 3 --- 1 file changed, 3 deletions(-) diff --git a/tests/system/shared/utils.py b/tests/system/shared/utils.py index 2b30aca0487..b4532752084 100644 --- a/tests/system/shared/utils.py +++ b/tests/system/shared/utils.py @@ -578,9 +578,6 @@ def dumpChildren(item): return [item.child(index) for index in range(item.childCount())] def writeTestResults(folder): - if squishinfo.version < 0x040200FF: - print "Skipping writing test results (Squish < 4.2)" - return if not os.path.exists(folder): print "Skipping writing test results (folder '%s' does not exist)." % folder return From 62e30ad5627f84ffeba5995ca4ae957b5c5cd15d Mon Sep 17 00:00:00 2001 From: Christian Kandeler Date: Thu, 12 Feb 2015 11:56:51 +0100 Subject: [PATCH 33/34] Update qbs submodule. To HEAD of 1.3 branch. Change-Id: I1b900208dd52978ae0a7cf0a79e2469cfc6928f0 Reviewed-by: Joerg Bornemann --- src/shared/qbs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/shared/qbs b/src/shared/qbs index aec6c77bb8c..e1ea84b740f 160000 --- a/src/shared/qbs +++ b/src/shared/qbs @@ -1 +1 @@ -Subproject commit aec6c77bb8ce33b6535106c78eeb9cd755398953 +Subproject commit e1ea84b740fb54bf7a60e852f68dd5a126da0104 From 28971701fd4baa99f294d9393650b83c40754e18 Mon Sep 17 00:00:00 2001 From: Robert Loehning Date: Thu, 12 Feb 2015 12:57:17 +0100 Subject: [PATCH 34/34] Squish: Don't rely on progress bars when parsing qbs project Task-number: QBS-746 Change-Id: I316934884432953e2137d7e97b73fce352be4cac Reviewed-by: Christian Stenger --- tests/system/suite_general/tst_opencreator_qbs/test.py | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/tests/system/suite_general/tst_opencreator_qbs/test.py b/tests/system/suite_general/tst_opencreator_qbs/test.py index b7d363c7cc9..27a70a72489 100644 --- a/tests/system/suite_general/tst_opencreator_qbs/test.py +++ b/tests/system/suite_general/tst_opencreator_qbs/test.py @@ -39,7 +39,12 @@ def main(): if not startedWithoutPluginError(): return openQbsProject(pathCreator) - progressBarWait(200000) + test.log("Start parsing project") naviTreeView = "{column='0' container=':Qt Creator_Utils::NavigationTreeView' text~='qtcreator( \[\S+\])?' type='QModelIndex'}" + ntwObject = waitForObject(naviTreeView) + if waitFor("ntwObject.model().rowCount(ntwObject) > 2", 200000): # No need to wait for C++-parsing + test.log("Parsing project done") # we only need the project + else: + test.warning("Parsing project timed out") compareProjectTree(naviTreeView, "projecttree_creator.tsv") invokeMenuItem("File", "Exit")