Redundant condition: widget

Redundant condition: widget. '!widget || (widget && widget->isEnabled())'
is equivalent to '!widget || widget->isEnabled()'

Pick-to: 6.1
Change-Id: Ife915bd5ea66f8ccff48a1612f8c78c263075c89
Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com>
bb10
Huang Jie 2021-03-04 09:48:18 +08:00
parent 8a226cd76b
commit d3ec08eea0
1 changed files with 1 additions and 1 deletions

View File

@ -3223,7 +3223,7 @@ int QWindowsXPStyle::styleHint(StyleHint hint, const QStyleOption *option, const
break;
case SH_GroupBox_TextLabelColor:
if (!widget || (widget && widget->isEnabled()))
if (!widget || widget->isEnabled())
res = d->groupBoxTextColor;
else
res = d->groupBoxTextColorDisabled;