Fix T78630: Custom icons not grayed out in inactive layouts

For regular icons this worked because they used the text color, which
was already grayed out by the caller.
This commit is contained in:
Julian Eisel
2020-08-05 12:12:05 +02:00
parent de53178b26
commit c3113724ed

View File

@@ -1401,7 +1401,7 @@ static void widget_draw_icon(
}
}
else if (ELEM(but->type, UI_BTYPE_BUT)) {
if (but->flag & UI_BUT_DISABLED) {
if (but->flag & (UI_BUT_DISABLED | UI_BUT_INACTIVE)) {
alpha *= 0.5f;
}
}