mirror of
https://gitlab.freedesktop.org/wlroots/wlroots.git
synced 2025-10-31 22:25:21 -04:00
compositor: don't call role unmap hook without an object
This commit is contained in:
parent
0f67580aab
commit
fc9b58e84d
2 changed files with 5 additions and 1 deletions
|
|
@ -752,7 +752,8 @@ void wlr_surface_unmap(struct wlr_surface *surface) {
|
|||
}
|
||||
surface->mapped = false;
|
||||
wl_signal_emit_mutable(&surface->events.unmap, NULL);
|
||||
if (surface->role != NULL && surface->role->unmap != NULL) {
|
||||
if (surface->role != NULL && surface->role->unmap != NULL &&
|
||||
(surface->role_data != NULL || surface->role->no_object)) {
|
||||
surface->role->unmap(surface);
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue