diff options
-rw-r--r-- | include/wlr/types/wlr_compositor.h | 2 | ||||
-rw-r--r-- | types/wlr_compositor.c | 3 |
2 files changed, 5 insertions, 0 deletions
diff --git a/include/wlr/types/wlr_compositor.h b/include/wlr/types/wlr_compositor.h index d67ce1c3..53e663fd 100644 --- a/include/wlr/types/wlr_compositor.h +++ b/include/wlr/types/wlr_compositor.h @@ -211,6 +211,8 @@ struct wlr_surface { int buffer_width, buffer_height; } previous; + bool unmap_commit; + bool opaque; bool has_buffer; diff --git a/types/wlr_compositor.c b/types/wlr_compositor.c index 15cb5f82..70c1f9cc 100644 --- a/types/wlr_compositor.c +++ b/types/wlr_compositor.c @@ -439,7 +439,10 @@ static void surface_commit_state(struct wlr_surface *surface, bool invalid_buffer = next->committed & WLR_SURFACE_STATE_BUFFER; if (invalid_buffer && next->buffer == NULL) { + surface->unmap_commit = surface->mapped; wlr_surface_unmap(surface); + } else { + surface->unmap_commit = false; } surface_update_damage(&surface->buffer_damage, &surface->current, next); |