Re: [PATCH weston 3/3] compositor: add an option to set the default numlock value

2014-08-21 Thread Daniel Stone
Hi, On Wednesday, August 20, 2014, Giulio Camuffo giuliocamu...@gmail.com wrote: Add a new numlock-on option in the [keyboard] section of weston.ini which, if set to true, is used to enable the numlock of the keyboards attached at startup. I'm fine with this in principle, but would like to

Re: [PATCH weston 1/3] evdev/libinput: sync the leds of keyboards with the xkb state

2014-08-21 Thread Daniel Stone
Hi, On Wednesday, August 20, 2014, Giulio Camuffo giuliocamu...@gmail.com wrote: When a new keyboard is found (including during startup) sync its leds with the internal state of the xkb map. It appears that by setting them immediately when getting the new device we're racing with the kernel

Re: [PATCH 2/2] compositor: add a way to change the keyboard leds

2014-08-21 Thread Daniel Stone
Hi, Last nitpick, sorry ... On Wednesday, August 20, 2014, Giulio Camuffo giuliocamu...@gmail.com wrote: + mods_depressed = xkb_state_serialize_mods(keyboard-xkb_state.state, + XKB_STATE_DEPRESSED); + mods_latched =

Re: [PATCH weston 1/3] evdev/libinput: sync the leds of keyboards with the xkb state

2014-08-21 Thread Giulio Camuffo
2014-08-21 10:34 GMT+03:00 Daniel Stone dan...@fooishbar.org: Hi, On Wednesday, August 20, 2014, Giulio Camuffo giuliocamu...@gmail.com wrote: When a new keyboard is found (including during startup) sync its leds with the internal state of the xkb map. It appears that by setting them

Re: [PATCH 2/2] tests: test the wl_display_roundtrip_queue() function

2014-08-21 Thread Marek Chalupa
Hi, On 20 August 2014 18:29, Giulio Camuffo giuliocamu...@gmail.com wrote: --- tests/queue-test.c | 62 ++ 1 file changed, 62 insertions(+) diff --git a/tests/queue-test.c b/tests/queue-test.c index a4b165d..fc8a920 100644 ---

Re: [PATCH] wl_surface: clarify the base of time passed in the callback of frame

2014-08-21 Thread Pekka Paalanen
On Thu, 21 Aug 2014 00:25:36 +0900 Ryo Munakata ryomnk...@gmail.com wrote: Signed-off-by: Ryo Munakata ryomnk...@gmail.com --- protocol/wayland.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/protocol/wayland.xml b/protocol/wayland.xml index 2d57f69..bb457bc 100644

Re: [PATCH 2/2] tests: test the wl_display_roundtrip_queue() function

2014-08-21 Thread Pekka Paalanen
On Thu, 21 Aug 2014 10:46:55 +0200 Marek Chalupa mchqwe...@gmail.com wrote: Hi, On 20 August 2014 18:29, Giulio Camuffo giuliocamu...@gmail.com wrote: --- tests/queue-test.c | 62 ++ 1 file changed, 62 insertions(+) diff

Re: [PATCH 2/2] tests: test the wl_display_roundtrip_queue() function

2014-08-21 Thread Marek Chalupa
The issues I pointed out are not anything big. I'll send a patch that removes wl_display_dispatch_pending from both test-cases and I noticed that there are more leaks it the queue-test, so I'll get rid of them all in another patch if it's OK :) Thanks, Marek On 21 August 2014 10:57, Pekka

Re: [PATCH wayland v3] protocol: define the concept of wl_surface role

2014-08-21 Thread Pekka Paalanen
On Wed, 20 Aug 2014 10:26:48 -0400 Jasper St. Pierre jstpie...@mecheye.net wrote: On Wed, Aug 20, 2014 at 7:09 AM, Pekka Paalanen ppaala...@gmail.com wrote: From: Pekka Paalanen pekka.paala...@collabora.co.uk Define what a role is, and what restrictions there are. A change to

Re: [PATCH 2/2] tests: test the wl_display_roundtrip_queue() function

