Commit Graph

49787 Commits

Author SHA1 Message Date
Vitor Sousa 3f5149a675 elm fileselector: fix events that must be using Efl.Model objects
Use the new behavior of Efl.Object.event_callback_call to correctly
update events to pass Efl.Model objects while still suppling path
strings for legacy smart callbacks.

Override Elm.Fileselector.event_callback_legacy_call in order to separate
the types of any incoming event call that uses Efl.Model.
2016-08-29 12:22:22 -03:00
Subodh Kumar 0f4cdf7a48 Edje entry: Pass correct cursor position and text to imf in case of selection
Summary:
When selection is there we are passing the whole text and position to imf
which sees that next character like matras (eg .Hindi) should be inserted
(if pressed) and when matra comes the selected text is gone and only matra
remains in the entry.

eg:  we have text in hindi like मानक, select all and hit matra in keyboard
selected text is gone, only matra is there.

@fix

Test Plan: Tested in Tizen device

Reviewers: jihoon, tasn, herdsman, thiepha

Subscribers: Hermet, shilpasingh, raster, subodh, jpeg, cedric

Differential Revision: https://phab.enlightenment.org/D2951
2016-08-29 17:26:40 +09:00
Carsten Haitzler a9fbe6cb8f eo callbacks - move to mempools for callback data for more speed
also help reduce fragmentation. also remove callbacks immediately if
callbacks are not being walked at the time (as opposed to just marking
them to need deletion then call a clean that if not being walked will
walk all cb's when we already know what to remove).

@optimize
2016-08-29 16:48:08 +09:00
Carsten Haitzler 3000038051 efl po's - update 2016-08-29 14:56:58 +09:00
WooHyun Jung d553a5a836 elm focus: focus_auto_hide should be done with mouse_down
Focus highlight can be on the air, when focused object in scroller is
moved by mouse down and move.
So, mouse up is not proper for executing focus_auto_hide.

@fix
2016-08-27 13:48:35 +09:00
Carsten Haitzler 6256978b61 fix filselector legacy cb call order and entry set - fix file,chosen
The visible bug for this issue is that the Elm External Video example
is broken:

elementary_test -to "ExtVideo"
The root cause is that the "file,choose" event of the
FileselectorEntry is (wrongly) not listed by the function:
evas_object_smart_callbacks_descriptions_get()
This evas functions is used in elm_external to forward all the widget
events to edje, but it cannot forward the "file,chosen" event because
it's not listed.
Thus the video test is not working for the lacks of that event.

I think the fix should be somewhere in elc_fileselector_entry.c, there
are some hacks there for the incriminated signal, but I don't know how
to properly fix.

as pointed out by dave:

DaveMDS added a comment.Fri, Aug 26, 5:19 PM
I think the problem is in this function: (elc_fileselector_entry.c)

...

this fixes T4337
2016-08-27 09:08:05 +09:00
Vitor Sousa 5d2948b016 elm fileselector: fix possible premature deletion of Listing_Request struct
In a case where eina_promise_then is executed immediately (like with some
quick and light Efl.Model), the Listing_Request struct will be prematurely
freed in the first iteration of the child processing loop, because the
item_total counter had not accumulated the right number of items yet.

With this commit, we traverse the children accessor first, so we can know
the number of items.

Also, no longer use the Listing_Request pointer after the loop, once it
may have been deallocate already.
And put a note about this too.
2016-08-26 19:45:26 -03:00
Jean Guyomarc'h 1ab1e3697d efreet: mime types database can be empty
When the mime types database is empty, the file will
be exactly 28 bytes.

Fixes T4426
2016-08-26 21:16:39 +02:00
Jean Guyomarc'h 92d3fc8f4f elementary: better error handling of fileselector 2016-08-26 21:16:39 +02:00
Jean Guyomarc'h 0874c4da38 elementary: prevent double free
This one is a bit tricky... When we create the aggregated
promise, if one of the properties of the model returns an
error, the eina_promise_then() will immediately call the
error callback. In this happened for the first item, the
total items in the listing request would be 1.

Before this commit, we tested for incremented the processed
counter and compared it to this total count. If it was
greater or equal, we would free the common listing request.
But in the case of successive failures, we would set the
total counter to 1, then the processed counter to 1 and
therefore free. Then increment the total counter to 2, then
then processed counter to 2, and free again... which would
cause an abort() from the libc or something else nasty.

Now we just decrease the total count of items. We avoid
the cases and double frees, without leaking.
2016-08-26 21:16:39 +02:00
Jean Guyomarc'h 322adb2e03 elementary: make sure we don't iterate out of bounds
The carray iterator will end iterating only when it finds a NULL
object. We must make sure the last element of the array is NULL
to avoid out of bounds access.
2016-08-26 21:16:39 +02:00
Jean Guyomarc'h 5db3357f40 eina: overhaul Mac OS X semaphores
Mac OS X does not support POSIX unnamed semaphores, only named
semaphores, which are persistant IPC: when the program exits,
and if semaphores where not released, they stay forever...

All EFL programs were "leaking" a semaphore, due to how
eina_log_monitor manages its resources. Therefore, after building
EFL a lot (which run eolian_gen, eolian_cxx, elua, edje_cc, ...)
we were not able to create any semaphore...

Now, we get rid of these semaphores and use Mac OS X's own
semaphores. Code is less cumbersome, and we don't have any
disavantage of the named semaphores.

Fixes T4423

@fix
2016-08-26 21:16:39 +02:00
Cedric BAIL aaa0e962b7 eo: speedup efl_isa by 50%.
Most of our use case of efl_isa is related to legacy Evas_Object_Image API,
that check the isa of the same object again and again. Caching help.
2016-08-26 12:14:14 -07:00
Cedric BAIL 93a706a947 eo: general speedup of all Eo related operation.
This change rely on the fact that we do fetch the same
object id over and over again. _efl_object_call_resolve got
15% faster, efl_data_scope_get 20%.
2016-08-26 12:14:14 -07:00
Cedric BAIL 5e67a80753 eo: remove useless duplicated check. 2016-08-26 12:14:14 -07:00
Vitor Sousa 8356b16a49 Efl Object: remove legacy callback calls from event_callback_call
Efl.Object.event_callback_call no longer calls legacy smart callbacks;
calling only event callbacks registered with the given event description
pointer.

Create the method Efl.Object.event_callback_legacy_call to inherit the old
behavior from Efl.Object.event_callback_call, calling both Efl.Object events
and legacy smart callbacks.

Update all other files accordingly in order to still supply legacy
callbacks while they are necessary.
2016-08-26 15:45:07 -03:00
Jean Guyomarc'h 6b3ca899e8 ecore_cocoa: fix fullscreen for older osx versions
Tested on 10.11 and 10.9.

Fixes T4395
2016-08-26 19:38:57 +02:00
Jean Guyomarc'h 7397b9fbe9 ecore_cocoa: refactor resizing request 2016-08-26 19:05:48 +02:00
Jean Guyomarc'h 8d41099f9e ecore_cocoa: fix memory leak 2016-08-26 19:05:48 +02:00
Stephen okra Houston 1e458450cd Elementary: Genlist Tree Test - Add an item with the indent style to match tree style. 2016-08-26 10:37:26 -05:00
Stephen okra Houston 19cf910321 Elementary Theme: Add "indent" genlist item style. This style allows non tree items to match tree items. 2016-08-26 10:05:20 -05:00
Mike Blumenkrantz 8c3efbd174 efreet: add doc note about stringshare reliability for efreet_mime_type_get() 2016-08-26 10:20:45 -04:00
Andy Williams 6fce2fb80b elm: Show code widget width marker after the column
Provide a clearer indication of what width is available
2016-08-26 15:17:37 +01:00
Daniel Kolesa 17d79745a3 docs: add an option to disable title plugin usage 2016-08-26 14:45:45 +01:00
Daniel Kolesa d69d54ff17 docs: let the writer handle title headings 2016-08-26 14:42:19 +01:00
Daniel Kolesa cdaa4ab68c docs: generate proper title for all pages 2016-08-26 14:31:33 +01:00
Daniel Kolesa b04c0cf241 docs: add writer support for pagetitle plugin 2016-08-26 14:28:11 +01:00
Jean-Philippe Andre 3b175fd7e9 elm: Fix some ERR messages following previous patch
This simply avoids calling functions on NULL objects, since
the previous patch would ERR out rather than silently ignore
the problem.

I just add explicit NULL checks before calling the functions,
so it's clear the object could be NULL (in the widget).
2016-08-26 17:15:05 +09:00
Jean-Philippe Andre 5fc5cff03e evas3d examples: Add EFL_EO_API_SUPPORT where needed
I might have broken this in a previous commit in evas headers,
but the thing is that beta does not imply eo api, so both are
still required.
2016-08-26 11:44:11 +09:00
Jean-Philippe Andre 9123e5add2 evas events: Add efl_isa safety checks in legacy EAPI
This removes useless magic checks (only check whether the
arg is not null) that were not even present in every function.
The cost should be similar or lower than an eo function call.
2016-08-26 11:28:34 +09:00
Jean-Philippe Andre d504284dd2 efl: Rename Efl.Event.XX to Efl.Input.XX
This removes:
 Efl.Event interface

And renames:
 Efl.Event.Input -> Efl.Input.Event
 Efl.Event -> Efl.Input.Event (merged)
 Efl.Event.Pointer -> Efl.Input.Pointer
 Efl.Event.Key -> Efl.Input.Key
 Efl.Event.Hold -> Efl.Input.Hold

This also moves some interfaces from efl/ to evas/ where they
belong better.

This allows renaming Eo_Event to Efl_Event.
2016-08-26 10:18:01 +09:00
Jean-Philippe Andre 60526528a6 evas: Add normalized and window coordinates to axis events
This is for Wacom graphics tablets (with a pen).

The raw data sent by ecore to evas (and then to apps) is pretty
useless as it's not normalized, and apps have no way of knowing the
dimensions of the tablet, without themselves opening the device
(we don't know nor expose the path to the device).

This is for Xi2 only for now, as Wayland support hasn't been done
yet.

The intent is to deprecate LABEL_X and LABEL_Y. I'm not sure yet
if the normalized value is useful or not (it would seem we may not
be able to provide this info in Wayland).

The new WINDOW_X, WINDOW_Y labels will be used in the new event
type (Efl.Event.Pointer). Normalized values are not exposed yet,
let's decide if we want them or not first (based on what can be
done in Wayland space).

@feature
2016-08-26 10:18:01 +09:00
Jean-Philippe Andre 443aa91d53 evas: Simplify internal evas_object_event_callback_call
This removes the distinction between legacy and new eo style
event info, since all those types have now been ported to eo.
2016-08-26 10:18:01 +09:00
Jean-Philippe Andre 7b25619213 ecore xi2: Discard "axis" inputs from standard mice
Mice in X with xi2 send Axis events which are badly defined,
and carry basically useless information, as we also receive
proper mouse events. Notably, all mice input events are
"Rel something" but in fact they are absolute values (even
the wheel information is a counter increasing every time you
scroll).

This should not break any application as such axis events
carried only values with label ECORE_AXIS_LABEL_UNKNOWN.
This also fixes a leak when n == 0 (no "valuator" found
in the list, this used to be unlikely, now happens at every
mouse event).
2016-08-26 10:18:01 +09:00
Jean-Philippe Andre 925878e931 evas events: Switch axis events to the new eo type
This converts Evas_Axis or Ecore_Axis info arrays into basic
pointer data. Also marks those fields as set. All events need
to properly implement the value_has property (mark all bits
whenever a value is known).
2016-08-26 10:18:01 +09:00
Jean-Philippe Andre 8938d8d557 evas events: Rename properties and introduce generic value
This paves the way to a merge of pointer and axis events into
the class Efl.Event.Pointer.
2016-08-26 10:18:01 +09:00
Jean-Philippe Andre ef4859d5bd evas: Optimize out most callback call events
This sets a bit whenever a callback listener is added.
I couldn't get any profiling data easily (too small for
valgrind).

