Re: [PATCH weston 1/1] compositor: Abort on bad page flip timestamps

2014-11-06 Thread Mario Kleiner
On 06/11/14 17:42, Pekka Paalanen wrote: On Thu, 06 Nov 2014 16:08:56 +0900 Michel Dänzer wrote: On 06.11.2014 03:06, Frederic Plourde wrote: Many features, like animations, hardly depend on page flip timestamps to work properly, but some DRM drivers do not correctly support page flip timesta

Re: [PATCH 10/11] test: Add litest_button_scroll helper function

2014-11-06 Thread Peter Hutterer
On Thu, Nov 06, 2014 at 04:37:39PM +0100, Hans de Goede wrote: > Turn test_trackpoint_scroll into a generic helper function for testing > "button scrolling". > > Signed-off-by: Hans de Goede > --- > test/litest.c | 28 > test/litest.h | 3 +++ > test/trackpo

Re: [PATCH 02/11] Add libinput_device_has_key function

2014-11-06 Thread Peter Hutterer
On Thu, Nov 06, 2014 at 04:37:31PM +0100, Hans de Goede wrote: > In some cases the compositor will want to know which keys (buttons) a device > has. > > E.g. for scrolling we want the compositor to be able to set a button to change > a relative device (e.g. a trackball) into scroll mode, so that i

Re: [PATCH 09/11] test: Add trackpoint middle button scrolling disable test

2014-11-06 Thread Peter Hutterer
On Thu, Nov 06, 2014 at 04:37:38PM +0100, Hans de Goede wrote: > Signed-off-by: Hans de Goede > --- > test/trackpoint.c | 39 +++ > 1 file changed, 39 insertions(+) > > diff --git a/test/trackpoint.c b/test/trackpoint.c > index eb9ddfb..7a36370 100644 > --- a/

Re: [PATCH 07/11] touchpad: Hookup scroll-mode configuration

2014-11-06 Thread Peter Hutterer
On Thu, Nov 06, 2014 at 04:37:36PM +0100, Hans de Goede wrote: > Default to 2fg scrolling for now, once we have edge-scrolling we can default > to edge-scrolling on touchpads which cannot detect more then 1 touch. s/then/than/ > > Signed-off-by: Hans de Goede > --- > src/evdev-mt-touchpad.c |

Re: [PATCH 03/11] Add configuration option to select scroll mode

2014-11-06 Thread Peter Hutterer
On Thu, Nov 06, 2014 at 04:37:32PM +0100, Hans de Goede wrote: > Add a configuration option to allow selecting between 2-finger / edge / none > scrolling (for touchpads). > > Signed-off-by: Hans de Goede > --- > src/libinput-private.h | 13 > src/libinput.c | 82 ++

Re: [PATCH 02/11] Add libinput_device_has_key function

2014-11-06 Thread Peter Hutterer
On Thu, Nov 06, 2014 at 05:46:26PM -0800, Bill Spitzak wrote: > > > On 11/06/2014 05:17 PM, Peter Hutterer wrote: > >On Thu, Nov 06, 2014 at 11:41:20AM -0800, Bill Spitzak wrote: > >>It sure seems like an api that returned a list of all the keycodes the > >>device has would be better. It looks li

Re: [PATCH 02/11] Add libinput_device_has_key function

2014-11-06 Thread Bill Spitzak
On 11/06/2014 05:17 PM, Peter Hutterer wrote: On Thu, Nov 06, 2014 at 11:41:20AM -0800, Bill Spitzak wrote: It sure seems like an api that returned a list of all the keycodes the device has would be better. It looks like the client has to try every possible keycode to find out what exists with

Re: [PATCH 02/11] Add libinput_device_has_key function

