Not all platforms do have QRegularExpression as it is based on
pcre.
Change-Id: I3247f8b2213f78a6e537f6781d97b0c6382482ad
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
foreach (const QString &path, files) {
//QUrl::fromUserInput doesn't treat no scheme as relative file paths
+#ifndef QT_NO_REGULAREXPRESSION
QRegularExpression urlRe("[[:word:]]+://.*");
if (urlRe.match(path).hasMatch()) { //Treat as a URL
QUrl url = QUrl::fromUserInput(path);
? QDir::toNativeSeparators(url.toLocalFile())
: url.toString()));
e.load(url);
- } else { //Local file path
+ } else
+#endif
+ { //Local file path
if (verboseMode)
printf("qml: loading %s\n", qPrintable(QDir::toNativeSeparators(path)));