Commit Graph

393 Commits

Author SHA1 Message Date
Mike Blumenkrantz 87614044cd edje_edit: remove all legacy usage from eo files
this takes the current generated output from eolian for legacy code in
evas and adds it to the tree, then removes legacy references from the
corresponding eo files. in the case where the entire eo file was for
a legacy object, that eo file has been removed from the tree

ref T7724

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D8130
2019-03-06 13:03:00 -08:00
Mike Blumenkrantz 5bfe2e89d2 evas: remove all legacy usage from eo files
this takes the current generated output from eolian for legacy code in
evas and adds it to the tree, then removes legacy references from the
corresponding eo files. in the case where the entire eo file was for
a legacy object, that eo file has been removed from the tree

ref T7724

Reviewed-by: Marcel Hollerbach <marcel-hollerbach@t-online.de>
Differential Revision: https://phab.enlightenment.org/D8107
2019-03-06 19:05:48 +01:00
Mike Blumenkrantz 6326e18b3f efl.file: improve api a bit
Summary:
the previous implementation/api had a number of issues:
* "file" property contained both "file" and "key" values
  - also performed file loading operation
* "load_error" property which was specific to image objects
* no methods for controlling file loading/unloading

this patch attempts the following changes:
* split "file" property into "file" and "key" properties
  - also remove "key" from existing "mmap" property
* remove "load_error"
* directly return error codes from operations
* add "load" and "unload" methods for directly controlling load state
* add implicit file loading if file/mmap is set during construction
* rewrite all efl.file implementations to move file loading into load() method
* rewrite all usage of efl.file api based on these changes
* add C extension functions to mimic previous behavior

ref T7577

Reviewers: segfaultxavi, bu5hm4n, cedric

Reviewed By: segfaultxavi

Subscribers: vitor.sousa, #reviewers, #committers

Tags: #efl_api

Maniphest Tasks: T7577

Differential Revision: https://phab.enlightenment.org/D8018
2019-02-27 13:17:10 -05:00
Xavi Artigas 6b7346b7b2 Remove individual class BETA guards
Summary:
Eolian adds a per-class BETA guard (like EFL_UI_WIN_BETA) to any method tagged
as @beta. This means that any app (and the EFL code) wanting to use BETA features
has to enable them class by class, which is cumbersome.
This commit replaces the individual guards with the global EFL_BETA_API_SUPPORT
guard, so apps only need to define one symbol to access BETA features.

Any usage of the per-class guards has been removed from the EFL code and examples.
When building EFL the global guard is defined by configure, so all EFL methods
already have access to BETA API.
Efl_Core.h and Efl_Ui.h no longer define EFL_BETA_API_SUPPORT. Apps wanting to
use BETA API have to define this symbol before including any EFL header
(It has been added to the examples requiring it).

Test Plan:
make && make check && make examples still work, but there's a lot less #defines
in the code

Reviewers: zmike, bu5hm4n, q66

Reviewed By: q66

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Maniphest Tasks: T6788

Differential Revision: https://phab.enlightenment.org/D7924
2019-02-13 18:09:17 +01:00
Carsten Haitzler 71ee265130 edje edit - warn - use bigger buffer to avoid buf trunc warnings 2018-11-09 11:44:00 +00:00
Yeongjong Lee e19292aa2b evas: call evas_find before safety check
Summary:
edje_edit_object_add
edje_object_add
emotion_object_add
evas_object_xxx_add

These APIs had allowed to set parent to EFL_CANVAS_OBJECT(Evas_Object) before
8bb11a17. we should call evas_find before safety check for backward compatibility.

Test Plan:
  win = elm_win_add(NULL, "main", ELM_WIN_BASIC);

 1.  `rect = evas_object_rectangle_add(evas_object_evas_get(win));`

 2.  `rect = evas_object_rectangle_add(win);`

Check that 1. and 2. works.

Reviewers: Hermet, zmike

Reviewed By: Hermet

Subscribers: cedric, #reviewers, CHAN, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D6909
2018-08-29 21:11:00 +09:00
Yeongjong Lee 8bb11a172b evas: check evas class instead of using evas_find
Summary:
A object that is not evas class shouldn't use evas_find. it may occurs segfault.

ref c2e8b492b1

Test Plan:
Evas *evas = evas_new();
evas_free(evas);
evas_object_line_add(evas);

Check weather there is segfault.

Reviewers: Hermet, raster, zmike

Reviewed By: zmike

Subscribers: cedric, #reviewers, #committers, zmike

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D6816
2018-08-16 13:01:39 -04:00
Hermet Park 2663dceaf1 Revert "edje: code refactoring for readibility."
This reverts commit 7fb47fc064.

subsequential revert for previous one.

