pointer/keyboard: Make sure not to get stale on client resources as well
Both the pointer/keyboard resource and surface resource can be destroyed at any point in the destruction process, so we need to have destroy listeners on both. To make the code easier to follow, rename ->focus to ->focus_surface at the same time, and rearrange the code so that the two of them are always grouped together.
This commit is contained in:
@@ -46,9 +46,11 @@ struct _MetaWaylandPointerGrab
|
||||
struct _MetaWaylandPointer
|
||||
{
|
||||
struct wl_list resource_list;
|
||||
MetaWaylandSurface *focus;
|
||||
struct wl_resource *focus_resource;
|
||||
|
||||
MetaWaylandSurface *focus_surface;
|
||||
struct wl_listener focus_surface_listener;
|
||||
struct wl_resource *focus_resource;
|
||||
struct wl_listener focus_resource_listener;
|
||||
guint32 focus_serial;
|
||||
guint32 click_serial;
|
||||
|
||||
|
Reference in New Issue
Block a user