Commit Graph

128 Commits

Author SHA1 Message Date
Derek Foreman aa8d9c1829 ecore_evas: Add a function pointer for last_tick_get
Engines that provide their own tickers may need to be able to provide the
time of the last tick even if they weren't sending ticks to EFL at the
time.

This is a feature added during freeze as it's necessary to resolve a bug.

ref T5462
2017-07-13 18:07:42 -05:00
Derek Foreman e69cc0f552 ecore_evas engines: Add some nulls to the func arrays
Purely cosmetic, but gets the comments back in sync with reality.
2017-07-13 18:07:41 -05:00
Jean-Philippe Andre 76a668f022 ecore_evas_x: Track changes in framespace size
If the framespace size has changed and by accident (or in fact, by
design) the evas size + framespace size is equal to the size sent
by the X server, ecore_evas_x was skipping the resize event. This
patch adds a tracking of the framespace size so that we redraw the
canvas if it changed.

This will fix issues with the main menu (since it's in the framespace,
23 pixels tall with the default theme & scale).

Note that all this is partly because the ecore evas size is the size
without the framespace, so weird calculations are made during resize...

Ref T5482
2017-07-05 17:43:59 +09:00
Jean-Philippe Andre e8f9f109a6 evas: Rename device Class to Type, remove Sub_Class
1. The word "class" is a pain point with many languages where
   it's a keyword. Type is a little better. Also, the property
   was already named "device_type" and not "device_class".

2. Remove Efl.Input.Device.Sub_Class
   It's not used inside EFL upstream codebase, and unlikely to
   be used anywhere else (even in Tizen).

Hopefully no one used the Efl_ enum types. So far only the Evas_
types should be in used.

Ref T5540
2017-06-12 15:21:55 +09:00
Chris Michael d57bdb5fbc ecore-evas-x: Remove blank line
NB: No functional changes

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2017-06-08 14:29:02 -04:00
Mike Blumenkrantz 1e6e5047be ee engines: update engines for per-seat cursor objects
ref 5856d3b52f6124ad5b4cfe47b21f28ab6f380002
2017-06-02 18:23:42 -04:00
Cedric Bail 73592d4e72 ecore_evas: first step into refactoring x backend. 2017-05-05 17:55:06 -07:00
Mike Blumenkrantz 57412cba94 ecore-evas-x: set flag for maximized state
fixes initial maximize state
2017-03-10 15:54:21 -05:00
Jean Guyomarc'h 566b23dcb8 ecore_evas/x: don't mark as unused a used parameter 2017-03-07 20:23:12 +01:00
Cedric BAIL 8f1c071d6a eina: rename EINA_{FLT,DBL}_CMP to EINA_{FLT,DBL}_EQ. 2017-01-06 15:58:46 -08:00
Guilherme Iscaro 044219226c Ecore Evas: Add support for multiple mouse positions.
Since it's possible to have more than one mouse, Ecore Evas
must take into account the position of all mouses and update them
correctly.
2016-12-20 18:34:39 -02:00
Guilherme Iscaro e5acc5604a Ecore Evas: Add support to set cursor icon per mouse device.
Since Ecore Evas now supports multiple mouses new APIs were added
in order to be able to set the cursor image to any device.
2016-12-20 18:34:39 -02:00
Guilherme Iscaro 64986bccac Ecore Evas: Add API to set/get the pointer position per device.
Since Ecore Evas now support multiple mouse devices new APIs were
added in order to fetch the mouse position.
2016-12-20 18:34:39 -02:00
Chris Michael 2bc53c9013 ecore-evas-x: remove float comparison warning from X backend
Signed-off-by: Chris Michael <cp.michael@samsung.com>
2016-12-20 08:54:01 -05:00
Jean-Philippe Andre 348bd11609 ecore_evas/x: Fix window size when framespace != 0
This fixes the sizing of EDI. And elm_test "States 2"

The sizes stored in ecore_evas are the "window content" sizes,
excluding the framespace which thus must be added to all calls
to ecore_x / Xlib.
2016-12-02 17:21:47 +09:00
Guilherme Iscaro 75619fc290 Ecore Evas: Add multi seat support for mouse in/out. 2016-11-28 13:57:55 -02:00
Guilherme Iscaro be609118c6 Ecore_Evas: Add support for per-seat focus. 2016-11-28 13:57:55 -02:00
Jean-Philippe Andre b2dbf9d9dd win: Fix maximized geometry with CSD in X
There is still a geometry issue after un-maximizing.
2016-11-23 13:04:12 +09:00
Jean-Philippe Andre 4722b685cf ecore_evas/x: Inform WM about borders and shadows
This exploits the existing X Atom "GTK_FRAME_EXTENTS"
2016-11-23 13:04:12 +09:00
Jean-Philippe Andre 86e18c3f61 ecore_evas/x: Take framespace into account during resize
This is another step towards CSD support for X.
2016-11-23 13:04:12 +09:00
Carsten Haitzler 4ed2e01591 remove xcb support in ecore_x and evas engines as per mailing list
as per mailing list discussion about dropping xcb support now. it
hasn't been complete for a long time, thus not recommented for being
turned on. as we are moving to a wayland world xcbmakes even less
sense. as agreed, time to clean up a bit and remove a distraction as
well as not well tested code. this also updates po's too.

@feature
2016-11-03 22:22:54 +09:00
Jean-Philippe Andre 7f57e23670 ecore_evas/x: Minor code simplification 2016-11-03 17:22:15 +09:00
Guilherme Iscaro 4bffa7bfa7 ecore_evas: refactor VNC as an Eina Module.
Summary:
This change removes the necessity to link EFL against the libvncserver

Please ignore the first three commits, they're being reviewed here:

https://phab.enlightenment.org/D4323

Reviewers: bdilly, cedric

Reviewed By: cedric

Subscribers: cedric, jpeg

Differential Revision: https://phab.enlightenment.org/D4338

Signed-off-by: Cedric Bail <cedric@osg.samsung.com>
2016-10-28 09:56:47 -07:00
Guilherme Iscaro 8040d20f90 This series fixes two problems in the VNC implementation.
One deadlock and one segfault.

Patch 1:

Software X11 Evas Engine: Fix deadlock

Summary:
The patch bc6e8d2692 introduced a callback responsible to notify the pixels
that were sent to the X server. Since all EFL rendering is done by another
thread, the callback should be called from the main thread context.
To achieve this behaviour evas_software_x11_region_push_hook_call()
was using ecore_thread_main_loop_begin(), which may cause deadlocks, since
evas mainloop waits for the render thread and the render thread waits
the mainloop.

In order to fix this problem, the function
ecore_main_loop_thread_safe_call_async() will be used to
schedule the callback to run in the main loop context.

Since a callback is schedule to run in async manner, the pixels that
were sent to the X server must not be deleted until the user is informed.
In order to avoid more mallocs(), this patch adds the support for refcounts to the
X_Output_Buffer and Xcb_Output_Buffer.

Patch 2:

Ecore_Evas VNC: Use the image size to create the buffer.

In same cases they may differ and may lead to a segfault, since
memcpy() causes a buffer overrun.

Reviewers: bdilly, raster

Reviewed By: raster

Subscribers: cedric, jpeg

Differential Revision: https://phab.enlightenment.org/D4323
2016-10-21 13:56:00 +09:00
Carsten Haitzler f9f94bcb5f ecore_evas - fix setting urgent immediately after show
fixes T4726
2016-10-14 11:11:07 +09:00
Carsten Haitzler 690319b2f3 ecore-evas - x fix intial iconified state so terminology -I works
this fixes intitial iconic state for x11 as demonstrated by

terminology -I

but enlightenment is broken though... xterm -iconic also shows the
same break with a black window.

