Olivier Fourdan [Thu, 8 Jan 2015 14:40:29 +0000 (15:40 +0100)]
Fix mutex hang in colord on output removal
Using the x11 output (maybe with others as well), weston would hang
when closing the output if the colord plugin is enabled.
The hang occurs in mutex lock in the output notifier handler because
the given GMutex value is incorrect.
This is because of a cast error, the type of container should be
"cms_output" and not "cms_colord".
Signed-off-by: Olivier Fourdan <ofourdan@redhat.com>
Reviewed-by: Richard Hughes <richard@hughsie.com>
Reviewed-by: Bryce Harrington <bryce@osg.samsung.com>
Bryce Harrington [Sat, 10 Jan 2015 02:09:21 +0000 (18:09 -0800)]
releasing: Add example commands to release directions
Note that for weston, configure.ac needs version numbers updated in
several places. `make distcheck` for weston no longer triggers the test
suite to run, so update the directions to run a `make check`
pre-release. Switch to using the X.org release.sh script in place of
some of the manual steps.
Signed-off-by: Bryce Harrington <bryce@osg.samsung.com>
Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
Lubomir Rintel [Sun, 28 Dec 2014 13:20:49 +0000 (14:20 +0100)]
build: install a login manager session entry
This makes it possible to run Weston session from GDM (and possibly
other login managers).
Carlos Olmedo Escobar [Sat, 17 Jan 2015 19:31:53 +0000 (20:31 +0100)]
zoom: Check the value of level before using it.
Check the value of level before dividing 1 by it.
Signed-off-by: Carlos Olmedo Escobar <carlos.olmedo.e@gmail.com>
Reviewed-by: Derek Foreman <derekf@osg.samsung.com>
Reviewed-by: Bryce Harrington <bryce@osg.samsung.com>
Derek Foreman [Fri, 16 Jan 2015 23:47:10 +0000 (17:47 -0600)]
text: Fix typo
Signed-off-by: Derek Foreman <derekf@osg.samsung.com>
Reviewed-by: Bryce Harrington <bryce@osg.samsung.com>
Bryce Harrington [Sat, 10 Jan 2015 02:09:20 +0000 (18:09 -0800)]
releasing: Typo
Signed-off-by: Bryce Harrington <bryce@osg.samsung.com>
Reviewed-by: Derek Foreman <derekf@osg.samsung.com>
Bryce Harrington [Wed, 21 Jan 2015 01:22:16 +0000 (17:22 -0800)]
Revert "simple-egl: HACK to report presentation flags"
This reverts commit
b77acf592fdc625a09e4d1ea1672dba2db128238.
Change is listed as "not for upstream"
Pekka Paalanen [Wed, 17 Dec 2014 14:20:43 +0000 (16:20 +0200)]
simple-egl: HACK to report presentation flags
So that we can test the per-surface ZERO_COPY flag:
- start Weston on DRM backend
- run ./weston-simple-egl -o (need to be opaque to end up on overlay)
- hit debug key 'V' to enable the (broken) hw overlays
The debug key is used by first hitting Mod+Shift+space, then hitting 'v'.
Enabling overlays should change the flags from 0x7 to 0xe. To verify the
window is really on an overlay, use debug key 'S' to tint all
GL-composited things green.
This patch is not intended for upstream.
Reviewed-by: Mario Kleiner <mario.kleiner.de@gmail.com>
Tested-by: Mario Kleiner <mario.kleiner.de@gmail.com>
Pekka Paalanen [Wed, 17 Dec 2014 14:20:42 +0000 (16:20 +0200)]
tests, clients: add Presentation feedback flags
Decode the new feedback flags.
Signed-off-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
Reviewed-by: Mario Kleiner <mario.kleiner.de@gmail.com>
Tested-by: Mario Kleiner <mario.kleiner.de@gmail.com>
Pekka Paalanen [Wed, 17 Dec 2014 14:20:41 +0000 (16:20 +0200)]
compositor, drm: set per-surface Presentation feedback flags
PRESENTATION_FEEDBACK_KIND_ZERO_COPY is a flag that needs to be set for
each surface separately. Some surfaces may be zero-copy (as defined by
Presentation feedback) while some are not.
A complication with Weston is that a surface may have multiple views on
screen. All copies (views) of the surface are required to be zero-copy
for the ZERO_COPY flag to be set.
Backends set per-view feedback flags during the assing_planes hook, and
then Weston core collects the flags from all views of a surface.
Signed-off-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
Reviewed-by: Mario Kleiner <mario.kleiner.de@gmail.com>
Tested-by: Mario Kleiner <mario.kleiner.de@gmail.com>
Pekka Paalanen [Wed, 17 Dec 2014 14:20:40 +0000 (16:20 +0200)]
compositor: set presentation.presented flags
Change weston_output_finish_frame() signature so that backends are
required to set the flags, that will be reported on the Presentation
'presented' event. This is meant for output-wide feedback flags. Flags
that vary per wl_surface are subject for the following patch.
All start_repaint_loop functions use the special private flag
PRESENTATION_FEEDBACK_INVALID to mark, that this call of
weston_output_finish_frame() cannot trigger the 'presented' event. If it
does, we now hit an assert, and should then investigate why a fake update
triggered Presentation feedback.
DRM:
Page flip is always vsync'd, and always gets the completion timestamp
from the kernel which should correspond well to hardware. Completion is
triggered by the kernel/hardware.
Vblank handler is only used with the broken planes path, therefore do
not report VSYNC, because we cannot guarantee all the planes updated at
the same time. We cannot set the INVALID, because it would abort the
compositor if the broken planes path was ever used. This is a hack that
will get fixed with nuclear pageflip support in the future.
fbdev:
No vsync, update done by copy, no completion event from hardware, and
completion time is totally fake.
headless:
No real output to update.
RDP:
Guessing that maybe no vsync, fake time, and copy make sense (pixels
sent over network). Also no event that the pixels have been shown?
RPI:
Presumably Dispmanx updates are vsync'd. We get a completion event from
the driver, but need to read the clock ourselves, so the completion time
is somewhat unreliable. Zero-copy flag not implemented though it would
be theoretically possible with EGL clients (zero-copy is a per-surface
flag anyway, so in this patch).
Wayland:
No information how the host compositor is doing updates, so make a safe
guess without assuming vsync or hardware completion event. While we do
get some timestamp from the host compositor, it is not the completion
time. Would need to hook to the Presentation extension of the host
compositor to get more accurate flags.
X11:
No idea about vsync, completion event, or copying. Also the timestamp is
a fake.
Signed-off-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
Reviewed-by: Mario Kleiner <mario.kleiner.de@gmail.com>
Tested-by: Mario Kleiner <mario.kleiner.de@gmail.com>
Acked-by: Mario Kleiner <mario.kleiner.de@gmail.com>
Pekka Paalanen [Wed, 17 Dec 2014 14:20:39 +0000 (16:20 +0200)]
protocol: add Presentation feedback flags
Add the missing feedback flags to the Presentation extension protocol
specification.
These flags are slightly different from the previous RFCv3.1 definition:
http://lists.freedesktop.org/archives/wayland-devel/2014-March/013598.html
Now, all compositors are safe to use 0 as the flags if they don't bother
setting them properly. 0 is the "worst case" with the least guarantees.
The meaning of ZERO_COPY is not exactly the opposite of the old COPY
flag. ZERO_COPY is more strict, but applies only to that one surface.
Therefore it can be used to verify a zero-copy video playback pipeline,
also to a hardware overlay.
There is no longer a flag to clearly indicate if the final presentation
was done by a copy or a page flip. ZERO_COPY forbids the copy, but VSYNC
alone does allow copy in case it cannot tear. It is possible to have
first a compositing pass, and then another copy into the frontbuffer,
and still set VSYNC if it cannot tear. Usually "cannot tear" is too
hard to guarantee with a copy, so it often implies a page flip.
Signed-off-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
Reviewed-by: Mario Kleiner <mario.kleiner.de@gmail.com>
Tested-by: Mario Kleiner <mario.kleiner.de@gmail.com>
Pekka Paalanen [Wed, 17 Dec 2014 14:20:38 +0000 (16:20 +0200)]
compositor-drm: use drm_output in drm_output_*() func args
When a function is named drm_output_FOO(), you'd expect it to take a
struct drm_output * as an argument. Convert
drm_output_prepare_scanout_view(), drm_output_prepare_overlay_view(),
drm_output_prepare_cursor_view() from weston_output to drm_output.
Additionally convert drm_sprite_crtc_supported() from weston_output to
drm_output.
This change makes drm_assign_planes() to operate on drm_output terms,
which makes further changes a tiny bit easier.
Signed-off-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
Reviewed-by: Mario Kleiner <mario.kleiner.de@gmail.com>
Tested-by: Mario Kleiner <mario.kleiner.de@gmail.com>
Bryce Harrington [Sat, 17 Jan 2015 11:45:34 +0000 (03:45 -0800)]
configure.ac: bump to version 1.6.91 for the alpha release
David Herrmann [Tue, 30 Dec 2014 13:33:23 +0000 (14:33 +0100)]
logind: fix PropertiesChanged parser
The current parser directly reads a BOOLEAN on the PropertiesChanged
signal for 'Active' properties. However, all property-values are packed in
a VARIANT, otherwise, we wouldn't know the type. Fix the parser to recurse
into the variant before reading the boolean.
To avoid such bugs in the future, we extract the 'Active' parser into a
helper function parse_active(), which is then shared between the
PropertiesChanged and Get handlers.
Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
Reviewed-by: Bryce Harrington <bryce@osg.samsung.com>
Tested-by: nerdopolis <bluescreen_avenger@verizon.net>
David Herrmann [Tue, 30 Dec 2014 13:33:22 +0000 (14:33 +0100)]
logind: forward Active=true changes for non-DRM backends
Logind sends us a notification whenever the Active attribute of our session
changes. However, due to the way compositor-drm.c relies on the master DRM
device to be synced with the session, we used to delay Active=true
handling until the DRM device was up, too. See:
commit
aedc7732ebd9bc7b4f51ee247ea857ffec6260a7
Author: David Herrmann <dh.herrmann@gmail.com>
Date: Sat Nov 30 11:25:45 2013 +0100
logind: delay wakeup until DRM-device is resumed
However, the other compositor backends do not use DRM, so logind-util will
never get notified about any DRM device. Therefore, we have to forward the
Active=true change immediately.
This commit fixes logind-util to take sync_drm as argument. If it is true,
we do DRM-device synchronisation, otherwise we don't.
Fixes: https://bugs.freedesktop.org/show_bug.cgi?id=86889
Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
Reviewed-by: Bryce Harrington <bryce@osg.samsung.com>
Tested-by: nerdopolis <bluescreen_avenger@verizon.net>
David Herrmann [Tue, 30 Dec 2014 13:33:21 +0000 (14:33 +0100)]
launcher: use SIGRTMIN to not conflict with xwayland
xwayland uses SIGUSR1 as startup notification. Make sure to use SIGRTMIN
for VT handling to avoid conflicts.
A bonus is SIGRT* signals can be queued multiple times, so we will be able
to correctly track them and will no longer lose signals (which wouldn't
really matter, but is confusing in logs).
Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
Reviewed-by: Bryce Harrington <bryce@osg.samsung.com>
Tested-by: nerdopolis <bluescreen_avenger@verizon.net>
David Herrmann [Tue, 30 Dec 2014 13:33:20 +0000 (14:33 +0100)]
logind: use SIGRTMIN to not conflict with xwayland
xwayland uses SIGUSR1 as startup notification. Make sure to use SIGRTMIN
and SIGRTMIN+1 for VT handling.
A bonus is SIGRT* signals can be queued multiple times, so we will be able
to correctly track them and will no longer lose signals (which wouldn't
really matter, but is confusing in logs).
Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
Reviewed-by: Bryce Harrington <bryce@osg.samsung.com>
Tested-by: nerdopolis <bluescreen_avenger@verizon.net>
Jonas Ådahl [Thu, 15 Jan 2015 06:45:56 +0000 (14:45 +0800)]
configure.ac: Require libinput 0.8
Signed-off-by: Jonas Ådahl <jadahl@gmail.com>
Peter Hutterer [Thu, 15 Jan 2015 03:14:43 +0000 (13:14 +1000)]
libinput-device: use the discrete axis value for wheel events
libinput < 0.8 sent wheel click events with value 10. Since 0.8
the value is the angle of the click in degrees but it now provides
the click count as separate value. To keep backwards-compat with
existing clients, we just send multiples of the click count.
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Signed-off-by: Jonas Ådahl <jadahl@gmail.com>
Reviewed-by: Jonas Ådahl <jadahl@gmail.com>
Peter Hutterer [Tue, 13 Jan 2015 01:55:37 +0000 (11:55 +1000)]
libinput-device: use the new merged scroll events
libinput now provides a single event for scroll events. Extract the axes from
that event and split them into the wl events.
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Jonas Ådahl <jadahl@gmail.com>
Derek Foreman [Wed, 7 Jan 2015 21:00:25 +0000 (15:00 -0600)]
input: Add comment explaining why pointer isn't freed when device is removed
When the last pointer is removed from a seat, the pointer struct is
intentionally kept. This has some interesting side effects, so I've
documented it here so people like me don't errantly assume it's a bug.
Signed-off-by: Derek Foreman <derekf@osg.samsung.com>
Reviewed-by: Jonas Ådahl <jadahl@gmail.com>
Derek Foreman [Thu, 11 Dec 2014 21:44:46 +0000 (15:44 -0600)]
compositor-x11: Fix some shutdown crashes
The assertion in x11_compositor_find_output() can trigger during normal
shutdown, for example, when moving the mouse while hitting a hotkey to
close the weston window.
Instead we can remove the assert(), return NULL, and discard events
we can't find a destination output for.
v2 Signed-off-by: Derek Foreman <derekf@osg.samsung.com>
v1 Reviewed-by: Bryce Harrington <bryce@osg.samsung.com>
Reviewed-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
Pekka Paalanen [Thu, 18 Dec 2014 12:57:19 +0000 (14:57 +0200)]
configure: bump libwayland requirements
wl_surface role error codes were added during the 1.6.90 development to
libwayland.
Reported-by: Sjoerd Simons <sjoerd.simons@collabora.co.uk>
Signed-off-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
Nobuhiko Tanibata [Tue, 16 Dec 2014 10:37:22 +0000 (19:37 +0900)]
ivi-shell: Fix wrong condition to check return value of controller_module_init
Signed-off-by: Nobuhiko Tanibata <NOBUHIKO_TANIBATA@xddp.denso.co.jp>
Derek Foreman [Mon, 8 Dec 2014 16:48:29 +0000 (10:48 -0600)]
text: Don't crash if a seat has no keyboard
A keyboard might not be present in a seat, so check that before
dereferencing keyboard related pointers.
Also, use the keyboard pointer we set to shorten the code a little bit.
Signed-off-by: Derek Foreman <derekf@osg.samsung.com>
Reviewed-by: Jan Arne Petersen <janarne@gmail.com>
Giulio Camuffo [Fri, 5 Dec 2014 16:02:58 +0000 (18:02 +0200)]
input: swallow the key press event when running a compositor key binding
Reviewed-by: Daniel Stone <daniel.stone@collabora.com>
Derek Foreman [Fri, 5 Dec 2014 21:38:39 +0000 (15:38 -0600)]
text: Use bool for input_panel_visible
Signed-off-by: Derek Foreman <derekf@osg.samsung.com>
Derek Foreman [Fri, 5 Dec 2014 21:38:38 +0000 (15:38 -0600)]
text: Remove unused linked list from input_method_context
Signed-off-by: Derek Foreman <derekf@osg.samsung.com>
Derek Foreman [Fri, 5 Dec 2014 21:38:37 +0000 (15:38 -0600)]
text: Fix coding style
Put the return type on a separate line in function declarations.
Signed-off-by: Derek Foreman <derekf@osg.samsung.com>
Derek Foreman [Fri, 5 Dec 2014 21:38:36 +0000 (15:38 -0600)]
text: Fix some typos
Signed-off-by: Derek Foreman <derekf@osg.samsung.com>
Nobuhiko Tanibata [Mon, 15 Dec 2014 04:25:39 +0000 (13:25 +0900)]
ivi-shell: rewrite controller API
This fixes the breakage caused by "ivi-shell: make ivi-layout.c as a
part of ivi-shell.so"
hmi-controller.c:
A reference implementation of controller module does not use the layout
functions directly. This get function pointers at controller_module_init
which called by ivi-shell.
ivi-layout-export.h:
Definition of interfaces in a struction: ivi_controller_interface.
function pointers are set at ivi-layout.c.
ivi-layout-private.h:
Definition of some interfaces are remove bucause it is implemented in
ivi-layout.c and set it as function pointer. Several interfaces are kept
here because they are implemented in ivi-layout.c/transition.c but used
in other files.
ivi-layout-transition.c:
remove WL_EXPORT because export is not needed anymore.
remove unnesesary unsed method.
ivi-shell.c:
call controller_module_init of hmi-controller to init it and set
function pointers. If the interface_version is equal or
greater than what hmi_controller was built with, things are pass.
If the interface_version is smaller than what the controller expects,
it has to fail because it cannot work. This is followed the manner,
- never remove a function pointer
- never modify an existing function signature
- additions are allowed at the end of struct ivi_controller_interface
- all function pointers must always be populated and working in
ivi-shell.so (ivi-layout.c etc.)
Signed-off-by: Nobuhiko Tanibata <NOBUHIKO_TANIBATA@xddp.denso.co.jp>
Acked-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
Nobuhiko Tanibata [Mon, 15 Dec 2014 04:22:31 +0000 (13:22 +0900)]
ivi-shell: make ivi-layout.c as a part of ivi-shell.so
ivi-layout.so is separately built and loaded by using dlopen with
RTLD_GLOBAL. This was because these apis defined in ivi-layout.so shall
be used by ivi-modules; e.g. hmi-controller. This shall be improved that
a struct ivi_layout_api contains the whole exported API as function
pointers to be exposed as module_init.
This patch alone builds, but loading controller modules at runtime
failes. This failure will be fixed by following patches.
Signed-off-by: Nobuhiko Tanibata <NOBUHIKO_TANIBATA@xddp.denso.co.jp>
Reviewed-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
Nobuhiko Tanibata [Mon, 15 Dec 2014 04:20:58 +0000 (13:20 +0900)]
ivi-shell: several ivi-layout interfaces moved accross source.
Interfaces for properties setting shall be implemented in ivi-layout.
Signed-off-by: Nobuhiko Tanibata <NOBUHIKO_TANIBATA@xddp.denso.co.jp>
Acked-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
Nobuhiko Tanibata [Mon, 15 Dec 2014 04:20:44 +0000 (13:20 +0900)]
ivi-shell: reordering method in ivi_layout.c
In the future, re-alignmenet of WL_EXPORT per method should be done.
For that work, re-ordering is required to be used by another method.
Signed-off-by: Nobuhiko Tanibata <NOBUHIKO_TANIBATA@xddp.denso.co.jp>
Acked-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
Nobuhiko Tanibata [Mon, 15 Dec 2014 04:20:14 +0000 (13:20 +0900)]
ivi-shell: clean up unnecesary header
Signed-off-by: Nobuhiko Tanibata <NOBUHIKO_TANIBATA@xddp.denso.co.jp>
Reviewed-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
Nobuhiko Tanibata [Mon, 15 Dec 2014 04:18:46 +0000 (13:18 +0900)]
ivi-shell: clean-up transition animation code.
ivi_layout_transition_layer_render_order is not necesary called. Remove
the method and methods called by it.
Signed-off-by: Nobuhiko Tanibata <NOBUHIKO_TANIBATA@xddp.denso.co.jp>
Reviewed-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
Ondřej Majerech [Sat, 6 Dec 2014 01:49:18 +0000 (02:49 +0100)]
ivi-shell: Say something when configuration is missing
When ivi-module is not set in weston.conf, we probably want to tell the
user about their error instead of just dying.
Signed-off-by: Ondřej Majerech <majerech.o@gmail.com>
[Pekka: include Tanibata's suggestion, fix file name, fix surrounding
coding style]
Signed-off-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
Ondřej Majerech [Sat, 6 Dec 2014 01:49:17 +0000 (02:49 +0100)]
compositor: Propagate errors from module_init
load_modules currently ignores errors signalled by both
weston_load_module and module_init, and instead always returns 0. Its
return value appears to be checked in callers, so we most likely want to
propagate any errors.
Signed-off-by: Ondřej Majerech <majerech.o@gmail.com>
Reviewed-by: Derek Foreman <derekf@osg.samsung.com>
Reviewed-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
Marek Chalupa [Wed, 10 Dec 2014 11:07:58 +0000 (12:07 +0100)]
clipboard: set fd member of clipboard_source
The fd member of clipboard_source structure was not set
but was used in close().
v2. don't do unnecessary changes
Signed-off-by: Marek Chalupa <mchqwerty@gmail.com>
Reviewed-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
Marek Chalupa [Wed, 10 Dec 2014 10:50:46 +0000 (11:50 +0100)]
screenshooter: fix various memory handling
There were unchecked malloc and no free for this memory.
Also simplify error handling in one function.
v2. remove check if memory is NULL, according to man pages,
free(NULL) is a no-op
Signed-off-by: Marek Chalupa <mchqwerty@gmail.com>
Reviewed-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
Marek Chalupa [Fri, 5 Dec 2014 12:49:40 +0000 (13:49 +0100)]
window: use roundtrip instead of dispatch after get_registry
wl_display_dispatch() just dispatches events that are in
default and display queues and if there are no events,
then it will wait for them. But only dispatching
the events doesn't guarantee that we got all the global announcements,
we need to do sync too. Therefore use wl_display_roundtrip() instead
of wl_display_dispatch().
Signed-off-by: Marek Chalupa <mchqwerty@gmail.com>
Reviewed-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
Andrew Engelbrecht [Tue, 2 Dec 2014 17:18:44 +0000 (12:18 -0500)]
xwm: fix a crash in handle_state
To produce the bug, build and run: (you don't need the game data to test)
https://github.com/clintbellanger/flare-engine/
$ mv ~/.config/flare ~/.config/flare.bak
$ ./flare # click 'configure', set full screen mode then click 'ok'
# weston will crash and dump core.
[Pekka: edited the commit message]
Reviewed-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
Bryce Harrington [Thu, 11 Dec 2014 02:33:47 +0000 (18:33 -0800)]
tests: Fix minor typo
Pekka Paalanen [Wed, 12 Nov 2014 13:09:24 +0000 (15:09 +0200)]
compositor: Implement JSON-timeline logging
Logging is activated and deactivated with the debug key binding 't'.
When activated, it creates a new log file, where it records the events.
The log file contains events and detailed object information entries in
JSON format, and is meant to be parsed in sequence from beginning to the
end.
The emitted events are mostly related to the output repaint cycle, like
when repaint begins, is submitted to GPU, and when it completes on a
vblank. This is recorded per-output. Also some per-surface events are
recorded, including when surface damage is flushed.
To reduce the log size, events refer to objects like outputs and
surfaces by id numbers. Detailed object information is emitted only as
needed: on the first object occurrence, and afterwards only if
weston_timeline_object::force_refresh asks for it.
The detailed information for surfaces includes the string returned by
weston_surface::get_label. Therefore it is important to set
weston_timeline_object::force_refresh = 1 whenever the string would
change, so that the new details get recorded.
A rudimentary parser and SVG generator can be found at:
https://github.com/ppaalanen/wesgr
The timeline logs can answer questions including:
- How does the compositor repaint cycle work timing-wise?
- When was the vblank deadline missed?
- What is the latency from surface commit to showing the new content on
screen?
- How long does it take to process the scenegraph?
v2: weston_surface::get_description renamed to get_label.
v3: reafctor a bit into fprint_quoted_string().
Signed-off-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
Pekka Paalanen [Wed, 6 Aug 2014 16:36:51 +0000 (19:36 +0300)]
compositor: add weston_surface_set_label_func()
When printing out logs from Weston's actions, mainly for debugging, it
can be very difficult to identify the different surfaces. Inspecting
the configure function pointer is not useful, as the configure functions
may live in modules.
Add vfunc get_label to weston_surface, which will produce a short,
human-readable description of the surface, which allows identifying it
better, rather than just looking at the surface size, for instance.
Set the label function from most parts of Weston, to identify cursors and
drag icons, and panels, backgrounds, screensavers and lock surfaces, and
the desktop shell's application surfaces.
v2: renamed 'description' to 'label', so we get
weston_surface_set_label_func().
Signed-off-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
Nobuhiko Tanibata [Thu, 27 Nov 2014 04:25:34 +0000 (13:25 +0900)]
ivi-shell: reference implementation of input panel for ivi-shell
- introduces ivi-shell/input-panel-ivi.c which is basically copied
from desktop shell. It shall be improvaded to remove duplicate
implementation.
Signed-off-by: Nobuhiko Tanibata <NOBUHIKO_TANIBATA@xddp.denso.co.jp>
Acked-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
Nobuhiko Tanibata [Thu, 27 Nov 2014 04:24:52 +0000 (13:24 +0900)]
clients: support ivi-application.xml for clients/window.c
Signed-off-by: Nobuhiko Tanibata <NOBUHIKO_TANIBATA@xddp.denso.co.jp>
Reviewed-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
Nobuhiko Tanibata [Thu, 27 Nov 2014 04:24:42 +0000 (13:24 +0900)]
clients: support ivi-application.xml for clients/simple-egl.c
Signed-off-by: Nobuhiko Tanibata <NOBUHIKO_TANIBATA@xddp.denso.co.jp>
Reviewed-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
Nobuhiko Tanibata [Thu, 27 Nov 2014 04:24:29 +0000 (13:24 +0900)]
clients: support ivi-application.xml for clients/simple-shm.c
Signed-off-by: Nobuhiko Tanibata <NOBUHIKO_TANIBATA@xddp.denso.co.jp>
Reviewed-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
Nobuhiko Tanibata [Thu, 27 Nov 2014 04:24:16 +0000 (13:24 +0900)]
ivi-shell: a reference of weston.ini for ivi-shell and ivi-hmi-controller.
- introduces ivi-shell/weston.ini.in
Signed-off-by: Nobuhiko Tanibata <NOBUHIKO_TANIBATA@xddp.denso.co.jp>
Reviewed-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
Nobuhiko Tanibata [Tue, 11 Mar 2014 02:54:45 +0000 (11:54 +0900)]
data: add reference image files for weston-ivi-shell-user-interface
- introduces reference images used by weston-ivi-shell-user-interface.
Signed-off-by: Nobuhiko Tanibata <NOBUHIKO_TANIBATA@xddp.denso.co.jp>
Reviewed-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
Nobuhiko Tanibata [Thu, 27 Nov 2014 04:23:32 +0000 (13:23 +0900)]
clients: a reference implementation of UI client how to use ivi-hmi-controller.
- introduces ivi-shell-user-interface.c
This is launched from hmi-controller by launch_hmi_client_process and
invoke a
client process.
The basic flow is as followed,
1/ process invoked
2/ read configuration from weston.ini.
3/ draw png file to surface according to configuration of weston.ini
4/ all parts of UI are ready. request "UI_ready" to draw UI.
5/ Enter event loop
6/ If a surface receives touch/pointer event, followings are invoked
according
to type of event and surface
6-1/ If a surface to launch ivi_application receive touch up, it execs
ivi-application configured in weston.ini.
6-2/ If a surface to switch layout mode receive touch up, it sends a
request,
ivi_hmi_controller_switch_mode, to hmi-controller.
6-3/ If a surface to show workspace having launchers, it sends a
request,
ivi_hmi_controller_home, to hmi-controller.
6-4/ If touch down events happens in workspace,
ivi_hmi_controller_workspace_control is sent to slide workspace.
When control finished, event:
ivi_hmi_controller_workspace_end_control
is received.
Signed-off-by: Nobuhiko Tanibata <NOBUHIKO_TANIBATA@xddp.denso.co.jp>
Acked-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
Nobuhiko Tanibata [Thu, 27 Nov 2014 04:23:12 +0000 (13:23 +0900)]
ivi-shell: a reference implementation how to use ivi-layout internal APIs
- hmi-controller.so
- introduces hmi-controller.so
The library is used to manage layout of surfaces/layers. Layout change
is triggered by ivi-hmi-controller protocol, ivi-hmi-controller.xml. A
reference how to use the protocol, see ivi-shell-user-interface.c.
In-Vehicle Infotainment system usually manages properties of
surfaces/layers by only a central component which decide where
surfaces/layers shall be. This is differenct use case from desktop
style; each application can request property of its window via xdg-shell
protocol, like fullscreen and set its to top level. In-Vehicle
Infortainment system doesn't allow each application to chagen them from
its application because of safty reasons. The concept of layer is
simillar with a use case of cursor layer of Destop. For In-Vehicle
Infortainment system, it is extended to all applications. For example,
rearview camera application is assigned to a layer to group several
surfaces, e.g. captured image and drawing lines separately. Central
manaegr can control property of the layer of rearview camera.
This reference show examples to implement the central component as a
module of weston.
Default Scene graph of UI is defined in hmi_controller_create. It
consists of
- In the bottom, a base layer to group surfaces of background, panel,
and buttons
- Next, a application layer to show application surfaces.
- Workspace background layer to show a surface of background image.
- Workspace layer to show launcher to launch application with icons.
Paths to binary and icon are defined in weston.ini. The width of
this layer is longer than the size of screen because a workspace
has several pages and is controlled by motion of input.
Signed-off-by: Nobuhiko Tanibata <NOBUHIKO_TANIBATA@xddp.denso.co.jp>
Acked-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
Nobuhiko Tanibata [Thu, 27 Nov 2014 04:22:53 +0000 (13:22 +0900)]
protocol: ivi hmi controller protocol to set up IVI style UI
- introduces ivi-hmi-controller.xml
This protocol realizes following features,
- UI ready
- changing modes; tiling, side by side, full_screen, and random
- Give control a surface; workspace to be controlled by using ivi layout
APIs
- Display/undisplay a surface; home contains sevaral workspaces to
launch applications
Signed-off-by: Nobuhiko Tanibata <NOBUHIKO_TANIBATA@xddp.denso.co.jp>
Acked-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
Nobuhiko Tanibata [Thu, 27 Nov 2014 04:22:37 +0000 (13:22 +0900)]
ivi-shell: add the shell plugin for In-Vehicle Infotainment system
- ivi-shell.so
- introduces ivi-shell/ivi-shell.[ch]
In-Vehicle Infotainment system traditionally manages surfaces with
global identification. A protocol, ivi_application, supports such a
feature by implementing a request, ivi_application::surface_creation
defined in ivi_application.xml.
The ivi-shell explicitly loads ivi-layout.so and a module to add
business logic like how to layout surfaces by using ivi-layout APIs.
Signed-off-by: Nobuhiko Tanibata <NOBUHIKO_TANIBATA@xddp.denso.co.jp>
Reviewed-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
Nobuhiko Tanibata [Thu, 27 Nov 2014 04:22:00 +0000 (13:22 +0900)]
ivi-shell: add IVI layout APIs
- ivi-layout.so
- introduces ivi-layout-export.h, ivi-layout.[ch]
API set of controlling properties of surface and layer which groups
surfaces. An unique ID whose type is integer is required to create
surface and layer. With the unique ID, surface and layer are identified
to control them. The API set consists of APIs to control properties of
surface and layers about followings,
- visibility.
- opacity.
- clipping (x,y,width,height).
- position and size of it to be displayed.
- orientation per 90 degree.
- add or remove surfaces to a layer.
- order of surfaces/layers in layer/screen to be displayed.
- commit to apply property changes.
- notifications of property change.
Signed-off-by: Nobuhiko Tanibata <NOBUHIKO_TANIBATA@xddp.denso.co.jp>
Acked-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
Nobuhiko Tanibata [Thu, 27 Nov 2014 04:21:34 +0000 (13:21 +0900)]
protocol: add interface ivi_application extension
- introduces ivi-application.xml
Many applications in an IVI-system are special single-purpose
applications that have a very specific role in the whole IVI UI, for
example a rear camera, speedometer, map, etc. The IVI system vendor
specifies what these are and how they integrate into the UI. They also
vary between particular IVI systems. This is why we use (system-)global,
unique, pre-determined ID numbers to tell what wl_surface is which
application, instead of writing specific shell requests for each one.
Using ID numbers allows vendors to easily invent new component
applications without extending or breaking the actual Wayland protocol.
In IVI-systems, the ID is a standard concept already used in several
APIs, with a vendor-specified global definition of ID assignments.
Signed-off-by: Nobuhiko Tanibata <NOBUHIKO_TANIBATA@xddp.denso.co.jp>
Reviewed-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
Nobuhiko Tanibata [Thu, 27 Nov 2014 04:19:23 +0000 (13:19 +0900)]
ivi-shell: add README for ivi-shell
Signed-off-by: Nobuhiko Tanibata <NOBUHIKO_TANIBATA@xddp.denso.co.jp>
Reviewed-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
nerdopolis [Wed, 3 Dec 2014 15:53:03 +0000 (15:53 +0000)]
fbdev: Remove unnecessary semicolon
[daniels: removed extraneous changes]
Giulio Camuffo [Sat, 22 Nov 2014 09:16:56 +0000 (11:16 +0200)]
input: send focus events to the focused client when running a key binding
When running a key binding we don't send the key press to the client
via the wl_keyboard.key event. Instead, send a wl_keyboard.leave/enter
pair so that the client knows the actual state of the keyboard.
Reviewed-by: Daniel Stone <daniel@fooishbar.org>
Derek Foreman [Fri, 21 Nov 2014 18:31:04 +0000 (12:31 -0600)]
rpi-renderer: don't pass a box to pixman_region32_contains_point()
We don't care which box contained the point, so don't pass one in.
Signed-off-by: Derek Foreman <derekf@osg.samsung.com>
Reviewed-by: Bryce Harrington <b.harrington@samsung.com>
Bryce Harrington [Fri, 21 Nov 2014 06:21:57 +0000 (22:21 -0800)]
Use zalloc instead of calloc(1, ...)
Signed-off-by: Bryce Harrington <bryce@osg.samsung.com>
Reviewed-by: Marek Chalupa <mchqwerty@gmail.com>
Bryce Harrington [Fri, 21 Nov 2014 06:21:56 +0000 (22:21 -0800)]
Setting members to 0/NULL after a zalloc or calloc is redundant
calloc (and zalloc) set the allocated memory to 0, so there's really no
need to do it manually.
Signed-off-by: Bryce Harrington <bryce@osg.samsung.com>
Reviewed-by: Marek Chalupa <mchqwerty@gmail.com>
[Pekka: dropped the src/evdev.c hunk.]
Signed-off-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
Bryce Harrington [Fri, 21 Nov 2014 06:21:55 +0000 (22:21 -0800)]
Use zalloc rather than malloc and manually setting members to 0
Signed-off-by: Bryce Harrington <bryce@osg.samsung.com>
Reviewed-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
Derek Foreman [Thu, 20 Nov 2014 21:42:35 +0000 (15:42 -0600)]
clients: Use xmalloc in a few more places
Just changes some places where a malloc failure is unhandled
to our xmalloc function that exit()s a little more gracefully.
Signed-off-by: Derek Foreman <derekf@osg.samsung.com>
Reviewed-by: Bryce Harrington <b.harrington@samsung.com>
Bryce Harrington [Thu, 20 Nov 2014 01:18:36 +0000 (17:18 -0800)]
tests: Use one shared xzalloc implementation
Since this is an inlined function, move it to a common header file.
Signed-off-by: Bryce Harrington <bryce@osg.samsung.com>
Reviewed-by: Marek Chalupa <mchqwerty@gmail.com>
Bryce Harrington [Thu, 20 Nov 2014 01:18:35 +0000 (17:18 -0800)]
tests: Move ARRAY_LENGTH to a shared header for reuse
Signed-off-by: Bryce Harrington <bryce@osg.samsung.com>
Reviewed-by: Marek Chalupa <mchqwerty@gmail.com>
Bryce Harrington [Thu, 20 Nov 2014 01:18:34 +0000 (17:18 -0800)]
tests: Cleanup superfluous headers
Mostly remove headers that aren't actually needed for anything.
Add stdint.h to permit dropping xf86drm.h, which is otherwise unneeded.
Signed-off-by: Bryce Harrington <bryce@osg.samsung.com>
Acked-by: Marek Chalupa <mchqwerty@gmail.com>
Tested-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
Bryce Harrington [Thu, 20 Nov 2014 01:18:33 +0000 (17:18 -0800)]
tests: Include "config.h" as first header
Signed-off-by: Bryce Harrington <bryce@osg.samsung.com>
Derek Foreman [Thu, 20 Nov 2014 21:32:40 +0000 (15:32 -0600)]
dnd: Fix some mouse cursor issues
When ending a drag in the window the cursor will be wrong until the mouse
is moved again. This is because the item being dragged isn't added
until after the enter event.
Also, when picking up an item while moving the mouse the cursor can switch
back to a non-drag cursor before the drag begins. This is because of a
slight delay between button click and drag start.
Finally picking up or dropping an item under a second pointer could cause
that pointer to have the wrong cursor.
Closes one of the issues in bug 56298
https://bugs.freedesktop.org/show_bug.cgi?id=56298
Signed-off-by: Derek Foreman <derekf@osg.samsung.com>
Tested-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
Derek Foreman [Wed, 19 Nov 2014 17:04:12 +0000 (11:04 -0600)]
input: Use slightly less obscure logic in evdev_notify_keyboard_focus()
While the test is actually correct (for non-negative numbers), it's not
at all clear and seems to be an accidental order of operations mistake.
Also, add an assert() to make sure this number is never negative.
Closes bug 86346 - https://bugs.freedesktop.org/show_bug.cgi?id=86346
Signed-off-by: Derek Foreman <derekf@osg.samsung.com>
Reviewed-by: Marek Chalupa <mchqwerty@gmail.com>
Pekka Paalanen [Tue, 25 Nov 2014 07:56:53 +0000 (09:56 +0200)]
simple-shm: explain two initial roundtrips
Explain carefully why we need two roundtrips, not just one, not just
dispatch and roundtrip, but two roundtrips after creating the
wl_registry object.
v2: Explain what initial events are, and that this is a general
technique.
Signed-off-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
Reviewed-by: Marek Chalupa <mchqwerty@gmail.com>
Pekka Paalanen [Wed, 26 Nov 2014 11:48:29 +0000 (13:48 +0200)]
configure: remove input backend result
Don't print a line with empty value.
Signed-off-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
Peter Hutterer [Tue, 25 Nov 2014 21:06:31 +0000 (07:06 +1000)]
compositor: Drop legacy backends in favor of libinput
Reviewed-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
Pekka Paalanen [Thu, 20 Nov 2014 08:15:07 +0000 (10:15 +0200)]
desktop-shell: don't crash input-panel if no kbd focus
If a keyboard exists but it has no current focus, yet something asks the
input-panel to come up, we would crash here. Check that there is a focus
before attempting to use it.
Maybe there should not even exist a case where input-panel tries to come
up without a keyboard focus, but I am not sure there is no race where it
could happen.
In any case, this fix was brought up by the ivi-shell work, where I
suppose you can somehow hit it.
Signed-off-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
Cc: Tanibata, Nobuhiko <ntanibata@jp.adit-jv.com>
Giulio Camuffo [Thu, 20 Nov 2014 21:03:22 +0000 (23:03 +0200)]
input: don't run the key bindings on focus in
When getting the focus we get the list of pressed keys, but we are
not supposed to run the key binding on them.
Reviewed-by: Daniel Stone <daniel@fooishbar.org>
Derek Foreman [Wed, 19 Nov 2014 23:06:20 +0000 (15:06 -0800)]
tests: Allow tests to use customized command line parameters
Tests will now return the extra command line parameters they need
when run with --params
Signed-off-by: Bryce Harrington <bryce@osg.samsung.com>
Reviewed-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
Bryce Harrington [Wed, 19 Nov 2014 23:06:19 +0000 (15:06 -0800)]
compositor: Document options for headless compositor
Signed-off-by: Bryce Harrington <bryce@osg.samsung.com>
[Pekka: s/Wayland surface/memory surface/, and say default renderer.]
Signed-off-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
Derek Foreman [Wed, 19 Nov 2014 23:06:18 +0000 (15:06 -0800)]
compositor-headless: add support for transforms set on command line
We now allow --transform with the headless compositor, however it still
doesn't parse anything out of weston.ini
Signed-off-by: Bryce Harrington <bryce@osg.samsung.com>
Reviewed-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
Derek Foreman [Wed, 19 Nov 2014 23:06:17 +0000 (15:06 -0800)]
compositor-headless: allow rendering with pixman
Allow the headless backend to render into an off screen buffer with pixman.
Signed-off-by: Bryce Harrington <bryce@osg.samsung.com>
Reviewed-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
Bryce Harrington [Wed, 19 Nov 2014 23:06:16 +0000 (15:06 -0800)]
configure.ac: Indicate headless compositor presence in config.h
Signed-off-by: Bryce Harrington <bryce@osg.samsung.com>
Reviewed-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
Pekka Paalanen [Fri, 21 Nov 2014 14:11:44 +0000 (16:11 +0200)]
man: explain idle-time=0 in weston.ini
Signed-off-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
Frederic Plourde [Thu, 30 Oct 2014 19:06:34 +0000 (15:06 -0400)]
compositor: Add idle timeout option to weston.ini
Weston's idle timeout can already be set via the '-i' command-line
option, but this patch lets users specify it also via weston.ini.
Note that the command-line option takes precedence over the .ini,
should the option be set by both.
This patch also Updates weston.ini man page with idle-timeout bits
https://bugs.freedesktop.org/show_bug.cgi?id=83921
Signed-off-by: Frederic Plourde <frederic.plourde@collabora.co.uk>
Reviewed-by: Bryce Harrington <b.harrington@samsung.com>
Marek Chalupa [Wed, 29 Oct 2014 12:44:44 +0000 (13:44 +0100)]
xwayland: fix fullscreening
set_fullscreen has been sending configure before changing the state
and xwayland windows added border to the fullscreen size.
This fixes the bug:
https://bugs.freedesktop.org/show_bug.cgi?id=83502
Signed-off-by: Marek Chalupa <mchqwerty@gmail.com>
Reviewed-by: Ryo Munakata <ryomnktml@gmail.com>
Tested-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
Javier Jardón [Mon, 27 Oct 2014 15:13:19 +0000 (15:13 +0000)]
Makefile.am: Link weston_multi_resource against rt library
This fixes this build failure:
/usr/lib/gcc/x86_64-unknown-linux-gnu/4.7.3/../../../../x86_64-unknown-linux-gnu/bin/ld:
clients/weston_multi_resource-multi-resource.o: undefined reference to
symbol 'clock_gettime@@GLIBC_2.2.5'
/usr/lib/gcc/x86_64-unknown-linux-gnu/4.7.3/../../../../x86_64-unknown-linux-gnu/bin/ld:
note: 'clock_gettime@@GLIBC_2.2.5' is defined in DSO /lib64/librt.so.1
so try adding it to the linker command line
/lib64/librt.so.1: could not read symbols: Invalid operation
Derek Foreman [Thu, 16 Oct 2014 21:37:02 +0000 (16:37 -0500)]
gl-renderer: compress pixman bands to simplify geometry
Pixman uses y-x banded rectangles to represent regions. We use these
y-x banded rectangles to generate triangle fans, resulting in more
geometry than strictly necessary to draw the screen.
This patch combines the bands to reduce geometry for complex scenes.
Acked-by: "Jasper St. Pierre" <jstpierre@mecheye.net>
Tested-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
Derek Foreman [Thu, 23 Oct 2014 17:24:18 +0000 (12:24 -0500)]
backends: refactor transform string parsing
Most of the backends do their own parsing of transform strings, so let's
put that all in the same place (compositor.c/h)
Reviewed-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
Marek Chalupa [Wed, 29 Oct 2014 13:51:23 +0000 (14:51 +0100)]
cairo-util: fix shadows for small clients
If the client is small (< 128 pixels in any ward),
then the shadows overlap and create dark lines behind clients.
This is a problem mosly with pop-up menues. The lines become observable
when the menu has less than three items. The other case is when
the client doesn't restrict its size when resizing (try
'weston-eventdemo --max-width=1 --max-height=1' for example)
This fixes a part of the bug:
https://bugs.freedesktop.org/show_bug.cgi?id=78511
v2:
- rework computing of the size of corners
- rewrite some comments
- rename tile_mask to render_shadow (in separate patch)
Signed-off-by: Marek Chalupa <mchqwerty@gmail.com>
Tested-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
Marek Chalupa [Wed, 29 Oct 2014 13:51:22 +0000 (14:51 +0100)]
toytoolkit: rename tile_mask to render_shadow
This function is used and clearly designed only for drawing the shadows.
Rename it so that it has name after what it does and also move some
common code into the function.
Signed-off-by: Marek Chalupa <mchqwerty@gmail.com>
Reviewed-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
Seedo Eldho Paul [Sun, 16 Nov 2014 13:34:04 +0000 (19:04 +0530)]
protocol: Fix some typos in protocol files
Signed-off-by: Seedo Eldho Paul <seedoeldhopaul@gmail.com>
Reviewed-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
Pekka Paalanen [Wed, 19 Nov 2014 11:43:32 +0000 (13:43 +0200)]
Revert "input: don't send to clients key events eaten by bindings"
This reverts commit
5c11fc6fb7d9b1bccd50fc982c0798c9e09a2a04.
According to two input specialists, this was the wrong way:
http://lists.freedesktop.org/archives/wayland-devel/2014-November/018287.html
Cc: Peter Hutterer <peter.hutterer@who-t.net>
Cc: Daniel Stone <daniel@fooishbar.org>
Cc: Giulio Camuffo <giuliocamuffo@gmail.com>
Signed-off-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
Pekka Paalanen [Tue, 18 Nov 2014 13:57:04 +0000 (15:57 +0200)]
compositor: do not overwrite error exit code
If there are several things that cause an exit, keep the error code from
the first one, not the last one. The latter ones could be just fallout
from the first.
Signed-off-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
Frederic Plourde [Wed, 29 Oct 2014 18:44:33 +0000 (14:44 -0400)]
compositor: Return a user-defined exit code
Currently, once we've reached our main's wl_display_run(), we always
return ret=EXIT_SUCCESS when weston terminates through wl_display_terminate.
This patch makes it possible to specify another return value by setting
prior to terminating Weston. This is useful for automated tests that want
to report test failures to the overlying testing infrastructure.
Signed-off-by: Frederic Plourde <frederic.plourde@collabora.co.uk>
[Pekka: fixed some tabs.]
Signed-off-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
Giulio Camuffo [Sat, 4 Oct 2014 10:58:33 +0000 (13:58 +0300)]
xwm: find a seat for all the surface's views
This allows to move or resize a xwayland client by acting on all
its views.
Pekka Paalanen [Wed, 12 Nov 2014 14:42:52 +0000 (16:42 +0200)]
input: use tmp var in pointer_unmap_sprite
Remove lots of repeated indirection.
Signed-off-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
Giulio Camuffo [Tue, 11 Nov 2014 09:23:40 +0000 (11:23 +0200)]
input: don't send to clients key events eaten by bindings
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 key binding hiding a surface having the keyboard focus,
the shell may decide to give the focus to another surface, but that will
happen before the key is released, so the new focus surface will receive
the code of the bound key in the wl_keyboard.enter array.
Reviewed-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
Pekka Paalanen [Tue, 11 Nov 2014 12:10:46 +0000 (14:10 +0200)]
compositor: add missing newline to help text
Signed-off-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
Bryce Harrington [Thu, 23 Oct 2014 22:25:04 +0000 (15:25 -0700)]
compositor: List only available backends in help text
Signed-off-by: Bryce Harrington <bryce@osg.samsung.com>
Reviewed-by: Derek Foreman <derekf@osg.samsung.com>
Bryce Harrington [Thu, 23 Oct 2014 22:25:03 +0000 (15:25 -0700)]
compositor: Display option help text only for enabled backends
Signed-off-by: Bryce Harrington <bryce@osg.samsung.com>
Reviewed-by: Derek Foreman <derekf@osg.samsung.com>