suicide assertion added

This commit is contained in:
Uwe Rathmann 2019-04-18 16:12:33 +02:00
parent 126fb5b9bd
commit 3c8cea78ee

View File

@ -543,6 +543,14 @@ QskControl::QskControl( QQuickItem* parent )
QskControl::~QskControl()
{
#if defined( QT_DEBUG )
if ( auto w = window() )
{
// to catch suicide situations as a result of mouse clicks
Q_ASSERT( this != w->mouseGrabberItem() );
}
#endif
if ( qskRegistry )
qskRegistry->remove( this );