From 4dad15f5914ad31b5303ea9b66d6619fb2c5bf4b Mon Sep 17 00:00:00 2001 From: Uwe Rathmann Date: Tue, 10 Mar 2020 10:28:39 +0100 Subject: [PATCH] assertion weakened to a warning --- src/controls/QskControl.cpp | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/src/controls/QskControl.cpp b/src/controls/QskControl.cpp index 0822c7ae..299b9d28 100644 --- a/src/controls/QskControl.cpp +++ b/src/controls/QskControl.cpp @@ -45,8 +45,12 @@ 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() ); + if( this == w->mouseGrabberItem() ) + { + // to catch suicide situations as a result of mouse clicks + qWarning() << "QskControl::~QskControl: probably suicide situation detected, control is the mouse grabber item" << this; + } + } #endif } @@ -901,6 +905,7 @@ void QskControl::updateItemPolish() We don't want to resize invisible children, but then we would need to set up connections to know when a child becomes visible. So we don't use qskIsVisibleToLayout here. + And what about using QskControl::LayoutOutWhenHidden ? */ if ( !qskIsTransparentForPositioner( child ) ) {