Re: [PATCH] Introduce set_size_hints xdg_surface request.

2014-08-07 Thread Jari Vetoniemi
Relying only on maximized/fullscreen states to do tiling or hiding decorations feels bit nasty, as for client developers it's documented that fullscreen and maximized are indeed what they are. For example fullscreen application such as video player could hide controls in fullscreen mode, which is n

Re: [PATCH] Introduce set_size_hints xdg_surface request.

2014-08-07 Thread Pekka Paalanen
On Tue, 5 Aug 2014 22:07:39 +0300 Jari Vetoniemi wrote: > Rationale for this patch is to provide way for applications that can't go > below/above > certain bounds to inform compositor about it. > > More feedback is needed. For example are maximimum size useful for any > particular application?

Re: [PATCH wayland 6/6] server: Add a simple API to find a good default display

2014-08-07 Thread Pekka Paalanen
On Fri, 18 Jul 2014 11:05:03 +0200 Marek Chalupa wrote: > On 17 July 2014 19:54, Jasper St. Pierre wrote: > > > This allows compositors to easily select a good display to listen on. > > --- > > src/wayland-server.c | 97 > > ++-- > > src/wayland-

Re: [PATCH wayland 3/6] server: Split out code to initialize the socket address for a display name

2014-08-07 Thread Pekka Paalanen
On Thu, 17 Jul 2014 13:54:21 -0400 "Jasper St. Pierre" wrote: > We'll use this to autodetect a good socket to open on. > --- > src/wayland-server.c | 41 ++--- > 1 file changed, 26 insertions(+), 15 deletions(-) 79b1d2039aeb77b712cf4e1bb4049ebf9c453b59 is the

Re: [PATCH] server: fix error handling when adding socket

2014-08-07 Thread Pekka Paalanen
On Wed, 6 Aug 2014 11:21:59 +0200 Marek Chalupa wrote: > When some function during adding socket fails, it must clean > everything it set or we can get funky errors. > > This patch fixes: > http://lists.freedesktop.org/archives/wayland-devel/2014-August/016331.html > > Signed-off-by: Marek Cha

Re: [PATCH] server: move memset after check

2014-08-07 Thread Pekka Paalanen
On Wed, 6 Aug 2014 11:28:34 +0200 Marek Chalupa wrote: > If the malloc fails, memset would touch invalid memory. > --- > src/wayland-server.c | 3 ++- > 1 file changed, 2 insertions(+), 1 deletion(-) > > diff --git a/src/wayland-server.c b/src/wayland-server.c > index 75de313..3c162d4 100644 >

Re: [PATCH wayland 3/6] server: Split out code to initialize the socket address for a display name

2014-08-07 Thread Pekka Paalanen
On Thu, 7 Aug 2014 15:41:10 +0300 Pekka Paalanen wrote: > On Thu, 17 Jul 2014 13:54:21 -0400 > "Jasper St. Pierre" wrote: > > > We'll use this to autodetect a good socket to open on. > > --- > > src/wayland-server.c | 41 ++--- > > 1 file changed, 26 inserti

Re: [PATCH weston] desktop-shell: don't assume there's a pointer when mapping a popup

