Merge remote-tracking branch 'origin/11.0' into qds/dev

Conflicts: src/plugins/qmldesigner/components/stateseditor/stateseditorwidget.cpp
  src/plugins/qmldesigner/components/stateseditornew/stateseditorwidget.cpp
  tests/unit/unittest/qmlprojectmanager/projectitem-test.cpp

Change-Id: Icdb63851ec0162d82217e85b3beb0b6f9f12899e
This commit is contained in:
Tim Jenssen
2023-06-22 16:49:37 +02:00
466 changed files with 5238 additions and 5077 deletions

View File

@@ -20,9 +20,11 @@
#include <QtCore/qstring.h>
#include <QtCore/qstack.h>
QT_QML_BEGIN_NAMESPACE
QT_BEGIN_NAMESPACE
class QDebug;
QT_END_NAMESPACE
QT_QML_BEGIN_NAMESPACE
namespace QmlJS {

View File

@@ -697,12 +697,19 @@ Check::Check(Document::Ptr doc, const ContextPtr &context, Utils::QtcSettings *q
_enabledMessages = Utils::toSet(Message::allMessageTypes());
if (qtcSettings && qtcSettings->value("J.QtQuick/QmlJSEditor.useCustomAnalyzer").toBool()) {
auto disabled = qtcSettings->value("J.QtQuick/QmlJSEditor.disabledMessages").toList();
auto toIntList = [](const QList<StaticAnalysis::Type> list) {
return Utils::transform(list, [](StaticAnalysis::Type t) { return int(t); });
};
auto disabled = qtcSettings->value("J.QtQuick/QmlJSEditor.disabledMessages",
QVariant::fromValue(
toIntList(defaultDisabledMessages()))).toList();
for (const QVariant &disabledNumber : disabled)
disableMessage(StaticAnalysis::Type(disabledNumber.toInt()));
if (!isQtQuick2Ui()) {
auto disabled = qtcSettings->value("J.QtQuick/QmlJSEditor.disabledMessagesNonQuickUI").toList();
auto disabled = qtcSettings->value("J.QtQuick/QmlJSEditor.disabledMessagesNonQuickUI",
QVariant::fromValue(
toIntList(defaultDisabledMessagesForNonQuickUi()))).toList();
for (const QVariant &disabledNumber : disabled)
disableMessage(StaticAnalysis::Type(disabledNumber.toInt()));
}

View File

@@ -370,7 +370,7 @@ QByteArray LibraryInfo::calculateFingerprint() const
{
QCryptographicHash hash(QCryptographicHash::Sha1);
auto addData = [&hash](auto p, size_t len) {
hash.addData(QByteArrayView(reinterpret_cast<const char *>(p), len));
hash.addData(reinterpret_cast<const char *>(p), len);
};
addData(&_status, sizeof(_status));