Go to file
John Layt 5bd5f6ae69 QtPrintSupport: Change QPrinterInfo::defaultPrinter() behaviour
In Qt4 QPrinterInfo::defaultPrinter() has inconsistant behaviour
depending on the platform.  On Mac and Unix if no default printer
is set in the system then the first available printer is returned.
but on Windows it returns a null QPrinterInfo.

Currently Qt5 returns the first printer on all platforms, but this
causes an inconsistency if you call isDefault() on the returned
QPrinterInfo.

The apidox is slightly ambiguous, but does seem to imply no printer
will be returned if no default is set.

The only place in Qt the public api is used is in QPrinter which is
coded expecting that defaultPrinter() may return null but for there
still to be availablePrinters().

Change-Id: I1bbef8cba259b7d51980a0199e9fd6d5466d921f
Reviewed-by: Teemu Katajisto <teemu.katajisto@digia.com>
Reviewed-by: John Layt <jlayt@kde.org>
2012-05-29 00:41:46 +02:00
bin Fix qpa legacy headers installation 2012-05-09 06:42:25 +02:00
config.tests configure: Remove the -dwarf2 argument for Mac OS X builds 2012-05-11 12:52:21 +02:00
dist Make QCoreApp::translate and related methods use UTF-8 2012-05-18 21:38:35 +02:00
doc Doc: Add a default license footer. 2012-05-11 17:39:13 +02:00
examples Replace QVariant::typeToName usage by QMetaType::typeName call. 2012-05-28 03:30:21 +02:00
lib Initial import from the monolithic Qt. 2011-04-27 12:05:43 +02:00
mkspecs Introduce a Snowball mkspec to the device specs 2012-05-25 00:19:37 +02:00
qmake Add Visual Studio 11 mkspec 2012-05-16 13:34:20 +02:00
src QtPrintSupport: Change QPrinterInfo::defaultPrinter() behaviour 2012-05-29 00:41:46 +02:00
tests Eliminate QTreeWidget drag crash 2012-05-28 16:49:56 +02:00
tools Windows-configure.exe: Do not print licensing info in log. 2012-05-21 16:02:06 +02:00
util Move ScriptSentinel enum from header to .cpp 2012-05-25 21:48:44 +02:00
.gitattributes Added .tag file with Git revision. 2011-05-03 16:23:49 +02:00
.gitignore Add imports directory to ignore list 2012-04-11 01:42:12 +02:00
.tag Added .tag file with Git revision. 2011-05-03 16:23:49 +02:00
configure fix QT_GCC_*_VERSION definition after exception option removal 2012-05-25 14:52:36 +02:00
configure.bat Remove Q_BYTE_ORDER and -*-endian arguments from configures 2012-03-02 14:48:00 +01:00
header.BSD Remove "All rights reserved" line from license headers. 2012-01-30 03:54:59 +01:00
header.FDL Remove "All rights reserved" line from license headers. 2012-01-30 03:54:59 +01:00
header.LGPL Remove "All rights reserved" line from license headers. 2012-01-30 03:54:59 +01:00
header.LGPL-ONLY Remove "All rights reserved" line from license headers. 2012-01-30 03:54:59 +01:00
INSTALL Remove Symbian specific code from qtbase. 2012-01-31 07:08:31 +01:00
LGPL_EXCEPTION.txt Initial import from the monolithic Qt. 2011-04-27 12:05:43 +02:00
LICENSE.FDL Initial import from the monolithic Qt. 2011-04-27 12:05:43 +02:00
LICENSE.GPL Add the LICENSE.GPL file to the module referenced from license headers 2012-05-20 22:41:08 +02:00
LICENSE.LGPL Update contact information in license headers. 2012-01-23 04:04:33 +01:00
LICENSE.PREVIEW.COMMERCIAL Initial import from the monolithic Qt. 2011-04-27 12:05:43 +02:00
qtbase.pro device: Add -device and -device-option to configure 2012-03-27 05:35:57 +02:00
sync.profile Expose QPA API under qpa/* 2012-05-07 20:25:24 +02:00