Only set a simplewindow's opacity if there is a window
Technically setting the opacity of an invalid window doesn't hurt, but still it's nicer to catch this instead. Signed-off-by: Uli Schlachter <psychon@znc.in>
This commit is contained in:
parent
0b93a6a6a8
commit
c56453347e
|
@ -88,6 +88,7 @@ static inline void
|
||||||
simplewindow_opacity_set(simple_window_t *sw, double opacity)
|
simplewindow_opacity_set(simple_window_t *sw, double opacity)
|
||||||
{
|
{
|
||||||
sw->opacity = opacity;
|
sw->opacity = opacity;
|
||||||
|
if(sw->window != XCB_NONE)
|
||||||
window_opacity_set(sw->window, opacity);
|
window_opacity_set(sw->window, opacity);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue