Commit Graph

154 Commits

Author SHA1 Message Date
Cedric BAIL 33fd77e9e4 ecore: move close_on_destructor to close_on_invalidate as that describe the behavior best.
Fix all use to correctly behave on invalidate.
2018-05-01 10:39:01 -07:00
Cedric BAIL a408c145e9 elementary: migrate Efl.Ui.Image to use the new Efl.Model API. 2018-04-30 14:21:12 -07:00
Xavi Artigas 5697f6e94b Efl.Gfx.Image* (From Efl.Image*)
Ref https://phab.enlightenment.org/T6847

Reviewed-by: Cedric Bail <cedric@osg.samsung.com>
2018-04-24 09:03:40 -07:00
Xavi Artigas c837b321bf Efl.Image_Load_Controller* (From Efl.Image.Load*)
Ref https://phab.enlightenment.org/T6847

Reviewed-by: Cedric Bail <cedric@osg.samsung.com>
2018-04-24 09:03:39 -07:00
Xavi Artigas 55bd097a3d Efl.Gfx.Entity (from Efl.Gfx)
Ref https://phab.enlightenment.org/T6847

Reviewed-by: Cedric Bail <cedric@osg.samsung.com>
2018-04-24 09:03:32 -07:00
Xavi Artigas 9dcc31ed4a Efl.Access.Object (from Efl.Access)
Ref https://phab.enlightenment.org/T6847

Reviewed-by: Cedric Bail <cedric@osg.samsung.com>
2018-04-24 09:03:24 -07:00
Daniel Kolesa fcae7cab27 eolian gen: enable constness generation on property getter impls
This changes a lot of things all across the EFL. Previously,
methods tagged @const had both their external prototype and
internal impl generated with const on object, while property
getters only had const on the external API. This is now changed
and it all has const everywhere.

Ref T6859.
2018-04-17 20:31:55 +02:00
Mike Blumenkrantz 7372802c32 Efl.Access.Image: remove the whole class
this is a copy of Efl.Access.Component and serves no purpose
2018-02-15 13:11:00 -05:00
Jaeun Choi c950b17a57 efl_ui_image: add missing NULL check 2018-01-30 21:21:35 +09:00
Sungtaek Hong 30593b19ba Efl.Ui.Image: remove previous image when NULL is set
Summary:
when Efl.Ui.Image has an image,
         efl_file_set(efl_added, NULL, NULL) is not working.
         I think this should remove prevous image and go back to empty image.
         @fix

Reviewers: jpeg, cedric, eunue, woohyun, Jaehyun_Cho

Subscribers: Blackmole

Differential Revision: https://phab.enlightenment.org/D5742
2018-01-30 13:55:51 +09:00
Sungtaek Hong cb25699dac efl_ui_legacy: add new interface to indicate legacy widget
Summary:
For now, how to check whether a widget is legacy or not
is to check flags in private data or static flag, which is set
during elm_legacy_add.
If Efl.Ui.Legacy interface is added, it can be easilly checked
by efl_isa(obj, EFL_UI_LEGACY_INTERFACE)

Reviewers: woohyun, jpeg, cedric, Jaehyun_Cho

Subscribers: conr2d, cedric, jpeg

Differential Revision: https://phab.enlightenment.org/D5748
2018-01-24 18:14:26 +09:00
Jean-Philippe Andre 71ee800521 efl: Merge Flipable and Orientation
No need to split: those two are used in all the same classes, since the
split between Orientation and Ui.Dir.

Note that the enum types remain in the main namespace.
2018-01-18 17:29:28 +09:00
Amitesh Singh 44d3227beb widget: rename elm widget to Efl.Ui.Widget. 2018-01-08 21:28:10 +09:00
Amitesh Singh 9db0ec554b interface: add Efl.Gfx.Color interface for color related APIs
This would eventually turn into mixin class later after adding
more color related helper functions.
2017-12-22 13:29:20 +09:00
Sungtaek Hong a2309c5083 efl_ui_image: apply load_size when API is called
Summary:
when  efl_image_load_size_set() is called, image only sets
internal variable and not apply to the internal image.
elm_image_prescale_set() is also affected.