@fix
2016-10-06 11:00:52 +09:00
Carsten Haitzler 2d0be47290 ecore_evas x - dont set withdrawn to fals on show but wait for wm state
so we handled override cases and set withdrawn to false on show, but
when normally managed it might be nicer to wait for a state change via
the wm state property to know we are "normal"

this should fix T4699

@fix
2016-10-06 11:00:52 +09:00
Carsten Haitzler 9a2e14faad Revert "ecore_evas x - dont set withdrawn to fals on show but wait for wm state"
This reverts commit 2c736adc87.

well that was totally unexpected. - efl app windows dont show at all..
wtf? this should not have affected that at all..
2016-10-06 08:53:19 +09:00
Carsten Haitzler 2c736adc87 ecore_evas x - dont set withdrawn to fals on show but wait for wm state
so we handled override cases and set withdrawn to false on show, but
when normally managed it might be nicer to wait for a state change via
the wm state property to know we are "normal"

this should fix T4699
2016-10-06 08:40:27 +09:00
Guilherme Iscaro 50f5704cc6 Evas_Device: Fix API name.
Summary:
It should be evas_device_add_full() in order to follow the EFL
name pattern.

Reviewers: DaveMDS, bdilly

Reviewed By: DaveMDS, bdilly

Subscribers: cedric, jpeg

Differential Revision: https://phab.enlightenment.org/D4325
2016-09-29 17:51:15 -03:00
Guilherme Iscaro 491fda4796 Ecore_Evas_X: Dispatch Ecore_Events for VNC clients.
This patch adds the support for Ecore events from a remove
VNC client. Every time it happens a VNC mouse move/click/wheel or a
VNC keyboard event an Ecore event event will be created and dispatched.
2016-09-26 22:06:59 -03:00
Guilherme Iscaro bc6e8d2692 Ecore_Evas_X: Add VNC draw support.
This patch adds the support to draw the X11 screen contents to
all remove VNC clients.
2016-09-26 22:06:59 -03:00
Derek Foreman 398771bf8a evas_engines: Add fn_evas_changed callback
To allow using the pageflip completion event to drive timing in the DRM
engine we need to know as soon as possible that a render has been after
a render has been considered if it will cause a page flip or not.

The fn_evas_changed callback sends this information.
2016-09-08 13:55:23 -05:00
Jean-Philippe Andre 014295fbc9 ecore_evas: Fix mouse in/out events
Apparently I broke some inputs in E (efm) like mouse wheel.
Somehow the list of objects where the pointer is in was NULL.
This was because the mouse_in/out events were not matched to
the proper window ID.

Fixes T3760
2016-06-02 14:19:18 +09:00
Jean-Philippe Andre 8e31929aab Efl.Pointer.Event: Add dup() method to copy an event 2016-05-31 19:03:04 +09:00
Jean-Philippe Andre 05dfab8442 ecore_x: Pass in/out through ecore_input_evas
This whole input system is a massive mess. It looks like spaghetti.
Long live the giant flying monster.

This commit changes how some events are propagated in X.

Before:
 ecore_x -> evas_event -> evas

After:
 ecore_x -> ecore_input_evas -> ecore_evas -> evas_event -> evas

There are still inconsistencies between events and between X and WL,
but ecore_evas should be used for all events since it rotates the
inputs.
2016-05-31 19:03:04 +09:00
Jean-Philippe Andre 5aa00004a5 ecore_evas: Register direct input cb from modules
If the ecore_evas modules were using
ecore_event_window_register() then they can also redirect
everything though the direct callback instead.
2016-05-31 19:03:04 +09:00
Carsten Haitzler 59d32121d6 ecore evas: remove printfs
forgot i still had them (wa stestign wayland with no printfs in it)
2016-02-20 23:12:17 +09:00
Carsten Haitzler ab31424ea6 ecore evas: fix configure request queue count to only count changes
we counted more requests outstanding than actually existed for x11 as
we sometimes sized to the SAME size or position. this keeps that
number more correct only incremeting outstanding count if we change.