Note: This removes the proper refcounting on the "move"
event listeners. I believe this is not a problem as most times
the move_ref goes to 0, it is because the object is deleted.
Worst case, we just trigger a callback_call with no listeners.

This adds 32 bits to each evas object private data.
2016-08-26 10:18:01 +09:00
Jean-Philippe Andre 57f0c850ec evas: Move event catcher to evas_callbacks.c
No functional change.
2016-08-26 10:18:01 +09:00
Jean-Philippe Andre 4746627fcf evas: Remove deprecated events from public EO class
del and free eo events don't need to be exposed, even as beta
API. They are still required for legacy callbacks.
2016-08-26 10:18:01 +09:00
Jean-Philippe Andre b325097e71 elm,evas: Remove use of EFL_CANVAS_OBJECT_EVENT_DEL
This event should not be exposed at all, it's not necessary
anymore, EFL_EVENT_DEL already exists and should be good enough.

This does move the callback call a little bit ealier in the del
process, but at first glance, this shouldn't have any impact.
2016-08-26 10:18:01 +09:00
Jean-Philippe Andre 834794ed84 evas events: Add new "finger,move/down/up" events for multi touch
This moves MULTI events to those new finger event types,
and also sends a finger event for finger 0 (aka the pointer).

NOTE: This may require a separation between a mouse input and
      an actual finger touch. To be defined, ie: do we let the app
      check the input device info to decide whether the event is
      actually the first finger of a multi touch device, or do
      we want to send only actual finger events from multi touch
      devices only?

