Skip to content

Commit

Permalink
wlserver: Clear x11_surface when content override is destroyed
Browse files Browse the repository at this point in the history
  • Loading branch information
misyltoad committed Apr 9, 2024
1 parent 676a069 commit decc450
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions src/wlserver.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -611,6 +611,13 @@ static struct wl_listener new_surface_listener = { .notify = wlserver_new_surfac

void gamescope_xwayland_server_t::destroy_content_override( struct wlserver_content_override *co )
{
if ( co->surface )
{
wlserver_wl_surface_info *wl_surface_info = get_wl_surface_info( co->surface );
if ( wl_surface_info )
wl_surface_info->x11_surface = nullptr;
}

if ( co->gamescope_swapchain )
{
gamescope_swapchain_send_retired(co->gamescope_swapchain);
Expand Down

0 comments on commit decc450

Please sign in to comment.