Honor opacity prop if set
If opacity prop is explicitly set on the window, active/inactive opacity shouldn't kick in.
This commit is contained in:
parent
91ca387723
commit
66785aae99
|
@ -2377,9 +2377,10 @@ calc_opacity(session_t *ps, win *w) {
|
|||
opacity = 0;
|
||||
else {
|
||||
// Try obeying opacity property and window type opacity firstly
|
||||
if (OPAQUE == (opacity = w->opacity_prop)) {
|
||||
if(w->has_opacity_prop)
|
||||
opacity = w->opacity_prop;
|
||||
else {
|
||||
opacity = ps->o.wintype_opacity[w->window_type] * OPAQUE;
|
||||
}
|
||||
|
||||
// Respect inactive_opacity in some cases
|
||||
if (ps->o.inactive_opacity && false == w->focused
|
||||
|
@ -2391,6 +2392,7 @@ calc_opacity(session_t *ps, win *w) {
|
|||
if (OPAQUE == opacity && ps->o.active_opacity && win_is_focused_real(ps, w))
|
||||
opacity = ps->o.active_opacity;
|
||||
}
|
||||
}
|
||||
|
||||
w->opacity_tgt = opacity;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue