[PATCH 3/3] Add a release request on wl_seat

Jonas Ã…dahl jadahl at gmail.com
Wed Sep 23 16:59:06 PDT 2015


On Wed, Sep 23, 2015 at 11:17:33AM -0500, Derek Foreman wrote:
> On 25/02/15 08:03 AM, David FORT wrote:
> > This is required if we want to correctly remove a wl_seat server-side.
> > ---
> >  protocol/wayland.xml | 6 ++++++
> >  1 file changed, 6 insertions(+)
> > 
> > diff --git a/protocol/wayland.xml b/protocol/wayland.xml
> > index 4fb8035..8f63ebf 100644
> > --- a/protocol/wayland.xml
> > +++ b/protocol/wayland.xml
> > @@ -1400,6 +1400,12 @@
> >        <arg name="name" type="string"/>
> >      </event>
> >  
> > +    <!-- Version 3 additions -->
> > +
> > +    <request name="release" type="destructor" since="3">
> > +      <description summary="release the seat object"/>
> > +    </request>
> > +
> 
> wl_seat appears to currently be version="4", so I guess we'd have to
> bump the since= and the version in the comment... (and probably the
> version of wl_seat as well)

Yes. And we should bump the version of wl_pointer, wl_touch and
wl_keyboard as part of it, just to make things clearer.

> 
> Unfortunately, I don't think this is necessary or sufficient to solve
> the problem at hand (RDP compositor connections are new seats, once apps
> bind these seats they're essentially leaked forever even after RDP
> client disconnect)
> 
> It's unnecessary because we already can remove seats once all clients
> using them close (I don't feel this is realistic, though)
> 
> It's insufficient because we don't have a way to tell a client the seat
> it currently has isn't going to provide any more input ever.
> 
> However, I think if we're ever going to kill this problem we'll need
> this destructor, so if the version numbers are updated appropriately:
> 
> Reviewed-by: Derek Foreman <derekf at osg.samsung.com>
> 
> We'll still need a way to tell the client the seat it has is
> dead/inert/whatever.  I don't think we can rely on the existing
> capabilities being empty, since with libinput backed seats it may be
> worthwhile for a toolkit/app to keep those seats to retain state in case
> the devices are plugged back in.
> 
> That is, there's a difference between a disconnected RDP client and a
> libinput backed seat with no devices left in it.
> 
> Would a new seat event (say, "removed") solve this sufficiently?

Wouldn't the global advertisement being removed be enough? Every seat is
advertised individually in the registry, and removing it there should
IMO be interpreted as there no longer any use for objects that was bound
to the that global.


Jonas

> 
> >    </interface>
> >  
> >    <interface name="wl_pointer" version="3">
> > 
> 
> _______________________________________________
> wayland-devel mailing list
> wayland-devel at lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/wayland-devel


More information about the wayland-devel mailing list