90a89d1ab2b5d23b29ad0f2680b77b5ba7f56b42.
2018-06-21 19:33:41 +09:00
Hermet Park 7fb47fc064 edje: code refactoring for readibility.
collection.part is too ambigious, since group has parts as well.
Normally we regard it as "name" (of group) instead of part.
2018-06-07 17:53:12 +09:00
Cedric Bail c2e8b492b1 evas: enforce legacy parent to be the canvas. 2018-05-24 16:02:19 -07:00
Derek Foreman 1982046315 edje: Pass extra signal data to program_run
Summary: Depends on D6114

Reviewers: zmike, cedric

Reviewed By: zmike

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D6115
2018-05-08 12:26:13 -05:00
Mike Blumenkrantz 645c573efb edje: EDJE_IMAGE_SOURCE_TYPE_EXTERNAL -> EDJE_IMAGE_SOURCE_TYPE_USER
no functional changes, just a confusing define rename
2018-02-28 16:02:37 -05:00
Marcel Hollerbach c4f33c67a8 move from efl.vpath to eina_vpath
The usages from efl.vpath are moved to to eina_vpath
2018-02-22 09:26:55 +01:00
Marcel Hollerbach e360312678 edje: use new bs static lib 2018-02-17 21:17:58 +01:00
Amitesh Singh 54ae9cc18b edje: rename Edje.Object to Efl.Canvas.Layout 2017-12-06 13:12:29 +09:00
subhransu mohanty 4c47200c49 edje: cleanup old implementation of handling svg file. 2017-10-27 14:58:38 +09:00
Subodh Kumar 230810c4c4 edje_edit: duplicate assignment to variable.
Summary:
Avoid duplicate assignment to same variable.
@fix

Reviewers: cedric, jpeg

Reviewed By: cedric, jpeg

Subscribers: shilpasingh, jpeg

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

Signed-off-by: Cedric BAIL <cedric@osg.samsung.com>
2017-10-16 13:27:38 -07:00
Jean-Philippe Andre 46001cde38 edje: Remove use of smart clipped data
This removes dependency on a legacy structure.
Edje object does not change the smart data, unlike evas box and grid.
2017-09-13 09:57:05 +09:00
Carsten Haitzler 1670ee2766 edje edit - remove pointless setting attr_mount to 0
static analysers dont like it bug not a bug at all

found by PVS studio
2017-07-29 09:08:40 +09:00
Carsten Haitzler e9123a5a58 edje edit - when adding size class set max width and height to -1
since we're not using size class yet.. we hvent had to debug this...
but it is a bug.

fond by PVS studio

@fix
2017-07-29 09:08:40 +09:00
Andrii Kroitor 5f021bbfcf edje_edit: fix source generation 2017-07-12 19:21:15 +03:00
Jean-Philippe Andre 242127a96b evas,edje,elm: Mark all legacy objects as such 2017-07-07 13:21:18 +09:00
Cedric BAIL 7caa81ed9d edje: object have small difference and we use switch case fallthrough to reuse code. 2017-06-05 12:07:57 -07: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 a8ba44b708 edje: Fix shadow variable warning 2017-05-11 17:53:51 +09:00
JEONGHYUN YUN 5ed7378303 edje_edit: add NULL check for eina_mempool_malloc in _edje_edit_state_alloc()
Summary: Pointer eina_mempool_malloc return value may have NULL value when
module aren't properly installed. This reduce the chance of a crash and increase
the likelyness of properly handling the failure.

Reviewers: jpeg, jypark

Subscribers: cedric, jpeg

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

Signed-off-by: Cedric BAIL <cedric@osg.samsung.com>
2017-04-06 15:20:49 -07:00
Andrii Kroitor 75f772c898 edje_edit: fix scripts compilation
@fix
2017-02-21 19:33:51 +02:00
Gustavo Sverzut Barbieri 8dc853f230 ifdef RUN_IN_TREE logic.
This logic is only needed for autotools, cmake will replicate the
installation file structure and thus eina_prefix works out of box.
2017-02-03 12:36:38 -02:00
Vyacheslav Reutskiy 208c529e7a Revert "edje_edit: fix segmentation fault(Array index is out of bound)"
This patch need to revert because it just a temporary solution for load
'inherit_only' groups. Problem with these groups is solved in patch
c3733a213b

This reverts commit 88f5ac22c1.
2017-02-01 15:09:41 +02:00
Vitalii Vorobiov bbdfe393e4 Edje_Edit: add forgotten API for map.zoom.x/y 2017-01-17 16:30:45 +02:00
Andrii Kroitor b909f913ed edje_edit: add Efl.File.mmap.set implementation for edje_edit
This fixes edje_edit_program_source_get for mmaped edje_edit object
@fix
2017-01-17 13:42:36 +02:00
Vitalii Vorobiov b23289a2a0 Edje_Edit: first part of vector API implementation
edje_edit_vector_del
edje_edit_vector_usage_list_get
edje_edit_vector_id_get
edje_edit_vectors_list_get