@feature
2016-08-26 10:18:01 +09:00
Jean-Philippe Andre 608da26634 evas events: Simplify event counter
Simplify code:
 _evas_object_event_new()
 event_id = _evas_event_counter

Into:
  event_id = _evas_object_event_new()
2016-08-26 10:18:01 +09:00
Jean-Philippe Andre 049a5ddb44 evas events: Remove now unused code 2016-08-26 10:18:01 +09:00
Jean-Philippe Andre ab7f281c34 evas events: Fix crash when translating legacy events
An obvious crash happened when reusing a legacy struct
from another type.
2016-08-26 10:18:01 +09:00
Jean-Philippe Andre ac26c7d4f3 evas events: Switch mouse move events to the new type
This is the last commit for this crazy input transformation
series. The following commits will be cleaning up now
unused code, and fixing bugs.
2016-08-26 10:18:01 +09:00
Jean-Philippe Andre 46c85b87fd evas events: Switch multi move to new event type
Now only the single move remains. Almost done!
2016-08-26 10:18:01 +09:00
Jean-Philippe Andre 2857d7c2cf evas events: Switch multi up/down to the new event type 2016-08-26 10:18:01 +09:00
Jean-Philippe Andre 328151f999 evas events: Switch mouse in/out events to the new event type 2016-08-26 10:18:01 +09:00
Jean-Philippe Andre edd88292a4 evas events: Switch mouse move event to the new event type (1)
This only modifies the proxy source handling code.
2016-08-26 10:18:01 +09:00
Jean-Philippe Andre 56c682452c evas events: Switch mouse up/down to the new event type
This is getting trickier, as those events have a lot more
side effects and complexity than a simple wheel event...

Some code has been added that should be fixed in the following
commits.
2016-08-26 10:18:00 +09:00