summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTrond Kjernåsen <trond@trolltech.com>2009-05-08 08:20:27 (GMT)
committerTrond Kjernåsen <trond@trolltech.com>2009-05-08 08:26:40 (GMT)
commit184e36cfb62a50bba74d2563ca3284e64b610d40 (patch)
treedafff3a8426a1a7bfb3c69b61d1fb68c19e3f028
parent9ffcf3737901c49acb1a1bc6b65572d195d78a5d (diff)
downloadQt-184e36cfb62a50bba74d2563ca3284e64b610d40.zip
Qt-184e36cfb62a50bba74d2563ca3284e64b610d40.tar.gz
Qt-184e36cfb62a50bba74d2563ca3284e64b610d40.tar.bz2
Fixed a problem with QPrinter::NativeFormat printers not being valid.
It's obvious that not only PDF and PS printers are valid.. Task-number: related to 252873 Reviewed-by: Samuel
-rw-r--r--src/gui/painting/qprinter.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/gui/painting/qprinter.cpp b/src/gui/painting/qprinter.cpp
index 6cecf2c..5090b3a 100644
--- a/src/gui/painting/qprinter.cpp
+++ b/src/gui/painting/qprinter.cpp
@@ -773,8 +773,8 @@ void QPrinter::setOutputFormat(OutputFormat format)
if (def_engine)
delete oldPrintEngine;
- d->validPrinter = (d->outputFormat == QPrinter::PdfFormat
- || d->outputFormat == QPrinter::PostScriptFormat);
+ if (d->outputFormat == QPrinter::PdfFormat || d->outputFormat == QPrinter::PostScriptFormat)
+ d->validPrinter = true;
#else
Q_UNUSED(format);
#endif