From 9de38898312c5dccb1a57b093a6cbfe5b6ed4f77 Mon Sep 17 00:00:00 2001 From: Paul Olav Tvete Date: Thu, 2 Mar 2017 14:47:20 +0100 Subject: Build fix for -no-feature-library Change-Id: I9339b134c8025e9f3e44933121e339a3107ad975 Reviewed-by: Lars Knoll --- src/controls/Private/qquickcontrolsettings.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/controls/Private/qquickcontrolsettings.cpp b/src/controls/Private/qquickcontrolsettings.cpp index a2fb824c..99310c13 100644 --- a/src/controls/Private/qquickcontrolsettings.cpp +++ b/src/controls/Private/qquickcontrolsettings.cpp @@ -249,6 +249,7 @@ QQuickControlSettings1::QQuickControlSettings1(QQmlEngine *engine) bool QQuickControlSettings1::resolveCurrentStylePath() { +#if QT_CONFIG(library) if (!m_styleMap.contains(m_name)) { qWarning() << "WARNING: Cannot find style" << m_name; return false; @@ -279,7 +280,7 @@ bool QQuickControlSettings1::resolveCurrentStylePath() m_styleMap[m_name] = styleData; m_path = styleData.m_styleDirPath; } - +#endif // QT_CONFIG(library) return true; } @@ -294,7 +295,7 @@ void QQuickControlSettings1::findStyle(QQmlEngine *engine, const QString &styleN StyleData styleData; -#ifndef QT_STATIC +#if QT_CONFIG(library) && !defined(QT_STATIC) const auto list = dir.entryList(); for (const QString &fileName : list) { // This assumes that there is only one library in the style directory, -- cgit v1.2.1