2014-11-06 Thread Peter Hutterer
On Thu, Nov 06, 2014 at 11:41:20AM -0800, Bill Spitzak wrote: > It sure seems like an api that returned a list of all the keycodes the > device has would be better. It looks like the client has to try every > possible keycode to find out what exists with this. what is the caller (which is not a wl

[PATCH libinput 2/6] test: rename LITEST_POINTER to LITEST_RELATIVE

2014-11-06 Thread Peter Hutterer
Signed-off-by: Peter Hutterer --- test/device.c | 4 ++-- test/litest-mouse.c| 2 +- test/litest-ms-surface-cover.c | 2 +- test/litest-trackpoint.c | 2 +- test/litest.h | 2 +- test/pointer.c | 8 6 files changed, 10 i

[PATCH libinput 5/6] test: add Xen Virtual Pointer device

2014-11-06 Thread Peter Hutterer
Signed-off-by: Peter Hutterer --- test/Makefile.am | 1 + test/litest-xen-virtual-pointer.c | 106 ++ test/litest.c | 2 + test/litest.h | 1 + 4 files changed, 110 insertions(+) create mode 100644

[PATCH libinput 6/6] test: add VMWare Virtual USB Mouse device

2014-11-06 Thread Peter Hutterer
Yes, the name has VMware twice, not a typo. Signed-off-by: Peter Hutterer --- test/Makefile.am | 1 + test/litest-vmware-virtual-usb-mouse.c | 115 + test/litest.c | 2 + test/litest.h |

[PATCH libinput 4/6] test: add test for absolute pointer motion

2014-11-06 Thread Peter Hutterer
Signed-off-by: Peter Hutterer --- test/pointer.c | 39 +++ 1 file changed, 39 insertions(+) diff --git a/test/pointer.c b/test/pointer.c index 4387526..52d812f 100644 --- a/test/pointer.c +++ b/test/pointer.c @@ -102,6 +102,44 @@ START_TEST(pointer_motion_rela

[PATCH libinput 3/6] test: add QEMU tablet as test device

2014-11-06 Thread Peter Hutterer
Re-uses the touch_down interface for now, but requires the slot is always 0. That's easier for now than adding a new interface for abs event, at least until we have more than one device that needs it. This device, along with a couple of similar ones have a tendency to break in the X.Org stack with

[PATCH libinput 1/6] evdev: don't ignore REL_HWHEEL values over 1

2014-11-06 Thread Peter Hutterer
Matching patch for REL_WHEEL is 09a3770961aad0973, not sure why I didn't do both at the same time. Signed-off-by: Peter Hutterer --- src/evdev.c | 19 +-- 1 file changed, 5 insertions(+), 14 deletions(-) diff --git a/src/evdev.c b/src/evdev.c index 272d165..84c42b6 100644 --- a/

Re: [PATCH v2] input: don't send to clients key events eaten by bindings

2014-11-06 Thread Bill Spitzak
On 11/06/2014 11:55 AM, Giulio Camuffo wrote: 2014-11-06 21:48 GMT+02:00 Bill Spitzak : On 11/06/2014 09:55 AM, Giulio Camuffo wrote: weston key bindings are supposed to eat the key events, and not pass it on to clients, and indeed the wl_keyboard.key event is not sent. But we must also no

Re: [PATCH v3 libinput] util: introduce ratelimit helpers

2014-11-06 Thread Peter Hutterer
On Thu, Nov 06, 2014 at 11:46:30PM +0100, David Herrmann wrote: > Hi > > On Thu, Nov 6, 2014 at 11:39 PM, Peter Hutterer > wrote: > > From: David Herrmann > > > > This adds "struct ratelimit" and "ratelimit_test()". It's a very simple > > rate-limit helper modeled after Linux' lib/ratelimit.c by

Re: [PATCH v3 libinput] util: introduce ratelimit helpers

2014-11-06 Thread David Herrmann
Hi On Thu, Nov 6, 2014 at 11:39 PM, Peter Hutterer wrote: > From: David Herrmann > > This adds "struct ratelimit" and "ratelimit_test()". It's a very simple > rate-limit helper modeled after Linux' lib/ratelimit.c by Dave Young. > > This comes in handy to limit log-messages in possible busy loop

[PATCH v3 libinput] util: introduce ratelimit helpers

2014-11-06 Thread Peter Hutterer
From: David Herrmann This adds "struct ratelimit" and "ratelimit_test()". It's a very simple rate-limit helper modeled after Linux' lib/ratelimit.c by Dave Young. This comes in handy to limit log-messages in possible busy loops etc.. Signed-off-by: David Herrmann Reviewed-by: Peter Hutterer S

[PATCH weston 07/15] libweston: allow compositors to define the logging behavior

2014-11-06 Thread Giulio Camuffo
--- Makefile.am | 4 +-- src/compositor.h | 5 ++-- src/log.c| 69 ++--- src/weston.c | 78 4 files changed, 90 insertions(+), 66 deletions(-) diff --git a/Makefile.am b/Makefil

[PATCH weston 05/15] compositor: move the main() to a new weston.c file

2014-11-06 Thread Giulio Camuffo
--- Makefile.am | 1 + src/compositor.c | 679 src/weston.c | 718 +++ 3 files changed, 719 insertions(+), 679 deletions(-) create mode 100644 src/weston.c diff --git a/Makefile.am

[PATCH weston 14/15] libweston: expose the wayland backend API

2014-11-06 Thread Giulio Camuffo
--- Makefile.am | 1 + src/compositor-wayland.c | 37 ++- src/compositor-wayland.h | 51 3 files changed, 71 insertions(+), 18 deletions(-) create mode 100644 src/compositor-wayland.h diff --git a/Make

[PATCH weston 09/15] libweston: handle the screenshoot and record bindings in weston.c

2014-11-06 Thread Giulio Camuffo
Move the code launching the screenshooter client and implementing the screenshot protocol out of libweston, and make screenshooter.c a generic way to hook screenshoot protocols into weston. --- desktop-shell/shell.c | 2 - src/compositor.h | 5 +- src/screenshooter.c | 176 -

[PATCH weston 04/15] compositor: add API to manage compositor instances

2014-11-06 Thread Giulio Camuffo
--- src/compositor-drm.c | 2 +- src/compositor-wayland.c | 4 +-- src/compositor-x11.c | 2 +- src/compositor.c | 85 +++- src/compositor.h | 9 +++-- 5 files changed, 67 insertions(+), 35 deletions(-) diff --git a/src/compo

[PATCH weston 08/15] libweston: move the child process launching and monitoring to weston

2014-11-06 Thread Giulio Camuffo
libweston still internally uses those functions, so it is not linkable yet by other compositors. --- src/compositor.c | 144 -- src/weston.c | 145 +++ 2 files changed, 145 insertions(+), 14

[PATCH weston 12/15] libweston: expose the drm backend's API

2014-11-06 Thread Giulio Camuffo
--- Makefile.am | 1 + src/compositor-drm.c | 62 +--- src/compositor-drm.h | 60 ++ 3 files changed, 76 insertions(+), 47 deletions(-) create mode 100644 src/compositor-drm.h diff --git a/M

[PATCH weston 06/15] build a libweston.so used by the weston binary

2014-11-06 Thread Giulio Camuffo
--- Makefile.am | 28 ++-- src/input.c | 2 +- 2 files changed, 19 insertions(+), 11 deletions(-) diff --git a/Makefile.am b/Makefile.am index 6dbb4c3..0e5e88d 100644 --- a/Makefile.am +++ b/Makefile.am @@ -38,17 +38,14 @@ AM_CPPFLAGS =

[PATCH weston 13/15] libweston: make a shared library for compositor launchers

2014-11-06 Thread Giulio Camuffo
--- Makefile.am | 21 +- src/weston-launch.c | 698 + src/weston-launcher.c | 769 ++ src/weston-launcher.h | 45 +++ 4 files changed, 845 insertions(+), 688 deletions(-) create mode 100644 s

[PATCH weston 10/15] text: build the text-backend in weston

2014-11-06 Thread Giulio Camuffo
It uses the weston_client_launch API, which is not available in libweston. --- Makefile.am | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Makefile.am b/Makefile.am index 1d7ee62..d045137 100644 --- a/Makefile.am +++ b/Makefile.am @@ -54,7 +54,6 @@ libweston_la_SOURCES =

[PATCH weston 11/15] libweston: expose the X11 backend's API

2014-11-06 Thread Giulio Camuffo
--- Makefile.am | 1 + src/compositor-x11.c | 5 +++-- src/compositor-x11.h | 27 +++ 3 files changed, 31 insertions(+), 2 deletions(-) create mode 100644 src/compositor-x11.h diff --git a/Makefile.am b/Makefile.am index d045137..1e14bf2 100644 --- a/Makefile.a

[PATCH weston 03/15] compositor: remove the weston_config field from weston_compositor

2014-11-06 Thread Giulio Camuffo
Instead of the central weston_config pointer we now store it in some module-specific pointers. This way we can remove them one by one. --- desktop-shell/shell.c | 8 +--- desktop-shell/shell.h | 1 + fullscreen-shell/fullscreen-shell.c | 3 ++- src/cms-colord.c

[PATCH weston 15/15] libweston: libweston-ify xwayland

2014-11-06 Thread Giulio Camuffo
This creates a new library, libweston-xwayland.so with the entry point to easily spawn a xwayland server. The xwayland module now links to that library. --- Makefile.am| 40 -- xwayland/launcher.c| 157 -- xwayland/xwayland-modul

[PATCH weston 02/15] don't use weston_config in the backends code

2014-11-06 Thread Giulio Camuffo
This is to make them usable by future libweston users, since they will not use weston_config. weston_config is still used in the backends entry points, which will later on live in their own files. --- src/compositor-drm.c | 349 +-- src/compositor-fb

[RFC weston 00/15] libweston

2014-11-06 Thread Giulio Camuffo
This patchset makes a libweston.so out of the compositor core, thought to be used by many different users. The main() was moved out of compositor.c into a new weston.c, and so all weston-the-binary specific things, such as signal handling, child process handling, config, logging and the like. Some

Re: [PATCH v2] input: don't send to clients key events eaten by bindings

2014-11-06 Thread Giulio Camuffo
2014-11-06 21:48 GMT+02:00 Bill Spitzak : > > > On 11/06/2014 09:55 AM, Giulio Camuffo wrote: >> >> weston key bindings are supposed to eat the key events, and not pass it >> on to clients, and indeed the wl_keyboard.key event is not sent. But >> we must also not put the key in the keys array to pa

Re: [PATCH v2] input: don't send to clients key events eaten by bindings

2014-11-06 Thread Bill Spitzak
On 11/06/2014 09:55 AM, Giulio Camuffo wrote: weston key bindings are supposed to eat the key events, and not pass it on to clients, and indeed the wl_keyboard.key event is not sent. But we must also not put the key in the keys array to pass to client with the wl_keyboard.enter event, or else w

Re: [PATCH 02/11] Add libinput_device_has_key function

2014-11-06 Thread Bill Spitzak
It sure seems like an api that returned a list of all the keycodes the device has would be better. It looks like the client has to try every possible keycode to find out what exists with this. Also there should be some unification between how these things and keyboards work. On 11/06/2014 07

[PATCH v2] input: don't send to clients key events eaten by bindings

2014-11-06 Thread Giulio Camuffo
weston key bindings are supposed to eat the key events, and not pass it on to clients, and indeed the wl_keyboard.key event is not sent. But we must also not put the key in the keys array to pass to client with the wl_keyboard.enter event, or else we may send the 'eaten' one too. In the case of a k

Re: [PATCH weston 1/1] compositor: Abort on bad page flip timestamps

2014-11-06 Thread Pekka Paalanen
On Thu, 06 Nov 2014 16:08:56 +0900 Michel Dänzer wrote: > On 06.11.2014 03:06, Frederic Plourde wrote: > > Many features, like animations, hardly depend on page flip timestamps > > to work properly, but some DRM drivers do not correctly support page flip > > timestamps (or not at all) and in that

[PATCH 07/11] touchpad: Hookup scroll-mode configuration

2014-11-06 Thread Hans de Goede
Default to 2fg scrolling for now, once we have edge-scrolling we can default to edge-scrolling on touchpads which cannot detect more then 1 touch. Signed-off-by: Hans de Goede --- src/evdev-mt-touchpad.c | 63 ++--- src/evdev-mt-touchpad.h | 2 ++ 2 f

[PATCH 11/11] test: Add button scroll test to pointer tests

2014-11-06 Thread Hans de Goede
Non trackpoint button scrolling is mainly intended for use with trackballs, but we can test it just as well with any relative pointer device. Signed-off-by: Hans de Goede --- test/pointer.c | 40 1 file changed, 40 insertions(+) diff --git a/test/pointer

[PATCH 09/11] test: Add trackpoint middle button scrolling disable test

2014-11-06 Thread Hans de Goede
Signed-off-by: Hans de Goede --- test/trackpoint.c | 39 +++ 1 file changed, 39 insertions(+) diff --git a/test/trackpoint.c b/test/trackpoint.c index eb9ddfb..7a36370 100644 --- a/test/trackpoint.c +++ b/test/trackpoint.c @@ -60,6 +60,12 @@ test_trackpoint_sc

[PATCH 08/11] test: s/test_2fg_scroll/test_trackpoint_scroll/

2014-11-06 Thread Hans de Goede
Fix copy and paste error, causing the function to test trackpoint scrolling to be named test_2fg_scroll. Signed-off-by: Hans de Goede --- test/trackpoint.c | 14 +++--- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/test/trackpoint.c b/test/trackpoint.c index d4dfe41..eb9d

[PATCH 10/11] test: Add litest_button_scroll helper function

2014-11-06 Thread Hans de Goede
Turn test_trackpoint_scroll into a generic helper function for testing "button scrolling". Signed-off-by: Hans de Goede --- test/litest.c | 28 test/litest.h | 3 +++ test/trackpoint.c | 40 +++- 3 files changed, 38 insert

[PATCH 02/11] Add libinput_device_has_key function

2014-11-06 Thread Hans de Goede
In some cases the compositor will want to know which keys (buttons) a device has. E.g. for scrolling we want the compositor to be able to set a button to change a relative device (e.g. a trackball) into scroll mode, so that it sends scroll-axis events instead of pointer motion events. In order fo

[PATCH 01/11] Fix libinput_device_config_send_events_get_default_mode docs

2014-11-06 Thread Hans de Goede
Fix libinput_device_config_send_events_get_default_mode docs referring to itself, instead make it refer to libinput_device_config_send_events_get_mode. Signed-off-by: Hans de Goede --- src/libinput.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/libinput.h b/src/libinpu

[PATCH 05/11] evdev: Hookup scroll mode configuration

2014-11-06 Thread Hans de Goede
Keep the default behavior of middle button scrolling on trackpoints, this allows turning off middle button scrolling on trackpoints, as well as turning on button scrolling on trackballs. Signed-off-by: Hans de Goede --- src/evdev.c | 165 +++---

[PATCH 03/11] Add configuration option to select scroll mode

2014-11-06 Thread Hans de Goede
Add a configuration option to allow selecting between 2-finger / edge / none scrolling (for touchpads). Signed-off-by: Hans de Goede --- src/libinput-private.h | 13 src/libinput.c | 82 src/libinput.h | 165

[PATCH 06/11] touchpad: s/config/config_natural/

2014-11-06 Thread Hans de Goede
To avoid confusion with scroll mode configuration. Signed-off-by: Hans de Goede --- src/evdev-mt-touchpad.c | 10 +- src/evdev-mt-touchpad.h | 2 +- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/src/evdev-mt-touchpad.c b/src/evdev-mt-touchpad.c index 85d980c..67bbf96 10

[PATCH 04/11] evdev: Add evdev_any_button_down helper function

2014-11-06 Thread Hans de Goede
Signed-off-by: Hans de Goede --- src/evdev.c | 22 +++--- 1 file changed, 15 insertions(+), 7 deletions(-) diff --git a/src/evdev.c b/src/evdev.c index b39b484..2821cc6 100644 --- a/src/evdev.c +++ b/src/evdev.c @@ -580,6 +580,19 @@ evdev_process_absolute(struct evdev_device *dev

Re: [PATCH weston 1/1] compositor: Abort on bad page flip timestamps

2014-11-06 Thread Frederic Plourde
On 14-11-06 02:08 AM, Michel Dänzer wrote: On 06.11.2014 03:06, Frederic Plourde wrote: If a pathological case is detected, we gracefully exit Weston with an appropriate exit code to help developers debug their drivers. That seems a bit harsh. IIRC, zero can be returned for the timestamp inte

Re: [PATCH libinput v2 1/2] util: introduce ratelimit helpers

2014-11-06 Thread David Herrmann
Hi On Thu, Nov 6, 2014 at 6:51 AM, Peter Hutterer wrote: > On Wed, Nov 05, 2014 at 01:32:16PM +0100, David Herrmann wrote: >> diff --git a/test/misc.c b/test/misc.c >> index 1512180..aa411ec 100644 >> --- a/test/misc.c >> +++ b/test/misc.c >> @@ -508,6 +508,40 @@ START_TEST(matrix_helpers) >> }