summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorSimon Hausmann <simon.hausmann@qt.io>2019-10-04 09:35:32 +0200
committerSimon Hausmann <simon.hausmann@qt.io>2019-10-04 09:35:45 +0200
commit554a0d642056f06ad1b5da8d56460e2a70811763 (patch)
tree760d76663093f9f1eceb4f7a76b04cfd4e308095 /src
parentd6ac9211695791d3b104ceb71a550bb229fe5f9d (diff)
parentb5daa31da99fbe872b4df047f37da17ae2c119c9 (diff)
Merge remote-tracking branch 'origin/wip/qt6' into dev
Conflicts: .qmake.conf Change-Id: I1a52012a6e2c438a795222d687c33df6189962d2
Diffstat (limited to 'src')
-rw-r--r--src/imports/scxmlstatemachine/plugin.cpp5
-rw-r--r--src/imports/scxmlstatemachine/statemachineloader.cpp2
-rw-r--r--src/scxml/qscxmltabledata.cpp48
3 files changed, 28 insertions, 27 deletions
diff --git a/src/imports/scxmlstatemachine/plugin.cpp b/src/imports/scxmlstatemachine/plugin.cpp
index 69c2992..1d6c8a1 100644
--- a/src/imports/scxmlstatemachine/plugin.cpp
+++ b/src/imports/scxmlstatemachine/plugin.cpp
@@ -75,8 +75,9 @@ public:
qmlRegisterExtendedUncreatableType<QScxmlStateMachine, QScxmlStateMachineExtended>(
uri, major, minor, "StateMachine", "Only created through derived types");
- // Auto-increment the import to stay in sync with ALL future QtQuick minor versions
- qmlRegisterModule(uri, major, QT_VERSION_MINOR);
+ // The minor version used to be the current Qt 5 minor. For compatibility it is the last
+ // Qt 5 release.
+ qmlRegisterModule(uri, major, 15);
qmlProtectModule(uri, 1);
}
diff --git a/src/imports/scxmlstatemachine/statemachineloader.cpp b/src/imports/scxmlstatemachine/statemachineloader.cpp
index d691479..1d312a5 100644
--- a/src/imports/scxmlstatemachine/statemachineloader.cpp
+++ b/src/imports/scxmlstatemachine/statemachineloader.cpp
@@ -191,7 +191,7 @@ bool QScxmlStateMachineLoader::parse(const QUrl &source)
} else {
qmlWarning(this) << QStringLiteral("Something went wrong while parsing '%1':")
.arg(source.url())
- << endl;
+ << Qt::endl;
const auto errors = m_stateMachine->parseErrors();
for (const QScxmlError &error : errors) {
qmlWarning(this) << error.toString();
diff --git a/src/scxml/qscxmltabledata.cpp b/src/scxml/qscxmltabledata.cpp
index aa9a35e..ab63696 100644
--- a/src/scxml/qscxmltabledata.cpp
+++ b/src/scxml/qscxmltabledata.cpp
@@ -991,23 +991,23 @@ QString GeneratedTableData::toString(const int *stateMachineTable)
const StateTable *st = reinterpret_cast<const StateTable *>(stateMachineTable);
- out << "{" << endl
- << "\t0x" << hex << st->version << dec << ", // version" << endl
- << "\t" << st->name << ", // name" << endl
- << "\t" << st->dataModel << ", // data-model" << endl
- << "\t" << st->childStates << ", // child states array offset" << endl
- << "\t" << st->initialTransition << ", // transition to initial states" << endl
- << "\t" << st->initialSetup << ", // initial setup" << endl
- << "\t" << st->binding << ", // binding" << endl
- << "\t" << st->maxServiceId << ", // maxServiceId" << endl
+ out << "{" << Qt::endl
+ << "\t0x" << Qt::hex << st->version << Qt::dec << ", // version" << Qt::endl
+ << "\t" << st->name << ", // name" << Qt::endl
+ << "\t" << st->dataModel << ", // data-model" << Qt::endl
+ << "\t" << st->childStates << ", // child states array offset" << Qt::endl
+ << "\t" << st->initialTransition << ", // transition to initial states" << Qt::endl
+ << "\t" << st->initialSetup << ", // initial setup" << Qt::endl
+ << "\t" << st->binding << ", // binding" << Qt::endl
+ << "\t" << st->maxServiceId << ", // maxServiceId" << Qt::endl
<< "\t" << st->stateOffset << ", " << st->stateCount
- << ", // state offset and count" << endl
+ << ", // state offset and count" << Qt::endl
<< "\t" << st->transitionOffset << ", " << st->transitionCount
- << ", // transition offset and count" << endl
- << "\t" << st->arrayOffset << ", " << st->arraySize << ", // array offset and size" << endl
- << endl;
+ << ", // transition offset and count" << Qt::endl
+ << "\t" << st->arrayOffset << ", " << st->arraySize << ", // array offset and size" << Qt::endl
+ << Qt::endl;
- out << "\t// States:" << endl;
+ out << "\t// States:" << Qt::endl;
for (int i = 0; i < st->stateCount; ++i) {
const StateTable::State &s = st->state(i);
out << "\t"
@@ -1022,11 +1022,11 @@ QString GeneratedTableData::toString(const int *stateMachineTable)
<< s.childStates << ", "
<< s.transitions << ", "
<< s.serviceFactoryIds << ","
- << endl;
+ << Qt::endl;
}
- out << endl
- << "\t// Transitions:" << endl;
+ out << Qt::endl
+ << "\t// Transitions:" << Qt::endl;
for (int i = 0; i < st->transitionCount; ++i) {
auto t = st->transition(i);
out << "\t"
@@ -1036,11 +1036,11 @@ QString GeneratedTableData::toString(const int *stateMachineTable)
<< t.source << ", "
<< t.targets << ", "
<< t.transitionInstructions << ", "
- << endl ;
+ << Qt::endl ;
}
- out << endl
- << "\t// Arrays:" << endl;
+ out << Qt::endl
+ << "\t// Arrays:" << Qt::endl;
int nextStart = 0;
while (nextStart < st->arraySize) {
const StateTable::Array a = st->array(nextStart);
@@ -1048,13 +1048,13 @@ QString GeneratedTableData::toString(const int *stateMachineTable)
for (int j = 0; j < a.size(); ++j) {
out << a[j] << ", ";
}
- out << endl;
+ out << Qt::endl;
nextStart += a.size() + 1;
}
- out << hex;
- out << endl
- << "\t0x" << StateTable::terminator << " // terminator" << endl
+ out << Qt::hex;
+ out << Qt::endl
+ << "\t0x" << StateTable::terminator << " // terminator" << Qt::endl
<< "}";
return result;