2014-08-21 Thread Pekka Paalanen
On Thu, 21 Aug 2014 11:05:24 +0200 Marek Chalupa mchqwe...@gmail.com wrote: The issues I pointed out are not anything big. I'll send a patch that removes wl_display_dispatch_pending from both test-cases and I noticed that there are more leaks it the queue-test, so I'll get rid of them all in

Re: [PATCH wayland] gitignore: add ./message-test

2014-08-21 Thread Pekka Paalanen
On Mon, 7 Jul 2014 12:11:08 +0800 Guangyu Zhang zguangyu...@gmail.com wrote: ./message-test is generated by libtool and should be ignored by git. --- .gitignore | 1 + 1 file changed, 1 insertion(+) diff --git a/.gitignore b/.gitignore index c146bac..d9d26ed 100644 --- a/.gitignore

Re: [PATCH] option-parser: Don't read off the end of string options without an '='

2014-08-21 Thread Pekka Paalanen
On Thu, 21 Aug 2014 09:11:22 +1200 Robert Ancell robert.anc...@gmail.com wrote: Bill's patch looks a lot more comprehensive, I'd use that one. Ok, thank you. - pq On 21 August 2014 00:37, Pekka Paalanen ppaala...@gmail.com wrote: On Fri, 20 Jun 2014 15:23:59 +1200 Robert Ancell

[PATCH wayland v4 3/5] protocol: wl_data_device.start_drag may give a role

2014-08-21 Thread Pekka Paalanen
From: Pekka Paalanen pekka.paala...@collabora.co.uk Now that we have defined role, use the term. Signed-off-by: Pekka Paalanen pekka.paala...@collabora.co.uk --- protocol/wayland.xml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/protocol/wayland.xml

[PATCH wayland v4 1/5] protocol: define the concept of wl_surface role

2014-08-21 Thread Pekka Paalanen
From: Pekka Paalanen pekka.paala...@collabora.co.uk Define what a role is, and what restrictions there are. A change to existing behaviour is that a role cannot be changed at all once set. However, this is unlikely to cause problems, as there is no reason to re-use wl_surfaces in clients. v2:

[PATCH wayland v4 4/5] protocol: wl_subcompositor.get_subsurface gives a role

2014-08-21 Thread Pekka Paalanen
From: Pekka Paalanen pekka.paala...@collabora.co.uk Reword the conditions to make use of the definition of role. It is still forbidden to create more than one wl_subsurface for a wl_surface at a time. Signed-off-by: Pekka Paalanen pekka.paala...@collabora.co.uk --- protocol/wayland.xml | 6

[PATCH wayland v4 2/5] protocol: wl_pointer.set_cursor gives a role

2014-08-21 Thread Pekka Paalanen
From: Pekka Paalanen pekka.paala...@collabora.co.uk Now that we have defined role, use the term. Signed-off-by: Pekka Paalanen pekka.paala...@collabora.co.uk --- protocol/wayland.xml | 5 - 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/protocol/wayland.xml

[PATCH 3/3] client: remove unused variable

2014-08-21 Thread Marek Chalupa
display_thread variable is unused since 3c7e8bfbb4745315b7bcbf69fa746c3d6718c305 Signed-off-by: Marek Chalupa mchqwe...@gmail.com --- src/wayland-client.c | 1 - 1 file changed, 1 deletion(-) diff --git a/src/wayland-client.c b/src/wayland-client.c index 15a5acc..2252424 100644 ---

[PATCH 2/3] tests: remove unnecessary lines from queue-test

2014-08-21 Thread Marek Chalupa
Earlier, the wl_display_dispatch_pending were setting number of thread that can dispatch events. This behaviour was removed later, so now these lines are redundant. Related commits: 385fe30e8b144a968aa88c6546c2ef247771b3d7 78cfa967681c965d23f6cbf76e080bbb0b564ff6

[PATCH 1/3] tests: remove leaks from queue-test

