diff options
author | John Layt <jlayt@kde.org> | 2013-12-10 18:42:44 +0100 |
---|---|---|
committer | The Qt Project <gerrit-noreply@qt-project.org> | 2014-03-17 13:45:31 +0100 |
commit | f50d46e5eb257528828998a465634d9044cdd17f (patch) | |
tree | f7ae3f0ee13b06fb47247b1ef760a2274194c11e /src/printsupport/kernel/qplatformprintersupport.cpp | |
parent | 5eeed00f4d01d5033594854399a33d6ec54c3e58 (diff) |
QPlatformPrintDevice - New QPA base class
Add a new QPA class to abstract Print Devices. Each platform instance
will encapsulate all required details about a print device instead of
the code being distributed throughout the print engine and print
plugin.
Change-Id: I7f6a537ad55a6e7f599d83f461b1e2ee62b15094
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
Diffstat (limited to 'src/printsupport/kernel/qplatformprintersupport.cpp')
-rw-r--r-- | src/printsupport/kernel/qplatformprintersupport.cpp | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/src/printsupport/kernel/qplatformprintersupport.cpp b/src/printsupport/kernel/qplatformprintersupport.cpp index 4d80e55ab6..cddf979928 100644 --- a/src/printsupport/kernel/qplatformprintersupport.cpp +++ b/src/printsupport/kernel/qplatformprintersupport.cpp @@ -40,10 +40,12 @@ ****************************************************************************/ #include "qplatformprintersupport.h" +#include "qplatformprintdevice.h" #include <QtPrintSupport/qprinterinfo.h> #include <private/qprinterinfo_p.h> +#include <private/qprintdevice_p.h> #ifndef QT_NO_PRINTER @@ -77,6 +79,32 @@ QPaintEngine *QPlatformPrinterSupport::createPaintEngine(QPrintEngine *, QPrinte return 0; } +QPrintDevice QPlatformPrinterSupport::createPrintDevice(QPlatformPrintDevice *device) +{ + return QPrintDevice(device); +} + +QPrintDevice QPlatformPrinterSupport::createPrintDevice(const QString &id) +{ + Q_UNUSED(id) + return QPrintDevice(); +} + +QPrintDevice QPlatformPrinterSupport::createDefaultPrintDevice() +{ + return createPrintDevice(defaultPrintDeviceId()); +} + +QStringList QPlatformPrinterSupport::availablePrintDeviceIds() const +{ + return QStringList(); +} + +QString QPlatformPrinterSupport::defaultPrintDeviceId() const +{ + return QString(); +} + QList<QPrinter::PaperSize> QPlatformPrinterSupport::supportedPaperSizes(const QPrinterInfo &) const { return QList<QPrinter::PaperSize>(); |