Cocoa: avoid a crash in QCocoaDrag

NSEvent needs to be copied.

Reference:
http://lists.apple.com/archives/cocoa-dev/2007/Dec/msg00678.html

Task-number: QTBUG-33533
Change-Id: I73709545573e59aab6875a8c3dd903cb171e858f
Reviewed-by: Jake Petroules <jake.petroules@petroules.com>
Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@digia.com>
Fix invalid memory read when shutting down QML applications

As the last line in the QObject destructor, we call setParentHelper(0) to
remove ourselves from the parent. In the process of that we also initiate the
QML parentChanged callback. The first thing that parentChanged callback used to
do (but now does it too late, after 26350b5ceafa0ade1328037f6234a7d288eb8f48 in
qtdeclarative) is to check if the object was deleted and then return. We could
re-introduce the check there, but I think it's cleaner to not bother calling
the callback on a dead object in the first place.

Change-Id: Ia4d43b65a9b3744a451b4c312a2d6f9c0e3b67dc
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
Update ChangeLog for 5.2.0 [QtWidgets II]

Second batch of changes.

Change-Id: I5b3add1df19bcad195f8b9286337de9fe926337c
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
iOS: Forward [UIApplicationDelegate handleOpenURL:] to QDesktopServices

The user may use QDesktopServices::setUrlHandler() in combination with
the appropriate Info.plist keys (CFBundleURLTypes, CFBundleURLSchemes)
to react to URL requests from other applications.

This is among other things useful for handling OAuth authentication from
applications such as Dropbox. See:

  https://www.dropbox.com/developers/core/start/ios

We protect against recursive URL opening, but an application may still
redirect a request to open a URL by opening another URL, eg a website.

Task-number: QTBUG-35201
Change-Id: I9f1d246206c5594b1b65bb11fa98c6bcdefc443e
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@digia.com>
iOS: Update screen properties when we trigger statusbar changes on iOS7

Ideally we'd have a callback from iOS when this happens, so we can also
react to changes done outside of Qt, but willChangeStatusBarFrame and
friends do not seem to give us what we want.

Change-Id: I686ce7950395a83c4257372363c773a95c3935ed
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@digia.com>
iOS: Provide default launch image for 4-inch devices

Otherwise the application will not scale to the full resolution of
the device. We copy the image into the Xcode project, since it's
internal to our build system and not meant as a template to be
edited by the user.

For 5.3 we need to provide a proper qmake/qbs mechanism to handle
launch images.

Task-number: QTBUG-31431
Change-Id: Ied0b2843a78c5ea865750e0404418ced7ad27082
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@digia.com>
Add a few notes to changes-5.2.0

Mostly changes for Android. One change in Qt Gui.

Change-Id: Ifce627b6688702b3a3ae1634bd344eb8331f6caf
Reviewed-by: Paul Olav Tvete <paul.tvete@digia.com>
Reviewed-by: BogDan Vatra <bogdan@kde.org>
Doc: corrected invalid ref. to output iterators

Task-number: QTBUG-34749
Change-Id: I7abd504b6081e84a8e67c7957e13d402999e9d38
Reviewed-by: Martin Smith <martin.smith@digia.com>
Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
Docs: add important QWheelEvent::phase() related notes

Change-Id: I4901b96b44b7c1179e678689af5962cb4570d50d
Reviewed-by: Jens Bache-Wiig <jens.bache-wiig@digia.com>
Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@digia.com>
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
Make OpenGL examples work on retina displays.

glViewport expects device pixels, but the various
geometry accessors returns values in device-independent
pixels.

Change-Id: I8004692de82251e4f1f25bf8f2698895f222ede3
Reviewed-by: Gunnar Sletta <gunnar.sletta@digia.com>
Merge remote-tracking branch 'origin/release' into stable

Change-Id: I2e2bf789b0fe8442ed623bc0c8aef591235cdabe
Merge "Merge remote-tracking branch 'origin/release' into stable" into refs/staging/stable
QPrinter - Fix OutputFormat when no printers

Currently the QPrinter constructor, setOutputFormat() and
setPrinterName() make bad assumptions about the availability of printers
when configuring NativeFormat which can lead to inconsistent print
engine set-ups leading to crashes in the print dialog, especially on
Windows where a valid DEVMODE is needed.

This change cleans up the init and methods to ensure NativeFormat can
only ever be set if we have both a valid plugin and a valid printer,
if not the PdfFormat is used.  One side-effect of this is that it is
now impossible to set an invalid printer name via QPrinter (but still
able to be done via QPrintEngine if really needed).  Also if no
default printer is set then use the first available one.

This also fixes a bug where setting a new printer name on Windows
reset all the saved settings.

[ChangeLog][Important Behavior Changes] QPrinter no longer allows you
to set an invalid printer name.

Task-number: QTBUG-34345
Task-number: QTBUG-26008
Task-number: QTBUG-26430
Change-Id: I19737e4209d8c8df5817ea83246b3dd0c483ee85
Reviewed-by: Gunnar Sletta <gunnar.sletta@digia.com>
QPrinter - Simplify setting manual properties

Change from a list to a set and define a utility method to both set the
property and store that we have set it.

Change-Id: I0cf13f1b0e90942424744316d0d3f699b9ead144
Reviewed-by: Gunnar Sletta <gunnar.sletta@digia.com>