2014-08-21 Thread Marek Chalupa
Destroy all objects that we have created Signed-off-by: Marek Chalupa mchqwe...@gmail.com --- tests/queue-test.c | 5 + 1 file changed, 5 insertions(+) diff --git a/tests/queue-test.c b/tests/queue-test.c index f7ebc2b..3de8924 100644 --- a/tests/queue-test.c +++ b/tests/queue-test.c @@

Re: [PATCH weston 3/3] shell: constrain resize grabs so titlebars don't go under the panel

2014-08-21 Thread Pekka Paalanen
On Thu, 21 Aug 2014 11:42:03 +0800 Boyan Ding stu_...@126.com wrote: Hi, On Wed, 2014-08-20 at 17:50 +0300, Pekka Paalanen wrote: Hi, on first glance, it looks like this completely ignores window rotation, but when I briefly tested on a rotated window, it seemed work well enough!

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

2014-08-21 Thread Pekka Paalanen
On Thu, 7 Aug 2014 09:55:49 -0400 Jasper St. Pierre jstpie...@mecheye.net wrote: 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

Re: [PATCH weston 3/3] compositor: add an option to set the default numlock value

2014-08-21 Thread Giulio Camuffo
2014-08-21 10:31 GMT+03:00 Daniel Stone dan...@fooishbar.org: Hi, On Wednesday, August 20, 2014, Giulio Camuffo giuliocamu...@gmail.com wrote: Add a new numlock-on option in the [keyboard] section of weston.ini which, if set to true, is used to enable the numlock of the keyboards attached

Re: [PATCH weston] screen-share: Add screen-share command to weston.ini man page

2014-08-21 Thread Pekka Paalanen
On Thu, 26 Jun 2014 16:31:43 +0100 Andrew Wedgbury andrew.wedgb...@realvnc.com wrote: This adds a description of the screen-share command configuration key to the weston.ini man page. Signed-off-by: Andrew Wedgbury andrew.wedgb...@realvnc.com --- man/weston.ini.man | 10 ++ 1

Re: [PATCH] weston-test: check if resource is not NULL

2014-08-21 Thread Pekka Paalanen
On Fri, 11 Jul 2014 12:33:02 +0200 Marek Chalupa mchqwe...@gmail.com wrote: and post client_no_memory if is... --- tests/weston-test.c | 5 + 1 file changed, 5 insertions(+) diff --git a/tests/weston-test.c b/tests/weston-test.c index 44875a6..cc937e5 100644 ---

Re: [PATCH 3/3] client: remove unused variable

2014-08-21 Thread Pekka Paalanen
On Thu, 21 Aug 2014 12:07:08 +0200 Marek Chalupa mchqwe...@gmail.com wrote: display_thread variable is unused since 3c7e8bfbb4745315b7bcbf69fa746c3d6718c305 Signed-off-by: Marek Chalupa mchqwe...@gmail.com --- src/wayland-client.c | 1 - 1 file changed, 1 deletion(-) diff --git

Re: [PATCH weston 1/3] evdev/libinput: sync the leds of keyboards with the xkb state

2014-08-21 Thread Daniel Stone
Hi, On 21 August 2014 08:58, Giulio Camuffo giuliocamu...@gmail.com wrote: 2014-08-21 10:34 GMT+03:00 Daniel Stone dan...@fooishbar.org: Ugh. If you've your own kernel to hand, I'd hack it to WARN_ON(1) on LED updates, so you can track where the rogue update is coming from. My guess is

Re: [PATCH weston 1/3] evdev/libinput: sync the leds of keyboards with the xkb state

2014-08-21 Thread Giulio Camuffo
2014-08-21 15:06 GMT+03:00 Daniel Stone dan...@fooishbar.org: Hi, On 21 August 2014 08:58, Giulio Camuffo giuliocamu...@gmail.com wrote: 2014-08-21 10:34 GMT+03:00 Daniel Stone dan...@fooishbar.org: Ugh. If you've your own kernel to hand, I'd hack it to WARN_ON(1) on LED updates, so you

