Summary: This was a file that should have been updated with
the bump to xdg_shell version 5 however it was not pushed with that
update.
@fix
Signed-off-by: Chris Michael <cp.michael@samsung.com>
Summary: In order for wayland events to be processed properly, we
should be dispatching any pending events off of the queue First before
we make the call to flush.
@fix
Signed-off-by: Chris Michael <cp.michael@samsung.com>
Summary: This updates the xdg_shell protocol and code to support
XDG_SHELL version 5. This allows EFL/Elm apps to function again in
Weston.
@fix
Signed-off-by: Chris Michael <cp.michael@samsung.com>
Summary: When we generate an Ecore key down/up event, we should also
be setting the keycode in the event structure
@fix
Signed-off-by: Chris Michael <cp.michael@samsung.com>
Summary: As input->grab_count is an unsigned int there is no need for
the < 0 comparison as that will always return false
@fix
Signed-off-by: Chris Michael <cp.michael@samsung.com>
Summary:
The touch screen device generates touch events.
But in some special enviroments, a first finger will be matched to a pointer event(not touch event).
And other fingers (second, third, ...) will be matched touch events.
In that case ecore_wl_input_ungrab() is called abnormally.
A first finger pressed, _ecore_wl_input_cb_pointer_button() call ecore_wl_input_grab().
A second finger pressed, _ecore_wl_input_cb_touch_down() is called but not grab.
But when a second finger is released, _ecore_wl_input_cb_touch_up() call ecore_wl_input_ungrab()
So ungrab function generate two mouse up events and a first finger is released.
In other case, first finger pressed -> second finger pressed -> first finger release.
That case when a first finger released a second finger release event is generated.
So after that application doesn't get a release event about a second finger
when a second finger is really released.
I think in a multitouch case, ungrab function will be called when a all finger are released.
So I add a grab_count variable for count currently touched fingers.
And only called a ungrab funtion all fingers are released.
Test Plan:
In a touch screen supported multitouch, press two or more fingers and release.
And watch events generation.
Reviewers: raster, devilhorns
Subscribers: cedric
Differential Revision: https://phab.enlightenment.org/D2481
Summary: ecore_wl_dpi_get will return the correct value after wl_output's events are handled
Reviewers: zmike, devilhorns, bryceharrington
Subscribers: cedric
Differential Revision: https://phab.enlightenment.org/D2479
Summary:
ecore_wayland get a key information using libxkbcommon's functions.
Also generate key repeat check xkb keymap's information using xkb_keymap_key_repeats().
But xkb rules reflect X broken keycodes, so offset by 8.
In ecore_wayland backend, other xkb funtions using offset keycode
but only use default keycode to check key repeat.
So I fix it to use xkb ruled keycode.
Test Plan: Long press a key and watch repeated key events generate well
Reviewers: devilhorns, raster
Subscribers: cedric
Differential Revision: https://phab.enlightenment.org/D2475
Summary: Since evas handles surface damage & surface commit roles now,
we no longer are calling ecore_wl_commit inside ecore_evas. This was
causing the surface opaque & input regions to no longer be set. We fix
that here by creating and setting opaque/input regions whenever the
appropriate ecore_wl region functions are called.
@fix
Signed-off-by: Chris Michael <cp.michael@samsung.com>
Some fields (eg. data) may not be properly initialized.
Use calloc() instead of malloc() will ensure proper initialization
even if we add more fields.
These fields (data) would even be passed down to Evas as
Evas_Event_Key_Down for instance.
Summary:
Wayland API routines by policy do not check input parameters for invalid
values. In particular, many calls are wrappers through
wl_proxy_marshal, which derefs its first argument without a check.
So, for all wayland calls, always null check the first argument.
Reviewers: zmike, cedric
Subscribers: cedric
Differential Revision: https://phab.enlightenment.org/D2211
Summary:
The other functions in this module check inputs; this one should as
well.
Reviewers: zmike
Subscribers: cedric
Differential Revision: https://phab.enlightenment.org/D2210
Summary:
Most of the other ecore-wayland API will return NULL in the (hopefully
theoretical) case of bad inputs; this API routine should so similarly
for consistency.
Reviewers: zmike, cedric
Subscribers: cedric
Differential Revision: https://phab.enlightenment.org/D2181
Summary:
For calls that return pointers, specify that NULL is a
potential return value. Add API documentation for some misc. routines
missing it.
Reviewers: zmike, cedric, devilhorns
Subscribers: cedric
Differential Revision: https://phab.enlightenment.org/D2180
size/position
Summary: We should be implementing xdg_surface_set_window_geometry for
efl apps, so this commit adds the function call to that.
@fix
Signed-off-by: Chris Michael <cp.michael@samsung.com>
get them
Summary: Some keys in certain keyboard layouts should not be repeated
so add a test which uses xkb to inform us if this key supports
repeating.
@fix
Signed-off-by: Chris Michael <cp.michael@samsung.com>
actually have a grabbed button
Summary: If we don't have an actual grabbed mouse button, then don't
send a mouse up event. Caught this while adding e_grabinput support to
Enlightenment.
@fix
Signed-off-by: Chris Michael <cp.michael@samsung.com>
Summary: If we are using a touchscreen, there will be no pointer and
thus no cursor_name to use. Trap for that case by checking if
input->cursor_name is valid.
@fix
Signed-off-by: Chris Michael <cp.michael@samsung.com>
Summary: When we do an input_ungrab, we should be sending a mouse up
event so that apps/elm/etc know that the mouse has been released. This
fixes an issue in the Elm Features DnD test report by Daniel Zaoui
@fix
Signed-off-by: Chris Michael <cp.michael@samsung.com>
Summary: We should not be setting a 'move' cursor unless we actually
make the call to start a drag
@fix
Signed-off-by: Chris Michael <cp.michael@samsung.com>
Summary: We can make opaque and input region handling simplier if we
just use one opaque & input region per window. Previous code would
always create a new region, set it to the surface, then destroy it.
This code works much nicer in that it hammers the protocol with less
region create/destroy calls.
@fix
Signed-off-by: Chris Michael <cp.michael@samsung.com>
Summary:
Since xdg-shell is not yet supported officialy by wayland
It makes sense to have it disabled by default
and enable it on purpose.
Using env variable : EFL_WAYLAND_DONT_USE_XDG_SHELL
(name is inspired from Qt implementation of xdg-shell
but in the opposite way)
There is no EFL_WAYLAND_USE_XDG_SHELL in efl,
please use EFL_WAYLAND_DONT_USE_XDG_SHELL instead.
By default xdg-shell is enabled since it's supported by efl
Since there is only one shell supported at runtime
it's easier to switch to wl-shell (wayland's fallback shell)
by change this env variable.
Note, this patch can be reverted once xdg-shell replaces wl-shell
in wayland which is not the case in weston-1.6
but could integrated into upcoming wayland-1.7
(to be confirmed on release)
Change-Id: Id3732492397df9abe4a7c9e6e92a8f2c993c8395
Bug: https://phab.enlightenment.org/T1901
Bug-Tizen: TC-1353/part
Forwarded: https://phab.enlightenment.org/T1901
Signed-off-by: Philippe Coval <philippe.coval@open.eurogiciel.org>
Tizen Test Plan: echo 'export EFL_WAYLAND_DONT_USE_XDG_SHELL=defined' > /etc/profile.d/ecore.sh
Reviewers: seoz, devilhorns
Reviewed By: devilhorns
Subscribers: cedric
Differential Revision: https://phab.enlightenment.org/D1734
Summary: Calling wayland library functions with NULL typically leads
to an abort, so add a safety check for valid xdg_surface before
calling function
@fix
Signed-off-by: Chris Michael <cp.michael@samsung.com>
Summary: xdg_shell_get_xdg_popup could return NULL, in which case any
calls below would cause an abort in the wayland libraries, so this
adds a trap for that.
@fix
Signed-off-by: Chris Michael <cp.michael@samsung.com>
Summary: We cannot call wl_proxy_get_id if the surface creation failed
else that would lead to an abort in the wayland libraries. This commit
adds a safety check
@fix
Signed-off-by: Chris Michael <cp.michael@samsung.com>
directly below.
Summary: Not much of a functional change, just removing an extra
unnecessary line. Input is being set directly below this with an if
(!( line, so no point in this one.
@fix
Signed-off-by: Chris Michael <cp.michael@samsung.com>
Summary: If wl_region_create fails, then we cannot call wl_region
functions on a NULL region. That causes the wayland libraries to
abort, so let's add a safety check so that we don't crash.
@fix
Signed-off-by: Chris Michael <cp.michael@samsung.com>
the function.
Summary: If the compositor fails to create a new opaque region, then
we cannot call wl_region functions on a NULL region. This leads to an
abort in the wayland libraries, so let's trap the return of
wl_region_create and exit safely
@fix
Signed-off-by: Chris Michael <cp.michael@samsung.com>
Summary:
Added a condition to check if system has mouse before setting
the cursor on surface.
@fix
Signed-off-by: vivek <vivek.ellur@samsung.com>
Reviewers: devilhorns
Subscribers: cedric
Differential Revision: https://phab.enlightenment.org/D1707
Summary:
Fixed a request of start_drag with null value.
The request with null value has caused SIGABRT and printed
"error marshalling arguments for start_drag (signature ?oo?ou):
null value passed for arg 1".
@fix
Test Plan:
1. Run enlightenment(wayland)
2. Run elementary_test -to FeatureDnd on enlightenment
3. Click any image and try to drag it.
(Without this revision, SIGABRT will occur
and with this revision, will not.)
Reviewers: gwanglim, devilhorns
Subscribers: cedric
Differential Revision: https://phab.enlightenment.org/D1720
Summary:
Fixed the issue of UnIconifying an xdg_surface which is
needed for Enlightenment IBox scenario.
@fix
Signed-off-by: vivek <vivek.ellur@samsung.com>
Reviewers: devilhorns
Reviewed By: devilhorns
Subscribers: cedric
Differential Revision: https://phab.enlightenment.org/D1593
Summary:
_ecore_wl_shutdown should return int instead of EINA_BOOL. So changing the function prototype.
@fix
Signed-off-by: Srivardhan Hebbar <sri.hebbar@samsung.com>
Reviewers: devilhorns
Subscribers: cedric
Differential Revision: https://phab.enlightenment.org/D1574
init
Summary: If someone calls ecore_wayland_shutdown without first calling
ecore_wl_init, then the init count is wrong. Warn the caller.
@fix
Signed-off-by: Chris Michael <cp.michael@samsung.com>
Summary:
If _ecore_wl_init_count goes below zero, then there would be problem if someone calls ecore_wl_shutdown 1st and then ecore_wl_init later. So fixing this issue in ecore_wl_shutdown.
@fix
Signed-off-by: Srivardhan Hebbar <sri.hebbar@samsung.com>
Reviewers: devilhorns
Reviewed By: devilhorns
Subscribers: cedric
Differential Revision: https://phab.enlightenment.org/D1571
clients
Summary: When flush_clients is called, those clients may add events to
the queue. We should be waiting to dispatch pending events until After
clients have been flushed.
@fix
Signed-off-by: Chris Michael <cp.michael@samsung.com>
Summary: This adds a private function to call when a surface gets
deleted so we can cleanup properly.
@fix
Signed-off-by: Chris Michael <cp.michael@samsung.com>
Summary:
We had some duplication happening here when the IVI shell code got
added. This cleans up the surface creation code (parts of it were
being duplicated)
@fix
Signed-off-by: Chris Michael <cp.michael@samsung.com>
xdg_shell protocol provides functions to minimize a surface. This is
now implemented via ecore_wl_window_iconified_set.
NB: This Does Not work for wl_shell surfaces because wl_shell provides
no method to minimize.
Signed-off-by: Chris Michael <cp.michael@samsung.com>
These API functions will be called from ecore_evas to iconify an
Ecore_Wl_Window. This is implemented in the xdg_shell protocol
@feature
Signed-off-by: Chris Michael <cp.michael@samsung.com>
Wayland 1.6 is due in 2 weeks. The existing xdg_shell code here will
not function with current wayland (from git) unless we bump the xdg
version number.
@fix
Signed-off-by: Chris Michael <cp.michael@samsung.com>
xdg_shell supports setting a "class name" on a window by using
xdg_surface_set_app_id. This commit implements that.
@fix
Signed-off-by: Chris Michael <cp.michael@samsung.com>
We could have either wl_shell OR xdg_shell, so check if we have either
one before dispatching the interfaces_bound event.
@fix
Signed-off-by: Chris Michael <cp.michael@samsung.com>
places
Some paramaters here were being used, while others were not. This
fixes the various usage of EINA_UNUSED here to be proper.
Signed-off-by: Chris Michael <cp.michael@samsung.com>
Calloc 'can' fail so lets check the return and make sure 'global' is
valid else we will segfault.
@fix
Signed-off-by: Chris Michael <cp.michael@samsung.com>
Summary:
Added cursor_name to Ecore_Wl_Window so that we can compare with input cursor name and avoid unnecessary cursor set calls to wayland.
Signed-off-by: Srivardhan Hebbar <sri.hebbar@samsung.com>
Reviewers: devilhorns
Subscribers: cedric
Differential Revision: https://phab.enlightenment.org/D1481
Summary:
1) Created a event struct for data source cancel event
2) Raise a event when data source is cancelled
Signed-off-by: vivek <vivek.ellur@samsung.com>
Reviewers: devilhorns
Subscribers: cedric
Differential Revision: https://phab.enlightenment.org/D1465
Summary:
Instead of repeating the clean-up code if any initialization fails in the init function, I've moved those to one location and added goto.
Signed-off-by: Srivardhan Hebbar <sri.hebbar@samsung.com>
Reviewers: devilhorns
Subscribers: cedric
Differential Revision: https://phab.enlightenment.org/D1461
Summary:
1. Added cursor_theme_name to Ecore_Wl_Input struct.
2. Made it configurable through environment variable ECORE_WL_INPUT_CURSOR_THEME_NAME.
3. Added a API ecore_wl_cursor_theme_name_set for user to set manually.
Signed-off-by: Srivardhan Hebbar <sri.hebbar@samsung.com>
Reviewers: devilhorns
Subscribers: cedric
Differential Revision: https://phab.enlightenment.org/D1458
Summary:
1. Added cursor_size to Ecore_Wl_Input struct.
2. Made it configurable through environment variable ECORE_WL_INPUT_CURSOR_SIZE.
3. Added a API ecore_wl_input_cursor_size_set for user to set manually.
Signed-off-by: Srivardhan Hebbar <sri.hebbar@samsung.com>
Reviewers: devilhorns
Subscribers: cedric
Differential Revision: https://phab.enlightenment.org/D1456
Conflicts:
src/lib/ecore_wayland/ecore_wl_private.h
This commit moves the typedef struct to just above the structure, and
moves the external variable below the structure definition. No real
functional changes, just some cleanup.
Signed-off-by: Chris Michael <cp.michael@samsung.com>
When the application exits, an event cancels the DnD, that invokes the
Wayland release of data source but this was not setting an internal
pointer to NULL. ecore_wl_shutdown was then trying to use the same
Wayland API on the non-set internal pointer (via _ecore_wl_input_del),
that was leading to a segmentation fault.
This bug never occurred because some bug in Copy&Paste was preventing it
to reach this part of code.
than one output.
ecore_wl_screen_size_get function Should take into account all
existing outputs. Modify code to loop outputs and add up the sizes.
@fix
Signed-off-by: Chris Michael <cp.michael@samsung.com>
If we declare/define these functions Before they are needed in the
listener, then we can remove the need for using function prototypes.
@fix
Signed-off-by: Chris Michael <cp.michael@samsung.com>
IVI-Shell is a wayland shell implementation for in-vehicle infotainment.
Summary: This is a set of patches proposed to implement IVI-Shell (https://phab.enlightenment.org/T1552).
Reviewers: ntanibata, devilhorns
Subscribers: mbachmann
Projects: #efl
Differential Revision: https://phab.enlightenment.org/D1350
@feature