Commit 6856008e authored by Laurent Montel's avatar Laurent Montel 😁
Browse files

Make it compile against qt5.15. SkipEmptyParts is part of Qt::.

parent feda79ff
......@@ -153,7 +153,11 @@ void KWQCommandPaste::redo()
QString s = QApplication::clipboard()->text();
QStringList sl;
#if QT_VERSION < QT_VERSION_CHECK(5, 15, 0)
sl = s.split('\n', QString::SkipEmptyParts);
#else
sl = s.split('\n', Qt::SkipEmptyParts);
#endif
if (sl.isEmpty())
return;
QStringList sr;
......
......@@ -161,12 +161,20 @@ bool KWQQuizModel::checkAnswer(const QString & a)
if (!m_correctBlank.isEmpty()) {
QStringList la, ls;
if (ans.indexOf(';') > 0)
#if QT_VERSION < QT_VERSION_CHECK(5, 15, 0)
ls = ans.split(';', QString::SkipEmptyParts);
#else
ls = ans.split(';', Qt::SkipEmptyParts);
#endif
else
ls.append(ans);
if (m_correctBlank.indexOf(';') > 0)
#if QT_VERSION < QT_VERSION_CHECK(5, 15, 0)
la = m_correctBlank.split(';', QString::SkipEmptyParts);
#else
la = m_correctBlank.split(';', Qt::SkipEmptyParts);
#endif
else
la.append(m_correctBlank);
......
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