Re: [PATCH weston 1/3] evdev/libinput: sync the leds of keyboards with the xkb state

2014-08-21 Thread Daniel Stone
On 21 August 2014 13:17, Giulio Camuffo giuliocamu...@gmail.com wrote: 2014-08-21 15:06 GMT+03:00 Daniel Stone dan...@fooishbar.org: On 21 August 2014 08:58, Giulio Camuffo giuliocamu...@gmail.com wrote: Switching VT is another matter, because all the keyboard devices are removed so the

Re: [PATCH] tests: add multiple-queues testcases

2014-08-21 Thread Pekka Paalanen
On Wed, 25 Jun 2014 14:35:16 +0200 Marek Chalupa mchqwe...@gmail.com wrote: Test if events are going to the right queue and if the queue is interrupted from polling when an error to the main queue comes. The last one is failing. --- tests/queue-test.c | 128

Re: [PATCH] tests: test if thread can block on error

2014-08-21 Thread Pekka Paalanen
On Tue, 5 Aug 2014 11:39:49 +0200 Marek Chalupa mchqwe...@gmail.com wrote: wl_display_read_events() can make a thread wait until some other thread ends reading. Normally it wakes up all threads after the reading is done. But there's a place when it does not get to waking up the threads -

[PATCH] desktop-shell: Replace magic constants with named ones

2014-08-21 Thread Ondřej Majerech
Signed-off-by: Ondřej Majerech majerec...@gmail.com --- desktop-shell/shell.c | 11 +-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/desktop-shell/shell.c b/desktop-shell/shell.c index e3abaad..02e180d 100644 --- a/desktop-shell/shell.c +++ b/desktop-shell/shell.c @@

Re: [PATCH] client: check for error before prepare/read

2014-08-21 Thread Pekka Paalanen
On Tue, 5 Aug 2014 11:43:35 +0200 Marek Chalupa mchqwe...@gmail.com wrote: This prevents from blocking shown in one display test. Also, it makes sense to not proceed further in the code of these function when an error occurred. --- src/wayland-client.c | 6 ++ 1 file changed, 6

Re: [PATCH weston] screen-share: Add screen-share command to weston.ini man page

2014-08-21 Thread Andrew Wedgbury
Hi Pekka, On Thu, 21 Aug 2014, Pekka Paalanen wrote: On Thu, 26 Jun 2014 16:31:43 +0100 Andrew Wedgbury andrew.wedgb...@realvnc.com wrote: This adds a description of the screen-share command configuration key to the weston.ini man page. Signed-off-by: Andrew Wedgbury

Re: [PATCH 2/2] compositor: add a way to change the keyboard leds

