Guard QWidget::setStyleSheet() against invocation from destructor.
Task-number: QTBUG-45178 Change-Id: I3670d9cd9645155318b595d1324a3b3caf2352f6 Reviewed-by: Jørgen Lind <jorgen.lind@theqtcompany.com>
This commit is contained in:
parent
bc00e6da84
commit
d984b07221
@ -2608,6 +2608,8 @@ QString QWidget::styleSheet() const
|
|||||||
void QWidget::setStyleSheet(const QString& styleSheet)
|
void QWidget::setStyleSheet(const QString& styleSheet)
|
||||||
{
|
{
|
||||||
Q_D(QWidget);
|
Q_D(QWidget);
|
||||||
|
if (data->in_destructor)
|
||||||
|
return;
|
||||||
d->createExtra();
|
d->createExtra();
|
||||||
|
|
||||||
QStyleSheetStyle *proxy = qobject_cast<QStyleSheetStyle *>(d->extra->style);
|
QStyleSheetStyle *proxy = qobject_cast<QStyleSheetStyle *>(d->extra->style);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user