edje_edit_state_vector_get
edje_edit_state_vector_set
2017-01-11 17:25:05 +02:00
Mykyta Biliavskyi a3426a38ac edje_edit: fix set the images set as image.normal value.
Added ability to set the images set by name into image
part image.normal attribute.
Add search the images set id for case when the image id doesn't find in
image entries list.

@fix
2017-01-06 10:36:57 +02:00
Mykyta Biliavskyi 82b80212c6 Edje_Edit: replace eet_read_direct by eet_read function.
eet_read_direct function doesn't works with ciphered data, but it is
possible that edje file was ciphered. In this case data, that returned
by eet_read_direct always will be NULL.
2016-12-22 11:40:57 +02:00
Bruno Dilly 9308410479 edje: support filtering allowed seats per part
collections.group.parts.part.allowed_seats keeps a list
of seat names to be used for events filter.

So when evas devices of seat type are added, filters
may be applied for each part.

If no seat is listed, every seat may interact with such
part.
2016-12-21 23:03:33 -02:00
Cedric BAIL 14d7ec478c edje: fix float comparison warning in edje edit logic. 2016-12-20 16:39:30 -08:00
Bruno Dilly 287486e920 edje: add flag to choose between evas or edje seat naming
collections.group.use_custom_seat_names should be set to '1'
to use seat names on signals as provided by Evas.

By default just follow Edje naming approach
("seat1", "seat2", ...)
2016-12-19 14:58:35 -02:00
Bruno Dilly c6399665dd edje: support action seats on edje_edit 2016-12-19 14:58:35 -02:00
Bruno Dilly 5cfdf3ec3a edje: support seat on focus action and signals
Seat goes as an optional parameter for FOCUS_SET (if not
provided, act over default seat), and emit signals
with seat suffix:
 * focus,in,$SEAT
 * focus,out,$SEAT
 * focus,part,in,$SEAT
 * focus,part,out,$SEAT
2016-12-19 14:58:35 -02:00
Vitalii Vorobiov 1a9a3e701d Edje_Edit: use specific function to get file's name correctly on Win and Linux
Because '\' is dir path for linux, but '/' is dir path for Window,
so better use specific function for getting file's name depending on specific
system
2016-11-25 15:00:49 +02:00
Jaehwan Kim 88f5ac22c1 edje_edit: fix segmentation fault(Array index is out of bound)
@fix
2016-11-22 17:17:54 +09:00
Vyacheslav Reutskiy 5fc98901ec edje_edit: fix compare double values 2016-11-08 09:40:25 +02:00
Vyacheslav Reutskiy 7cce17fd46 edje_edit: generate to source code base_scale if it different from 1.0
Fixes T4767
2016-10-31 13:17:45 +02:00
Vitalii Vorobiov 4655f90aaf Edje_Edit: save files name instead of full path on sound add
Since file will be inside of edj file, there is no need in having full path to
the place from where it was imported

@fix
2016-10-28 15:57:23 +03:00
Vitalii Vorobiov aa423e7669 Edje_Edit: use correct description array accessing
its a loop with j, but not with i
kinda a little typo

@fix
2016-10-25 18:25:05 +03:00
Vyacheslav Reutskiy 2922b68fdf edje_edit: avoid generate '(null)' value for image.normal 2016-10-18 08:49:07 +03:00
Vyacheslav Reutskiy 7d3200c782 edje_edit: add correct tweens generation for inherit state 2016-10-18 08:24:39 +03:00
Andrii Kroitor 6711a414dc edje_edit: refactor eet file usage
Summary:
Move opening for read/write/read-write and error message to internal method
Reuse eet file from Edje instead of opening it again in read-only mode
Add wrapper for eet_close to skip closing if internal file was used

Reviewers: NikaWhite

Subscribers: cedric, jpeg, #eflete

Differential Revision: https://phab.enlightenment.org/D4353
2016-10-17 18:51:59 +03:00
Vyacheslav Reutskiy e6fa6ba945 edje_edit: new API for generate source code for color classes
Extend edje edit deberate source API. Add two new API.
 - edje_edit_object_color_class_list_get return a list of used color classes for
   given object
 - edje_edit_color_classes_source_generate is generate code for given
   color classes list
2016-10-12 15:03:20 +03:00
Vyacheslav Reutskiy 8d7ec4181e edje_edit: add API for get source code of global block data
This API is annex for edje_edit_object_source_generate. Together this
API's provide a mechanism for generate source for custom groups from
a edj file or more.
2016-10-12 15:03:20 +03:00