summaryrefslogtreecommitdiffstats
path: root/src/widgets
diff options
context:
space:
mode:
authorLars Knoll <lars.knoll@qt.io>2016-09-09 09:50:08 +0200
committerLars Knoll <lars.knoll@qt.io>2016-09-15 08:23:53 +0000
commit2d3c73fcfe7a93cb46190e8e82410fe93145dbe0 (patch)
tree0ef9b0903113bfb945dabc17654e1695872d5605 /src/widgets
parentfc098de70a5dda5f45ebe238a43f24f674426f3d (diff)
Modularize configure.json/.pri
Move the different parts of configure.json/.pri into the libraries where they belong. Gui is not yet fully modularized, and contains many things related to the different QPA plugins. Done-with: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com> Change-Id: I6659bb29354ed1f36b95b8c69e7fce58f642053f Reviewed-by: Lars Knoll <lars.knoll@qt.io>
Diffstat (limited to 'src/widgets')
-rw-r--r--src/widgets/configure.json97
-rw-r--r--src/widgets/configure.pri8
-rw-r--r--src/widgets/kernel/qtwidgetsglobal.h1
-rw-r--r--src/widgets/kernel/qtwidgetsglobal_p.h1
-rw-r--r--src/widgets/styles/styles.pri2
5 files changed, 109 insertions, 0 deletions
diff --git a/src/widgets/configure.json b/src/widgets/configure.json
new file mode 100644
index 0000000000..23ee540c32
--- /dev/null
+++ b/src/widgets/configure.json
@@ -0,0 +1,97 @@
+{
+ "module": "widgets",
+ "depends": [
+ "core-private",
+ "gui"
+ ],
+ "testDir": "../../config.tests",
+
+ "commandline": {
+ "options": {
+ "android-style-assets": "boolean",
+ "gtk": { "type": "boolean", "name": "gtk3" },
+ "style-windows": "boolean",
+ "style-windowsxp": "boolean",
+ "style-windowsvista": "boolean",
+ "style-fusion": "boolean",
+ "style-mac": "boolean",
+ "style-android": "boolean"
+ }
+ },
+
+ "libraries": {
+ "gtk3": {
+ "description": "GTK+",
+ "sources": [
+ { "type": "pkgConfig", "args": "gtk+-3.0" }
+ ]
+ }
+ },
+
+ "tests": {
+ "uxtheme": {
+ "description": "uxtheme.h",
+ "type": "files",
+ "files": [ "uxtheme.h" ]
+ }
+ },
+
+ "features": {
+ "gtk3": {
+ "description": "GTK+",
+ "autoDetect": "!config.darwin",
+ "condition": "features.glib && libs.gtk3",
+ "output": [ "privateFeature" ]
+ },
+ "style-fusion": {
+ "description": "Fusion Style",
+ "output": [ "styles" ]
+ },
+ "style-mac": {
+ "description": "Mac Style",
+ "condition": "config.osx",
+ "output": [ "styles" ]
+ },
+ "style-windows": {
+ "description": "Windows Style",
+ "output": [ "styles" ]
+ },
+ "style-windowsxp": {
+ "description": "Windows XP Style",
+ "condition": "features.style-windows && config.win32 && !config.winrt && tests.uxtheme",
+ "output": [ "styles" ]
+ },
+ "style-windowsvista": {
+ "description": "Windows Vista Style",
+ "condition": "features.style-windowsxp",
+ "output": [ "styles" ]
+ },
+ "style-android": {
+ "description": "Android Style",
+ "autoDetect": "config.android",
+ "output": [ "styles" ]
+ },
+ "android-style-assets": {
+ "description": "Android Style Assets",
+ "condition": "features.style-android",
+ "output": [ "privateConfig" ]
+ }
+ },
+
+ "report": [
+ ],
+
+ "summary": [
+ {
+ "section": "Qt Widgets",
+ "entries": [
+ "gtk3",
+ {
+ "message": "Styles",
+ "type": "featureList",
+ "args": "style-fusion style-mac style-windows style-windowsxp style-windowsvista style-android"
+ }
+ ]
+ }
+ ]
+}
diff --git a/src/widgets/configure.pri b/src/widgets/configure.pri
new file mode 100644
index 0000000000..ddb3657700
--- /dev/null
+++ b/src/widgets/configure.pri
@@ -0,0 +1,8 @@
+# custom outputs
+
+defineTest(qtConfOutput_styles) {
+ !$${2}: return()
+
+ style = $$replace($${1}.feature, "style-", "")
+ qtConfOutputVar(append, "privatePro", "styles", $$style)
+}
diff --git a/src/widgets/kernel/qtwidgetsglobal.h b/src/widgets/kernel/qtwidgetsglobal.h
index f6d003e629..1c74f37618 100644
--- a/src/widgets/kernel/qtwidgetsglobal.h
+++ b/src/widgets/kernel/qtwidgetsglobal.h
@@ -41,6 +41,7 @@
#define QTWIDGETSGLOBAL_H
#include <QtGui/qtguiglobal.h>
+#include <QtWidgets/qtwidgets-config.h>
QT_BEGIN_NAMESPACE
diff --git a/src/widgets/kernel/qtwidgetsglobal_p.h b/src/widgets/kernel/qtwidgetsglobal_p.h
index 7dd545415c..22ba876022 100644
--- a/src/widgets/kernel/qtwidgetsglobal_p.h
+++ b/src/widgets/kernel/qtwidgetsglobal_p.h
@@ -53,5 +53,6 @@
#include <QtWidgets/qtwidgetsglobal.h>
#include <QtGui/private/qtguiglobal_p.h>
+#include <QtWidgets/private/qtwidgets-config_p.h>
#endif // QTWIDGETSGLOBAL_P_H
diff --git a/src/widgets/styles/styles.pri b/src/widgets/styles/styles.pri
index 7b9497172c..69e13fb6ec 100644
--- a/src/widgets/styles/styles.pri
+++ b/src/widgets/styles/styles.pri
@@ -35,6 +35,8 @@ SOURCES += \
RESOURCES += styles/qstyle.qrc
+include($$OUT_PWD/qtwidgets-config.pri)
+
contains( styles, mac ) {
HEADERS += \
styles/qmacstyle_mac_p.h \