2014-08-21 Thread Pekka Paalanen
On Thu, 21 Aug 2014 08:37:17 +0100 Daniel Stone dan...@fooishbar.org wrote: Hi, Last nitpick, sorry ... On Wednesday, August 20, 2014, Giulio Camuffo giuliocamu...@gmail.com wrote: + mods_depressed = xkb_state_serialize_mods(keyboard-xkb_state.state, +

[PATCH v2] tests: add test-compositor

2014-08-21 Thread Marek Chalupa
This patch introduces a set of functions that can create a display and clients for tests. On server side the user can use functions: display_create() display_destroy() create_client() display_run() display_resume() and on client side the user can use: client_connect()

[PATCH v2] tests: use test compositor in queue-test

2014-08-21 Thread Marek Chalupa
Most of the code of the queue-test is covered by the test compositor, so we can save few lines and use the test compositor instead. I think it's also more readable. This patch removes timeout from the test. We plan to add timeout to all tests later, though. v2. rebased to master

[PATCH weston] xdg-shell: bump experimental protocol version

2014-08-21 Thread Pekka Paalanen
From: Pekka Paalanen pekka.paala...@collabora.co.uk The experimental versioning has not been updated when it was supposed to. Let's try to be better at it now, as xdg-shell is close to have its first stable version. Bump the version now to bring the world into the same exact version. There may

Re: [PATCH wayland v4 1/5] protocol: define the concept of wl_surface role

2014-08-21 Thread Jason Ekstrand
LGTM Reviewed-by: Jason Ekstrand jason.ekstr...@intel.com On Thu, Aug 21, 2014 at 2:52 AM, Pekka Paalanen ppaala...@gmail.com wrote: From: Pekka Paalanen pekka.paala...@collabora.co.uk Define what a role is, and what restrictions there are. A change to existing behaviour is that a role

Re: [PATCH wayland v4 1/5] protocol: define the concept of wl_surface role

2014-08-21 Thread Jason Ekstrand
That applies to the whole series, BTW On Thu, Aug 21, 2014 at 9:03 AM, Jason Ekstrand ja...@jlekstrand.net wrote: LGTM Reviewed-by: Jason Ekstrand jason.ekstr...@intel.com On Thu, Aug 21, 2014 at 2:52 AM, Pekka Paalanen ppaala...@gmail.com wrote: From: Pekka Paalanen

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

2014-08-21 Thread Jason Ekstrand
On Thu, Aug 21, 2014 at 4:00 AM, Pekka Paalanen ppaala...@gmail.com wrote: On Thu, 7 Aug 2014 09:55:49 -0400 Jasper St. Pierre jstpie...@mecheye.net wrote: 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

[PATCH] tests: allow running make check without make install

2014-08-21 Thread Derek Foreman
This is my first attempt at a patch to allow running weston-keyboard, desktop-shell and screenshooter out of the build directory so make check doesn't do funny things... From a97352451bff6398edace74defca67e18c92bb98 Mon Sep 17 00:00:00 2001 From: Derek Foreman der...@osg.samsung.com Date: Thu, 21

Re: [PATCH] tests: allow running make check without make install

2014-08-21 Thread Derek Foreman
And here's a second round with free()s for the asprintf()s. On 21/08/14 11:46 AM, Derek Foreman wrote: This is my first attempt at a patch to allow running weston-keyboard, desktop-shell and screenshooter out of the build directory so make check doesn't do funny things...

Re: [PATCH libinput 6/8] evdev: drop the button count when releasing keys on remove

2014-08-21 Thread Jonas Ådahl
On Wed, Aug 20, 2014 at 01:18:54PM +1000, Peter Hutterer wrote: We only called this function before device removal, so failing to update the button state didn't matter. To make this function generic for the upcoming device suspend/resume, we need to keep track of the button/key count properly.

Re: [PATCH libinput 7/8] evdev: ignore excessive releases of a button or key

2014-08-21 Thread Jonas Ådahl
On Wed, Aug 20, 2014 at 01:18:55PM +1000, Peter Hutterer wrote: When we're suspending a touchpad, several events triggered by timers may still be waiting in the background. We still need to release all buttons/keys immediately though so we get an uneven number of release events: one from

Re: [PATCH libinput 3/8] Add libinput_device_suspend() and libinput_device_resume()

2014-08-21 Thread Jonas Ådahl
On Wed, Aug 20, 2014 at 01:18:51PM +1000, Peter Hutterer wrote: Does what it says on the box, preventing events from the device without actually dropping the device from the context. Signed-off-by: Peter Hutterer peter.hutte...@who-t.net --- See my notes in the coverletter. For the T440

Re: [PATCH libinput 0/8] Add libinput_device_suspend() to disable devices

2014-08-21 Thread Jonas Ådahl
On Thu, Aug 21, 2014 at 04:18:41PM +1000, Peter Hutterer wrote: replying to myself, now that I've had a bit of a think about this all. On Wed, Aug 20, 2014 at 01:18:48PM +1000, Peter Hutterer wrote: This patchset adds two new API hooks, libinput_device_suspend() and

Re: [PATCH weston 00/19] Basic tablet support in Weston

2014-08-21 Thread Stephen Chandler Paul
On Tue, 2014-08-19 at 16:57 +0300, Pekka Paalanen wrote: On Tue, 19 Aug 2014 13:21:54 +0200 Jonas Ådahl jad...@gmail.com wrote: On Tue, Aug 19, 2014 at 01:03:52PM +0300, Pekka Paalanen wrote: On Wed, 6 Aug 2014 19:07:50 -0400 Stephen Chandler Paul thatsly...@gmail.com wrote:

Re: [PATCH weston 3/3] shell: constrain resize grabs so titlebars don't go under the panel

2014-08-21 Thread Bill Spitzak
Constrain it so that both the grabbed point and the nearest point on the edge cannot go under the panel. A radius about the cursor does not work because if they grab the titlebar too close to the top they can't put the window all the way up against the edge (Unity has this bug and it triggers

Re: [PATCH wayland v4 1/5] protocol: define the concept of wl_surface role

2014-08-21 Thread Bill Spitzak
On 08/21/2014 02:52 AM, Pekka Paalanen wrote: + Destroying the role object does not remove the role from the + wl_surface, but it may stop the wl_surface from playing the role. + For instance, if a wl_subsurface object is destroyed, the wl_surface + it was created for will

Re: [PATCH wayland v4 1/5] protocol: define the concept of wl_surface role

2014-08-21 Thread Jasper St. Pierre
On Thu, Aug 21, 2014 at 7:18 PM, Bill Spitzak spit...@gmail.com wrote: On 08/21/2014 02:52 AM, Pekka Paalanen wrote: + Destroying the role object does not remove the role from the + wl_surface, but it may stop the wl_surface from playing the role. + For instance, if a

Re: [PATCH libinput 0/8] Add libinput_device_suspend() to disable devices

2014-08-21 Thread Peter Hutterer
On Thu, Aug 21, 2014 at 10:16:49PM +0200, Jonas Ådahl wrote: On Thu, Aug 21, 2014 at 04:18:41PM +1000, Peter Hutterer wrote: replying to myself, now that I've had a bit of a think about this all. On Wed, Aug 20, 2014 at 01:18:48PM +1000, Peter Hutterer wrote: This patchset adds two new

Re: [PATCH libinput 3/8] Add libinput_device_suspend() and libinput_device_resume()

2014-08-21 Thread Peter Hutterer
On Thu, Aug 21, 2014 at 09:36:57PM +0200, Jonas Ådahl wrote: On Wed, Aug 20, 2014 at 01:18:51PM +1000, Peter Hutterer wrote: Does what it says on the box, preventing events from the device without actually dropping the device from the context. Signed-off-by: Peter Hutterer

Re: [PATCH wayland v4 1/5] protocol: define the concept of wl_surface role

2014-08-21 Thread Bill Spitzak
On 08/21/2014 04:30 PM, Jasper St. Pierre wrote: How do you create more than one copy of the role object in the first place? I thought you could create any number of wl_shell_surface objects for the same wl_surface. May also be really nasty if a former object-less role is updated

Re: [PATCH libinput 0/8] Add libinput_device_suspend() to disable devices

2014-08-21 Thread Bill Spitzak
Seems to me you only need two states: what you call disabled and what you are calling smart disable. The fully disabled is so a button the hardware does not know about can disable the device. Or a wayland compositor could use a mouse being added to disable the device. But the smart disable

Re: [PATCH wayland v4 1/5] protocol: define the concept of wl_surface role

2014-08-21 Thread Jasper St. Pierre
On Thu, Aug 21, 2014 at 9:29 PM, Bill Spitzak spit...@gmail.com wrote: On 08/21/2014 04:30 PM, Jasper St. Pierre wrote: How do you create more than one copy of the role object in the first place? I thought you could create any number of wl_shell_surface objects for the same wl_surface.

Re: [PATCH libinput 0/8] Add libinput_device_suspend() to disable devices

2014-08-21 Thread Peter Hutterer
On Thu, Aug 21, 2014 at 06:35:57PM -0700, Bill Spitzak wrote: Seems to me you only need two states: what you call disabled and what you are calling smart disable. The fully disabled is so a button the hardware does not know about can disable the device. Or a wayland compositor could use a