Test Plan: Run elementary_test->Image Prescale

Reviewers: jpeg, eunue, woohyun

Subscribers: cedric

Differential Revision: https://phab.enlightenment.org/D5645
2017-12-18 20:49:46 +09:00
Sungtaek Hong 25136ddf8c efl_ui_bg: add Efl.Ui.Bg interface
Summary:
- Previous class efl_ui_bg moved to efl_ui_bg_widget.
- Scale_type moved to efl_image from efl_ui_image.
- Previous enum Efl_Ui_Image_Scale_Type moved to Efl_Image_Scale_Type.

Test Plan:
Run elementary_test
1.Image Scale Type
2.Efl.Ui.Bg
3.Efl.Ui.Win
4.Part Background

Reviewers: jpeg, woohyun, cedric

Differential Revision: https://phab.enlightenment.org/D5616
2017-12-18 20:49:45 +09:00
Ross Vandegrift 71e5c74eb6 efl: drop deprecated Encoding key from desktop files
Summary:
The Encoding key is no longer required, all desktop files are assumed to
be UTF-8 encoded.  See details at:
https://standards.freedesktop.org/desktop-entry-spec/1.1/apc.html

Fix various typos and misspellings

lintian, Debian's package checker, uses strings to check for common typos
in compiled binaries.  This change fixes the ones it identified in 1.20.6.

Reviewers: cedric

Reviewed By: cedric

Subscribers: cedric, jpeg

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

Signed-off-by: Cedric BAIL <cedric@osg.samsung.com>
2017-12-13 10:27:48 -08:00
Amitesh Singh 54ae9cc18b edje: rename Edje.Object to Efl.Canvas.Layout 2017-12-06 13:12:29 +09:00
Amitesh Singh bdc3969452 edje: rename intf Efl.Canvas.Layout_Group to Efl.Layout.Group 2017-12-05 16:18:32 +09:00
Amitesh Singh c7aa3b2f83 edje: rename intf Efl.Canvas.Layout_Calc to Efl.Layout.Calc 2017-12-05 16:18:32 +09:00
Amitesh Singh 7b3fde4d4b edje: rename intf Efl.Canvas.Layout.Signal to Efl.Layout.Signal 2017-12-05 16:18:32 +09:00
Amitesh Singh 10103b9b45 efl.gfx: move scale{} from efl.ui.base to efl.gfx 2017-12-04 14:38:39 +09:00
Jean-Philippe Andre 029cf28745 image: Return file+key even for edje objects 2017-11-20 20:06:01 +09:00
Jean-Philippe Andre e9ebe5c676 elm: Define and rename internal atspi struct in EO
This thing is used by only 2 EO APIs that are marked as @beta. I wonder
if the @beta tag or the ptr() expression made it work for eolian,
because it simply wasn't defined in EO.

I'm renaming it just so that it's more consistent with the new names
used by atspi (and EO API in general).
2017-11-16 12:00:18 +09:00
Lukasz Stanislawski c838e30a24 elm: Rename elm_interface_atspi_widget_action mixin
Reviewers: jpeg

Subscribers: jenkins, cedric, jpeg

Differential Revision: https://phab.enlightenment.org/D5400
2017-11-16 12:00:18 +09:00
Jean-Philippe Andre d39bbc1491 elm: Create legacy widgets with elm_legacy_add
This will be used to solve issues around style_set:
if the widget is legacy or pure eo we may need to select a different
style. So in the constructor we need to know whether we are legacy or
eo. Note that calling style_set in finalize only is too late as we would
lose information such as efl_text_set() called inside efl_add().
2017-11-07 14:50:31 +09:00
Jean-Philippe Andre 2f465e1fbb widget: Rename EO APIs to efl_ui_widget_xxx
This only changes the eo_prefix for APIs.

Ref T5363
2017-10-24 14:30:21 +09:00
Lukasz Stanislawski 57aefc53c1 elm: rename Elm_Interface_Atspi_Accessible interface
Subscribers: cedric, jpeg

