Set correct transient parent in q_createNativeChildrenAndSetParent().

Fix warning:
void QWindow::setTransientParent(QWindow*) ... must be a top level window.
which occurred for example when parenting a QMenu onto a native child
widget.

Task-number: QTBUG-41898
Change-Id: Icc25fb2108bd68b2d9c0e551949b90fc7a82d358
Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
OS X - maximize app's window from the Dock or using cmd-tab

On OS X it's possible to maximize app's window by clicking on an app's
icon in the Dock.
Another trick is to use cmd-tab to select an app +,
while still holding the 'cmd' key, press the 'option' key -
this should also maximize a window.
None of these works at the moment, and to enable these features app
delegate should return YES from the

-applicationShouldHandleRepopen:hasVisibleWindows:.

method.

Task-number: QTBUG-40084
Change-Id: I33ba9e74d55d41d23deb429612519b746d461d9e
Reviewed-by: Timur Pocheptsov <Timur.Pocheptsov@digia.com>
Reviewed-by: Morten Johan Sørvig <morten.sorvig@digia.com>
Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
OS X - unified toolbar and AA_NativeWindows

In some cases QToolBar creates a child window (a child borderless NSWindow)
placed on top of the toolbar's  main window. As a result it's not possible
to drag this main window using its toolbar - the window "jumps" on the screen.
The reason is quite subtle - QNSView -handleMouseEvent: uses
[NSEvent mouseLocation] and this location is invalid:

- we have an NSWindow (parent)
- we have a child NSWindow ([parent addChildWindow:child ....]
- we handle drag event in a child window
- we move a parent window as a result of drag event
- Cocoa also moves a child window for us
- when handling the  next drag event, location [NSEvent mouseLocation]
  differs from the real event's location.

Task-number: QTBUG-40106
Change-Id: Ic68cb92ab4233a1e0746b478820c1e33fd37a462
Reviewed-by: Morten Johan Sørvig <morten.sorvig@digia.com>
OS X: Retina displays and blurry QToolButton

Checkable QToolButton has a special pixmap in the background,
painted with a 'smooth pixmaps' hint. This hint also affects
how an icon on a toolbutton itself is painted later. The difference
can be quite visible on a Retina display, so this patch makes the toolbutton's
image always look the same in checked/unchecked state.

Task-number: QTBUG-35162
Change-Id: I2adc8006371fa10d89d4b77da6b3aa168aa5abc8
Reviewed-by: Morten Johan Sørvig <morten.sorvig@digia.com>
Produce more correct clip path for QGraphicsShapeItem

If no pen is set on the item, we can completely ignore the
pen for the creation of the items shape. This both speeds
up the creation of the shape and applying it as a clip mask
as well as creating more correct results.

Task-number: QTBUG-32846
Change-Id: I5f6f690256c71309713d8f746e67599af3088dd7
Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
Correctly apply miter limits when stroking lines

The PDF generator was in many cases not correctly
applying miter limits to the generated strokes leading
to drawing artifacts for very sharp edges.

Task-number: QTBUG-37903
Change-Id: Ie93b0f4a56775729105a375ba3bcdb5b58993433
Reviewed-by: Gunnar Sletta <gunnar@sletta.org>
Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>