Re: [PATCH wayland] client: add wl_proxy_get_version function

2014-10-24 Thread Pekka Paalanen
On Mon, 06 Oct 2014 11:43:56 +0300 Rémi Denis-Courmont wrote: > Le 2014-10-06 11:26, Pekka Paalanen a écrit : > >> > 4 or higher as a wl_surface version 3? If not, I cannot rely on > >> > 'wl_proxy_get_version(surface) >= 2'... > >> > >> Changing the semantics[5] of wl_surface.damage is a good ex

Re: [PATCH wayland] client: add wl_proxy_get_version function

2014-10-07 Thread Pekka Paalanen
On Mon, 06 Oct 2014 13:09:05 +0300 Rémi Denis-Courmont wrote: > Le 2014-10-06 12:52, Pekka Paalanen a écrit : > > Could this be solved (completely?) by saying that libraries that take > > existing wl_proxy objects such that they > > a) set up listeners, or > > b) create new wl_proxies from it and

Re: [PATCH wayland] client: add wl_proxy_get_version function

2014-10-06 Thread Jason Ekstrand
On Oct 6, 2014 12:45 AM, "Pekka Paalanen" wrote: > > Re-adding CCs and some more... > > On Mon, 06 Oct 2014 09:17:41 +0300 > Rémi Denis-Courmont wrote: > > > Hello, > > > > Le 2014-10-06 03:29, Jason Ekstrand a écrit : > > > Remi, > > > While this would probably be nice, your approach isnt go

Re: [PATCH wayland] client: add wl_proxy_get_version function

2014-10-06 Thread Rémi Denis-Courmont
Le 2014-10-06 12:52, Pekka Paalanen a écrit : Could this be solved (completely?) by saying that libraries that take existing wl_proxy objects such that they a) set up listeners, or b) create new wl_proxies from it and set their listeners; need to also offer API to tell which versions of the passe

Re: [PATCH wayland] client: add wl_proxy_get_version function

2014-10-06 Thread Rémi Denis-Courmont
Le 2014-10-06 11:26, Pekka Paalanen a écrit : > 4 or higher as a wl_surface version 3? If not, I cannot rely on > 'wl_proxy_get_version(surface) >= 2'... Changing the semantics[5] of wl_surface.damage is a good example where this would fail indeed. If a library only knows up to version 3, but

Re: [PATCH wayland] client: add wl_proxy_get_version function

2014-10-06 Thread Pekka Paalanen
On Mon, 6 Oct 2014 10:45:14 +0300 Pekka Paalanen wrote: > Re-adding CCs and some more... > > On Mon, 06 Oct 2014 09:17:41 +0300 > Rémi Denis-Courmont wrote: > > > Hello, > > > > Le 2014-10-06 03:29, Jason Ekstrand a écrit : > > > Remi, > > > While this would probably be nice, your approac

Re: [PATCH wayland] client: add wl_proxy_get_version function

2014-10-06 Thread Pekka Paalanen
Re-adding CCs and some more... On Mon, 06 Oct 2014 09:17:41 +0300 Rémi Denis-Courmont wrote: > Hello, > > Le 2014-10-06 03:29, Jason Ekstrand a écrit : > > Remi, > > While this would probably be nice, your approach isnt going to work.  > > Yeah, I figured that much after I submitted the pa

Re: [PATCH wayland] client: add wl_proxy_get_version function

2014-10-05 Thread Rémi Denis-Courmont
Hello, Le 2014-10-06 03:29, Jason Ekstrand a écrit : Remi, While this would probably be nice, your approach isnt going to work.  Yeah, I figured that much after I submitted the patch. And then I rediscovered that the client library does not actually know the version of the project objects

Re: [PATCH wayland] client: add wl_proxy_get_version function

2014-10-05 Thread Jason Ekstrand
Remi, While this would probably be nice, your approach isn't going to work. The version provided in wl_interface is the version that was compiled into libwayland, not the version requested when the global was bound. In order to get this correct, it requires a bit more tracking. I did implement t

Re: [PATCH wayland] client: add wl_proxy_get_version function

2014-10-05 Thread Rémi Denis-Courmont
Nevermind, that gets the version number of the client protocol library, not the version actually instantiated for the object :-( -- Rémi Denis-Courmont http://www.remlab.net/ ___ wayland-devel mailing list wayland-devel@lists.freedesktop.org http://li

[PATCH wayland] client: add wl_proxy_get_version function

2014-10-05 Thread Rémi Denis-Courmont
In some scenarii, a component will obtain a reference to a proxy object created by another component. It may then be necessary to check the interface version of the proxy object at run-time to determine if a certain interface request is supported by the proxy object. For instance, a media player G