Differential Revision: https://phab.enlightenment.org/D5341
2017-10-19 10:13:54 +09:00
Sungtaek Hong 40e23ca459 efl_ui_image: add new scale type: EFL_UI_IMAGE_SCALE_TYPE_TILE
Summary:
Tile is common type which can be used eg: background.
This is added to scale type which can be set/get by
efl_ui_image_scale_type_set/get()
@feature

Test Plan:
Run elementary test
           Run Image Scale Type
           Check radio "Tile".

Reviewers: jpeg, cedric, woohyun

Differential Revision: https://phab.enlightenment.org/D5119
2017-09-19 18:18:07 +09:00
Jean-Philippe Andre a3250f975a efl: Use Eina.Size2D for image load size 2017-09-19 10:51:48 +09:00
Jean-Philippe Andre 89a7d9ea8e efl: Use Eina.Size2D for image size 2017-09-19 10:51:48 +09:00
Jean-Philippe Andre b19ee757e5 efl: Use Eina.Size2D in Gfx.View 2017-09-19 10:51:48 +09:00
Jean-Philippe Andre f53fe993a6 edje: Merge calc_size_min_restricted & calc_size_min
calc_size_min was just a helper passing 0,0 to the restricted form.
Let's not duplicate APIs in EO and use an optional argument instead.
Bindings should be nicer and C could use a macro if it's too cumbersome
to pass in 0,0.
2017-09-18 17:37:23 +09:00
Jean-Philippe Andre 641a58f735 edje: Use Eina.Size2D for min calc 2017-09-18 17:26:53 +09:00
Jean-Philippe Andre 942cbbed73 edje: Use Eina.Size2D for group min & max size 2017-09-18 17:26:53 +09:00
Jean-Philippe Andre a72f3ec64e efl: Use Eina.Size2D for size hint combined min
For this patch I decided to add a pseudo legacy wrapper as the function
is called in a very large number of places. Fixing all those calls to
use the size2d form is a lot of work and a greater risk of b0rking
something.
2017-09-18 16:33:33 +09:00
Jean-Philippe Andre 4c634ed78e efl: Use Eina.Size2D for Efl.Gfx.size
Big patch as a lot of things call or reimplement size_set. Hopefully I
got it right... fingers crossed.
2017-09-18 13:34:50 +09:00
Jean-Philippe Andre 8fb194d969 efl: Use Eina.Position2D for Efl.Gfx.position
Note: This is a little bit more cumbersome in some places but in most
it's more convenient than (x,y).
2017-09-18 13:22:54 +09:00
Jean-Philippe Andre cb3b4cc8d7 elm image: Fix async open to avoid multiple mmap
Reported by @jiin.moon:

