Merge pull request #9899 from igorkorsukov/bugs/9890_crash_on_open_editstyle

Fixed crash on open edit style dialog
This commit is contained in:
Elnur Ismailzada 2021-11-26 11:16:24 -08:00 committed by GitHub
commit 80c24598eb
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -512,7 +512,7 @@ void UiTheme::drawPrimitive(QStyle::PrimitiveElement element, const QStyleOption
} break;
case QStyle::PE_FrameFocusRect: {
bool isTreeWidget = option->styleObject->inherits("QTreeWidget");
bool isTreeWidget = option->styleObject && option->styleObject->inherits("QTreeWidget");
if (isTreeWidget) {
drawRoundedRect(painter, option->rect, 1, NO_FILL, QPen(fontPrimaryColor(), navCtrlBorderWidth()));
}