2014-08-07 Thread Pekka Paalanen
On Wed, 06 Aug 2014 11:51:26 +0200 Jonny Lamb wrote: > On mer, 2014-08-06 at 11:50 +0200, Jonny Lamb wrote: > > - if (shseat->seat->pointer->grab_serial == shsurf->popup.serial) { > > + if (shseat->seat->pointer && > > + shseat->seat->pointer->grab_serial == shsurf->popup.serial) { > >

Re: [PATCH 2/2] server: fix conditions for fds in wl_socket_destroy

2014-08-07 Thread Pekka Paalanen
On Wed, 6 Aug 2014 12:18:12 +0200 Marek Chalupa wrote: > The only value that is false with the former condition is 0. > On error we set fd to -1. > --- > src/wayland-server.c | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > > diff --git a/src/wayland-server.c b/src/wayland-server.

[PATCH wayland] server: fix conditions for fds in wl_socket_destroy

2014-08-07 Thread Pekka Paalanen
From: Pekka Paalanen 0 is also a valid fd, and needs to be closed. On error we set fd to -1. We need to also initialize fds to -1, so we do not accidentally close stdout on error. While fixing this, also remove one use-before-NULL-check. Based on the patch by Marek. Cc: Marek Chalupa Signed-

[PATCH wayland] server: Don't expose wl_display as a global

2014-08-07 Thread Jasper St. Pierre
The idea here was that once upon a time, clients could rebind wl_display to a higher version, so we offered the ability to rebind it here. However, this is particularly broken. The existing bind implementation actually still hardcodes version numbers, and it leaks previous resources, overwriting th

Re: [PATCH wayland] server: fix conditions for fds in wl_socket_destroy

2014-08-07 Thread Jasper St. Pierre
Reviewed-by: Jasper St. Pierre On Thu, Aug 7, 2014 at 9:51 AM, Pekka Paalanen wrote: > From: Pekka Paalanen > > 0 is also a valid fd, and needs to be closed. > > On error we set fd to -1. We need to also initialize fds to -1, so we do > not accidentally close stdout on error. > > While fixing

Re: [PATCH] Introduce set_size_hints xdg_surface request.

2014-08-07 Thread Jari Vetoniemi
> What is the default value of these hints? I would propose -1 as default, meaning unset. Compositor has to deal with not knowing the minimum size, preferably this would mean though that the client can be set to any valid size. > When is the client expected to send this? Can this be sent before >

Re: [PATCH wayland 0/6] Introduce API to automatically find a good default display

2014-08-07 Thread Jason Ekstrand
Sorry for not posting to the ML, but this looked good so I pushed it. --Jason On Thu, Jul 17, 2014 at 10:54 AM, Jasper St. Pierre wrote: > This patch series introduces a new API to find an open Wayland display > so that compositors don't need to reimplement all this code. This way, > the code s

Re: wayland: new socket addition

2014-08-07 Thread Jason Ekstrand
On Wed, Aug 6, 2014 at 1:31 AM, Marek Chalupa wrote: > Hi, > > After the new patches for socket automatic naming the socket test, namely > socket_path_overflow_server_create, fails. Probably introduced in > 79b1d2039aeb77b712cf4e1bb4049ebf9c453b59. It does not set errno as > expected: > > error:

Re: [PATCH] Introduce set_size_hints xdg_surface request.

2014-08-07 Thread Bill Spitzak
On 08/07/2014 07:18 AM, Jari Vetoniemi wrote: >> What is the default value of these hints? I think you could get away with defaulting the minimum to be about 100x100. I think that is sufficient to get clients to work ok and it is small enough to encourage them to set this rather than relying on

[PATCH weston 4/4] screenshooter: Add a missing return; in an error path

2014-08-07 Thread Jasper St. Pierre
--- src/screenshooter.c | 1 + 1 file changed, 1 insertion(+) diff --git a/src/screenshooter.c b/src/screenshooter.c index 9ae0d29..4403933 100644 --- a/src/screenshooter.c +++ b/src/screenshooter.c @@ -265,6 +265,7 @@ bind_shooter(struct wl_client *client, if (client != shooter->client)

[PATCH weston 2/4] Don't bother destroying resources after sending an error

2014-08-07 Thread Jasper St. Pierre
An error makes the client exit, which cleans up the resources anyway. --- desktop-shell/input-panel.c | 1 - desktop-shell/shell.c | 2 -- src/screenshooter.c | 1 - src/text-backend.c | 2 -- 4 files changed, 6 deletions(-) diff --git a/desktop-shell/input-panel.c b/deskto

[PATCH weston 1/4] Use the named SINCE_VERSION defines for version checks

2014-08-07 Thread Jasper St. Pierre
To make our code more clear. --- src/compositor.c | 4 ++-- src/input.c | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/compositor.c b/src/compositor.c index 55c959e..4d6a02a 100644 --- a/src/compositor.c +++ b/src/compositor.c @@ -3145,7 +3145,7 @@ bind_output(stru

[PATCH weston 3/4] desktop-shell: Add a missing return; in an error path

2014-08-07 Thread Jasper St. Pierre
--- desktop-shell/shell.c | 1 + 1 file changed, 1 insertion(+) diff --git a/desktop-shell/shell.c b/desktop-shell/shell.c index 250cf88..7370972 100644 --- a/desktop-shell/shell.c +++ b/desktop-shell/shell.c @@ -3741,6 +3741,7 @@ xdg_get_xdg_popup(struct wl_client *client, wl_res

[PATCH libinput 2/2 v2] tablet: Add libinput_tool_has_axis() and tests

2014-08-07 Thread Stephen Chandler Paul
Because the axes that tool reports can change depending on the tool in use, we want to be able to provide functionality to determine which axes each tool can support. Signed-off-by: Stephen Chandler Paul --- Changes: - Added a description to the patch - Fixed all of the memory le

[PATCH libinput 1/2 v2] tablet: Use separate tool objects for tools without serials

2014-08-07 Thread Stephen Chandler Paul
With tablets that don't support serial numbers, we can't guarantee that the tool objects are unique. Because of this, this can give clients the false impression that a tool without a serial number is being shared between tablets when it very well might not be. So we keep tools without serial number

[PATCH libinput v3] tablet: Use separate tool objects for tools without serials

2014-08-07 Thread Stephen Chandler Paul
With tablets that don't support serial numbers, we can't guarantee that the tool objects are unique. Because of this, this can give clients the false impression that a tool without a serial number is being shared between tablets when it very well might not be. So we keep tools without serial number

Re: [PATCH libinput v3] tablet: Use separate tool objects for tools without serials

2014-08-07 Thread Peter Hutterer
On Thu, Aug 07, 2014 at 07:00:52PM -0400, Stephen Chandler Paul wrote: > With tablets that don't support serial numbers, we can't guarantee that the > tool > objects are unique. Because of this, this can give clients the false > impression > that a tool without a serial number is being shared bet

Re: [PATCH libinput 2/2 v2] tablet: Add libinput_tool_has_axis() and tests

2014-08-07 Thread Peter Hutterer
On Thu, Aug 07, 2014 at 06:54:55PM -0400, Stephen Chandler Paul wrote: > Because the axes that tool reports can change depending on the tool in use, we > want to be able to provide functionality to determine which axes each tool can > support. > > Signed-off-by: Stephen Chandler Paul > --- > > C

[PATCH libinput v3] tablet: Add libinput_tool_has_axis() and tests

2014-08-07 Thread Stephen Chandler Paul
Because the axes that tool reports can change depending on the tool in use, we want to be able to provide functionality to determine which axes each tool can support. Signed-off-by: Stephen Chandler Paul --- = Changes = * Fixed the line width in test/tablet.c * Removed libinput_tool_axis

Re: [PATCH libinput v3] tablet: Add libinput_tool_has_axis() and tests

2014-08-07 Thread Peter Hutterer
On Thu, Aug 07, 2014 at 10:02:22PM -0400, Stephen Chandler Paul wrote: > Because the axes that tool reports can change depending on the tool in use, we > want to be able to provide functionality to determine which axes each tool can > support. > > Signed-off-by: Stephen Chandler Paul > --- merge

[PATCH libinput] touchpad: increase top software button area to 15%

2014-08-07 Thread Peter Hutterer
We had reports that the top software button area is hard to hit for those using the trackpoint and clicking the buttons with their thumb. Analysis of event recordings (3 different people) for left, right and middle clicks shows that there is a significant amount of events up to about 10mm (with ou

Re: [PATCH wayland] server: fix conditions for fds in wl_socket_destroy

2014-08-07 Thread Pekka Paalanen
On Thu, 7 Aug 2014 09:56:59 -0400 "Jasper St. Pierre" wrote: > Reviewed-by: Jasper St. Pierre Thanks, pushed. - pq > On Thu, Aug 7, 2014 at 9:51 AM, Pekka Paalanen wrote: > > > From: Pekka Paalanen > > > > 0 is also a valid fd, and needs to be closed. > > > > On error we set fd to -1. We n

Re: [PATCH] Introduce set_size_hints xdg_surface request.

2014-08-07 Thread Pekka Paalanen
On Thu, 7 Aug 2014 17:18:54 +0300 Jari Vetoniemi wrote: > > What is the default value of these hints? > > I would propose -1 as default, meaning unset. > Compositor has to deal with not knowing the minimum size, preferably > this would mean though that the client can be set to any valid size. >