In case of async_open for an elm_image, we try and open a file in a
thread, then map it and populate a bit, as this may take some time
(blocking I/O). This creates a mmap with eina_file_map_new. But later
evas image loaders will (usually) try and map the entire file with
eina_file_map_all() which creates another mmap. Since the size is
different (32Kb first then all) the returned map might be different
(it's up to the kernel to decide at this point).

So, in order to avoid having multiple maps on the same file, and try to
reduce the peak memory usage, we should prefer using the same map all
the time, i.e. the global one returned by eina_file_map_all().

This patch relies on the previous patch in eina_file which fixes
eina_file_map_populate() for the global map.

@fix
2017-09-18 11:58:53 +09:00
Lukasz Stanislawski a55f2c96d4 elm: rename Elm.Interface.Atspi.Image => Efl.Access.Image
Reviewers: jpeg, cedric

Differential Revision: https://phab.enlightenment.org/D5163
2017-09-12 15:48:39 +09:00
Mike Blumenkrantz 7745520852 efl_ui_image: maintain geometry for prev image while preloading new image
if prev_img exists then it is visible, so continue maintaining its geometry
until it is deleted

fix T5936

@fix
2017-08-25 14:48:12 -04:00
Jean-Philippe Andre 20a5968c12 elm: Use a macro to handle key bindings
This factorizes the code and makes most widgets handle key down events
in the same way:
 - check that the object is not disabled, event is not on hold
 - figure out the key binding based on the class name
 - mark event as on hold

The class name is usually MY_CLASS_NAME but in some cases it was
MY_CLASS_NAME_LEGACY which may be different from the EO class name (eg.
elm_win vs. Efl.Ui.Win). In that case the key bindings are broken.

This breaks key bindings for the following widgets:
 - Win (focus)
 - Image ("clicked")
 - Video (move, play)

This fixes key bindings for the following widgets:
 - Nstate

Some widgets remain broken:
 - Photocam / Efl.Ui.Image.Zoomable

A patch will be applied to restore the key bindings for the above
breaks.
2017-08-23 11:16:45 +09:00
Jean-Philippe Andre 069747b9de widget: Add eo event info inside widget_event
This is an internal function that should probably become an overridable
protected method, as it's required for proper event handling in widgets.
Next step: use eo_event_info in the widgets implementations. Then remove
legacy event struct.

Ref T5363
2017-08-23 11:16:45 +09:00
Amitesh Singh d5c80d61e7 Efl.Ui.Image: use internal func to detect legacy usage 2017-08-10 16:43:55 +09:00
Jean-Philippe Andre dee61f4097 elm: Cleanup theme and style set functions
This makes efl_ui_layout_theme_set() return a Theme_Apply error
code. The type is now public as Efl.Ui.Theme.Apply.

Ref T5329
Ref T5363
2017-08-09 17:08:24 +09:00
Jean-Philippe Andre 240cc9e501 edje: Move size_min/max and data to an interface
The new interface is:
  Efl.Canvas.Layout_Group

I'm not fan of the name.

Ref T5315
2017-08-04 11:52:17 +09:00
Jean-Philippe Andre 3e5cfb83c0 elm: Remove custom layout signal APIs
This merges them with the now standard interface:
  Efl.Canvas.Layout_Signal

Some wrapping work was required for legacy API which
takes no user_data in del() but instead returns it. The
new EO function, while harder to use, is more correct
(you can't delete the invalid callback by accident, and
this follows EO events design).

Another crazy wrapping was done in entry/text in order
to add the callbacks to 2 objects instead of just one,
and still return the user data.

As for Naviframe and Popup, those two widgets override
signal_emit to forward the call to another object than
the resize object, but not callback_add/del. So they
are definitely broken.

Ref T5315
2017-08-04 11:52:16 +09:00
Jean-Philippe Andre 6df17b2ed0 edje: Split off calc APIs to an interface (EO)
Those APIs can then be used by Elm.Layout, hopefully
simplifying the API.

I wonder if the APIs should be prefixed "calc_" (as is)
or "layout_calc_". The extra "layout_" prefix would make
it common with other layout APIs (eg. signals, data,
size min/max, ...).

Ref T5315
2017-08-04 11:52:16 +09:00
Amitesh Singh 0d6cdd661c Efl.Ui.Image: fix crash on passing NULL file in file_set()
img was crashing on elm_image_file_set(image, NULL, NULL).

fixes T5697
2017-07-10 15:28:31 +09:00
Jean-Philippe Andre 242127a96b evas,edje,elm: Mark all legacy objects as such 2017-07-07 13:21:18 +09:00
Amitesh Singh 2faeffde71 efl.ui.image: fix the old align behaviour in img.
After ab23a53094, evas_object_size_hint_align_set()
has stopped working on elm img and that patch was perfectly right
to do so but we don't change the old behaviour.
This patch is an effort to make evas_object_size_hint_align_set()
to work with elm img again.
make sure not to mix both eo apis and legacy apis.

Thanks to dave for reporting and jpeg to show the right fix.

fixes T4635
2017-07-06 18:35:06 +09:00
Jean-Philippe Andre 06b14827b7 widget: Implement scale from Efl.Ui.Base 2017-06-12 11:50:30 +09:00
Amitesh Singh 75aa39ff8d Efl.Ui.Image: fix efl.player.playable.get API
an edje obj is always playable. return TRUE always.

@fix
2017-06-07 18:52:08 +09:00
Amitesh Singh 5882d343f0 efl.ui.image: fix icon_get API
If icon set is failed, icon_get should return NULL,
not the old icon name.

@fix
2017-06-05 17:09:19 +09:00
jiin.moon 2c119f54af elm_image: Fix previous image visible issue
Summary: Previous image still visible when elm_image_file_set has wrong file path.

Test Plan: self

Reviewers: jpeg, jypark, singh.amitesh

Reviewed By: singh.amitesh

Subscribers: singh.amitesh, minkyu, cedric

Differential Revision: https://phab.enlightenment.org/D4888
2017-05-31 19:01:04 +09:00
Jean-Philippe Andre ce0d15ecb3 edje: Reshuffle a bit edje_object.eo
This changes a few method names:
 - freeze -> calc_freeze
 - thaw -> calc_thaw
 - update_hints -> calc_update_hints

Otherwise this is mostly about reshuffling the EO file itself
and changing documentation.

Ref T5315
2017-05-31 18:42:28 +09:00
Jean-Philippe Andre b114f8c66d evas/elm: Add Efl.Image.image_size read-only property
Following a remark in the mailing list, it is pretty clear that
Efl.Gfx.View.view_size is not as simple as "image_size".

I have defined this new image_size as being the size of the
image file, and not what's currently loaded. So it will not
apply to proxies, gl views, 3d scenes, etc... but only to
standard image files loaded with file_set or mmap_set.
Supported objects:
 - Efl.Canvas.Image (evas image)
 - Efl.Ui.Image (elm image)
 - Elm.Photocam (note: still needs some interface work)

@feature
2017-05-24 15:24:13 +09:00
Jean-Philippe Andre 55b529cebc evas/elm: Make group_add/group_del internal functions
This hides those two legacy functions from the EO API.
2017-05-19 14:07:00 +09:00
Jean-Philippe Andre 331bf9f746 elm_image: Fix file_set when preload is disabled
If we disable preload, then the second file set on an elm_image
object would not trigger a deletion of the first image. As a
consequence, both images would be visible... really bad if there's
alpha or different dimensions!

Thanks Anand Kumar for the report!

@fix
2017-04-20 18:54:59 +09:00
Larry Jr 093c592188 efl: add efl_model and efl_ui_view classes
Efl.Model.Container and Efl.Model.Item to efl/interfaces are used
to create Efl.Model objects with predefined property values.
This is useful to any situation where we want an Efl.Model with
explicit defined property values.

Efl.Ui.View and Efl.Ui.Factory are used to connect Efl.Models with
Widgets, Elm.Layout and Efl.Ui.Image has changed to use news interfaces

Signed-off-by: Cedric BAIL <cedric@osg.samsung.com>
2017-02-06 15:26:21 -08:00
Cedric BAIL 8f1c071d6a eina: rename EINA_{FLT,DBL}_CMP to EINA_{FLT,DBL}_EQ. 2017-01-06 15:58:46 -08:00
Jee-Yong Um 6d0a2398ad Elm.Widget: rename "event.*" methods to solve name conflict
Summary:
Elm.Widget.event_callback_add conflicts with Efl.Object.event_callback_add.
To solve this problem, "widget_" prefix is added to methods starting with
"event".

Reviewers: cedric, jpeg

Differential Revision: https://phab.enlightenment.org/D4521
2017-01-03 10:59:49 +09:00
Cedric BAIL c994976cdb elementary: fix float warning in Efl.Ui.Image. 2016-12-20 16:39:30 -08:00
Gustavo Sverzut Barbieri fa8630a9b1 elm: convert downloads to efl_net_dialer_http.
Remove Elm_Url and use efl_net_dialer_http with an efl_io_copier to
fetch stuff.

The code was also slightly improved, particularly in elm_photocam
destruction be explicit and clear the grid before deleting... this
will ensure any pending preload are stopped before we remove the
backing memory.
2016-11-22 13:24:16 -02:00
Daniel Zaoui 381d93f1e2 efl_ui_image: fix removal of the internal evas image
During the replacement of the image with the new preloaded one,
the previous image is deleted but not removed from the list of
children of the icon (efl_ui_image), leading to Eo errors when
walking over the icon children.

@fix
2016-11-21 12:24:16 +02:00
Jaehyun Cho e64fa28284 efl_ui_image: guarantee user's mouse up event callback is called.
Summary:
Without propagating event by hit_rect, user's mouse up event
callback may not be called if image file is replaced in user's mouse
down event callback.

Test Plan:
1. Register mouse up event callback for elm_image by calling
evas_object_event_callback_add() with EVAS_CALLBACK_MOUSE_UP.
2. Register mouse down event callback for elm_image by calling
evas_object_event_callback_add() with EVAS_CALLBACK_MOUSE_DOWN.
3. Replace image file of elm_image by calling elm_image_file_set() in
mouse down event callback.
4. Mouse down on elm_image.
5. Mouse up on elm_image.
6. Since image file object is newly created in mouse down event
callback, mouse up event is not triggered for the newly created image
file object. As a result, mouse up event is not propagated to elm_image
and user's mouse up callback for elm_image is not called.

Reviewers: cedric, woohyun, eunue, jpeg

Reviewed By: jpeg

Subscribers: jpeg

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

Signed-off-by: Cedric BAIL <cedric@osg.samsung.com>
2016-11-16 13:46:40 -08:00
Jean-Philippe Andre 9af981469d elm: Fix usage of invalid object type (image)
This fixes a a crash on NULL and ensures the EAPI call is
done on an elm_image. Just checking NULL is not good enough
as _efl_ui_image_sizing_eval() doesn't check the type first.
2016-11-03 17:22:14 +09:00
Jean-Philippe Andre a86e79141e elm: Fix disappearance of some elm images
After the commit 97c9fa64a4 (Remove group_show and group_hide),
some Efl.Ui.Image objects would not render properly. The reason
being that the object call to show() was aborted too early when
the image is still preloading.

This made for really random results as an image preload could
take more or less time, depending on chance.
2016-11-01 09:36:39 +02:00
Jean-Philippe Andre 8a9f0bd603 evas/elm: Remove function group_resize
This is an override of efl_gfx_size_set. Same as before, the
order of operations matter so it is possible that a corner
case will break. In particular, legacy code was:
 - intercept
 - smart resize (do stuff), super, super, super
 - evas object resize

The new code is more like:
 - intercept
 - super, super, super, evas object resize
 - do stuff

But unfortunately this broke elm_widget (read: all widgets) as
the internal resize was done before the object resize. So,
inside the resize event cb, the resize_obj size would not match
the smart object size. >_<
2016-10-12 11:25:56 +09:00
Jean-Philippe Andre 11b7cf6b72 evas/elm: Remove function group_move
This is an override of efl_gfx_position_set.
As for the other patches, I hope I didn't break anything.

A problem likely to happen is that the super call was inserted
too early or too late in the call flow. For instance:

  _myclass_position_set(obj, x, y) {
    position_set(super(obj), x, y);
    position_get(obj, &prevx, &prevy);
    do_something_with_delta_xy();
  }

The above code flow is obvisouly wrong, but may have crept in this
patch (such a bug sneaked in inside smart object, breaking
everything at first).
2016-10-12 11:25:56 +09:00
Jean-Philippe Andre 97c9fa64a4 evas/elm: Remove group_show and group_hide
These should be just overrides of Efl.Gfx.visible.set. Many
widgets were handling smart show() and hide() manually, which
means this patch is quite large.

Hopefully this doesn't break anything, obviously. But here are
some widgets known to be problematic, as the old code flow was
really strange (sometimes not calling the efl_super function):
 - window
 - notify
2016-10-12 11:25:56 +09:00
Jean-Philippe Andre 62abe2cbff evas: Move clip_unset to legacy, remove group_clip
Similarly to group_color_set, group_clip_[un]set should not
exist and should be a result of efl_super and inheritance.

This patch also removes clip_unset from the EO API and keeps
only clip_set(NULL). The reason is that it will avoid bad overrides
of clip_unset() vs. clip_unset(NULL). This also simplifies the code
a bit. Ideally we should be able to reintroduce clip_unset in EO
if we can have a "@final" tag (like java's final keyword), to
prevent overrides.
2016-10-12 11:25:56 +09:00
Jean-Philippe Andre 52969ccd9b evas: Remove method group_color_set
Widgets should simply override efl_gfx_color_set and call
super all the way up to evas object.

Legacy compatibility with call interceptors and early call
abortion (eg. delete_me or obj->layer == NULL) are implemented
with an internal call. See the previous commit introducing the
API.
2016-10-12 11:25:55 +09:00
Jean-Philippe Andre 63088b583c elm_image: Add smart cbs for async open
This adds a few callbacks to inform applications about
async open and preload:
- load,open
- load,ready
- load,error
- load,cancel

This patch adds a new EAPI as well: elm_image_async_open_set.
This is the only way to use async file open with the legacy APIs
and should be easily matched with whatever EO API we end up using
(be it based on promises or events).

Alter the test cases for make check as they were using the
unstable EO API which I just removed.

Thanks @arosis for the original patch. And sorry for the huge
delay in merging this.

See also: https://phab.enlightenment.org/D4215

@feature
2016-09-23 11:28:14 +09:00
Jean-Philippe Andre 97a2d7ff33 elm_image: Move back download events to legacy only
The events for (async) image download will be redefined by
@cedric later. So, remove them from eo now and only keep their
legacy implementation.

Also, improve elm_test example and add docs.
2016-09-22 15:02:45 +09:00
Cedric BAIL b5f47fbcb9 elementary: patch got pushed before the complete fix. 2016-09-19 16:12:31 -07:00
Cedric BAIL 0d0ca579c6 elementary: be more conservative on the amount of data requested from disk. 2016-09-19 16:07:03 -07:00
Cedric Bail 351af26271 elementary: properly handle refcounting of file in efl_ui_image asynchronous image openning. 2016-09-14 16:52:08 -07:00
Carsten Haitzler be29f3f4ec efl ui image - fix janky blocking async image preload thread handling
fix the elm image threaded image preload to be far simpler and
actually threadsafe without blocking the mainloop at all even on
object deletion. this also ensures ar least the first 512M of any
async precached file are loaded in so the preload doesnt stall on
headers that are outside maybe the first 4k of the file. i saw this
happening all over the place in the test i created.

@optimize
2016-09-08 17:30:59 +09:00
Cedric BAIL e6a810efa7 elementary: fix call to efl_data_scope_get from another thread.
This should fix the breakage on elm_suite.
2016-09-07 11:42:29 -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
Tom Hacohen e65aae994e Eo: Finish the renaming of Eo to the EFL.
This renames all the rest of the API to the EFL namespace except for
Eo_Event that will follow soon.

Obviously breaks both API and ABI.
2016-08-15 15:07:42 +01:00
Jean-Philippe Andre 4e00d5a71f image: Remove all new EAPI that shouldn't exist
Remove EAPI symbols and functions that were
wrongfully added:
 - elm_image_scale_down_set
 - elm_image_scale_down_get
 - elm_image_scale_up_set
 - elm_image_scale_up_get
 - elm_image_fill_inside_set
 - elm_image_fill_inside_get
 - elm_image_scale_get
 - elm_image_scale_set

Doing this before the 1.18.x release announcement.

Fixes T4343
@fix
2016-08-12 09:24:41 +09:00
Jean-Philippe Andre c6bb29c4e4 elm_image: Remove EAPI sizing_eval
This is an internal API, should not be exposed as EAPI.
Doing this before the 1.18.x announcement.

@fix
2016-08-12 09:20:21 +09:00
Tom Hacohen c662934be8 Change the EFL to follow the new Eo rename. 2016-08-11 17:04:43 +01:00
Jean-Philippe Andre 28c917836c efl: Cleanup some code (return values)
This removes some useless code in various places, where the
switch from eo_do() to standard function call was not properly
refactored.

This changes:

type ret = 0;
ret = my_eo_function();
return ret;

To:

return my_eo_function();
2016-08-05 10:32:30 +09:00
Jean-Philippe Andre 26ee77ff67 evas image: Lower ERR message to WRN and fix it
In elm_image, efl_file_get() was called on a legacy Evas Image
object, which generated an ERR message. This was way too much
noise for something that actually works.

It's best not to call efl_file_get/set API on a legacy
object, but it can be convenient for smooth code transitions
from legacy to pure eo.

Also, add safety to those APIs.

Test case: elm_test genlist dnd, start dragging anything.
2016-08-05 10:32:30 +09:00
Carsten Haitzler a3e7413992 elm image - silence warnings of setting smooth if image is edje 2016-08-04 08:17:18 +09:00
Carsten Haitzler f23788dcb0 elm image - store smooth scale var in object as intended
this fixesa bug reported by davemds and kuuko in python bindings test
suite where setting smooth flag != getting it right after.
2016-08-03 18:27:57 +09:00
Carsten Haitzler 1b8643b9a0 efl ui image - fix view size get to NOT apply scaling
this fixes T3254
2016-07-26 15:24:13 +09:00
Carsten Haitzler 8c9adcb616 efl ui image async locking -fix CID 1356199 - locked data cant be messed with
this addresses a coverity issue that in theory looks right

fix CID 1356199

@fix
2016-07-24 18:44:15 +09:00
Carsten Haitzler 2936834d31 elementary - fix focus switching again after break
this fixes T4053

this was due to everal widgets haveing changed their class names and
are using the new names for mapping to keybinding config that used
legacy names to match binding to widget.
2016-07-12 18:06:13 +09:00
Jinyong Park 3271ec8d18 theme: return enum from elm_widget_style_set instead of bool
Summary:
if trying to apply incorrect theme, widget apply default theme and return TRUE.
so there is no way to check it really apply correct theme.
To resolve this problem, _elm_theme_set return three type enum

* related history : 4ca3ef4514
* elm_object_style_set is public api, so I didn't change it.
* typedef name [ Theme_Apply ] is temporarily, please suggest better one.

@fix

Reviewers: singh.amitesh, herb, Hermet, cedric, jpeg, raster

Subscribers: cedric, jpeg

Differential Revision: https://phab.enlightenment.org/D4073
2016-07-01 15:09:43 +09:00
Jean-Philippe Andre 7bf8da2baa evas: Rename Evas.Object to Efl.Canvas.Object
One step closer to make the EO inheritance tree look like
it's all Efl.
2016-06-21 14:35:19 +09:00
Jean-Philippe Andre cb523121be efl.ui.image: Fix min size of non-resizable images
Legacy API was setting a value that was not used in the size
computation.

This fixes the layout in elm_test "Icon Animation".
2016-06-20 20:08:05 +09:00
Jean-Philippe Andre 80b6750a83 elm: Fix default image scale type
Elementary image used to respect aspect ratio by default,
corresponding to the fit_inside policy.

Fixes T3914.
2016-06-20 11:18:18 +09:00
Jean-Philippe Andre 52f9220b3f Evas: Rename smart object into Efl.Canvas.Group 2016-06-17 19:32:43 +09:00
Jean-Philippe Andre 42b63f5507 Evas: Add smart_ prefix to all smart functions (eo)
This is a first step at separating legacy smart
object features away from standard efl interfaces.
2016-06-17 19:25:48 +09:00
Jean-Philippe Andre 9a052a740d Evas: Move smart_callbacks_descriptions to legacy 2016-06-17 19:25:47 +09:00
Jean-Philippe Andre d67171940f Evas: Rename Draggable_Interface to Efl.Ui.Draggable 2016-06-10 18:06:10 +09:00