Skip to content
Permalink
Browse files

Don't set focusProxy in QgsCollapsibleGroupBoxBasic when compiled aga…

…inst Qt5.10+, it causes crashes
  • Loading branch information
manisandro committed Feb 19, 2018
1 parent a7ca742 commit ea9480ef0a7e706c5df5bc28d98dfde425727b7d
Showing with 4 additions and 0 deletions.
  1. +4 −0 src/gui/qgscollapsiblegroupbox.cpp
@@ -65,7 +65,11 @@ void QgsCollapsibleGroupBoxBasic::init()
// TODO set size (as well as margins) depending on theme, in updateStyle()
mCollapseButton->setIconSize( QSize( 12, 12 ) );
mCollapseButton->setIcon( mCollapseIcon );
// FIXME: This appears to mess up parent-child relationships and causes double-frees of children when destroying in Qt5.10, needs further investigation
// See also https://github.com/qgis/QGIS/pull/6301
#if QT_VERSION < QT_VERSION_CHECK(5, 10, 0)
setFocusProxy( mCollapseButton );
#endif
setFocusPolicy( Qt::StrongFocus );

connect( mCollapseButton, &QAbstractButton::clicked, this, &QgsCollapsibleGroupBoxBasic::toggleCollapsed );

0 comments on commit ea9480e

Please sign in to comment.
You can’t perform that action at this time.