x11: Look up reason for selection clear events from XFixes

If the event originates from a XSetSelectionOwner request, the event
will contain a XFixesSetSelectionOwnerNotify subtype. The other
subtypes (meant for the selection window being destroyed, and the
client closing) are the situations where we mean to replace the
selection.

Fixes: #1268

!1350
6 jobs for !1350 with wip/carlosg/xfixes-subtype in 8 minutes and 51 seconds (queued for 1 second)
latest detached
Status Job ID Name Coverage
  Review
passed #793679
check-commit-log

00:00:26

 
  Build
passed #793680
build-mutter

00:04:04

passed #793682
build-without-native-backend-and-wayland

00:03:00

passed #793681
build-without-opengl-and-glx

00:03:40

 
  Test
passed #793684
can-build-gnome-shell

00:01:23

passed #793683
test-mutter

00:04:21