@fix
2016-02-20 23:09:03 +09:00
Cedric BAIL bb1a1eef65 ecore_evas: introduce support for per window animator trigger.
This code is currently only using the older fallback code and not any
new event source, so all animator on all window are still triggered
whatever the case are.
2016-02-02 10:47:25 -08:00
Stefan Schmidt eb78bb2d24 ecore_evas x engine: use Eina_Bool for one-bit bitfield
Make sure we are using a unsigned var here. Best go with a Eina_Bool directly.
2015-11-13 13:31:34 +01:00
Carsten Haitzler 6a90df70bf ecore-evas x - solve internal window size flickrs in e
so there is an issue that e brings out where configure events get
queued and deferred AND e ends up requesting a new size, but new size
is wrong as its read from an old event (requested size is updated) and
in the end ecore-evas doesnt request the actual new size because
current w/h is "the same" even though it isn't... bah - it's complex
and a self-feeding event issue. just doing the move/resize solves it.

@fix
2015-10-09 13:06:20 +09:00
Mike Blumenkrantz b209100870 ecore_evas-x11: unset withdrawn flag when showing the ecore evas
while the window map event seemed like a reasonable place to unset
the withdrawn state at the time, studies and further tests have proven
that the direct show callback is even more reasonable and effective

ref T2745
2015-09-25 22:21:25 -04:00
Mike Blumenkrantz e31c703661 ecore_evas-x11: unset withdrawn state when window is mapped
according to ICCCM 4.1.4:
Newly created top-level windows are in the Withdrawn state.
Once the window has been provided with suitable properties,
the client is free to change its state...
...
Only the client can effect a transition into or out of the Withdrawn state

given that no external force can (according to spec) transition a
window out of the withdrawn state, this must be done at a reasonable
point. mapping the window seems like a reasonable point to me.

fix T2745
ref 5954289c6c

@fix
2015-09-25 21:57:37 -04:00
Seunghun Lee b38b349262 ecore-evas-x: resize window when it is rotated by window manager.
Summary:
window manager can send arguments and its meaning as follows.

1) resize:0
it means client window doesn't need to resize its window by rotation.
this case is a ELM_WIN_BASIC window in mobile profile.

2) resize:1, ee->w != w, ee->h != h (deprecated)
it means client window should be resized by rotation, and wm already resize its window.
so, client don't need to resize its window.
it's just for backward compatibility.

3) resize:1, ee->w == w, ee->h == h (addition)
it means client window should be resized by rotation, and wm don't resize it.
so, client should resize its window.

Test Plan: N/A

Reviewers: gwanglim, raster, jypark, devilhorns

Subscribers: cedric

Differential Revision: https://phab.enlightenment.org/D2831
2015-07-29 11:14:11 -04:00
Seunghun Lee 3adb6127ff ecore-evas-x: fix typo
Test Plan: N/A

Reviewers: gwanglim, raster, jypark, cedric

Reviewed By: cedric

Subscribers: cedric

Differential Revision: https://phab.enlightenment.org/D2832

Signed-off-by: Cedric BAIL <cedric@osg.samsung.com>
2015-07-28 03:05:37 +02:00
Ji-Youn Park 8c66b70aa9 ecore_evas: fix iconified state set bug
if app set iconified state false, ecore evas call activate instead of show.
2015-06-26 19:18:09 +09:00
Carsten Haitzler 25983dcedd evas render2 work - begin to make rectangles deal with render 2 basic
infra
2015-06-09 17:34:39 +09:00
Cedric BAIL ce5ccfb5be ecore: remove the need to order the header correctly for Windows. 2015-05-07 09:53:10 +02:00
Chris Michael c66275c99b ecore-evas-x: Fix issue of wrong interface function pointer being set
Summary: This fixes Coverity CID1267461 where the pointer to the
interface shape_input_reset function was being assigned multiple
times. It looks like this is just a copy/paste error.

@fix

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2015-04-20 12:58:42 -04:00