Commit 4eca1a4c authored by Laurent Montel's avatar Laurent Montel 😁
Browse files

Make it compile

parent 55b9fdd4
......@@ -663,7 +663,13 @@ QSet<int> MarkupDirector::getElementsToClose(QTextBlock::iterator it) const
if (it.atEnd()) {
// End of block?. Close all open tags.
const QList<int> openElement = d->m_openElements;
#if QT_VERSION < QT_VERSION_CHECK(5, 12, 0)
auto elementsToClose = d->m_openElements.toSet();
#else
auto elementsToClose = QSet<int>(openElement.begin(), openElement.end());
#endif
return elementsToClose.unite(d->m_elementsToOpen);
}
......@@ -860,7 +866,7 @@ QList<int> MarkupDirector::getElementsToOpen(QTextBlock::iterator it)
}
if (d->m_elementsToOpen.size() <= 1) {
return d->m_elementsToOpen.toList();
return d->m_elementsToOpen.values();
}
return sortOpeningOrder(d->m_elementsToOpen, it);
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment