summaryrefslogtreecommitdiffstats
path: root/examples/painting
diff options
context:
space:
mode:
authorJanne Anttila <janne.anttila@digia.com>2012-06-13 13:59:54 +0300
committerQt by Nokia <qt-info@nokia.com>2012-06-18 09:48:55 +0200
commit9fe5139e73958a2102cd5bb754c5049d18812c89 (patch)
tree4167c33c120f5f65ea1172dddb674ee001faa4cb /examples/painting
parent15db02cb11ff070fa32f90862ce00a895e614cad (diff)
Fix building of qtbase examples when printsupport module is disabled.
Printsupport module is not that interesting in embedded environments, and it also does not compile at the moment for WEC7. Fixed qtbase examples to obey the availability of printsupport module. Change-Id: I960d1b628b9ca82450aa3b0df8dd101b2544ee12 Reviewed-by: Björn Breitmeyer <bjoern.breitmeyer@kdab.com> Reviewed-by: Andreas Holzammer <andreas.holzammer@kdab.com> Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
Diffstat (limited to 'examples/painting')
-rw-r--r--examples/painting/fontsampler/fontsampler.pro3
-rw-r--r--examples/painting/fontsampler/mainwindow.cpp2
2 files changed, 4 insertions, 1 deletions
diff --git a/examples/painting/fontsampler/fontsampler.pro b/examples/painting/fontsampler/fontsampler.pro
index 539fc4894b..b918c51837 100644
--- a/examples/painting/fontsampler/fontsampler.pro
+++ b/examples/painting/fontsampler/fontsampler.pro
@@ -9,4 +9,5 @@ sources.files = $$SOURCES $$HEADERS $$RESOURCES $$FORMS fontsampler.pro
sources.path = $$[QT_INSTALL_EXAMPLES]/qtbase/painting/fontsampler
INSTALLS += target sources
-QT += widgets printsupport
+QT += widgets
+!isEmpty(QT.printsupport.name): QT += printsupport
diff --git a/examples/painting/fontsampler/mainwindow.cpp b/examples/painting/fontsampler/mainwindow.cpp
index c2d97f360e..ae45613abf 100644
--- a/examples/painting/fontsampler/mainwindow.cpp
+++ b/examples/painting/fontsampler/mainwindow.cpp
@@ -39,9 +39,11 @@
****************************************************************************/
#include <QtWidgets>
+#ifndef QT_NO_PRINTER
#include <QPrinter>
#include <QPrintDialog>
#include <QPrintPreviewDialog>
+#endif
#include "mainwindow.h"