summaryrefslogtreecommitdiffstats
path: root/src/printsupport
diff options
context:
space:
mode:
authorUlf Hermann <ulf.hermann@theqtcompany.com>2016-01-06 12:18:40 +0100
committerUlf Hermann <ulf.hermann@theqtcompany.com>2016-02-08 10:40:33 +0000
commit4fb7eb0da74798205f5cac693c921065492fa33e (patch)
tree2082182e4b640ef9233d1bd9108caccd30a5edb7 /src/printsupport
parent21861e6fd1fcd1e4642f3d4c06ee7181d2c81778 (diff)
Drop most "#ifndef QT_NO_LIBRARY"
As we can load plugins without QLibrary now, we don't have to #ifdef out the code that does so anymore. Change-Id: I1dc20216830a882dbd5a1b431183407e6b19c837 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Diffstat (limited to 'src/printsupport')
-rw-r--r--src/printsupport/kernel/qplatformprintplugin.cpp8
1 files changed, 0 insertions, 8 deletions
diff --git a/src/printsupport/kernel/qplatformprintplugin.cpp b/src/printsupport/kernel/qplatformprintplugin.cpp
index dc059f6612..b50f43056b 100644
--- a/src/printsupport/kernel/qplatformprintplugin.cpp
+++ b/src/printsupport/kernel/qplatformprintplugin.cpp
@@ -45,10 +45,8 @@
QT_BEGIN_NAMESPACE
-#ifndef QT_NO_LIBRARY
Q_GLOBAL_STATIC_WITH_ARGS(QFactoryLoader, loader,
(QPlatformPrinterSupportFactoryInterface_iid, QLatin1String("/printsupport"), Qt::CaseInsensitive))
-#endif
QPlatformPrinterSupportPlugin::QPlatformPrinterSupportPlugin(QObject *parent)
: QObject(parent)
@@ -61,15 +59,11 @@ QPlatformPrinterSupportPlugin::~QPlatformPrinterSupportPlugin()
static QPlatformPrinterSupport *printerSupport = 0;
-#ifndef QT_NO_LIBRARY
static void cleanupPrinterSupport()
{
-#ifndef QT_NO_PRINTER
delete printerSupport;
-#endif
printerSupport = 0;
}
-#endif // !QT_NO_LIBRARY
/*!
\internal
@@ -81,7 +75,6 @@ static void cleanupPrinterSupport()
*/
QPlatformPrinterSupport *QPlatformPrinterSupportPlugin::get()
{
-#ifndef QT_NO_LIBRARY
if (!printerSupport) {
const QMultiMap<int, QString> keyMap = loader()->keyMap();
if (!keyMap.isEmpty())
@@ -89,7 +82,6 @@ QPlatformPrinterSupport *QPlatformPrinterSupportPlugin::get()
if (printerSupport)
qAddPostRoutine(cleanupPrinterSupport);
}
-#endif // !QT_NO_LIBRARY
return printerSupport;
}