Fix a crash when calling effectiveWinId() on parentless widgets.
authorFriedemann Kleint <Friedemann.Kleint@nokia.com>
Thu, 7 Jun 2012 10:37:10 +0000 (12:37 +0200)
committerQt by Nokia <qt-info@nokia.com>
Fri, 8 Jun 2012 06:02:13 +0000 (08:02 +0200)
commit94a81928ac3ba8fc0ccb17eba7328cba5be56323
treee557e2dec069d41d22ae0f6be106489a67c390be
parent21e0d164110a4a1ff824e4014957353765542c2d
Fix a crash when calling effectiveWinId() on parentless widgets.

Remove the assert as it also triggers when the widget is one
that currently has no parent (setParent(0)).
Check that the WinId is != 0 in the cursor code.

Change-Id: I711fc600f1d803c8f01c15df87984e742a4c23d2
Reviewed-by: Miikka Heikkinen <miikka.heikkinen@digia.com>
Reviewed-by: Girish Ramakrishnan <girish.1.ramakrishnan@nokia.com>
src/widgets/kernel/qwidget.cpp
src/widgets/kernel/qwidget_qpa.cpp