[EGIT] [core/efl] master 01/01: efl - evas - sw engine - donmt free spinlock because cache always needed
raster pushed a commit to branch master. http://git.enlightenment.org/core/efl.git/commit/?id=5f307809b1d2ba2204bf073a06b4bc2fe1b205bb commit 5f307809b1d2ba2204bf073a06b4bc2fe1b205bb Author: Carsten Haitzler (Rasterman)Date: Tue Mar 29 12:09:40 2016 +0900 efl - evas - sw engine - donmt free spinlock because cache always needed never free the shm pool cache spinlock as it is alwasy needed once initiialized. this likely fixes a bsd hardlock issues @fix --- src/modules/evas/engines/software_x11/evas_xlib_outbuf.c | 8 ++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/src/modules/evas/engines/software_x11/evas_xlib_outbuf.c b/src/modules/evas/engines/software_x11/evas_xlib_outbuf.c index d556595..52dffd6 100644 --- a/src/modules/evas/engines/software_x11/evas_xlib_outbuf.c +++ b/src/modules/evas/engines/software_x11/evas_xlib_outbuf.c @@ -26,6 +26,7 @@ struct _Outbuf_Region int h; }; +static Eina_Bool shmpool_initted = EINA_FALSE; static Eina_List *shmpool = NULL; static int shmsize = 0; static int shmmemlimit = 20 * 1024 * 1024; @@ -150,7 +151,11 @@ _clear_xob(int psync) void evas_software_xlib_outbuf_init(void) { - eina_spinlock_new(_lock); + if (!shmpool_initted) + { +shmpool_initted = EINA_TRUE; +eina_spinlock_new(_lock); + } } void @@ -192,7 +197,6 @@ evas_software_xlib_outbuf_free(Outbuf *buf) eina_array_flush(>priv.onebuf_regions); free(buf); _clear_xob(0); - eina_spinlock_free(_lock); } Outbuf * --
[EGIT] [core/efl] master 02/03: Evas: Disable events on no-render objects
jpeg pushed a commit to branch master. http://git.enlightenment.org/core/efl.git/commit/?id=8407971a1a23bb601c546b1192395701445757d3 commit 8407971a1a23bb601c546b1192395701445757d3 Author: Jean-Philippe AndreDate: Mon Mar 28 20:10:21 2016 +0900 Evas: Disable events on no-render objects Source events still work for proxies (if the flag is set). --- src/lib/evas/include/evas_inline.x | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/lib/evas/include/evas_inline.x b/src/lib/evas/include/evas_inline.x index fcbceca..8f3644c 100644 --- a/src/lib/evas/include/evas_inline.x +++ b/src/lib/evas/include/evas_inline.x @@ -108,7 +108,7 @@ evas_event_freezes_through(Evas_Object *eo_obj EINA_UNUSED, Evas_Object_Protecte static inline int evas_event_passes_through(Evas_Object *eo_obj EINA_UNUSED, Evas_Object_Protected_Data *obj) { - if (obj->pass_events) return 1; + if (obj->pass_events || obj->no_render) return 1; if (obj->parent_cache.pass_events_valid) return obj->parent_cache.pass_events; if (!obj->smart.parent) return 0; --
[EGIT] [core/efl] master 03/03: evas/wayland_egl: Remove redundant function call.
jpeg pushed a commit to branch master. http://git.enlightenment.org/core/efl.git/commit/?id=a536f068dd0e6f24e6f878e25dda62f459129178 commit a536f068dd0e6f24e6f878e25dda62f459129178 Author: Minkyoung KimDate: Tue Mar 29 11:04:12 2016 +0900 evas/wayland_egl: Remove redundant function call. Summary: ob is already declared. need not to call again. Test Plan: Tizen3.0 Mobile Reviewers: jpeg, wonsik Subscribers: dkdk, cedric Differential Revision: https://phab.enlightenment.org/D3837 --- src/modules/evas/engines/wayland_egl/evas_engine.c | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/modules/evas/engines/wayland_egl/evas_engine.c b/src/modules/evas/engines/wayland_egl/evas_engine.c index bbfe738..0aab3af 100644 --- a/src/modules/evas/engines/wayland_egl/evas_engine.c +++ b/src/modules/evas/engines/wayland_egl/evas_engine.c @@ -1164,7 +1164,7 @@ eng_image_native_set(void *data, void *image, void *native) } else if (ns->type == EVAS_NATIVE_SURFACE_EVASGL) { - img2 = eina_hash_find(eng_get_ob(re)->gl_context->shared->native_evasgl_hash, ); + img2 = eina_hash_find(ob->gl_context->shared->native_evasgl_hash, ); if (img2 == img) return img; if (img2) { @@ -1310,7 +1310,7 @@ eng_image_native_set(void *data, void *image, void *native) { memcpy(&(n->ns), ns, sizeof(Evas_Native_Surface)); - eina_hash_add(eng_get_ob(re)->gl_context->shared->native_evasgl_hash, , img); + eina_hash_add(ob->gl_context->shared->native_evasgl_hash, , img); n->ns_data.evasgl.surface = ns->data.evasgl.surface; img->native.yinvert = 0; @@ -1335,13 +1335,13 @@ eng_image_native_set(void *data, void *image, void *native) n = calloc(1, sizeof(Native)); if (n) { - eina_hash_add(eng_get_ob(re)->gl_context->shared->native_tbm_hash, , img); + eina_hash_add(ob->gl_context->shared->native_tbm_hash, , img); memcpy(&(n->ns), ns, sizeof(Evas_Native_Surface)); n->ns_data.tbm.buffer = buffer; if (glsym_eglCreateImage) - n->ns_data.tbm.surface = glsym_eglCreateImage(eng_get_ob(re)->egl_disp, + n->ns_data.tbm.surface = glsym_eglCreateImage(ob->egl_disp, EGL_NO_CONTEXT, EGL_NATIVE_SURFACE_TIZEN, (void *)buffer, --
[EGIT] [core/efl] master 01/03: Evas render: Fix no-render with smart objects
jpeg pushed a commit to branch master. http://git.enlightenment.org/core/efl.git/commit/?id=8fb8e6d257f7199acd450f082188c282a48d339b commit 8fb8e6d257f7199acd450f082188c282a48d339b Author: Jean-Philippe AndreDate: Mon Mar 28 17:47:02 2016 +0900 Evas render: Fix no-render with smart objects Setting the no-render flag on an elm widget had no effect, as it was not properly propagated to its children. This should fix that, but I'm not a fan of the solution. Fixes T3371 --- src/lib/edje/edje_object.eo | 1 + src/lib/edje/edje_smart.c| 13 + src/lib/elementary/elm_widget.c | 16 src/lib/elementary/elm_widget.eo | 1 + src/lib/evas/canvas/evas_clip.c | 4 +++- src/lib/evas/canvas/evas_object_smart.c | 9 + src/lib/evas/canvas/evas_object_smart.eo | 5 + src/lib/evas/canvas/evas_render.c| 6 +++--- src/lib/evas/include/evas_inline.x | 4 ++-- 9 files changed, 53 insertions(+), 6 deletions(-) diff --git a/src/lib/edje/edje_object.eo b/src/lib/edje/edje_object.eo index be0c902..305684c 100644 --- a/src/lib/edje/edje_object.eo +++ b/src/lib/edje/edje_object.eo @@ -2234,6 +2234,7 @@ class Edje.Object (Evas.Smart_Clipped, Efl.File) Evas.Object_Smart.add; Evas.Object_Smart.del; Evas.Object_Smart.resize; + Evas.Object_Smart.smart_no_render.set; Efl.File.file.set; Efl.File.file.get; Efl.File.mmap.set; diff --git a/src/lib/edje/edje_smart.c b/src/lib/edje/edje_smart.c index a8ef1bc..2e905bf 100644 --- a/src/lib/edje/edje_smart.c +++ b/src/lib/edje/edje_smart.c @@ -332,6 +332,19 @@ _edje_object_evas_object_smart_hide(Eo *obj, Edje *ed) } EOLIAN static void +_edje_object_evas_object_smart_smart_no_render_set(Eo *obj, Edje *ed, Eina_Bool hide) +{ + Eina_List *l; + Edje *edg; + + evas_obj_smart_no_render_set(eo_super(obj, MY_CLASS), hide); + if (evas_obj_no_render_get(obj) == hide) return; + + EINA_LIST_FOREACH(ed->groups, l, edg) + if (edg != ed) evas_obj_smart_no_render_set(edg->obj, hide); +} + +EOLIAN static void _edje_object_evas_object_smart_calculate(Eo *obj EINA_UNUSED, Edje *ed) { _edje_recalc_do(ed); diff --git a/src/lib/elementary/elm_widget.c b/src/lib/elementary/elm_widget.c index b110f32..e165af9 100644 --- a/src/lib/elementary/elm_widget.c +++ b/src/lib/elementary/elm_widget.c @@ -556,6 +556,21 @@ _elm_widget_evas_object_smart_color_set(Eo *obj, Elm_Widget_Smart_Data *_pd EINA } EOLIAN static void +_elm_widget_evas_object_smart_smart_no_render_set(Eo *obj, Elm_Widget_Smart_Data *_pd EINA_UNUSED, Eina_Bool hide) +{ + Eina_Iterator *it; + Evas_Object *o; + + it = evas_object_smart_iterator_new(obj); + EINA_ITERATOR_FOREACH(it, o) + { + if (evas_object_data_get(o, "_elm_leaveme")) continue; + evas_obj_no_render_set(o, hide); + } + eina_iterator_free(it); +} + +EOLIAN static void _elm_widget_evas_object_smart_clip_set(Eo *obj, Elm_Widget_Smart_Data *_pd EINA_UNUSED, Evas_Object *clip) { Eina_Iterator *it; @@ -602,6 +617,7 @@ _elm_widget_evas_object_smart_member_add(Eo *obj, Elm_Widget_Smart_Data *_pd EIN evas_object_color_get(obj, , , , ); evas_object_color_set(child, r, g, b, a); + evas_obj_no_render_set(child, evas_obj_no_render_get(obj)); evas_object_clip_set(child, evas_object_clip_get(obj)); if (evas_object_visible_get(obj)) diff --git a/src/lib/elementary/elm_widget.eo b/src/lib/elementary/elm_widget.eo index b618b4d..505feb8 100644 --- a/src/lib/elementary/elm_widget.eo +++ b/src/lib/elementary/elm_widget.eo @@ -851,6 +851,7 @@ abstract Elm.Widget (Evas.Object_Smart, Elm.Interface_Atspi_Accessible, Elm.Inte Evas.Object_Smart.clip.set; Evas.Object_Smart.member_add; Evas.Object_Smart.resize; + Evas.Object_Smart.smart_no_render.set; @virtual .focus_direction; @virtual .focus_next; @virtual .parent_widget.get; diff --git a/src/lib/evas/canvas/evas_clip.c b/src/lib/evas/canvas/evas_clip.c index f1c5e4b..3fda1f7 100644 --- a/src/lib/evas/canvas/evas_clip.c +++ b/src/lib/evas/canvas/evas_clip.c @@ -537,9 +537,11 @@ _evas_object_clipees_has(Eo *eo_obj EINA_UNUSED, Evas_Object_Protected_Data *obj } EOLIAN void -_evas_object_no_render_set(Eo *eo_obj EINA_UNUSED, Evas_Object_Protected_Data *obj, Eina_Bool enable) +_evas_object_no_render_set(Eo *eo_obj, Evas_Object_Protected_Data *obj, Eina_Bool enable) { obj->no_render = enable; + if (obj->is_smart) + evas_obj_smart_no_render_set(eo_obj, enable); } EOLIAN Eina_Bool diff --git a/src/lib/evas/canvas/evas_object_smart.c b/src/lib/evas/canvas/evas_object_smart.c index 44c18f1..57c8801 100644 --- a/src/lib/evas/canvas/evas_object_smart.c +++ b/src/lib/evas/canvas/evas_object_smart.c @@ -679,6 +679,15 @@ _evas_object_smart_clip_unset(Eo *eo_obj, Evas_Smart_Data *o EINA_UNUSED) } EOLIAN
[EGIT] [website/www-content] master 01/01: Wiki page about-eflete changed with summary [] by Mykyta Biliavskyi
WWW-www.enlightenment.org pushed a commit to branch master. http://git.enlightenment.org/website/www-content.git/commit/?id=7359331396bf65312b71a69897d661289379c1c8 commit 7359331396bf65312b71a69897d661289379c1c8 Author: Mykyta BiliavskyiDate: Mon Mar 28 19:42:08 2016 -0700 Wiki page about-eflete changed with summary [] by Mykyta Biliavskyi --- pages/about-eflete.txt | 51 +- 1 file changed, 26 insertions(+), 25 deletions(-) diff --git a/pages/about-eflete.txt b/pages/about-eflete.txt index 0e2d91b..ffa3fef 100644 --- a/pages/about-eflete.txt +++ b/pages/about-eflete.txt @@ -6,14 +6,14 @@ {{ :icon-eflete.png?nolink|}} {{:eflete-main.png?&200 |}} -== What is Eflete? == +=== What is Eflete? === Efl Edje Theme Editor is a rich graphical tool, that provide UI for edc markup. It is aimed to simplify creation and editing widgets styles. No one, for sure, want to learn EDC syntax. Eflete was designed with mind, that target users are not just programmers but also designers. Besides styles Eflete is also able to create and edit custom layouts. This is useful feature for developers which creates applications layouts. -== Eflete projects == +=== Eflete projects === {{:eflete-projects.png?&200 |}} There are a lot of already existed projects, which are use edc collections for theming or layouting. Or binaries, that compiled by edje_cc tool. For both cases Eflete has import wizards to help in converting existing files into projects, @@ -23,23 +23,23 @@ required by Elementary library. User is free to modify those styles. It is possible to open existing project by File Selection tool. List of recently opened projects provides fast one- mouse-click selection interface. -NOTE: Eflete creates a specific file for each opened edj or edc-file. More precisely - for new project or imported file +Eflete creates a specific file for each opened edj or edc-file. More precisely - for new project or imported file Eflete creates a folder with project name, than copy imported file and create specific file. This file has a .pro -extension and Eflete used it for manipulations. - +extension and Eflete used it for manipulations. Editor operates with binary edj files, but for developers, source code is the must have thing. Of course Eflete support exporting of the currently editing project into the *.edc files. Also it can be standalone group inside project. The -export features could be found in main menu by path: File > Export as edc > Group (or Project). It is also +export features could be found in main menu by path: File -> Export as edc -> Group (or Project). It is also possible to export resources, that is used inside project (or group). There is a shell script can be found inside folder, where data was exported to. It builds edc source code back to the binary file. -== Resource management == +=== Resource management === +{{ :eflete-images.png?&200|}} Usually themes and layouts use a lot of images. Sometimes sounds, tones, fonts and other resources. Theme Editor include few manage tools, that provide natural way to add, delete or edit existed resources. It is also gives fast access to resource preview with additional info. Images, sounds, colorclasses and textblock style manager tools are represented as a pinned tabs. -{{ :eflete-images.png?&200|}} + Images and sounds could be added into project by using file selection dialog (it is possible to add a few files at the same time by holding Shift button and selecting necessary files in a dialog). Images preview and info block (file name, format, resolution, etc.) will be displayed on selection. Also list of styles which are used in selected images @@ -53,14 +53,15 @@ handle manually. Another useful feature - changeable color of background preview colors preview at the bottom of manager view. Second text resource manager responsible for manipulation with colorclasses values. It has mostly the same controls as in TextblockStyle manager. -== Navigations == +=== Navigations === {{:eflete-groups.png?&200 |}} +{{ :eflete-parts.png?&200|}} All navigation controls are represented by a tree-view lists. There are two main areas: groups and parts/programs lists. The list of groups are placed on the left side of Eflete and holds all groups from loaded project. Items sorted alphabetically. On the top of navigation bar placed two icons, that provides ability to add new group into project or delete currently existing. In case of adding new group, simple dialog wizard will be shown. It will set name for new group and chose source group if it is required to create copy or alias. -{{ :eflete-parts.png?&200|}} + Groups list structure is based on splitting group name by tokens, that separated one from another by '\' character. What kind of benefit from this way? For example take the default Elementary theme. This theme contain a lot of groups
[EGIT] [website/www-content] master 01/01: Add about page for Eflete project.
nikawhite pushed a commit to branch master. http://git.enlightenment.org/website/www-content.git/commit/?id=fe1e6db143253bf7eae098d3e6d10e8bcebfc037 commit fe1e6db143253bf7eae098d3e6d10e8bcebfc037 Author: Mykyta BiliavskyiDate: Tue Mar 29 09:49:24 2016 +0900 Add about page for Eflete project. --- media/eflete-code-mode.png | Bin 0 -> 162957 bytes media/eflete-demo-mode.png | Bin 0 -> 135099 bytes media/eflete-groups.png | Bin 0 -> 10238 bytes media/eflete-history.png | Bin 0 -> 108474 bytes media/eflete-images.png | Bin 0 -> 210009 bytes media/eflete-main.png| Bin 0 -> 344264 bytes media/eflete-navigation.png | Bin 0 -> 126453 bytes media/eflete-normal-mode.png | Bin 0 -> 143053 bytes media/eflete-parts.png | Bin 0 -> 16618 bytes media/eflete-projects.png| Bin 0 -> 44973 bytes media/eflete-texts.png | Bin 0 -> 347389 bytes media/icon-eflete.png| Bin 0 -> 24713 bytes pages/about-eflete.txt | 142 +++ pages/about.txt | 1 + 14 files changed, 143 insertions(+) diff --git a/media/eflete-code-mode.png b/media/eflete-code-mode.png new file mode 100644 index 000..69af9ed Binary files /dev/null and b/media/eflete-code-mode.png differ diff --git a/media/eflete-demo-mode.png b/media/eflete-demo-mode.png new file mode 100644 index 000..e1deac9 Binary files /dev/null and b/media/eflete-demo-mode.png differ diff --git a/media/eflete-groups.png b/media/eflete-groups.png new file mode 100644 index 000..229dc41 Binary files /dev/null and b/media/eflete-groups.png differ diff --git a/media/eflete-history.png b/media/eflete-history.png new file mode 100644 index 000..ade57f3 Binary files /dev/null and b/media/eflete-history.png differ diff --git a/media/eflete-images.png b/media/eflete-images.png new file mode 100644 index 000..6e7a6ef Binary files /dev/null and b/media/eflete-images.png differ diff --git a/media/eflete-main.png b/media/eflete-main.png new file mode 100644 index 000..4857a19 Binary files /dev/null and b/media/eflete-main.png differ diff --git a/media/eflete-navigation.png b/media/eflete-navigation.png new file mode 100644 index 000..d3c8d3f Binary files /dev/null and b/media/eflete-navigation.png differ diff --git a/media/eflete-normal-mode.png b/media/eflete-normal-mode.png new file mode 100644 index 000..13f98fc Binary files /dev/null and b/media/eflete-normal-mode.png differ diff --git a/media/eflete-parts.png b/media/eflete-parts.png new file mode 100644 index 000..3db43f1 Binary files /dev/null and b/media/eflete-parts.png differ diff --git a/media/eflete-projects.png b/media/eflete-projects.png new file mode 100644 index 000..f4e96e5 Binary files /dev/null and b/media/eflete-projects.png differ diff --git a/media/eflete-texts.png b/media/eflete-texts.png new file mode 100644 index 000..a6b26d2 Binary files /dev/null and b/media/eflete-texts.png differ diff --git a/media/icon-eflete.png b/media/icon-eflete.png new file mode 100644 index 000..5c0e6a5 Binary files /dev/null and b/media/icon-eflete.png differ diff --git a/pages/about-eflete.txt b/pages/about-eflete.txt new file mode 100644 index 000..0e2d91b --- /dev/null +++ b/pages/about-eflete.txt @@ -0,0 +1,142 @@ +~~Title: About Eflete~~ + Eflete + +[[download|Download Eflete Here]] + +{{ :icon-eflete.png?nolink|}} + +{{:eflete-main.png?&200 |}} +== What is Eflete? == + +Efl Edje Theme Editor is a rich graphical tool, that provide UI for edc markup. +It is aimed to simplify creation and editing widgets styles. No one, for sure, want to learn EDC syntax. Eflete was +designed with mind, that target users are not just programmers but also designers. Besides styles Eflete is also able +to create and edit custom layouts. This is useful feature for developers which creates applications layouts. + +== Eflete projects == +{{:eflete-projects.png?&200 |}} +There are a lot of already existed projects, which are use edc collections for theming or layouting. Or binaries, that +compiled by edje_cc tool. For both cases Eflete has import wizards to help in converting existing files into projects, +that supported by theme editor. +For new projects it is possible to select predefined widget styles. All widgets in list contains a sets of groups, that +required by Elementary library. User is free to modify those styles. +It is possible to open existing project by File Selection tool. List of recently opened projects provides fast one- +mouse-click selection interface. + +NOTE: Eflete creates a specific file for each opened edj or edc-file. More precisely - for new project or imported file +Eflete creates a folder with project name, than copy imported file and create specific file. This file has a .pro +extension and Eflete used it for manipulations. + + +Editor operates with binary edj files, but for developers, source code is the must
[EGIT] [core/efl] master 02/02: elementary: start bringing back documentation support.
cedric pushed a commit to branch master. http://git.enlightenment.org/core/efl.git/commit/?id=b6a81b6e7bbcc3991c6efc11d14802bc028d9365 commit b6a81b6e7bbcc3991c6efc11d14802bc028d9365 Author: Cedric BAILDate: Mon Mar 28 16:56:31 2016 -0700 elementary: start bringing back documentation support. I didn't know preview generation was so slow and done completely serialy. There is potential improvement here. Still need to kind of merge the documentation into something readable. --- configure.ac | 1 + {legacy/elementary/doc => doc}/.gitignore | 0 doc/Makefile.am | 185 +- doc/widgets/Makefile.am | 21 +++- 4 files changed, 199 insertions(+), 8 deletions(-) diff --git a/configure.ac b/configure.ac index f6cd7d8..7683969 100644 --- a/configure.ac +++ b/configure.ac @@ -5378,6 +5378,7 @@ data/Makefile doc/Makefile doc/Doxyfile doc/previews/Makefile +doc/widgets/Makefile src/Makefile src/benchmarks/eina/Makefile src/benchmarks/eo/Makefile diff --git a/legacy/elementary/doc/.gitignore b/doc/.gitignore similarity index 100% rename from legacy/elementary/doc/.gitignore rename to doc/.gitignore diff --git a/doc/Makefile.am b/doc/Makefile.am index 2765bb1..9b89fb2 100644 --- a/doc/Makefile.am +++ b/doc/Makefile.am @@ -1,4 +1,4 @@ -SUBDIRS = previews +SUBDIRS = previews widgets MAINTAINERCLEANFILES = Makefile.in @@ -16,8 +16,189 @@ previews-build: previews-data: @$(MAKE) -C previews doc +# dir:file name:executable:width:height +WGT_PREVIEW = \ + actionslider:preview-00.png:widget_preview_actionslider:120:30 \ + bg:preview-00.png:widget_preview_bg:50:50 \ + box:preview-00.png:widget_preview_box:200:160 \ + bubble:preview-00.png:widget_preview_bubble1:160:50 \ + bubble:preview-01.png:widget_preview_bubble2:160:50 \ + bubble:preview-02.png:widget_preview_bubble3:160:50 \ + button:preview-00.png:widget_preview_button1:160:50 \ + button:preview-01.png:widget_preview_button2:160:50 \ + button:preview-02.png:widget_preview_button3:160:50 \ + calendar:preview-00.png:widget_preview_calendar:300:300 \ + check:preview-00.png:widget_preview_check1:160:50 \ + check:preview-01.png:widget_preview_check2:160:50 \ + check:preview-02.png:widget_preview_check3:160:50 \ + clock:preview-00.png:widget_preview_clock:200:100 \ + colorselector:preview-00.png:widget_preview_colorselector:320:300 \ + conformant:preview-00.png:widget_preview_conformant:200:400 \ + combobox:preview-00.png:widget_preview_combobox:300:300 \ + ctxpopup:preview-00.png:widget_preview_ctxpopup:200:130 \ + datetime:preview-00.png:widget_preview_datetime1:360:60 \ + datetime:preview-01.png:widget_preview_datetime2:200:60 \ + datetime:preview-02.png:widget_preview_datetime3:200:60 \ + dayselector:preview-00.png:widget_preview_dayselector:350:50 \ + diskselector:preview-00.png:widget_preview_diskselector:120:50 \ + entry:preview-00.png:widget_preview_entry1:160:50 \ + entry:preview-01.png:widget_preview_entry2:160:50 \ + entry:preview-02.png:widget_preview_entry3:160:50 \ + entry:preview-03.png:widget_preview_entry4:160:50 \ + fileselector:preview-00.png:widget_preview_fileselector:300:300 \ + fileselector_button:preview-00.png:widget_preview_fileselector_button1:200:50 \ + fileselector_button:preview-01.png:widget_preview_fileselector_button2:200:50 \ + fileselector_button:preview-02.png:widget_preview_fileselector_button3:160:50 \ + fileselector_entry:preview-00.png:widget_preview_fileselector_entry:70:50 \ + flip:preview-00.png:widget_preview_flip:100:100 \ + flipselector:preview-00.png:widget_preview_flipselector:100:60 \ + frame:preview-00.png:widget_preview_frame:100:50 \ + gengrid:preview-00.png:widget_preview_gengrid:200:160 \ + genlist:preview-00.png:widget_preview_genlist1:200:200 \ + genlist:preview-01.png:widget_preview_genlist2:200:160 \ + genlist:preview-02.png:widget_preview_genlist3:200:160 \ + genlist:preview-03.png:widget_preview_genlist4:200:160 \ + genlist:preview-04.png:widget_preview_genlist5:200:160 \ + hover:preview-00.png:widget_preview_hover:90:170 \ + hoversel:preview-00.png:widget_preview_hoversel:90:170 \ + icon:preview-00.png:widget_preview_icon:50:50 \ + image:preview-00.png:widget_preview_image:50:50 \ + index:preview-00.png:widget_preview_index:200:160 \ + inwin:preview-00.png:widget_preview_inwin1:200:160 \ + inwin:preview-01.png:widget_preview_inwin2:200:160 \ + inwin:preview-02.png:widget_preview_inwin3:200:160 \ + label:preview-00.png:widget_preview_label:70:30 \ + layout:preview-00.png:widget_preview_layout:200:160 \ +
[EGIT] [core/efl] master 01/02: elementary: merge AUTHORS
cedric pushed a commit to branch master. http://git.enlightenment.org/core/efl.git/commit/?id=5f178387112f9250bc57be252b1e4456a250a05a commit 5f178387112f9250bc57be252b1e4456a250a05a Author: Cedric BAILDate: Mon Mar 28 16:30:41 2016 -0700 elementary: merge AUTHORS --- AUTHORS | 174 ++ legacy/elementary/AUTHORS | 171 - 2 files changed, 174 insertions(+), 171 deletions(-) diff --git a/AUTHORS b/AUTHORS index a3b0e1e..57b08ef 100644 --- a/AUTHORS +++ b/AUTHORS @@ -359,6 +359,180 @@ ELua Daniel Kolesa +Elementary +-- +The Rasterman (Carsten Haitzler) +Gustavo Sverzut Barbieri +Cedric Bail +Vincent Torri +Daniel Kolesa +Jaime Thomas +Swisscom - http://www.swisscom.ch/ +Christopher Michael +Marco Trevisan (Treviño) +Michael Bouchaud +Jonathan Atton (Watchwolf) +Brian Wang +Mike Blumenkrantz (discomfitor/zmike) +Samsung Electronics +Samsung SAIT +Brett Nash +Bruno Dilly +Rafael Fonseca +Hermet Park +Woohyun Jung +Jaehwan Kim +Wonguk Jeong +Leandro A. F. Pereira +Helen Fornazier +Gustavo Lima Chaves +Fabiano Fidêncio +Tiago Falcão +Otavio Pontes +Viktor Kojouharov +Daniel Juyung Seo (SeoZ) +Sangho Park +Rajeev Ranjan (Rajeev) +Seunggyun Kim +Sohyun Kim +Jihoon Kim +Jeonghyun Yun (arosis) +Tom Hacohen +Aharon Hillel +Shinwoo Kim +Govindaraju SM +Prince Kumar Dubey +Sung W. Park +Thierry el Borgi +Shilpa Singh +Chanwook Jung +Hyoyoung Chang +Guillaume "Kuri" Friloux +Kim Yunhan +Tae-Hwan Kim (Bluezery) +Nicolas Aguirre +Sanjeev BA +Hyunsil Park +Goun Lee +Mikael Sans +Doyoun Kang +M.V.K. Sumanth +Jérôme Pinot +Davide Andreoli +Michal Pakula vel Rutka +Thiep Ha +Artem Popov +Minseok Kim +Jean-Philippe André +JiHyeon Seol +Flavio Ceolin +Igor Murzov +Jiyoun Park +KoziarekBeata +Daniel Zaoui +Yakov Goldberg +Murilo Belluzzo +Ricardo de Almeida Gonzaga +Gwanglim Lee +JaeHyun Cho +Bora Hwang +Jiyoung Choi +Arvind R +Paulo Cavalcanti +Stefan Schmidt +Ryuan Choi (ryuan) +Hosang Kim +Youngbok Shin +Niraj Kumar +Amitesh Singh +Abhinandan Aryadipta +Sanghyeon Lee +Anil Kumar Nahak +Michal Jagiello +Chinmaya Panigrahi +Mohammad Irfan +ajwillia.ms (Andrew Williams) +Iván Briano +Jonas M. Gastal +Rafael Antognolli +Mike McCormack +Massimo Maiurana +Henrique Dante de Almeida
[EGIT] [tools/enventor] master 01/01: editor: removed a fixed 1 0; warning.
hermet pushed a commit to branch master. http://git.enlightenment.org/tools/enventor.git/commit/?id=c0942cd60a6b4d007a26fd878781840ca9c7ac38 commit c0942cd60a6b4d007a26fd878781840ca9c7ac38 Author: Hermet ParkDate: Tue Mar 29 08:35:19 2016 +0900 editor: removed a fixed 1 0; warning. --- data/themes/default/layout_common.edc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/data/themes/default/layout_common.edc b/data/themes/default/layout_common.edc index d47cb4f..f9f8c7e 100644 --- a/data/themes/default/layout_common.edc +++ b/data/themes/default/layout_common.edc @@ -2737,10 +2737,10 @@ group { name: "edit_layout"; rel1.to: "elm.swallow.linenumber"; rel2.to: "elm.swallow.linenumber"; rel2.relative: 1 1; +fixed: 1 0; } description { state: "hide" 0.0; -rel1.to: "elm.swallow.linenumber"; -rel2.to: "elm.swallow.linenumber"; +inherit: "default"; rel2.relative: 0 1; } } --
[EGIT] [core/efl] master 01/01: elementary: add back C++ generated binding.
cedric pushed a commit to branch master. http://git.enlightenment.org/core/efl.git/commit/?id=5155c2d156db16a454c542460223d99cf8fd6414 commit 5155c2d156db16a454c542460223d99cf8fd6414 Author: Cedric BAILDate: Mon Mar 28 16:16:15 2016 -0700 elementary: add back C++ generated binding. --- src/Makefile.am | 1 + src/Makefile_Elementary_Cxx.am | 54 ++ src/lib/elementary/Elementary.hh.in | 142 3 files changed, 55 insertions(+), 142 deletions(-) diff --git a/src/Makefile.am b/src/Makefile.am index 084d1a4..c256c4f 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -81,6 +81,7 @@ include Makefile_Efl_Cxx.am include Makefile_Edje_Cxx.am include Makefile_Evas_Cxx.am include Makefile_Eio_Cxx.am +include Makefile_Elementary_Cxx.am include Makefile_Elua.am diff --git a/src/Makefile_Elementary_Cxx.am b/src/Makefile_Elementary_Cxx.am new file mode 100644 index 000..d88795c --- /dev/null +++ b/src/Makefile_Elementary_Cxx.am @@ -0,0 +1,54 @@ +if HAVE_CXX11 + + +### Generated headers +generated_elementary_cxx_bindings = $(elm_eolian_files:%.eo=%.eo.hh) +generated_elementary_cxx_impl_bindings = $(elm_eolian_files:%.eo=%.eo.impl.hh) + +lib/elementary/Elementary.hh: $(generated_elementary_cxx_bindings) + @echo @ECHO_E@ "#ifndef EFL_CXX_ELEMENTARY_HH\n#define EFL_CXX_ELEMENTARY_HH\n" > $(top_builddir)/src/lib/elementary/Elementary.hh + @echo @ECHO_E@ "#if defined(ELEMENTARY_H) || defined(ELM_WIDGET_H)" >> $(top_builddir)/src/lib/elementary/Elementary.hh + @echo @ECHO_E@ "#error Do not include Elm C API headers before including Elementary.hh" >> $(top_builddir)/src/lib/elementary/Elementary.hh + @echo @ECHO_E@ "#endif" >> $(top_builddir)/src/lib/elementary/Elementary.hh + @echo @ECHO_E@ "" >> $(top_builddir)/src/lib/elementary/Elementary.hh + @echo @ECHO_E@ "extern \"C\" {" >> $(top_builddir)/src/lib/elementary/Elementary.hh + @echo @ECHO_E@ "#include \"Elementary.h\"" >> $(top_builddir)/src/lib/elementary/Elementary.hh + @echo @ECHO_E@ "#include \"elm_widget.h\"" >> $(top_builddir)/src/lib/elementary/Elementary.hh + @echo @ECHO_E@ "}" >> $(top_builddir)/src/lib/elementary/Elementary.hh + @echo @ECHO_E@ "" >> $(top_builddir)/src/lib/elementary/Elementary.hh + @echo @ECHO_E@ "#ifdef EFL_BETA_API_SUPPORT" >> $(top_builddir)/src/lib/elementary/Elementary.hh + @for i in $(generated_elementary_cxx_bindings); do echo "#include <$$(basename $$i)>" >> $(top_builddir)/src/lib/elementary/Elementary.hh; done + @echo @ECHO_E@ "#endif\n\n#endif\n" >> $(top_builddir)/src/lib/elementary/Elementary.hh + +generated_elementary_cxx_all = \ + $(generated_elementary_cxx_bindings) \ + $(generated_elementary_cxx_impl_bindings) \ + lib/elementary/Elementary.hh + +CLEANFILES += $(generated_elementary_cxx_all) + +installed_elementarycxxmainheadersdir = $(includedir)/elementary-cxx-@VMAJ@/ +nodist_installed_elementarycxxmainheaders_DATA = $(generated_elementary_cxx_all) + +### Unit tests +### To be reenable in the future when we do have a meaningful tests + +if EFL_ENABLE_TESTS + +check_PROGRAMS += +TESTS += + +# tests_elementary_cxx_cxx_compile_test_SOURCES = tests/elementary_cxx/cxx_compile_test.cc +# tests_elementary_cxx_cxx_compile_test_CPPFLAGS = -I$(top_builddir)/src/lib/efl \ +# -I$(top_builddir)/src/lib/evas/canvas/ \ +# -I$(top_builddir)/src/lib/efl/interfaces/ \ +# -DTESTS_SRC_DIR=\"$(top_srcdir)/src/tests/elementary_cxx\" \ +# -DTESTS_BUILD_DIR=\"$(top_builddir)/src/tests/elementary_cxx\" \ +# @CHECK_CFLAGS@ @ECORE_CXX_CFLAGS@ @EINA_CXX_CFLAGS@ @EVAS_CXX_CFLAGS@ @ELEMENTARY_CXX_CFLAGS@ @EO_CXX_CFLAGS@ \ +# @ECORE_CFLAGS@ @EINA_CFLAGS@ @EVAS_CFLAGS@ @ELEMENTARY_CFLAGS@ @EO_CFLAGS@ +# tests_elementary_cxx_cxx_compile_test_LDADD = @CHECK_LIBS@ @USE_ELEMENTARY_LIBS@ +# tests_elementary_cxx_cxx_compile_test_DEPENDENCIES = @USE_ELEMENTARY_INTERNAL_LIBS@ + +endif + +endif diff --git a/src/lib/elementary/Elementary.hh.in b/src/lib/elementary/Elementary.hh.in deleted file mode 100644 index 965e3fa..000 --- a/src/lib/elementary/Elementary.hh.in +++ /dev/null @@ -1,142 +0,0 @@ -/* This is the prmary Elementary header file that includes all other useful - * headers. - * - * Elementary is distributed under the LGPLv2 license. Please see the COPYING - * file that was distributed with this source. - */ -#ifndef ELEMENTARY_CXX_HH -#define ELEMENTARY_CXX_HH - -#if defined(ELEMENTARY_H) || defined(ELM_WIDGET_H) -#error Do not include Elm C API headers before including Elementary.hh -#endif - -#define EFL_BETA_API_SUPPORT 1 -#define EFL_EO_API_SUPPORT 1 -#define ELM_INTERNAL_API_ARGESFSDFEFC -#define ELM_WIDGET_ITEM_PROTECTED - -extern "C" { - -#include "Elementary.h" - -#include "elm_widget.h" - -} - -#ifdef EFL_BETA_API_SUPPORT -#define ELM_ELOCATION -#include -#include -#include -#include -#include -#include
[EGIT] [core/efl] master 01/01: ector: do not put ector_types.eot into the list of to be cleaned files.
cedric pushed a commit to branch master. http://git.enlightenment.org/core/efl.git/commit/?id=b9bd9228164b4ea810a33a888a2212d38b32a65e commit b9bd9228164b4ea810a33a888a2212d38b32a65e Author: Cedric BAILDate: Mon Mar 28 15:17:22 2016 -0700 ector: do not put ector_types.eot into the list of to be cleaned files. --- src/Makefile_Ector.am | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/Makefile_Ector.am b/src/Makefile_Ector.am index 6a3a14a..0c40f60 100644 --- a/src/Makefile_Ector.am +++ b/src/Makefile_Ector.am @@ -51,8 +51,7 @@ ector_eolian_files = \ $(ector_eolian_files_generic) \ $(ector_eolian_files_cairo) \ $(ector_eolian_files_software) \ - $(ector_eolian_files_gl) \ - $(ector_eolian_type_files) + $(ector_eolian_files_gl) ector_eolian_c = $(ector_eolian_files:%.eo=%.eo.c) ector_eolian_h = $(ector_eolian_files:%.eo=%.eo.h) \ @@ -67,7 +66,7 @@ CLEANFILES += \ $(ector_eolian_h) ectoreolianfilesdir = $(datadir)/eolian/include/ector-@VMAJ@ -ectoreolianfiles_DATA = $(ector_eolian_files) +ectoreolianfiles_DATA = $(ector_eolian_files) $(ector_eolian_type_files) EXTRA_DIST += $(ectoreolianfiles_DATA) \ lib/ector/Ector.h \ --
[EGIT] [core/enlightenment] master 01/01: add even more systray/dbusmenu hacks
discomfitor pushed a commit to branch master. http://git.enlightenment.org/core/enlightenment.git/commit/?id=286fb404288f2f96f7e5963d310a9e8d261ddaaf commit 286fb404288f2f96f7e5963d310a9e8d261ddaaf Author: Mike BlumenkrantzDate: Mon Mar 28 15:33:38 2016 -0400 add even more systray/dbusmenu hacks mrw Qt systray devs take working (4.X) and then break it in 5.X to be worse than steam: http://gfycat.com/CloudyPinkEmperorshrimp fix T3139 --- src/bin/e_dbusmenu.c | 111 --- 1 file changed, 70 insertions(+), 41 deletions(-) diff --git a/src/bin/e_dbusmenu.c b/src/bin/e_dbusmenu.c index 76cce57..bc87097 100644 --- a/src/bin/e_dbusmenu.c +++ b/src/bin/e_dbusmenu.c @@ -9,6 +9,7 @@ struct _E_DBusMenu_Ctx void *data; E_DBusMenu_Pop_Request_Cb pop_request_cb; E_DBusMenu_Update_Cb update_cb; + Eina_Bool hacks : 1; }; static const char *Menu_Item_Type_Names[] = @@ -31,6 +32,8 @@ static const char *Menu_Item_Event_Names[] = "clicked", "hovered", "opened", "closed" }; +static void proxy_init(E_DBusMenu_Ctx *ctx); + static int id_find(const char *text, const char *array_of_names[], unsigned max) { @@ -197,6 +200,46 @@ dbus_menu_free(E_DBusMenu_Item *m) free(m); } +static Eina_Bool +attempt_hacks(E_DBusMenu_Ctx *ctx) +{ + /* https://phab.enlightenment.org/T3139 */ + Eldbus_Object *obj; + Eldbus_Connection *conn; + const char *bus, *p; + int n; + char buf[1024] = {0}, buf2[1024] = {0}; + + if (ctx->hacks) return EINA_FALSE; + obj = eldbus_proxy_object_get(ctx->proxy); + conn = eldbus_object_connection_get(obj); + bus = eldbus_object_bus_name_get(obj); + if (bus[0] != ':') return EINA_FALSE; + /* if this is a qt5 app, menu bus is $bus + 2 +* ...probably +*/ + + p = strchr(bus + 1, '.'); + if (!p) return EINA_FALSE; + p++; + if (!p[0]) return EINA_FALSE; + n = strtol(p, NULL, 10); + if (n == -1) return EINA_FALSE; + n += 2; + if ((unsigned int)(p - bus) > sizeof(buf) - 1) return EINA_FALSE; + strncpy(buf, bus, p - bus); + snprintf(buf2, sizeof(buf2), "%s%d", buf, n); + E_FREE_FUNC(ctx->root_menu, dbus_menu_free); + eldbus_proxy_unref(ctx->proxy); + eldbus_object_unref(obj); + + obj = eldbus_object_get(conn, buf2, "/MenuBar"); + ctx->proxy = eldbus_proxy_get(obj, DBUS_MENU_IFACE); + proxy_init(ctx); + ctx->hacks = 1; + return EINA_TRUE; +} + static void layout_get_cb(void *data, const Eldbus_Message *msg, Eldbus_Pending *pending EINA_UNUSED) { @@ -220,6 +263,15 @@ layout_get_cb(void *data, const Eldbus_Message *msg, Eldbus_Pending *pending EIN m = parse_layout(layout, NULL, ctx); m->revision = revision; + if (m->is_submenu && (!m->parent) && (!m->sub_items)) + { +if (attempt_hacks(ctx)) + { + dbus_menu_free(m); + return; + } + } + if (ctx->update_cb) ctx->update_cb(ctx->data, m); if (ctx->root_menu) @@ -271,32 +323,6 @@ menu_pop_request(void *data, const Eldbus_Message *msg) } static void -icon_theme_path_get_cb(void *data EINA_UNUSED, const Eldbus_Message *msg, Eldbus_Pending *pending EINA_UNUSED) -{ - const char *error, *error_msg; - Eldbus_Message_Iter *var, *array; - const char *path; - - if (eldbus_message_error_get(msg, , _msg)) - { -ERR("%s %s", error, error_msg); -return; - } - - if (!eldbus_message_arguments_get(msg, "v", ) || - !eldbus_message_iter_arguments_get(var, "as", )) - { -ERR("Error reading message."); -return; - } - - while (eldbus_message_iter_get_and_next(array, 's', )) - { -//TODO - } -} - -static void prop_changed_cb(void *data EINA_UNUSED, const Eldbus_Message *msg) { const char *interface, *propname; @@ -337,6 +363,23 @@ layout_updated_cb(void *data, const Eldbus_Message *msg EINA_UNUSED) layout_update(ctx); } +static void +proxy_init(E_DBusMenu_Ctx *ctx) +{ + layout_update(ctx); + eldbus_proxy_signal_handler_add(ctx->proxy, + "ItemActivationRequested", + menu_pop_request, ctx); + + eldbus_proxy_properties_changed_callback_add(ctx->proxy, + prop_changed_cb, ctx); + + eldbus_proxy_signal_handler_add(ctx->proxy, "ItemsPropertiesUpdated", + layout_updated_cb, ctx); + eldbus_proxy_signal_handler_add(ctx->proxy, "LayoutUpdated", + layout_updated_cb, ctx); +} + E_API E_DBusMenu_Ctx * e_dbusmenu_load(Eldbus_Connection *conn, const char *bus, const char *path, const void *data) { @@ -353,21 +396,7 @@ e_dbusmenu_load(Eldbus_Connection *conn, const char *bus, const char *path, cons eldbus_connection_ref(conn); obj = eldbus_object_get(conn, bus, path); ctx->proxy = eldbus_proxy_get(obj,
[EGIT] [core/efl] master 02/02: edje: add edje_object_box_part_insert_after()
cedric pushed a commit to branch master. http://git.enlightenment.org/core/efl.git/commit/?id=aa920444224785527ce718fb2f41adcd45a0cdd0 commit aa920444224785527ce718fb2f41adcd45a0cdd0 Author: Jee-Yong UmDate: Mon Mar 28 11:24:02 2016 -0700 edje: add edje_object_box_part_insert_after() Summary: In evas and elm box, function for inserting child object after referenced one is available, but edje doesn't have it. This adds edje_object_box_part_insert_after() API. @feature Reviewers: raster, jpeg, cedric Reviewed By: jpeg Subscribers: jpeg Differential Revision: https://phab.enlightenment.org/D3733 Signed-off-by: Cedric BAIL --- src/lib/edje/edje_object.eo | 30 - src/lib/edje/edje_private.h | 1 + src/lib/edje/edje_util.c| 47 + 3 files changed, 73 insertions(+), 5 deletions(-) diff --git a/src/lib/edje/edje_object.eo b/src/lib/edje/edje_object.eo index 63f4c22..be0c902 100644 --- a/src/lib/edje/edje_object.eo +++ b/src/lib/edje/edje_object.eo @@ -1030,7 +1030,8 @@ class Edje.Object (Evas.Smart_Clipped, Efl.File) Adds child to the box indicated by part, in the position given by pos. - See also @.part_box_append(), @.part_box_prepend() and @.part_box_insert_before()]] + See also @.part_box_append(), @.part_box_prepend(), + @.part_box_insert_before() and @.part_box_insert_after()]] return: bool; [[$true: Successfully added. $false: An error occurred.]] @@ -1097,7 +1098,8 @@ class Edje.Object (Evas.Smart_Clipped, Efl.File) Prepends child to the box indicated by part. - See also @.part_box_append(), @.part_box_insert_before() and @.part_box_insert_at()]] + See also @.part_box_append(), @.part_box_insert_before(), + @.part_box_insert_after and @.part_box_insert_at()]] return: bool; [[$true: Successfully added. $false: An error occurred.]] @@ -1594,7 +1596,25 @@ class Edje.Object (Evas.Smart_Clipped, Efl.File) Inserts child in the box given by part, in the position marked by reference. - See also @.part_box_append(), @.part_box_prepend() and @.part_box_insert_at()]] + See also @.part_box_append(), @.part_box_prepend(), + @.part_box_insert_after() and @.part_box_insert_at()]] + + return: bool; [[$true: Successfully added. + $false: An error occurred.]] + params { +@in part: const(char)*; [[The part name]] +@in child: Evas.Object *; [[The object to insert]] +@in reference: const(Evas.Object)*; [[The object to be used as reference]] + } + } + part_box_insert_after { + [[Adds an object to the box. + + Inserts child in the box given by part, in the position marked by + reference. + + See also @.part_box_append(), @.part_box_prepend(), + @.part_box_insert_before() and @.part_box_insert_at()]] return: bool; [[$true: Successfully added. $false: An error occurred.]] @@ -1680,8 +1700,8 @@ class Edje.Object (Evas.Smart_Clipped, Efl.File) Appends child to the box indicated by part. - See also @.part_box_prepend(), @.part_box_insert_before() - and @.part_box_insert_at()]] + See also @.part_box_prepend(), @.part_box_insert_before(), + @.part_box_insert_after() and @.part_box_insert_at()]] return: bool; [[$true: Successfully added. $false: An error occurred.]] diff --git a/src/lib/edje/edje_private.h b/src/lib/edje/edje_private.h index 402c50f..517a2ca 100644 --- a/src/lib/edje/edje_private.h +++ b/src/lib/edje/edje_private.h @@ -2428,6 +2428,7 @@ Edje_Part_Description_Text *_edje_real_part_text_text_source_description_get(Edj Eina_Bool _edje_real_part_box_append(Edje *ed, Edje_Real_Part *rp, Evas_Object *child_obj); Eina_Bool _edje_real_part_box_prepend(Edje *ed, Edje_Real_Part *rp, Evas_Object *child_obj); Eina_Bool _edje_real_part_box_insert_before(Edje *ed, Edje_Real_Part *rp, Evas_Object *child_obj, const Evas_Object *ref); +Eina_Bool _edje_real_part_box_insert_after(Edje *ed, Edje_Real_Part *rp, Evas_Object *child_obj, const Evas_Object *ref); Eina_Bool _edje_real_part_box_insert_at(Edje *ed, Edje_Real_Part *rp, Evas_Object *child_obj, unsigned int pos); Evas_Object *_edje_real_part_box_remove(Edje *ed, Edje_Real_Part *rp, Evas_Object *child_obj); Evas_Object *_edje_real_part_box_remove_at(Edje *ed, Edje_Real_Part *rp, unsigned int pos); diff --git a/src/lib/edje/edje_util.c b/src/lib/edje/edje_util.c index cb6300d..97e00f9 100644 ---
[EGIT] [core/efl] master 01/02: elementary: fix clean installation
cedric pushed a commit to branch master. http://git.enlightenment.org/core/efl.git/commit/?id=2ae6307c7228c5ef37816018e6faebfb2acf3813 commit 2ae6307c7228c5ef37816018e6faebfb2acf3813 Author: Andrii KroitorDate: Mon Mar 28 11:23:18 2016 -0700 elementary: fix clean installation Summary: elocation should be included before elementary otherwise 'make install' will fail on clean instalation Test Plan: make uninstall && make install Reviewers: raster, tasn, stefan_schmidt, cedric Reviewed By: cedric Subscribers: reutskiy.v.v, jpeg Differential Revision: https://phab.enlightenment.org/D3832 Signed-off-by: Cedric BAIL --- src/Makefile.am | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Makefile.am b/src/Makefile.am index 4019fcb..084d1a4 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -68,6 +68,7 @@ include Makefile_Edje.am include Makefile_Emotion.am include Makefile_Ethumb.am include Makefile_Ethumb_Client.am +include Makefile_Elocation.am include Makefile_Elementary.am include Makefile_Eina_Cxx.am @@ -82,7 +83,6 @@ include Makefile_Evas_Cxx.am include Makefile_Eio_Cxx.am include Makefile_Elua.am -include Makefile_Elocation.am if HAVE_JS AM_V_CP = $(am__v_CP_@AM_V@) --
[EGIT] [core/enlightenment] master 01/04: do not add deleted clients to tasks gadgets
discomfitor pushed a commit to branch master. http://git.enlightenment.org/core/enlightenment.git/commit/?id=488ece76a65349a0751a8dfb600a8a9ca0eedc98 commit 488ece76a65349a0751a8dfb600a8a9ca0eedc98 Author: Mike BlumenkrantzDate: Mon Mar 28 12:59:34 2016 -0400 do not add deleted clients to tasks gadgets --- src/modules/tasks/e_mod_main.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/modules/tasks/e_mod_main.c b/src/modules/tasks/e_mod_main.c index cbe69a9..d0d2ece 100644 --- a/src/modules/tasks/e_mod_main.c +++ b/src/modules/tasks/e_mod_main.c @@ -369,7 +369,7 @@ _tasks_new(Evas *e, E_Zone *zone, const char *id) tasks->horizontal = 1; EINA_LIST_FOREACH(e_comp->clients, l, ec) { -if (!e_client_util_ignored_get(ec)) +if ((!e_client_util_ignored_get(ec)) && (!e_object_is_del(E_OBJECT(ec tasks->clients = eina_list_append(tasks->clients, ec); } @@ -889,7 +889,7 @@ _tasks_cb_event_client_add(void *data EINA_UNUSED, int type EINA_UNUSED, void *e Tasks *tasks; Eina_List *l; - if (e_client_util_ignored_get(ev->ec)) return ECORE_CALLBACK_RENEW; + if (e_client_util_ignored_get(ev->ec) || e_object_is_del(E_OBJECT(ev->ec))) return ECORE_CALLBACK_RENEW; EINA_LIST_FOREACH(tasks_config->tasks, l, tasks) { if ((!tasks->clients) || (!eina_list_data_find(tasks->clients, ev->ec))) --
[EGIT] [core/enlightenment] master 03/04: use canvas pointer coords in systray mouse cb
discomfitor pushed a commit to branch master. http://git.enlightenment.org/core/enlightenment.git/commit/?id=19eb5d264477d8979b2e623cac279e3a06d1943f commit 19eb5d264477d8979b2e623cac279e3a06d1943f Author: Mike BlumenkrantzDate: Mon Mar 28 13:37:21 2016 -0400 use canvas pointer coords in systray mouse cb --- src/modules/systray/e_mod_notifier_host.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/modules/systray/e_mod_notifier_host.c b/src/modules/systray/e_mod_notifier_host.c index a15d4bc..81c4e59 100644 --- a/src/modules/systray/e_mod_notifier_host.c +++ b/src/modules/systray/e_mod_notifier_host.c @@ -197,7 +197,7 @@ _clicked_item_cb(void *data, Evas *evas, Evas_Object *obj EINA_UNUSED, void *eve e_menu_post_deactivate_callback_set(m, _menu_post_deactivate, gadcon); zone = e_gadcon_zone_get(gadcon); - ecore_evas_pointer_xy_get(e_comp->ee, , ); + evas_pointer_canvas_xy_get(e_comp->evas, , ); e_menu_activate_mouse(m, zone, x, y, 1, 1, E_MENU_POP_DIRECTION_DOWN, ev->timestamp); evas_event_feed_mouse_up(evas, ev->button, EVAS_BUTTON_NONE, ev->timestamp, NULL); --
[EGIT] [core/enlightenment] master 02/04: remove deleted clients from tasks client list during repop
discomfitor pushed a commit to branch master. http://git.enlightenment.org/core/enlightenment.git/commit/?id=9f52dfa50ccc5cbb6b46521a233193413e7b6069 commit 9f52dfa50ccc5cbb6b46521a233193413e7b6069 Author: Mike BlumenkrantzDate: Mon Mar 28 12:59:45 2016 -0400 remove deleted clients from tasks client list during repop fix T3369 --- src/modules/tasks/e_mod_main.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/modules/tasks/e_mod_main.c b/src/modules/tasks/e_mod_main.c index d0d2ece..fa78b69 100644 --- a/src/modules/tasks/e_mod_main.c +++ b/src/modules/tasks/e_mod_main.c @@ -616,6 +616,8 @@ static void _tasks_item_free(Tasks_Item *item) { if (item->o_icon) evas_object_del(item->o_icon); + if (e_object_is_del(E_OBJECT(item->client))) + item->tasks->clients = eina_list_remove(item->tasks->clients, item->client); e_object_unref(E_OBJECT(item->client)); evas_object_del(item->o_item); free(item); --
[EGIT] [core/enlightenment] master 04/04: ignore x11 ConfigureRequest events when maximize_override is set
discomfitor pushed a commit to branch master. http://git.enlightenment.org/core/enlightenment.git/commit/?id=d02679383fbf4f370402eda415f63f12f82c2b6f commit d02679383fbf4f370402eda415f63f12f82c2b6f Author: Mike BlumenkrantzDate: Mon Mar 28 13:37:40 2016 -0400 ignore x11 ConfigureRequest events when maximize_override is set --- src/bin/e_comp_x.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/bin/e_comp_x.c b/src/bin/e_comp_x.c index ce0759e..32ba9a4 100644 --- a/src/bin/e_comp_x.c +++ b/src/bin/e_comp_x.c @@ -1626,7 +1626,7 @@ _e_comp_x_configure_request(void *data EINA_UNUSED, int type EINA_UNUSED, Ecore ec->saved.y -= zone->y; } } -else +else if (!ec->maximize_override) { /* client is completely outside the screen, policy does not allow */ if (((!E_INTERSECTS(x, y, ec->w, ec->h, 0, 0, e_comp->w - 5, e_comp->h - 5)) && @@ -1650,7 +1650,7 @@ _e_comp_x_configure_request(void *data EINA_UNUSED, int type EINA_UNUSED, Ecore { if ((ec->maximized & E_MAXIMIZE_TYPE) != E_MAXIMIZE_NONE) e_comp_object_frame_wh_unadjust(ec->frame, w, h, >saved.w, >saved.h); -else +else if (!ec->maximize_override) { evas_object_resize(ec->frame, w, h); } --
[EGIT] [tools/eflete] master 02/03: workspace: add zoom shortcuts
rimmed pushed a commit to branch master. http://git.enlightenment.org/tools/eflete.git/commit/?id=70bcf12b3fb1a2cc06575b74f66a2c2ec4b23bff commit 70bcf12b3fb1a2cc06575b74f66a2c2ec4b23bff Author: Andrii KroitorDate: Mon Mar 28 14:05:32 2016 +0300 workspace: add zoom shortcuts zoom_in: KP_PLUS zoom_out: KP_MINUS zoom_reset: KP_DIVIDE --- src/bin/common/signals.h | 3 +++ src/bin/ui/shortcuts/shortcuts.c | 10 ++ src/bin/ui/shortcuts/shortcuts.h | 3 +++ src/bin/ui/tabs.c| 40 src/bin/ui/workspace/workspace.c | 2 ++ 5 files changed, 58 insertions(+) diff --git a/src/bin/common/signals.h b/src/bin/common/signals.h index d5b9870..320b58e 100644 --- a/src/bin/common/signals.h +++ b/src/bin/common/signals.h @@ -469,6 +469,9 @@ typedef struct { #define SIGNAL_SHORTCUT_MODE_DEMO "SIGNAL_SHORTCUT_MODE_DEMO" #define SIGNAL_SHORTCUT_STATE_NEXT "SIGNAL_SHORTCUT_STATE_NEXT" #define SIGNAL_SHORTCUT_PART_SHOWHIDE "SIGNAL_SHORTCUT_PART_SHOWHIDE" +#define SIGNAL_SHORTCUT_ZOOM_IN "SIGNAL_SHORTCUT_ZOOM_IN" +#define SIGNAL_SHORTCUT_ZOOM_OUT "SIGNAL_SHORTCUT_ZOOM_OUT" +#define SIGNAL_SHORTCUT_ZOOM_RESET "SIGNAL_SHORTCUT_ZOOM_RESET" /** * emited when shortcut is pressed. * eventinfo - tab number. diff --git a/src/bin/ui/shortcuts/shortcuts.c b/src/bin/ui/shortcuts/shortcuts.c index 7db14a7..33febf8 100644 --- a/src/bin/ui/shortcuts/shortcuts.c +++ b/src/bin/ui/shortcuts/shortcuts.c @@ -167,6 +167,9 @@ _shortcut_handle(Shortcut_Type type) SHORTCUT(MODE_NORMAL); SHORTCUT(MODE_CODE); SHORTCUT(MODE_DEMO); +SHORTCUT(ZOOM_IN); +SHORTCUT(ZOOM_OUT); +SHORTCUT(ZOOM_RESET); case SHORTCUT_TYPE_NONE: break; @@ -421,6 +424,13 @@ _default_shortcuts_add() MOD_NONE, 75/*F9*/); _add_shortcut(SHORTCUT_TYPE_TAB_COLOR_CLASS_MANAGER, SHORTCUT_TYPE_NONE, MOD_NONE, 76/*F10*/); + + _add_shortcut(SHORTCUT_TYPE_ZOOM_IN, SHORTCUT_TYPE_NONE, + MOD_NONE, 86/*KP_+*/); + _add_shortcut(SHORTCUT_TYPE_ZOOM_OUT, SHORTCUT_TYPE_NONE, + MOD_NONE, 82/*KP_-*/); + _add_shortcut(SHORTCUT_TYPE_ZOOM_RESET, SHORTCUT_TYPE_NONE, + MOD_NONE, 106/*KP_/ */); } /*=*/ diff --git a/src/bin/ui/shortcuts/shortcuts.h b/src/bin/ui/shortcuts/shortcuts.h index 7c919ab..1629a4a 100644 --- a/src/bin/ui/shortcuts/shortcuts.h +++ b/src/bin/ui/shortcuts/shortcuts.h @@ -86,6 +86,9 @@ typedef enum { SHORTCUT_TYPE_MODE_DEMO, SHORTCUT_TYPE_STATE_NEXT, SHORTCUT_TYPE_PART_SHOWHIDE, + SHORTCUT_TYPE_ZOOM_IN, + SHORTCUT_TYPE_ZOOM_OUT, + SHORTCUT_TYPE_ZOOM_RESET, SHORTCUT_TYPE_LAST, } Shortcut_Type; diff --git a/src/bin/ui/tabs.c b/src/bin/ui/tabs.c index 66450e8..6d15911 100644 --- a/src/bin/ui/tabs.c +++ b/src/bin/ui/tabs.c @@ -742,6 +742,43 @@ _shortcut_mode_demo_cb(void *data __UNUSED__, workspace_mode_set(tabs.current_workspace, MODE_DEMO); } +static void +_shortcut_zoom_in_cb(void *data __UNUSED__, + Evas_Object *obj __UNUSED__, + void *event_info __UNUSED__) +{ + double factor; + + if (tabs.current_workspace) + { +factor = workspace_zoom_factor_get(tabs.current_workspace); +workspace_zoom_factor_set(tabs.current_workspace, factor + 0.1); + } +} + +static void +_shortcut_zoom_out_cb(void *data __UNUSED__, + Evas_Object *obj __UNUSED__, + void *event_info __UNUSED__) +{ + double factor; + + if (tabs.current_workspace) + { +factor = workspace_zoom_factor_get(tabs.current_workspace); +workspace_zoom_factor_set(tabs.current_workspace, factor - 0.1); + } +} + +static void +_shortcut_zoom_reset_cb(void *data __UNUSED__, +Evas_Object *obj __UNUSED__, +void *event_info __UNUSED__) +{ + if (tabs.current_workspace) + workspace_zoom_factor_set(tabs.current_workspace, 1.0); +} + Evas_Object * tabs_add(void) { @@ -860,6 +897,9 @@ tabs_add(void) evas_object_smart_callback_add(ap.win, SIGNAL_SHORTCUT_MODE_NORMAL, _shortcut_mode_normal_cb, NULL); evas_object_smart_callback_add(ap.win, SIGNAL_SHORTCUT_MODE_CODE, _shortcut_mode_code_cb, NULL); evas_object_smart_callback_add(ap.win, SIGNAL_SHORTCUT_MODE_DEMO, _shortcut_mode_demo_cb, NULL); + evas_object_smart_callback_add(ap.win, SIGNAL_SHORTCUT_ZOOM_IN, _shortcut_zoom_in_cb, NULL); + evas_object_smart_callback_add(ap.win, SIGNAL_SHORTCUT_ZOOM_OUT, _shortcut_zoom_out_cb, NULL); + evas_object_smart_callback_add(ap.win, SIGNAL_SHORTCUT_ZOOM_RESET, _shortcut_zoom_reset_cb, NULL); return tabs.layout; } diff --git a/src/bin/ui/workspace/workspace.c b/src/bin/ui/workspace/workspace.c index e7591b6..460cb57 100644 --- a/src/bin/ui/workspace/workspace.c +++
[EGIT] [tools/eflete] master 01/03: groupview: fix missing description error
rimmed pushed a commit to branch master. http://git.enlightenment.org/tools/eflete.git/commit/?id=c2b2ebb7fd23ff6c5a51a6b870e23e31e279a178 commit c2b2ebb7fd23ff6c5a51a6b870e23e31e279a178 Author: Andrii KroitorDate: Mon Mar 28 13:29:15 2016 +0300 groupview: fix missing description error --- data/themes/default/widgets/layout.edc | 3 +++ 1 file changed, 3 insertions(+) diff --git a/data/themes/default/widgets/layout.edc b/data/themes/default/widgets/layout.edc index 30f8d11..0979183 100644 --- a/data/themes/default/widgets/layout.edc +++ b/data/themes/default/widgets/layout.edc @@ -1698,6 +1698,9 @@ group { name: "elm/layout/groupview/default"; } fill.type: TILE; } + description { state: "text" 0.0; +inherit: "default" 0.0; + } #define BG(NAME, IMG) \ description { state: #NAME 0.0; \ inherit: "default" 0.0; \ --
[EGIT] [tools/eflete] master 03/03: workspace: add ctrl+wheel zoom shortcuts
rimmed pushed a commit to branch master. http://git.enlightenment.org/tools/eflete.git/commit/?id=adfcac67d707e854a8a60e5c6f5f0d3a4ecbb2a8 commit adfcac67d707e854a8a60e5c6f5f0d3a4ecbb2a8 Author: Andrii KroitorDate: Mon Mar 28 14:24:59 2016 +0300 workspace: add ctrl+wheel zoom shortcuts --- src/bin/ui/shortcuts/shortcuts.c | 23 +++ 1 file changed, 23 insertions(+) diff --git a/src/bin/ui/shortcuts/shortcuts.c b/src/bin/ui/shortcuts/shortcuts.c index 33febf8..850911b 100644 --- a/src/bin/ui/shortcuts/shortcuts.c +++ b/src/bin/ui/shortcuts/shortcuts.c @@ -100,6 +100,8 @@ typedef struct _Shortcut Shortcut; struct _Shortcut_Module { + Ecore_Event_Handler *shortcuts_wheel_handler; /**< handler for catching mouse wheel\ + for shortcuts */ Ecore_Event_Handler *shortcuts_handler; /**< handler for catching key presses\ for shortcuts */ Ecore_Event_Handler *shortcuts_handler_unpress; /**< handler for catching key @@ -180,6 +182,22 @@ _shortcut_handle(Shortcut_Type type) } static Eina_Bool +_mouse_wheel_event_cb(void *data __UNUSED__, int type __UNUSED__, void *event) +{ + Ecore_Event_Mouse_Wheel *ev = event; + + if ((ev->modifiers & 255) != MOD_CTRL) + return ECORE_CALLBACK_PASS_ON; + + if (ev->z > 0) + evas_object_smart_callback_call(ap.win, SIGNAL_SHORTCUT_ZOOM_OUT, NULL); + else if (ev->z < 0) + evas_object_smart_callback_call(ap.win, SIGNAL_SHORTCUT_ZOOM_IN, NULL); + + return ECORE_CALLBACK_DONE; +} + +static Eina_Bool _key_press_event_cb(void *data __UNUSED__, int type __UNUSED__, void *event) { Ecore_Event_Key *ev = (Ecore_Event_Key *)event; @@ -450,6 +468,9 @@ shortcuts_init(void) ap.shortcuts = mem_calloc(1, sizeof(Shortcut_Module)); + ap.shortcuts->shortcuts_wheel_handler = ecore_event_handler_add(ECORE_EVENT_MOUSE_WHEEL, + _mouse_wheel_event_cb, + NULL); ap.shortcuts->shortcuts_handler = ecore_event_handler_add(ECORE_EVENT_KEY_DOWN, _key_press_event_cb, NULL); @@ -469,6 +490,8 @@ shortcuts_shutdown(void) assert(ap.shortcuts != NULL); assert(ap.shortcuts->shortcuts_handler != NULL); + ecore_event_handler_del(ap.shortcuts->shortcuts_wheel_handler); + ap.shortcuts->shortcuts_wheel_handler = NULL; ecore_event_handler_del(ap.shortcuts->shortcuts_handler); ap.shortcuts->shortcuts_handler = NULL; ecore_event_handler_del(ap.shortcuts->shortcuts_handler_unpress); --
[EGIT] [core/efl] master 01/02: Slider: Theme - Add support for range in edc
ami pushed a commit to branch master. http://git.enlightenment.org/core/efl.git/commit/?id=1152fb3e3528e024f0f9e01451783a937fdbe4dc commit 1152fb3e3528e024f0f9e01451783a937fdbe4dc Author: Yeshwanth ReddivariDate: Mon Mar 28 13:41:27 2016 +0530 Slider: Theme - Add support for range in edc phab: https://phab.enlightenment.org/D3821 Test Plan: elementary_test -to slider @feature Change-Id: Ibc3f7c93efb927a6fc602f246a795c426f80bd39 --- data/elementary/themes/edc/elm/slider.edc | 473 ++-- data/elementary/themes/img/horiz_glow_range.png | Bin 0 -> 131 bytes data/elementary/themes/img/vert_glow_range.png | Bin 0 -> 127 bytes 3 files changed, 443 insertions(+), 30 deletions(-) diff --git a/data/elementary/themes/edc/elm/slider.edc b/data/elementary/themes/edc/elm/slider.edc index b39a680..5786dfe 100644 --- a/data/elementary/themes/edc/elm/slider.edc +++ b/data/elementary/themes/edc/elm/slider.edc @@ -39,6 +39,7 @@ group { name: "elm/slider/horizontal/default"; images.image: "slider_run_bevel_horiz.png" COMP; images.image: "slider_run_base_light_horiz.png" COMP; images.image: "horiz_glow_run.png" COMP; + images.image: "horiz_glow_range.png" COMP; images.image: "horiz_glow_run_rev.png" COMP; images.image: "knob_round_small_normal.png" COMP; images.image: "knob_round_small_selected.png" COMP; @@ -65,6 +66,19 @@ group { name: "elm/slider/horizontal/default"; #define DISABLE 32 script { public slmode; + public range; + public g_timer_id; + public update_glow() +{ + new x1,y1,w1,h1; + new x2,y2,w2,h2; + get_geometry(PART:"knob", x1, y1, w1, h1); + get_geometry(PART:"knob2", x2, y2, w2, h2); + if(x2 < x1) + set_state(PART:"glow", "range_reverse", 0.0); + else + set_state(PART:"glow", "range", 0.0); +} public eval_mode(m) { new ic = m & ICON; new l = m & LABEL; @@ -72,22 +86,36 @@ group { name: "elm/slider/horizontal/default"; new u = m & UNITS; new d = m & DISABLE; new i = m & INVERT; - if (i) { -if (!d) { - set_state(PART:"base", "default", 0.0); - set_state(PART:"glow", "inverted", 0.0); -} else { - set_state(PART:"base", "disabled", 0.0); - set_state(PART:"glow", "disabled_inverted", 0.0); -} - } else { -if (!d) { - set_state(PART:"base", "default", 0.0); - set_state(PART:"glow", "default", 0.0); -} else { - set_state(PART:"base", "disabled", 0.0); - set_state(PART:"glow", "disabled", 0.0); -} + new r = get_int(range); + if (!r) { + if (i) { +if (!d) { + set_state(PART:"base", "default", 0.0); + set_state(PART:"glow", "inverted", 0.0); +} else { + set_state(PART:"base", "disabled", 0.0); + set_state(PART:"glow", "disabled_inverted", 0.0); +} + } else { +if (!d) { + set_state(PART:"base", "default", 0.0); + set_state(PART:"glow", "default", 0.0); +} else { + set_state(PART:"base", "disabled", 0.0); + set_state(PART:"glow", "disabled", 0.0); +} + } + } else if (d) { + new x1,y1,w1,h1; + new x2,y2,w2,h2; + get_geometry(PART:"knob", x1, y1, w1, h1); + get_geometry(PART:"knob2", x2, y2, w2, h2); + set_state(PART:"base", "disabled", 0.0); + if(x2 < x1) +set_state(PART:"glow", "disabled_range_reverse", 0.0); + else +set_state(PART:"glow", "disabled_range", 0.0); + } if (l) { if (!d) { @@ -189,6 +217,32 @@ group { name: "elm/slider/horizontal/default"; rel2.to: "base"; image.border: 4 0 0 0; } + description { state: "range" 0.0; +image.normal: "horiz_glow_range.png"; +rel1.relative: 0.5 1.0; +rel1.offset: -1 -2; +rel1.to_x: "button"; +rel1.to_y: "base"; +rel2.relative: 0.5 1.0; +rel2.offset: -1 -2; +rel2.to_x: "button2"; +rel2.to_y: "base"; +fixed: 0 1; +image.border: 0 4 0 0; + } + description { state: "disabled_range" 0.0; +inherit: "range" 0.0; +color: 255 255 255 64; + } + description { state: "range_reverse" 0.0; +inherit: "range" 0.0; +rel1.to_x: "button2"; +rel2.to_x: "button"; + } +
[EGIT] [core/efl] master 02/02: slider: Add range support
ami pushed a commit to branch master. http://git.enlightenment.org/core/efl.git/commit/?id=92296545710fbea3eab112978eb4823addc5f227 commit 92296545710fbea3eab112978eb4823addc5f227 Author: Amitesh SinghDate: Mon Mar 28 14:05:51 2016 +0530 slider: Add range support Slider can have two indicators if enabled and user can select range values. phab: https://phab.enlightenment.org/D3822 Test Plan: elementary_test -to slider @feature Change-Id: If4ca74de6f5a94531ebd21750d52704b2b02afee --- src/bin/elementary/test_slider.c | 220 - src/lib/elementary/elm_slider.c| 345 + src/lib/elementary/elm_slider.eo | 23 +++ src/lib/elementary/elm_widget_slider.h | 5 +- 4 files changed, 554 insertions(+), 39 deletions(-) diff --git a/src/bin/elementary/test_slider.c b/src/bin/elementary/test_slider.c index c613da6..9956a9b 100644 --- a/src/bin/elementary/test_slider.c +++ b/src/bin/elementary/test_slider.c @@ -58,10 +58,20 @@ _step_size_calculate(double min, double max) return step; } +static void +_change_range_print_cb(void *data EINA_UNUSED, Evas_Object *obj, void *event_info EINA_UNUSED) +{ + double from, to; + + elm_slider_range_get(obj, , ); + + printf("range values:- from: %f, to: %f\n", from, to); +} + void test_slider(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void *event_info EINA_UNUSED) { - Evas_Object *win, *fr, *bx, *sl, *ic, *sl1, *bx2, *bt; + Evas_Object *win, *fr, *bx, *sl, *ic, *sl1, *bx2, *bx3, *bx4, *bt; double step; char buf[PATH_MAX]; @@ -264,7 +274,6 @@ test_slider(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void *event_in elm_slider_span_size_set(sl, 60); evas_object_size_hint_align_set(sl, 0.5, EVAS_HINT_FILL); evas_object_size_hint_weight_set(sl, 0.0, EVAS_HINT_EXPAND); - elm_slider_indicator_show_set(sl, EINA_FALSE); elm_slider_value_set(sl, 0.2); elm_object_scale_set(sl, 1.0); elm_slider_horizontal_set(sl, EINA_FALSE); @@ -303,5 +312,212 @@ test_slider(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void *event_in evas_object_show(bt); elm_box_pack_end(bx2, bt); + fr = elm_frame_add(bx); + elm_object_text_set(fr, "Range"); + evas_object_size_hint_weight_set(fr, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND); + elm_box_pack_end(bx, fr); + evas_object_show(fr); + + bx3 = elm_box_add(fr); + evas_object_size_hint_weight_set(bx3, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND); + evas_object_show(bx3); + elm_object_content_set(fr, bx3); + + //Disabled + sl = elm_slider_add(bx3); + elm_object_text_set(sl, "Disabled"); + elm_slider_unit_format_set(sl, "%1.1f units"); + elm_slider_span_size_set(sl, 120); + elm_slider_min_max_set(sl, 50, 150); + evas_object_size_hint_align_set(sl, EVAS_HINT_FILL, 0.5); + evas_object_size_hint_weight_set(sl, EVAS_HINT_EXPAND, 0.0); + elm_object_disabled_set(sl, EINA_TRUE); + elm_slider_range_enabled_set(sl, EINA_TRUE); + elm_slider_range_set(sl, 20, 100); + elm_box_pack_end(bx3, sl); + evas_object_show(sl); + + // horizontal slider with range + sl = elm_slider_add(bx3); + evas_object_size_hint_weight_set(sl, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND); + elm_slider_indicator_show_set(sl, EINA_TRUE); + elm_object_text_set(sl, "Horizontal"); + elm_slider_unit_format_set(sl, "%1.5f units"); + elm_slider_indicator_format_set(sl, "%1.5f"); + elm_slider_span_size_set(sl, 160); + elm_slider_range_enabled_set(sl, EINA_TRUE); + elm_slider_range_set(sl, 0.4, 0.9); + elm_box_pack_end(bx3, sl); + evas_object_show(sl); + + sl = elm_slider_add(bx3); + elm_slider_unit_format_set(sl, "%1.0f units"); + elm_slider_indicator_format_set(sl, "%1.0f"); + elm_slider_span_size_set(sl, 120); + elm_slider_min_max_set(sl, 0, 9); + elm_object_text_set(sl, "Manual step"); + step = _step_size_calculate(0, 9); + elm_slider_step_set(sl, step); + evas_object_size_hint_align_set(sl, EVAS_HINT_FILL, 0.5); + evas_object_size_hint_weight_set(sl, EVAS_HINT_EXPAND, 0.0); + elm_slider_range_enabled_set(sl, EINA_TRUE); + elm_box_pack_end(bx3, sl); + evas_object_show(sl); + + sl = elm_slider_add(bx3); + elm_slider_unit_format_set(sl, "%1.0f units"); + elm_slider_indicator_format_set(sl, "%1.0f"); + elm_slider_span_size_set(sl, 120); + elm_slider_min_max_set(sl, 0, 100); + elm_object_text_set(sl, "Show Indicator on Focus: "); + step = _step_size_calculate(0, 9); + elm_slider_step_set(sl, step); + elm_slider_indicator_show_on_focus_set(sl, EINA_TRUE); + evas_object_size_hint_align_set(sl, EVAS_HINT_FILL, 0.5); + evas_object_size_hint_weight_set(sl, EVAS_HINT_EXPAND, 0.0); + elm_slider_range_enabled_set(sl, EINA_TRUE); + elm_box_pack_end(bx3, sl); + evas_object_show(sl); + + // normal horizontal slider + ic = elm_icon_add(bx3); + snprintf(buf, sizeof(buf),
[EGIT] [core/efl] master 25/25: emotion/libvlc: fix url opening
jpeg pushed a commit to branch master. http://git.enlightenment.org/core/efl.git/commit/?id=3f1686d01e4f3a23c125afb4a9bb89106609c303 commit 3f1686d01e4f3a23c125afb4a9bb89106609c303 Author: Thomas GuillemDate: Fri Mar 25 09:05:40 2016 +0100 emotion/libvlc: fix url opening --- src/modules/emotion/libvlc/emotion_libvlc.c | 5 + 1 file changed, 5 insertions(+) diff --git a/src/modules/emotion/libvlc/emotion_libvlc.c b/src/modules/emotion/libvlc/emotion_libvlc.c index d9500cd..c550551 100644 --- a/src/modules/emotion/libvlc/emotion_libvlc.c +++ b/src/modules/emotion/libvlc/emotion_libvlc.c @@ -443,6 +443,11 @@ em_file_open(void *video, /* Create libvlc_media */ ev->m = libvlc_media_new_path(libvlc, file); + if (strstr(file, "://") == NULL) + ev->m = libvlc_media_new_path(libvlc, file); + else + ev->m = libvlc_media_new_location(libvlc, file); + EINA_SAFETY_ON_NULL_GOTO(ev->m, error); if (ev->opt.no_audio || ev->audio_mute) --
[EGIT] [core/efl] master 23/25: emotion/libvlc: use vlc vout display module
jpeg pushed a commit to branch master. http://git.enlightenment.org/core/efl.git/commit/?id=a6bd5dda420520a509fc1cee26e131a13401348f commit a6bd5dda420520a509fc1cee26e131a13401348f Author: Thomas GuillemDate: Fri Mar 25 09:05:38 2016 +0100 emotion/libvlc: use vlc vout display module The vlc vout display module adds key and mouse event support. It improves performances since a video filter is not needed anymore to scale the image, and direct rendering with vlc avcodec module is now possible (less memcpy). --- src/modules/emotion/libvlc/emotion_libvlc.c | 417 +--- 1 file changed, 70 insertions(+), 347 deletions(-) diff --git a/src/modules/emotion/libvlc/emotion_libvlc.c b/src/modules/emotion/libvlc/emotion_libvlc.c index e256a56..98f6fdf 100644 --- a/src/modules/emotion/libvlc/emotion_libvlc.c +++ b/src/modules/emotion/libvlc/emotion_libvlc.c @@ -39,8 +39,6 @@ #endif #define CRI(...) EINA_LOG_DOM_CRIT(_emotion_libvlc_log_domain, __VA_ARGS__) -#define SINK_MAX_PLANES 3 - static int _emotion_libvlc_log_domain = -1; static Eina_Bool debug_fps = EINA_FALSE; static libvlc_instance_t *libvlc = NULL; @@ -68,6 +66,7 @@ struct _Emotion_LibVLC /* options */ intvideo_mute; + intvideo_mute_force; intaudio_mute; intspu_mute; intaudio_vol; @@ -90,24 +89,12 @@ struct _Emotion_LibVLC Eina_Bool seeking; Eina_Bool started; Eina_Bool invalidate_tracks; +}; - /* sink, must be locked by ev->lock */ - struct - { - int width; - int height; - Evas_Colorspace colorspace; - void *data; - Eina_Bool waiting; - Eina_Bool is_yuv; - - unsigned intnb_planes; - unsigned intlines[SINK_MAX_PLANES]; - unsigned intpitches[SINK_MAX_PLANES]; - unsigned intyuv_height[SINK_MAX_PLANES]; - unsigned char *yuv_data[SINK_MAX_PLANES]; - unsigned intyuv_planes_order[SINK_MAX_PLANES]; - } sink; +struct close_data +{ + libvlc_media_player_t *mp; + Evas_Object *evas_obj; }; static const libvlc_event_type_t mp_events[] = { @@ -178,119 +165,6 @@ emotion_mainloop_call_locked(Emotion_LibVLC *ev, Ecore_Cb callback) ecore_main_loop_thread_safe_call_async(callback, ev); } -/* Take the ev->lock from a sink mainloop callback. - * Returns false if the ev object is destroyed or is there is no evas object. */ -static Eina_Bool -emotion_mainloop_sink_lock(Emotion_LibVLC *ev) -{ - if (emotion_mainloop_lock(ev)) - { -if (!ev->evas_obj) - { - eina_lock_release(>lock); - return EINA_FALSE; - } -else - return EINA_TRUE; - } - else - return EINA_FALSE; -} - -/* Release the ev->lock from a sink mainloop callback and signal that the - * callback is processed. */ -static void -emotion_mainloop_sink_signal_unlock(Emotion_LibVLC *ev) -{ - ev->sink.waiting = EINA_FALSE; - eina_condition_signal(>wait); - eina_lock_release(>lock); -} - -/* Send a sink mainloop callback and wait. */ -static void -emotion_mainloop_sink_call_wait_locked(Emotion_LibVLC *ev, Ecore_Cb callback) -{ - ev->sink.waiting = EINA_TRUE; - - emotion_mainloop_call_locked(ev, callback); - - while (ev->evas_obj && ev->sink.waiting) - eina_condition_wait(>wait); -} - -/* Sink mainloop callback, sent by libvlc_video_on_lock. */ -static void -emotion_mainloop_sink_pic_lock(void *data) -{ - Emotion_LibVLC *ev = data; - if (!emotion_mainloop_sink_lock(ev)) return; - - ev->sink.data = evas_object_image_data_get(ev->evas_obj, 1); - - emotion_mainloop_sink_signal_unlock(ev); -} - -/* Sink mainloop callback, sent by libvlc_video_on_unlock. */ -static void -emotion_mainloop_sink_pic_unlock(void *data) -{ - Emotion_LibVLC *ev = data; - - if (!emotion_mainloop_sink_lock(ev)) return; - - if (!ev->sink.data) - goto end; - - if (ev->sink.is_yuv) - { -unsigned int i, j; -const unsigned char **rows = (const unsigned char **)ev->sink.data; - -for (i = 0; i < ev->sink.nb_planes; ++i) - for (j = 0; j < ev->sink.yuv_height[i]; ++j) -*(rows++) = >sink.yuv_data[i][j * ev->sink.pitches[i]]; - } - evas_object_image_data_set(ev->evas_obj, ev->sink.data); - ev->sink.data = NULL; - -end: - emotion_mainloop_sink_signal_unlock(ev); -} - -/* Sink mainloop callback, sent by libvlc_video_on_display. */ -static void -emotion_mainloop_sink_display(void *data) -{ - Emotion_LibVLC *ev = data; - - if (!emotion_mainloop_sink_lock(ev)) return; - - evas_object_image_data_update_add(ev->evas_obj, 0, 0, ev->sink.width, - ev->sink.height); - _emotion_frame_new(ev->obj);
[EGIT] [core/efl] master 12/25: draw: Import or implement some colorspace conversion routines
jpeg pushed a commit to branch master. http://git.enlightenment.org/core/efl.git/commit/?id=078117d367afff6862b72bec8bbc29909b259fd4 commit 078117d367afff6862b72bec8bbc29909b259fd4 Author: Jean-Philippe AndreDate: Tue Mar 22 16:57:52 2016 +0900 draw: Import or implement some colorspace conversion routines Those and many more will be required for proper map/unmap support. There will be problems with planar formats: YUV, RGB565_A5P, ETC1_ALPHA The quick solution to this problem is to not support region conversions, only full-image (so we can assume the location of the various planes in memory). --- src/Makefile_Evas.am| 1 + src/static_libs/draw/draw.h | 2 + src/static_libs/draw/draw_convert.c | 527 src/static_libs/draw/draw_main.c| 3 + src/static_libs/draw/draw_private.h | 27 ++ 5 files changed, 560 insertions(+) diff --git a/src/Makefile_Evas.am b/src/Makefile_Evas.am index a2a4bea..4a47e35 100644 --- a/src/Makefile_Evas.am +++ b/src/Makefile_Evas.am @@ -298,6 +298,7 @@ lib/evas/canvas/evas_vg_shape.c # Static draw lib lib_evas_libevas_la_SOURCES += \ static_libs/draw/draw_alpha_main.c \ +static_libs/draw/draw_convert.c \ static_libs/draw/draw_main_neon.c \ static_libs/draw/draw_main.c diff --git a/src/static_libs/draw/draw.h b/src/static_libs/draw/draw.h index 51bf917..b63b73d 100644 --- a/src/static_libs/draw/draw.h +++ b/src/static_libs/draw/draw.h @@ -13,6 +13,7 @@ typedef void (*RGBA_Comp_Func_Solid) (uint32_t *dest, int length, uint32_t color typedef void (*RGBA_Comp_Func_Mask) (uint32_t *dest, uint8_t *mask, int length, uint32_t color); typedef void (*Draw_Func_ARGB_Mix3) (uint32_t *dest, uint32_t *src, uint32_t *mul, int len, uint32_t color); typedef void (*Alpha_Gfx_Func) (uint8_t *src, uint8_t *dst, int len); +typedef Eina_Bool (*Cspace_Convert_Func) (void *dst, const void *src, int w, int h, int src_stride, int dst_stride, Eina_Bool has_alpha, Efl_Gfx_Colorspace srccs, Efl_Gfx_Colorspace dstcs); int efl_draw_init(void); @@ -21,6 +22,7 @@ RGBA_Comp_Func_Solid efl_draw_func_solid_span_get (Efl_Gfx_Render_Op op, uint3 RGBA_Comp_Func_Mask efl_draw_func_mask_span_get(Efl_Gfx_Render_Op op, uint32_t color); Draw_Func_ARGB_Mix3 efl_draw_func_argb_mix3_get(Efl_Gfx_Render_Op op, uint32_t color); Alpha_Gfx_Func efl_draw_alpha_func_get(Efl_Gfx_Render_Op op, Eina_Bool has_mask); +Cspace_Convert_Func efl_draw_convert_func_get (Efl_Gfx_Colorspace origcs, Efl_Gfx_Colorspace dstcs, Eina_Bool *region_can); /* common sw draw helpers */ diff --git a/src/static_libs/draw/draw_convert.c b/src/static_libs/draw/draw_convert.c new file mode 100644 index 000..6e1a35b --- /dev/null +++ b/src/static_libs/draw/draw_convert.c @@ -0,0 +1,527 @@ +#include "draw.h" +#include "draw_private.h" +#include "../rg_etc/rg_etc1.h" + +#if DIV_USING_BITSHIFT +# define DEFINE_DIVIDER(div) const int pow2 = _pow2_geq((div) << 10); const int numerator = (1 << pow2) / (div); +# define DIVIDE(val) (((val) * numerator) >> pow2) +#else +# define DEFINE_DIVIDER(div) const int divider = (div); +# define DIVIDE(val) ((val) / divider) +#endif + +#define CONVERT_RGB_565_TO_RGB_888(s) \ +(s) << 3) & 0xf8) | (((s) >> 2) & 0x7)) | \ + s) << 5) & 0xfc00) | (((s) >> 1) & 0x300)) | \ + s) << 8) & 0xf8) | (((s) << 3) & 0x7))) + +#define CONVERT_A5P_TO_A8(s) \ +s) << 3) & 0xf8) | (((s) >> 2) & 0x7)) + +#define CONVERT_ARGB__TO_A_8(s)((s) >> 24) + +// finds smallest power of 2 above val +static int +_pow2_geq(int val) +{ + for (int n = 0; n < 32; n++) + if (val <= (1 << n)) + return n; + + return 32; // impossible +} + +static Eina_Bool +_convert_gry8_to_argb(void *dst, const void *src, int w, int h, + int src_stride, int dst_stride, Eina_Bool has_alpha, + Efl_Gfx_Colorspace srccs EINA_UNUSED, + Efl_Gfx_Colorspace dstcs EINA_UNUSED) +{ + const uint8_t *in = src; + uint32_t *out = dst; + int in_step, out_step, x, y; + + if (!src_stride) src_stride = w; + if (!dst_stride) dst_stride = w * 4; + in_step = src_stride; + out_step = dst_stride / 4; + + if (has_alpha) + { +// transparent white +for (y = 0; y < h; y++) + { + for (x = 0; x < w; x++) + { + int c = in[x]; + out[x] = DRAW_ARGB_JOIN(c, c, c, c); + } + in += in_step; + out += out_step; + } + } + else + { +// opaque grayscale +for (y = 0; y < h; y++) + { + for (x = 0; x < w; x++) + { + int c = in[x]; + out[x] = DRAW_ARGB_JOIN(0xFF, c, c, c); + } + in += in_step; +
[EGIT] [core/efl] master 09/25: Evas.Image: Add ERR in long-deprecated functions
jpeg pushed a commit to branch master. http://git.enlightenment.org/core/efl.git/commit/?id=8b9f525c019f48de52bd624d910bfcae150629ab commit 8b9f525c019f48de52bd624d910bfcae150629ab Author: Jean-Philippe AndreDate: Tue Mar 22 14:45:10 2016 +0900 Evas.Image: Add ERR in long-deprecated functions - evas_object_image_data_convert() - evas_object_image_pixels_import() --- src/lib/evas/canvas/evas_image_legacy.c | 23 ++- 1 file changed, 18 insertions(+), 5 deletions(-) diff --git a/src/lib/evas/canvas/evas_image_legacy.c b/src/lib/evas/canvas/evas_image_legacy.c index 1850057..6103cc6 100644 --- a/src/lib/evas/canvas/evas_image_legacy.c +++ b/src/lib/evas/canvas/evas_image_legacy.c @@ -918,9 +918,17 @@ evas_object_image_data_convert(Evas_Object *eo_obj, Evas_Colorspace to_cspace) Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS); Evas_Image_Data *o; + void *engine_data; DATA32 *data; void* result = NULL; + static int warned = 0; + if (!warned) + { +ERR("%s is deprecated and shouldn't be called", __FUNCTION__); +warned = 1; + } + evas_object_async_block(obj); o = eo_data_scope_get(eo_obj, EVAS_IMAGE_CLASS); if ((o->preloading) && (o->engine_data)) @@ -933,12 +941,10 @@ evas_object_image_data_convert(Evas_Object *eo_obj, Evas_Colorspace to_cspace) o->pixels->video.update_pixels(o->pixels->video.data, eo_obj, >pixels->video); if (o->cur->cspace == to_cspace) return NULL; data = NULL; - o->engine_data = ENFN->image_data_get(ENDT, o->engine_data, 0, , >load_error, NULL); + engine_data = ENFN->image_data_get(ENDT, o->engine_data, 0, , >load_error, NULL); result = _evas_image_data_convert_internal(o, data, to_cspace); - if (o->engine_data) - { -o->engine_data = ENFN->image_data_put(ENDT, o->engine_data, data); - } + if (engine_data) + o->engine_data = ENFN->image_data_put(ENDT, engine_data, data); return result; } @@ -988,6 +994,13 @@ evas_object_image_pixels_import(Evas_Object *eo_obj, Evas_Pixel_Import_Source *p Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS); Evas_Image_Data *o; + static int warned = 0; + if (!warned) + { +ERR("%s is deprecated and shouldn't be called", __FUNCTION__); +warned = 1; + } + evas_object_async_block(obj); o = eo_data_scope_get(eo_obj, EVAS_IMAGE_CLASS); _evas_image_cleanup(eo_obj, obj, o); --
[EGIT] [core/efl] master 05/25: Evas.Image: Remove buffer_set/get
jpeg pushed a commit to branch master. http://git.enlightenment.org/core/efl.git/commit/?id=f78cbac9e60406a0b2e63ed488575613074d7b90 commit f78cbac9e60406a0b2e63ed488575613074d7b90 Author: Jean-Philippe AndreDate: Mon Mar 21 16:15:52 2016 +0900 Evas.Image: Remove buffer_set/get This will be properly implemented by the subclasses. In particular, map/unmap will be used where it makes sense, and data_get/set will be limited to Efl.Canvas.Image and Surface. --- src/lib/evas/canvas/evas_image.eo | 3 -- src/lib/evas/canvas/evas_object_image.c | 82 - 2 files changed, 85 deletions(-) diff --git a/src/lib/evas/canvas/evas_image.eo b/src/lib/evas/canvas/evas_image.eo index b4f4f3c..f1685b4 100644 --- a/src/lib/evas/canvas/evas_image.eo +++ b/src/lib/evas/canvas/evas_image.eo @@ -68,9 +68,6 @@ class Evas.Image (Evas.Object, Evas.Filter, Efl.Gfx.Buffer.alpha.set; Efl.Gfx.Buffer.buffer_update_add; Efl.Gfx.Buffer.colorspace.get; - Efl.Gfx.Buffer.buffer_get; - Efl.Gfx.Buffer.buffer_set; - Efl.Gfx.Buffer.buffer_copy_set; Efl.Gfx.Fill.fill.set; Efl.Gfx.Fill.fill.get; Efl.Gfx.Fill.fill_auto.get; diff --git a/src/lib/evas/canvas/evas_object_image.c b/src/lib/evas/canvas/evas_object_image.c index 959d08e..92f58a1 100644 --- a/src/lib/evas/canvas/evas_object_image.c +++ b/src/lib/evas/canvas/evas_object_image.c @@ -3246,88 +3246,6 @@ _evas_object_image_surface_get(Evas_Object *eo, Evas_Object_Protected_Data *obj) return pd->engine_data; } -EOLIAN static void * -_evas_image_efl_gfx_buffer_buffer_get(Eo *eo_obj, Evas_Image_Data *o, - Eina_Bool to_write, - int *width, int *height, int *stride_out, - Efl_Gfx_Colorspace *cspace) -{ - Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS); - int stride = 0; - void *data; - - // use the old api - same behaviour with more return info - data = evas_object_image_data_get(eo_obj, to_write); - if (!data) goto end; - - // FIXME: length needs to be properly checked with the engine - // as we just ignore l,r,t,b here - if (ENFN->image_stride_get) - ENFN->image_stride_get(ENDT, o->engine_data, ); - if (!stride) - stride = _evas_common_rgba_image_surface_size(o->cur->image.w, 1, o->cur->cspace, NULL, NULL, NULL, NULL); - -end: - if (width) *width = o->cur->image.w; - if (height) *height = o->cur->image.h; - if (cspace) *cspace = (Efl_Gfx_Colorspace) o->cur->cspace; - if (stride_out) *stride_out = stride; - return data; -} - -static Eina_Bool -_evas_image_buffer_set_common(Eo *obj, Evas_Image_Data *o, void *pixels, - int width, int height, int stride, - Efl_Gfx_Colorspace cspace, Eina_Bool copy) -{ - Evas_Colorspace cs = (Evas_Colorspace) cspace; - int stride_min; - - stride_min = _evas_common_rgba_image_surface_size(width, 1, cs, NULL, NULL, NULL, NULL); - if (!stride) stride = stride_min; - if (stride < stride_min) - { -ERR("Image stride is too small: given %d needs %d", stride, stride_min); -return EINA_FALSE; - } - if (stride > stride_min) // FIXME/TODO - { -ERR("Image stride support is not implemented: given %d needs %d", stride, stride_min); -return EINA_FALSE; - } - - if (cs != o->cur->cspace) - evas_object_image_colorspace_set(obj, cs); - - if ((width != o->cur->image.w) || (height != o->cur->image.h)) - evas_object_image_size_set(obj, width, height); - - if (!pixels) - evas_object_image_data_set(obj, NULL); - else if (!copy) - evas_object_image_data_set(obj, pixels); - else - evas_object_image_data_copy_set(obj, pixels); - - return o->engine_data ? EINA_TRUE : EINA_FALSE; -} - -EOLIAN static Eina_Bool -_evas_image_efl_gfx_buffer_buffer_set(Eo *obj, Evas_Image_Data *o, void *pixels, - int width, int height, int stride, - Efl_Gfx_Colorspace cspace) -{ - return _evas_image_buffer_set_common(obj, o, pixels, width, height, stride, cspace, EINA_FALSE); -} - -EOLIAN static Eina_Bool -_evas_image_efl_gfx_buffer_buffer_copy_set(Eo *obj, Evas_Image_Data *o, const void *pixels, - int width, int height, int stride, - Efl_Gfx_Colorspace cspace) -{ - return _evas_image_buffer_set_common(obj, o, (void *) pixels, width, height, stride, cspace, EINA_TRUE); -} - /* FIXME: Temporarily allow efl_file_ APIs on Evas.Image. * They don't belong here, as only Efl.Canvas.Image should support them. * Elm.Image uses them, though, instead of using the legacy APIs... --
[EGIT] [core/efl] master 04/25: Evas.Image: Move stride.get away from Evas.Image
jpeg pushed a commit to branch master. http://git.enlightenment.org/core/efl.git/commit/?id=d4e713a18c07f9f5b819d863373402a2b96ca522 commit d4e713a18c07f9f5b819d863373402a2b96ca522 Author: Jean-Philippe AndreDate: Mon Mar 21 15:38:19 2016 +0900 Evas.Image: Move stride.get away from Evas.Image stride does not apply to all image objects, eg. proxies or 3d scenes. it will be implemented by the classes that support stride and pixel data access --- src/lib/evas/canvas/evas_image.eo | 1 - src/lib/evas/canvas/evas_image_legacy.c | 3 ++- src/lib/evas/canvas/evas_object_image.c | 6 -- 3 files changed, 2 insertions(+), 8 deletions(-) diff --git a/src/lib/evas/canvas/evas_image.eo b/src/lib/evas/canvas/evas_image.eo index 5fe400a..b4f4f3c 100644 --- a/src/lib/evas/canvas/evas_image.eo +++ b/src/lib/evas/canvas/evas_image.eo @@ -67,7 +67,6 @@ class Evas.Image (Evas.Object, Evas.Filter, Efl.Gfx.Buffer.alpha.get; Efl.Gfx.Buffer.alpha.set; Efl.Gfx.Buffer.buffer_update_add; - Efl.Gfx.Buffer.stride.get; Efl.Gfx.Buffer.colorspace.get; Efl.Gfx.Buffer.buffer_get; Efl.Gfx.Buffer.buffer_set; diff --git a/src/lib/evas/canvas/evas_image_legacy.c b/src/lib/evas/canvas/evas_image_legacy.c index 01c9353..80d9a0f 100644 --- a/src/lib/evas/canvas/evas_image_legacy.c +++ b/src/lib/evas/canvas/evas_image_legacy.c @@ -157,7 +157,8 @@ EAPI int evas_object_image_stride_get(const Evas_Object *obj) { EVAS_IMAGE_API(obj, 0); - return efl_gfx_buffer_stride_get(obj); + Evas_Image_Data *o = eo_data_scope_get(eo_obj, EVAS_IMAGE_CLASS); + return o->cur->image.stride; } EAPI void diff --git a/src/lib/evas/canvas/evas_object_image.c b/src/lib/evas/canvas/evas_object_image.c index 7e05c53..959d08e 100644 --- a/src/lib/evas/canvas/evas_object_image.c +++ b/src/lib/evas/canvas/evas_object_image.c @@ -622,12 +622,6 @@ _evas_image_efl_gfx_view_view_size_get(Eo *eo_obj, Evas_Image_Data *o, int *w, i if (h) *h = uvh; } -EOLIAN static int -_evas_image_efl_gfx_buffer_stride_get(Eo *eo_obj EINA_UNUSED, Evas_Image_Data *o) -{ - return o->cur->image.stride; -} - EOLIAN static void _evas_image_efl_gfx_buffer_buffer_update_add(Eo *eo_obj, Evas_Image_Data *o, int x, int y, int w, int h) { --
[EGIT] [core/efl] master 03/25: Emile: Move colorspaces to Efl.Gfx
jpeg pushed a commit to branch master. http://git.enlightenment.org/core/efl.git/commit/?id=0d41ad0c837a2e1655a4d41c28ec7f0ccf10639c commit 0d41ad0c837a2e1655a4d41c28ec7f0ccf10639c Author: Jean-Philippe AndreDate: Fri Mar 18 18:02:19 2016 +0900 Emile: Move colorspaces to Efl.Gfx A small hack to the toolchain allows us to generate enums with eolian for use by Eet and Emile (internal or otherwise non-eo libraries). Thanks to how BUILT_SOURCES works, the eo.h files required by Emile will be generated before they are used. This adds a partial dependency on eo for eet and emile: - package dependency - include dependency There is no library link dependency. --- configure.ac | 4 +++ src/lib/efl/interfaces/efl_gfx_types.eot | 21 ++-- src/lib/emile/Emile.h| 1 + src/lib/emile/emile_image.h | 56 +--- src/lib/evas/Evas_Loader.h | 42 5 files changed, 68 insertions(+), 56 deletions(-) diff --git a/configure.ac b/configure.ac index 3458e97..f6cd7d8 100644 --- a/configure.ac +++ b/configure.ac @@ -1333,6 +1333,8 @@ fi EFL_CHECK_LIBS([EMILE], [zlib]) EFL_INTERNAL_DEPEND_PKG([EMILE], [eina]) +requirements_cflags_emile="${requirements_cflags_emile} -I\${top_srcdir}/src/lib/efl -I\${top_builddir}/src/lib/efl" +requirements_pc_emile="efl >= ${PACKAGE_VERSION} ${requirements_pc_emile}" EFL_EVAL_PKGS([EMILE]) @@ -1384,6 +1386,8 @@ fi EFL_INTERNAL_DEPEND_PKG([EET], [eina]) EFL_INTERNAL_DEPEND_PKG([EET], [emile]) +requirements_pc_eet="${requirements_pc_eet} ${requirements_pc_emile}" +requirements_cflags_eet="${requirements_cflags_eet} ${requirements_cflags_emile}" EFL_EVAL_PKGS([EET]) diff --git a/src/lib/efl/interfaces/efl_gfx_types.eot b/src/lib/efl/interfaces/efl_gfx_types.eot index 782ac9d..1dcc816 100644 --- a/src/lib/efl/interfaces/efl_gfx_types.eot +++ b/src/lib/efl/interfaces/efl_gfx_types.eot @@ -1,6 +1,23 @@ enum Efl.Gfx.Colorspace { - argb = 0, [[ARGB 32 bits per pixel, high-byte is Alpha, accessed one 32-bit word at a time.]] - gry8 = 4, [[8-bit gray image, or alpha only.]] + argb, [[ARGB 32 bits per pixel, high-byte is Alpha, accessed one 32bit word at a time.]] + ycbcr422p601_pl, [[YCbCr 4:2:2 Planar, ITU.BT-601 specifications. The data pointed to is just an array of row pointer, pointing to the Y rows, then the Cb, then Cr rows.]] + ycbcr422p709_pl, [[YCbCr 4:2:2 Planar, ITU.BT-709 specifications. The data pointed to is just an array of row pointer, pointing to the Y rows, then the Cb, then Cr rows.]] + rgb565_a5p, [[16bit rgb565 + Alpha plane at end - 5 bits of the 8 being used per alpha byte.]] + gry8 = 4, [[8-bit gray image, or alpha only.]] + ycbcr422601_pl, [[ YCbCr 4:2:2, ITU.BT-601 specifications. The data pointed to is just an array of row pointer, pointing to line of Y,Cb,Y,Cr bytes.]] + ycbcr420nv12601_pl, [[YCbCr 4:2:0, ITU.BT-601 specification. The data pointed to is just an array of row pointer, pointing to the Y rows, then the Cb,Cr rows..]] + ycbcr420tm12601_pl, [[YCbCr 4:2:0, ITU.BT-601 specification. The data pointed to is just an array of tiled row pointer, pointing to the Y rows, then the Cb,Cr rows..]] + agry88 = 8, [[AY 8bits Alpha and 8bits Grey, accessed 1 16bits at a time.]] + etc1 = 9, [[OpenGL ETC1 encoding of RGB texture (4 bit per pixel) @since 1.10.]] + rgb8_etc2 = 10, [[OpenGL GL_COMPRESSED_RGB8_ETC2 texture compression format (4 bit per pixel) @since 1.10.]] + rgba8_etc2_eac = 11, [[OpenGL GL_COMPRESSED_RGBA8_ETC2_EAC texture compression format, supports alpha (8 bit per pixel) @since 1.10.]] + etc1_alpha = 12, [[ETC1 with alpha support using two planes: ETC1 RGB and ETC1 grey for alpha @since 1.11.]] + rgb_s3tc_dxt1 = 13, [[OpenGL COMPRESSED_RGB_S3TC_DXT1_EXT format with RGB only. @since 1.11.]] + rgba_s3tc_dxt1 = 14, [[OpenGL COMPRESSED_RGBA_S3TC_DXT1_EXT format with RGBA punchthrough. @since 1.11.]] + rgba_s3tc_dxt2 = 15, [[DirectDraw DXT2 format with premultiplied RGBA. Not supported by OpenGL itself. @since 1.11.]] + rgba_s3tc_dxt3 = 16, [[OpenGL COMPRESSED_RGBA_S3TC_DXT3_EXT format with RGBA. @since 1.11.]] + rgba_s3tc_dxt4 = 17, [[DirectDraw DXT4 format with premultiplied RGBA. Not supported by OpenGL itself. @since 1.11.]] + rgba_s3tc_dxt5 = 18 [[OpenGL COMPRESSED_RGBA_S3TC_DXT5_EXT format with RGBA. @since 1.11.]] } enum Efl.Gfx.Render_Op { diff --git a/src/lib/emile/Emile.h b/src/lib/emile/Emile.h index 890b5ed..03d8e53 100644 --- a/src/lib/emile/Emile.h +++ b/src/lib/emile/Emile.h @@ -20,6 +20,7 @@ #define EMILE_H_ #include +#include #ifdef EAPI # undef EAPI diff --git a/src/lib/emile/emile_image.h b/src/lib/emile/emile_image.h index bee101d..9d6f1af 100644 ---
[EGIT] [core/efl] master 11/25: Evas: Remove unimplemented border_set/get (engine internal)
jpeg pushed a commit to branch master. http://git.enlightenment.org/core/efl.git/commit/?id=39a970835b58fe82a0e2cb0f809c5ecdee201861 commit 39a970835b58fe82a0e2cb0f809c5ecdee201861 Author: Jean-Philippe AndreDate: Tue Mar 22 15:25:37 2016 +0900 Evas: Remove unimplemented border_set/get (engine internal) --- src/lib/evas/canvas/evas_object_image.c | 6 -- src/lib/evas/include/evas_private.h | 2 -- src/modules/evas/engines/gl_cocoa/evas_engine.c | 13 - src/modules/evas/engines/gl_generic/evas_engine.c | 13 - src/modules/evas/engines/software_generic/evas_engine.c | 17 - 5 files changed, 51 deletions(-) diff --git a/src/lib/evas/canvas/evas_object_image.c b/src/lib/evas/canvas/evas_object_image.c index 12fa3b6..f275120 100644 --- a/src/lib/evas/canvas/evas_object_image.c +++ b/src/lib/evas/canvas/evas_object_image.c @@ -1823,12 +1823,6 @@ _evas_image_render(Eo *eo_obj, Evas_Object_Protected_Data *obj, int offx, offy; ENFN->image_scale_hint_set(output, pixels, o->scale_hint); - /* This is technically a bug here: If the value is recreated - * (which is returned)it may be a new object, however exactly 0 - * of all the evas engines do this. */ - ENFN->image_border_set(output, pixels, -o->cur->border.l, o->cur->border.r, -o->cur->border.t, o->cur->border.b); idx = evas_object_image_figure_x_fill(eo_obj, obj, o->cur->fill.x, o->cur->fill.w, ); idy = evas_object_image_figure_y_fill(eo_obj, obj, o->cur->fill.y, o->cur->fill.h, ); if (idw < 1) idw = 1; diff --git a/src/lib/evas/include/evas_private.h b/src/lib/evas/include/evas_private.h index e3eab64..b9f2ce3 100644 --- a/src/lib/evas/include/evas_private.h +++ b/src/lib/evas/include/evas_private.h @@ -1355,8 +1355,6 @@ struct _Evas_Func int (*image_alpha_get) (void *data, void *image); void *(*image_orient_set) (void *data, void *image, Evas_Image_Orient orient); Evas_Image_Orient (*image_orient_get) (void *data, void *image); - void *(*image_border_set) (void *data, void *image, int l, int r, int t, int b); - void (*image_border_get) (void *data, void *image, int *l, int *r, int *t, int *b); Eina_Bool (*image_draw) (void *data, void *context, void *surface, void *image, int src_x, int src_y, int src_w, int src_h, int dst_x, int dst_y, int dst_w, int dst_h, int smooth, Eina_Bool do_async); void (*image_colorspace_set)(void *data, void *image, Evas_Colorspace cspace); Evas_Colorspace (*image_colorspace_get) (void *data, void *image); diff --git a/src/modules/evas/engines/gl_cocoa/evas_engine.c b/src/modules/evas/engines/gl_cocoa/evas_engine.c index 58f26d0..31bc120 100644 --- a/src/modules/evas/engines/gl_cocoa/evas_engine.c +++ b/src/modules/evas/engines/gl_cocoa/evas_engine.c @@ -444,17 +444,6 @@ eng_image_alpha_set(void *data, void *image, int has_alpha) // return image; } -static void * -eng_image_border_set(void *data EINA_UNUSED, void *image, int l EINA_UNUSED, int r EINA_UNUSED, int t EINA_UNUSED, int b EINA_UNUSED) -{ - return image; -} - -static void -eng_image_border_get(void *data EINA_UNUSED, void *image EINA_UNUSED, int *l EINA_UNUSED, int *r EINA_UNUSED, int *t EINA_UNUSED, int *b EINA_UNUSED) -{ -} - static Evas_Colorspace eng_image_file_colorspace_get(void *data EINA_UNUSED, void *image) { @@ -1371,8 +1360,6 @@ module_open(Evas_Module *em) ORD(image_data_preload_cancel); ORD(image_alpha_set); ORD(image_alpha_get); - ORD(image_border_set); - ORD(image_border_get); ORD(image_draw); ORD(image_colorspace_set); ORD(image_colorspace_get); diff --git a/src/modules/evas/engines/gl_generic/evas_engine.c b/src/modules/evas/engines/gl_generic/evas_engine.c index a0d956b..cb25114 100644 --- a/src/modules/evas/engines/gl_generic/evas_engine.c +++ b/src/modules/evas/engines/gl_generic/evas_engine.c @@ -231,17 +231,6 @@ eng_image_alpha_set(void *data, void *image, int has_alpha) return evas_gl_common_image_alpha_set(im, has_alpha ? 1 : 0); } -static void * -eng_image_border_set(void *data EINA_UNUSED, void *image, int l EINA_UNUSED, int r EINA_UNUSED, int t EINA_UNUSED, int b EINA_UNUSED) -{ - return image; -} - -static void -eng_image_border_get(void *data EINA_UNUSED, void *image EINA_UNUSED, int *l EINA_UNUSED, int *r EINA_UNUSED, int *t EINA_UNUSED, int *b EINA_UNUSED) -{ -} - static Evas_Colorspace eng_image_file_colorspace_get(void *data EINA_UNUSED, void *image) { @@ -2818,8 +2807,6 @@ module_open(Evas_Module *em) ORD(image_alpha_get); ORD(image_orient_set); ORD(image_orient_get); - ORD(image_border_set); - ORD(image_border_get);
[EGIT] [core/efl] master 15/25: Evas: Add a test case for image buffer_map.
jpeg pushed a commit to branch master. http://git.enlightenment.org/core/efl.git/commit/?id=ba4ffba8c164400acf662eea7b7a715093812f12 commit ba4ffba8c164400acf662eea7b7a715093812f12 Author: Jean-Philippe AndreDate: Wed Mar 23 17:43:07 2016 +0900 Evas: Add a test case for image buffer_map. This: 1. opens a file 2. maps its data and vaguely verifies it 3. writes data to it 4. writes data to it with a GRY8 map 5. verifies that the final image has all the proper pixels --- src/tests/evas/evas_test_image.c | 167 +++ 1 file changed, 167 insertions(+) diff --git a/src/tests/evas/evas_test_image.c b/src/tests/evas/evas_test_image.c index 3414fb2..7f90754 100644 --- a/src/tests/evas/evas_test_image.c +++ b/src/tests/evas/evas_test_image.c @@ -654,6 +654,172 @@ START_TEST(evas_object_image_defaults) } END_TEST +// FIXME: belongs to another file +START_TEST(evas_object_image_map_unmap) +{ + Evas *e = _setup_evas(); + Evas_Object *o, *o2; + void *data; + int len, stride; + int w, h, rx, ry, rw, rh; + Efl_Gfx_Colorspace cs; + Eina_Tmpstr *tmp; + int fd; + uint32_t *data32; + uint8_t *data8; + Eina_Bool all_white = 1, all_transparent = 1; + + const char *imgpath = TESTS_IMG_DIR "/Pic4.png"; + + o = eo_add(EFL_CANVAS_IMAGE_CLASS, e); + efl_file_set(o, imgpath, NULL); + efl_gfx_view_size_get(o, , ); + cs = efl_gfx_buffer_colorspace_get(o); + + rx = (w / 4) & ~3; + ry = (h / 4) & ~3; + rw = (w / 2) & ~3; + rh = (h / 2) & ~3; + + // same cspace, full image + data = efl_gfx_buffer_map(o, , EFL_GFX_BUFFER_ACCESS_MODE_READ, 0, 0, w, h, cs, ); + fail_if(!data); + fail_if(!len); + fail_if(!stride); + efl_gfx_buffer_unmap(o, data, len); + + // same cspace, partial image + data = efl_gfx_buffer_map(o, , EFL_GFX_BUFFER_ACCESS_MODE_READ, rx, ry, rw, rh, cs, ); + fail_if(!data); + fail_if(!len); + fail_if(!stride); + efl_gfx_buffer_unmap(o, data, len); + + // argb cspace, full image + data = efl_gfx_buffer_map(o, , EFL_GFX_BUFFER_ACCESS_MODE_READ, 0, 0, w, h, EFL_GFX_COLORSPACE_ARGB, ); + fail_if(!data); + fail_if(!len); + fail_if(!stride); + data32 = data; + for (int k = 0; (k < len) && (all_white || all_transparent); k++) + { +if (data32[k]) + all_transparent = 0; +if (data32[k] != 0x) + all_white = 0; + } + fail_if(all_white || all_transparent); + efl_gfx_buffer_unmap(o, data, len); + + // argb cspace, partial image + data = efl_gfx_buffer_map(o, , EFL_GFX_BUFFER_ACCESS_MODE_READ, rx, ry, rw, rh, EFL_GFX_COLORSPACE_ARGB, ); + fail_if(!data); + fail_if(!len); + fail_if(!stride); + efl_gfx_buffer_unmap(o, data, len); + + // argb cspace, partial image, write + data = efl_gfx_buffer_map(o, , EFL_GFX_BUFFER_ACCESS_MODE_WRITE, rx, ry, rw, rh, EFL_GFX_COLORSPACE_ARGB, ); + fail_if(!data); + fail_if(!len); + fail_if(!stride); + data32 = data; + for (int y = 0; y < rh; y += 2) + for (int x = 0; x < rw; x++) + { + data32[y*stride/4 + x] = 0xFF00FF00; + data32[(y+1)*stride/4 + x] = 0x; + } + efl_gfx_buffer_unmap(o, data, len); + + // argb cspace, partial image, write + data = efl_gfx_buffer_map(o, , EFL_GFX_BUFFER_ACCESS_MODE_READ| EFL_GFX_BUFFER_ACCESS_MODE_WRITE, + rx, ry, rw, rh / 2, EFL_GFX_COLORSPACE_GRY8, ); + fail_if(!data); + fail_if(!len); + fail_if(!stride); + data8 = data; + for (int y = 0; y < rh / 4; y++) + for (int x = 0; x < rw; x++) + data8[y*stride + x] = x & 0xFF; + efl_gfx_buffer_unmap(o, data, len); + + // save file, verify its pixels + fd = eina_file_mkstemp("/tmp/evas-test.XX.png", ); + close(fd); + if (efl_file_save(o, tmp, NULL, NULL)) + { +Efl_Gfx_Colorspace cs2; +int w2, h2, stride2, len2; +uint32_t *data2, *orig; +int x, y; + +o2 = eo_add(EFL_CANVAS_IMAGE_CLASS, e); +efl_file_set(o2, tmp, NULL); +efl_gfx_view_size_get(o, , ); +cs2 = efl_gfx_buffer_colorspace_get(o2); + +// unlink now to not leave any crap after failing the test +unlink(tmp); + +fail_if(w2 != w); +fail_if(h2 != h); + +orig = efl_gfx_buffer_map(o, , EFL_GFX_BUFFER_ACCESS_MODE_READ, 0, 0, w, h, EFL_GFX_COLORSPACE_ARGB, ); +fail_if(!orig); +fail_if(!len); +fail_if(!stride); + +data2 = efl_gfx_buffer_map(o2, , EFL_GFX_BUFFER_ACCESS_MODE_READ, 0, 0, w2, h2, EFL_GFX_COLORSPACE_ARGB, ); +fail_if(!data2); +fail_if(len2 != len); +fail_if(stride2 != stride); + +// first quarter: same image +for (y = 0; y < h / 4; y++) + for (x = 0; x < w; x++) +fail_if(orig[y*stride/4 + x] != data2[y*stride2/4+x], "pixels differ [1]"); + +// middle zone top: grey gradient +
[EGIT] [core/efl] master 01/25: Evas 3d: Hide warning with clang
jpeg pushed a commit to branch master. http://git.enlightenment.org/core/efl.git/commit/?id=015554e57e3a88aba6b5a03ef70d023a5bdc5e5e commit 015554e57e3a88aba6b5a03ef70d023a5bdc5e5e Author: Jean-Philippe AndreDate: Fri Mar 25 17:51:17 2016 +0900 Evas 3d: Hide warning with clang An otherwise good looking macro triggers a warning with clang, because of self comparison of constants (always true or always false). Let's just silence the warning in this specific spot with a pragma. --- src/tests/evas/evas_test_mesh.c | 5 + 1 file changed, 5 insertions(+) diff --git a/src/tests/evas/evas_test_mesh.c b/src/tests/evas/evas_test_mesh.c index 40a2239..aba8a0b 100644 --- a/src/tests/evas/evas_test_mesh.c +++ b/src/tests/evas/evas_test_mesh.c @@ -106,10 +106,15 @@ static int _compare_meshes(Evas_Canvas3D_Mesh *mesh1, Evas_Canvas3D_Mesh *mesh2) if ((pd1->vertex_count) != (pd2->vertex_count)) return 1; +#pragma clang diagnostic push +#pragma clang diagnostic ignored "-Wtautological-compare" + COMPARE_GEOMETRICS(EVAS_CANVAS3D_VERTEX_ATTRIB_POSITION) COMPARE_GEOMETRICS(EVAS_CANVAS3D_VERTEX_ATTRIB_NORMAL) COMPARE_GEOMETRICS(EVAS_CANVAS3D_VERTEX_ATTRIB_TEXCOORD) +#pragma clang diagnostic pop + return 0; } --
[EGIT] [core/efl] master 13/25: Evas: Add SW engine map/unmap functions
jpeg pushed a commit to branch master. http://git.enlightenment.org/core/efl.git/commit/?id=d5b0b1e683310d16855d2183f509b11c4c3b8971 commit d5b0b1e683310d16855d2183f509b11c4c3b8971 Author: Jean-Philippe AndreDate: Wed Mar 23 13:33:08 2016 +0900 Evas: Add SW engine map/unmap functions Also, fix some of the code using them. --- src/lib/efl/interfaces/efl_gfx_types.eot | 6 +- src/lib/evas/canvas/efl_canvas_image.c | 25 +- src/lib/evas/canvas/efl_canvas_image.eo| 4 +- src/lib/evas/common/evas_image.h | 3 +- src/lib/evas/common/evas_image_main.c | 89 ++- src/lib/evas/include/evas_common_private.h | 16 ++ .../evas/engines/software_generic/evas_engine.c| 266 - src/static_libs/draw/draw_convert.c| 11 +- 8 files changed, 405 insertions(+), 15 deletions(-) diff --git a/src/lib/efl/interfaces/efl_gfx_types.eot b/src/lib/efl/interfaces/efl_gfx_types.eot index 1dcc816..b1f3ab1 100644 --- a/src/lib/efl/interfaces/efl_gfx_types.eot +++ b/src/lib/efl/interfaces/efl_gfx_types.eot @@ -4,9 +4,9 @@ enum Efl.Gfx.Colorspace { ycbcr422p709_pl, [[YCbCr 4:2:2 Planar, ITU.BT-709 specifications. The data pointed to is just an array of row pointer, pointing to the Y rows, then the Cb, then Cr rows.]] rgb565_a5p, [[16bit rgb565 + Alpha plane at end - 5 bits of the 8 being used per alpha byte.]] gry8 = 4, [[8-bit gray image, or alpha only.]] - ycbcr422601_pl, [[ YCbCr 4:2:2, ITU.BT-601 specifications. The data pointed to is just an array of row pointer, pointing to line of Y,Cb,Y,Cr bytes.]] - ycbcr420nv12601_pl, [[YCbCr 4:2:0, ITU.BT-601 specification. The data pointed to is just an array of row pointer, pointing to the Y rows, then the Cb,Cr rows..]] - ycbcr420tm12601_pl, [[YCbCr 4:2:0, ITU.BT-601 specification. The data pointed to is just an array of tiled row pointer, pointing to the Y rows, then the Cb,Cr rows..]] + ycbcr422601_pl, [[YCbCr 4:2:2, ITU.BT-601 specifications. The data pointed to is just an array of row pointer, pointing to line of Y,Cb,Y,Cr bytes.]] + ycbcr420nv12601_pl, [[YCbCr 4:2:0, ITU.BT-601 specifications. The data pointed to is just an array of row pointer, pointing to the Y rows, then the Cb,Cr rows..]] + ycbcr420tm12601_pl, [[YCbCr 4:2:0, ITU.BT-601 specifications. The data pointed to is just an array of tiled row pointer, pointing to the Y rows, then the Cb,Cr rows..]] agry88 = 8, [[AY 8bits Alpha and 8bits Grey, accessed 1 16bits at a time.]] etc1 = 9, [[OpenGL ETC1 encoding of RGB texture (4 bit per pixel) @since 1.10.]] rgb8_etc2 = 10, [[OpenGL GL_COMPRESSED_RGB8_ETC2 texture compression format (4 bit per pixel) @since 1.10.]] diff --git a/src/lib/evas/canvas/efl_canvas_image.c b/src/lib/evas/canvas/efl_canvas_image.c index 3da4290..2dac517 100644 --- a/src/lib/evas/canvas/efl_canvas_image.c +++ b/src/lib/evas/canvas/efl_canvas_image.c @@ -38,6 +38,21 @@ _efl_canvas_image_class_destructor(Eo_Class *eo_class EINA_UNUSED) _map_data_cow = NULL; } +EOLIAN static Eo_Base * +_efl_canvas_image_eo_base_constructor(Eo *obj, Efl_Canvas_Image_Data *pd) +{ + obj = eo_constructor(eo_super(obj, MY_CLASS)); + pd->map_data = eina_cow_alloc(_map_data_cow); + return obj; +} + +EOLIAN static void +_efl_canvas_image_eo_base_destructor(Eo *obj, Efl_Canvas_Image_Data *pd) +{ + eina_cow_free(_map_data_cow, (const Eina_Cow_Data **) >map_data); + eo_destructor(eo_super(obj, MY_CLASS)); +} + Eina_Bool _evas_image_mmap_set(Eo *eo_obj, const Eina_File *f, const char *key) { @@ -805,7 +820,11 @@ _efl_canvas_image_efl_gfx_buffer_buffer_map(Eo *eo_obj, Efl_Canvas_Image_Data *p goto end; // not implemented if (!o->engine_data) - goto end; + { +if (o->cur->u.file) + ERR("image is not loaded yet"); +goto end; + } if ((x < 0) || (y < 0) || ((x + (int) w) > (int) o->cur->image.w) || ((y + (int) h) > (int) o->cur->image.h)) { @@ -839,7 +858,7 @@ _efl_canvas_image_efl_gfx_buffer_buffer_unmap(Eo *eo_obj, Efl_Canvas_Image_Data Evas_Image_Data *o = eo_data_scope_get(eo_obj, EVAS_IMAGE_CLASS); Map_Data *map; - if (!ENFN->image_data_map) + if (!ENFN->image_data_unmap) goto fail; // not implemented if (!o->engine_data) @@ -855,6 +874,8 @@ _efl_canvas_image_efl_gfx_buffer_buffer_unmap(Eo *eo_obj, Efl_Canvas_Image_Data free(map); } + return; + fail: ERR("unmap failed"); } diff --git a/src/lib/evas/canvas/efl_canvas_image.eo b/src/lib/evas/canvas/efl_canvas_image.eo index 05c8373..8cececd 100644 --- a/src/lib/evas/canvas/efl_canvas_image.eo +++ b/src/lib/evas/canvas/efl_canvas_image.eo @@ -1,4 +1,4 @@ -class Efl.Canvas.Image (Evas.Image, Efl.Image_Load, Efl.Image_Animated) +class Efl.Canvas.Image (Evas.Image,
[EGIT] [core/efl] master 08/25: Efl.Canvas.Image: Implement support for map/unmap
jpeg pushed a commit to branch master. http://git.enlightenment.org/core/efl.git/commit/?id=326ff9ae8246d480503ca6f5d04f4e626a2b81ef commit 326ff9ae8246d480503ca6f5d04f4e626a2b81ef Author: Jean-Philippe AndreDate: Tue Mar 22 11:13:55 2016 +0900 Efl.Canvas.Image: Implement support for map/unmap Now the real hard work is to actually implement support inside the engines: SW and GL generic. --- src/lib/evas/canvas/efl_canvas_image.c | 225 - src/lib/evas/canvas/efl_canvas_image.eo| 5 +- src/lib/evas/include/evas_private.h| 3 + .../evas/engines/software_generic/evas_engine.c| 2 + 4 files changed, 178 insertions(+), 57 deletions(-) diff --git a/src/lib/evas/canvas/efl_canvas_image.c b/src/lib/evas/canvas/efl_canvas_image.c index 14a0274..3da4290 100644 --- a/src/lib/evas/canvas/efl_canvas_image.c +++ b/src/lib/evas/canvas/efl_canvas_image.c @@ -1,6 +1,42 @@ #include "evas_image_private.h" +#include "efl_canvas_image.eo.h" -static void _image_preload_internal(Eo *eo_obj, Evas_Image_Data *o, Eina_Bool cancel); +#define MY_CLASS EFL_CANVAS_IMAGE_CLASS + +// see also: ector_software_buffer +typedef struct { + EINA_INLIST; + unsigned char *ptr; + unsigned int size; // in bytes +} Map_Data; + +typedef struct { + Map_Data *maps; +} Map_Data_Cow; + +typedef struct { + const Map_Data_Cow *map_data; +} Efl_Canvas_Image_Data; + +static Eina_Cow *_map_data_cow = NULL; +static const Map_Data_Cow _map_data_cow_default = { NULL }; + +EOLIAN static void +_efl_canvas_image_class_constructor(Eo_Class *eo_class EINA_UNUSED) +{ + if (!_map_data_cow) + { +_map_data_cow = eina_cow_add("image_map_data", sizeof(Map_Data_Cow), + 1, &_map_data_cow_default, EINA_FALSE); + } +} + +EOLIAN static void +_efl_canvas_image_class_destructor(Eo_Class *eo_class EINA_UNUSED) +{ + eina_cow_del(_map_data_cow); + _map_data_cow = NULL; +} Eina_Bool _evas_image_mmap_set(Eo *eo_obj, const Eina_File *f, const char *key) @@ -26,7 +62,7 @@ _evas_image_mmap_set(Eo *eo_obj, const Eina_File *f, const char *key) } EOLIAN static Eina_Bool -_efl_canvas_image_efl_file_mmap_set(Eo *eo_obj, void *_pd EINA_UNUSED, +_efl_canvas_image_efl_file_mmap_set(Eo *eo_obj, Efl_Canvas_Image_Data *pd EINA_UNUSED, const Eina_File *f, const char *key) { return _evas_image_mmap_set(eo_obj, f, key); @@ -44,7 +80,7 @@ _evas_image_mmap_get(const Eo *eo_obj, const Eina_File **f, const char **key) } EOLIAN static void -_efl_canvas_image_efl_file_mmap_get(Eo *eo_obj, void *_pd EINA_UNUSED, +_efl_canvas_image_efl_file_mmap_get(Eo *eo_obj, Efl_Canvas_Image_Data *pd EINA_UNUSED, const Eina_File **f, const char **key) { _evas_image_mmap_get(eo_obj, f, key); @@ -75,7 +111,7 @@ _evas_image_file_set(Eo *eo_obj, const char *file, const char *key) } EOLIAN static Eina_Bool -_efl_canvas_image_efl_file_file_set(Eo *eo_obj, void *_pd EINA_UNUSED, +_efl_canvas_image_efl_file_file_set(Eo *eo_obj, Efl_Canvas_Image_Data *pd EINA_UNUSED, const char *file, const char *key) { return _evas_image_file_set(eo_obj, file, key); @@ -97,7 +133,7 @@ _evas_image_file_get(const Eo *eo_obj, const char **file, const char **key) } EOLIAN static void -_efl_canvas_image_efl_file_file_get(Eo *eo_obj, void *_pd EINA_UNUSED, +_efl_canvas_image_efl_file_file_get(Eo *eo_obj, Efl_Canvas_Image_Data *pd EINA_UNUSED, const char **file, const char **key) { _evas_image_file_get(eo_obj, file, key); @@ -112,11 +148,41 @@ _evas_image_load_error_get(const Eo *eo_obj) } EOLIAN static Efl_Image_Load_Error -_efl_canvas_image_efl_image_load_load_error_get(Eo *eo_obj, void *_pd EINA_UNUSED) +_efl_canvas_image_efl_image_load_load_error_get(Eo *eo_obj, Efl_Canvas_Image_Data *pd EINA_UNUSED) { return _evas_image_load_error_get(eo_obj); } +static void +_image_preload_internal(Eo *eo_obj, Evas_Image_Data *o, Eina_Bool cancel) +{ + if (!o->engine_data) + { +o->preloading = EINA_TRUE; +evas_object_inform_call_image_preloaded(eo_obj); +return; + } + // FIXME: if already busy preloading, then dont request again until + // preload done + Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS); + if (cancel) + { +if (o->preloading) + { + o->preloading = EINA_FALSE; + ENFN->image_data_preload_cancel(ENDT, o->engine_data, eo_obj); + } + } + else + { +if (!o->preloading) + { + o->preloading = EINA_TRUE; + ENFN->image_data_preload_request(ENDT, o->engine_data, eo_obj); + } + } +} + void _evas_image_load_async_start(Eo *eo_obj) { @@ -128,7 +194,7 @@
[EGIT] [core/efl] master 16/25: Efl.Canvas.Image: Remove object data for maps
jpeg pushed a commit to branch master. http://git.enlightenment.org/core/efl.git/commit/?id=22353e31e13ba4c13acc2edecb9cc69394cc2d99 commit 22353e31e13ba4c13acc2edecb9cc69394cc2d99 Author: Jean-Philippe AndreDate: Fri Mar 25 16:44:25 2016 +0900 Efl.Canvas.Image: Remove object data for maps The engine is responsible for the complete tracking of maps. Also, make buffer_unmap return bool. --- src/lib/efl/interfaces/efl_gfx_buffer.eo | 7 +- src/lib/evas/canvas/efl_canvas_image.c | 167 ++--- src/lib/evas/canvas/efl_canvas_image.eo| 5 +- src/lib/evas/include/evas_private.h| 3 +- .../evas/engines/software_generic/evas_engine.c| 36 - 5 files changed, 85 insertions(+), 133 deletions(-) diff --git a/src/lib/efl/interfaces/efl_gfx_buffer.eo b/src/lib/efl/interfaces/efl_gfx_buffer.eo index 2492792..8019145 100644 --- a/src/lib/efl/interfaces/efl_gfx_buffer.eo +++ b/src/lib/efl/interfaces/efl_gfx_buffer.eo @@ -118,10 +118,7 @@ interface Efl.Gfx.Buffer () } } - /* FIXME: not bindable to JS, potentially tricky to bind to Lua */ - - /* FIXME: split into read-only and writeable methods? */ - /* FIXME: This was copy pasta from ector generic buffer. changed a bit. */ + /* Note: Not for bindings, only C/C++ */ buffer_map { [[Map a region of this buffer for read or write access by the CPU. @@ -156,6 +153,8 @@ interface Efl.Gfx.Buffer () @in data: void*; [[Data pointer returned by a previous call to map]] @in length: int; [[Must be the same as returned by map.]] } + return: bool; [[This will return $false in case of failure (invalid + parameters or state of the object).]] } /* FIXME: naming: buffer_set, buffer_attach, external_data_set, ...? */ diff --git a/src/lib/evas/canvas/efl_canvas_image.c b/src/lib/evas/canvas/efl_canvas_image.c index 5a65050..45e5d50 100644 --- a/src/lib/evas/canvas/efl_canvas_image.c +++ b/src/lib/evas/canvas/efl_canvas_image.c @@ -3,56 +3,6 @@ #define MY_CLASS EFL_CANVAS_IMAGE_CLASS -// see also: ector_software_buffer -typedef struct { - EINA_INLIST; - unsigned char *ptr; - int size; // in bytes -} Map_Data; - -typedef struct { - Map_Data *maps; -} Map_Data_Cow; - -typedef struct { - const Map_Data_Cow *map_data; -} Efl_Canvas_Image_Data; - -static Eina_Cow *_map_data_cow = NULL; -static const Map_Data_Cow _map_data_cow_default = { NULL }; - -EOLIAN static void -_efl_canvas_image_class_constructor(Eo_Class *eo_class EINA_UNUSED) -{ - if (!_map_data_cow) - { -_map_data_cow = eina_cow_add("image_map_data", sizeof(Map_Data_Cow), - 1, &_map_data_cow_default, EINA_FALSE); - } -} - -EOLIAN static void -_efl_canvas_image_class_destructor(Eo_Class *eo_class EINA_UNUSED) -{ - eina_cow_del(_map_data_cow); - _map_data_cow = NULL; -} - -EOLIAN static Eo_Base * -_efl_canvas_image_eo_base_constructor(Eo *obj, Efl_Canvas_Image_Data *pd) -{ - obj = eo_constructor(eo_super(obj, MY_CLASS)); - pd->map_data = eina_cow_alloc(_map_data_cow); - return obj; -} - -EOLIAN static void -_efl_canvas_image_eo_base_destructor(Eo *obj, Efl_Canvas_Image_Data *pd) -{ - eina_cow_free(_map_data_cow, (const Eina_Cow_Data **) >map_data); - eo_destructor(eo_super(obj, MY_CLASS)); -} - Eina_Bool _evas_image_mmap_set(Eo *eo_obj, const Eina_File *f, const char *key) { @@ -77,7 +27,7 @@ _evas_image_mmap_set(Eo *eo_obj, const Eina_File *f, const char *key) } EOLIAN static Eina_Bool -_efl_canvas_image_efl_file_mmap_set(Eo *eo_obj, Efl_Canvas_Image_Data *pd EINA_UNUSED, +_efl_canvas_image_efl_file_mmap_set(Eo *eo_obj, void *_pd EINA_UNUSED EINA_UNUSED, const Eina_File *f, const char *key) { return _evas_image_mmap_set(eo_obj, f, key); @@ -95,7 +45,7 @@ _evas_image_mmap_get(const Eo *eo_obj, const Eina_File **f, const char **key) } EOLIAN static void -_efl_canvas_image_efl_file_mmap_get(Eo *eo_obj, Efl_Canvas_Image_Data *pd EINA_UNUSED, +_efl_canvas_image_efl_file_mmap_get(Eo *eo_obj, void *_pd EINA_UNUSED EINA_UNUSED, const Eina_File **f, const char **key) { _evas_image_mmap_get(eo_obj, f, key); @@ -126,7 +76,7 @@ _evas_image_file_set(Eo *eo_obj, const char *file, const char *key) } EOLIAN static Eina_Bool -_efl_canvas_image_efl_file_file_set(Eo *eo_obj, Efl_Canvas_Image_Data *pd EINA_UNUSED, +_efl_canvas_image_efl_file_file_set(Eo *eo_obj, void *_pd EINA_UNUSED EINA_UNUSED, const char *file, const char *key) { return _evas_image_file_set(eo_obj, file, key); @@ -148,7 +98,7 @@ _evas_image_file_get(const Eo *eo_obj, const char **file, const char **key) } EOLIAN static void -_efl_canvas_image_efl_file_file_get(Eo *eo_obj,
[EGIT] [core/efl] master 18/25: emotion/libvlc: set libvlc_log static
jpeg pushed a commit to branch master. http://git.enlightenment.org/core/efl.git/commit/?id=f04903119c27355b80dc52445fe329eac2a98c40 commit f04903119c27355b80dc52445fe329eac2a98c40 Author: Thomas GuillemDate: Fri Mar 25 09:05:33 2016 +0100 emotion/libvlc: set libvlc_log static --- src/modules/emotion/libvlc/emotion_libvlc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/modules/emotion/libvlc/emotion_libvlc.c b/src/modules/emotion/libvlc/emotion_libvlc.c index 2b941f0..b1a930e 100644 --- a/src/modules/emotion/libvlc/emotion_libvlc.c +++ b/src/modules/emotion/libvlc/emotion_libvlc.c @@ -1662,7 +1662,7 @@ static const Emotion_Engine em_engine = NULL /* priority_get */ }; -void +static void libvlc_log(void *data EINA_UNUSED, int level, const libvlc_log_t *ctx EINA_UNUSED, const char *fmt, va_list args) --
[EGIT] [core/efl] master 14/25: Efl.Gfx.Buffer: Switch to void* data and signed ints
jpeg pushed a commit to branch master. http://git.enlightenment.org/core/efl.git/commit/?id=488854af2bbae2e18624fec235599de6e191a812 commit 488854af2bbae2e18624fec235599de6e191a812 Author: Jean-Philippe AndreDate: Wed Mar 23 18:14:37 2016 +0900 Efl.Gfx.Buffer: Switch to void* data and signed ints 1. unsigned char* as a return type was not even compatible with the default colorspace (ARGB: 32 bits). 2. Change all unsigned to int for... uh... simplicity unsigned is more correct than int for things like width, size or stride, but in fact having both ints (x,y) and unsigned ints makes the code more complex. This is a matter of personal taste. --- src/lib/efl/interfaces/efl_gfx_buffer.eo| 14 +++--- src/lib/evas/canvas/efl_canvas_image.c | 14 +++--- src/lib/evas/include/evas_common_private.h | 7 +++ src/lib/evas/include/evas_private.h | 4 ++-- src/modules/evas/engines/software_generic/evas_engine.c | 4 ++-- 5 files changed, 21 insertions(+), 22 deletions(-) diff --git a/src/lib/efl/interfaces/efl_gfx_buffer.eo b/src/lib/efl/interfaces/efl_gfx_buffer.eo index 7585393..2492792 100644 --- a/src/lib/efl/interfaces/efl_gfx_buffer.eo +++ b/src/lib/efl/interfaces/efl_gfx_buffer.eo @@ -133,19 +133,19 @@ interface Efl.Gfx.Buffer () be negative. ]] params { -@out length: uint @nonull; [[Accessible buffer size in bytes, should not be $null.]] +@out length: int @nonull; [[Accessible buffer size in bytes, should not be $null.]] @in mode: Efl.Gfx.Buffer.Access_Mode; [[Specifies whether to map for read-only, write-only or read-write access (OR combinaison of flags).]] @in x: int @optional; [[X position of the top-left pixel to map, defaults to 0.]] @in y: int @optional; [[Y position of the top-left pixel to map, defaults to 0.]] -@in w: uint @optional; [[If 0, defaults to the buffer width.]] -@in h: uint @optional; [[If 0, defaults to the buffer height.]] +@in w: int @optional; [[If 0, defaults to the buffer width.]] +@in h: int @optional; [[If 0, defaults to the buffer height.]] @in cspace: Efl.Gfx.Colorspace @optional; [[Requested colorspace. If differen from the internal cspace, map should try to convert the data into a new buffer. argb by default.]] -@out stride: uint @optional; [[Returns the length in bytes of a mapped line]] +@out stride: int @optional; [[Returns the length in bytes of a mapped line]] } - return: ubyte* @warn_unused; [[Pointer to the top-left pixel data. Returns $null in case of failure]] + return: void* @warn_unused; [[Pointer to the top-left pixel data. Returns $null in case of failure]] } buffer_unmap { [[Unmap a region of this buffer, and update the internal data if needed. @@ -153,8 +153,8 @@ interface Efl.Gfx.Buffer () EFL will update the internal image if the map had write access. ]] params { -@in data: ubyte*; [[Data pointer returned by a previous call to map]] -@in length: uint; [[Must be the same as returned by map.]] +@in data: void*; [[Data pointer returned by a previous call to map]] +@in length: int; [[Must be the same as returned by map.]] } } diff --git a/src/lib/evas/canvas/efl_canvas_image.c b/src/lib/evas/canvas/efl_canvas_image.c index 2dac517..5a65050 100644 --- a/src/lib/evas/canvas/efl_canvas_image.c +++ b/src/lib/evas/canvas/efl_canvas_image.c @@ -7,7 +7,7 @@ typedef struct { EINA_INLIST; unsigned char *ptr; - unsigned int size; // in bytes + int size; // in bytes } Map_Data; typedef struct { @@ -803,16 +803,16 @@ _efl_canvas_image_efl_gfx_buffer_buffer_data_get(Eo *eo_obj, Efl_Canvas_Image_Da return ENFN->image_data_direct(ENDT, o->engine_data, NULL); } -EOLIAN static unsigned char * +EOLIAN static void * _efl_canvas_image_efl_gfx_buffer_buffer_map(Eo *eo_obj, Efl_Canvas_Image_Data *pd, -unsigned int *length, +int *length, Efl_Gfx_Buffer_Access_Mode mode, -int x, int y, unsigned int w, unsigned int h, -Efl_Gfx_Colorspace cspace, unsigned int *stride) +int x, int y, int w, int h, +Efl_Gfx_Colorspace cspace, int *stride) { Evas_Object_Protected_Data *obj
[EGIT] [core/efl] master 20/25: emotion/libvlc: set libvlc args from "EMOTION_LIBVLC_ARGS" env
jpeg pushed a commit to branch master. http://git.enlightenment.org/core/efl.git/commit/?id=f5296e8afc680e5c35c08ebb126f4f3636d32dd5 commit f5296e8afc680e5c35c08ebb126f4f3636d32dd5 Author: Thomas GuillemDate: Fri Mar 25 09:05:35 2016 +0100 emotion/libvlc: set libvlc args from "EMOTION_LIBVLC_ARGS" env --- src/modules/emotion/libvlc/emotion_libvlc.c | 63 - 1 file changed, 62 insertions(+), 1 deletion(-) diff --git a/src/modules/emotion/libvlc/emotion_libvlc.c b/src/modules/emotion/libvlc/emotion_libvlc.c index 4f4ffb3..c18d5ed 100644 --- a/src/modules/emotion/libvlc/emotion_libvlc.c +++ b/src/modules/emotion/libvlc/emotion_libvlc.c @@ -1696,6 +1696,67 @@ libvlc_log(void *data EINA_UNUSED, int level, __FILE__, __FUNCTION__, __LINE__, fmt, args); } +static libvlc_instance_t * +libvlc_new_env_args(void) +{ + unsigned int argc = 0, i = 0; + const char **argv = NULL; + char *args_env, *args_dup = NULL, *str = NULL, *token, *saveptr; + libvlc_instance_t *instance = NULL; + + args_env = getenv("EMOTION_LIBVLC_ARGS"); + if (!args_env) + goto fallback; + + /* dup since strtok modify the str */ + args_dup = strdup(args_env); + if (!args_dup) + goto fallback; + + /* call strtok to count the numbers of arguments */ + str = strdup(args_dup); + if (!str) + goto fallback; + + token = strtok_r(str, " ", ); + while (token) + { +argc++; +token = strtok_r(NULL, " ", ); + } + if (!argc) + goto fallback; + + /* alloc argv */ + argv = malloc(argc * sizeof(char *)); + if (!argv) + goto fallback; + + /* call strtok to fill argv */ + free(str); + str = strdup(args_dup); + if (!str) + goto fallback; + + token = strtok_r(str, " ", ); + while (token && i < argc) + { +argv[i++] = token; +token = strtok_r(NULL, " ", ); + } + + for (i = 0; i < argc; ++i) + INF("libvlc_argv[%d]: %s", i, argv[i]); + + instance = libvlc_new(argc, argv); + +fallback: + free(args_dup); + free(str); + free(argv); + return instance ? instance : libvlc_new(0, NULL); +} + Eina_Bool libvlc_module_init(void) { @@ -1716,7 +1777,7 @@ libvlc_module_init(void) return EINA_FALSE; } - libvlc = libvlc_new(0, NULL); + libvlc = libvlc_new_env_args(); if (!libvlc) { CRI("could not create libvlc instance"); --
[EGIT] [core/efl] master 17/25: Evas proxy: Implement buffer map/unmap
jpeg pushed a commit to branch master. http://git.enlightenment.org/core/efl.git/commit/?id=cb93c26db719baa0a93406cdf5ecd3763eef77ba commit cb93c26db719baa0a93406cdf5ecd3763eef77ba Author: Jean-Philippe AndreDate: Fri Mar 25 17:46:41 2016 +0900 Evas proxy: Implement buffer map/unmap --- src/lib/evas/canvas/efl_canvas_image.c | 27 +++--- src/lib/evas/canvas/efl_canvas_proxy.c | 98 -- src/lib/evas/canvas/efl_canvas_proxy.eo| 4 +- src/lib/evas/include/evas_private.h| 5 +- src/modules/evas/engines/gl_generic/evas_engine.c | 5 ++ .../evas/engines/software_generic/evas_engine.c| 12 ++- 6 files changed, 124 insertions(+), 27 deletions(-) diff --git a/src/lib/evas/canvas/efl_canvas_image.c b/src/lib/evas/canvas/efl_canvas_image.c index 45e5d50..66d7b8c 100644 --- a/src/lib/evas/canvas/efl_canvas_image.c +++ b/src/lib/evas/canvas/efl_canvas_image.c @@ -762,34 +762,39 @@ _efl_canvas_image_efl_gfx_buffer_buffer_map(Eo *eo_obj, void *_pd EINA_UNUSED, { Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS); Evas_Image_Data *o = eo_data_scope_get(eo_obj, EVAS_IMAGE_CLASS); - int len = 0, str = 0; + int len = 0, s = 0, width = 0, height = 0; void *data = NULL; if (!ENFN->image_data_map) goto end; // not implemented - if (!o->engine_data) + if (o->engine_data) + ENFN->image_size_get(ENDT, o->engine_data, , ); + + if (!o->engine_data || !width || !height) { -if (o->cur->u.file) - ERR("image is not loaded yet"); +// TODO: Create a map_surface and draw there. Maybe. This could +// depend on the flags (eg. add a "force render" flag). +WRN("This image image has no data available"); goto end; } - if (!w) w = o->cur->image.w; - if (!h) h = o->cur->image.h; + if (!w) w = width; + if (!h) h = height; - if ((x < 0) || (y < 0) || ((x + (int) w) > (int) o->cur->image.w) || ((y + (int) h) > (int) o->cur->image.h)) + if ((x < 0) || (y < 0) || ((x + w) > width) || ((y + h) > height)) { ERR("Invalid map dimensions: %dx%d +%d,%d. Image is %dx%d.", -w, h, x, y, o->cur->image.w, o->cur->image.h); +w, h, x, y, width, height); goto end; } - data = ENFN->image_data_map(ENDT, >engine_data, , , x, y, w, h, cspace, mode); + data = ENFN->image_data_map(ENDT, >engine_data, , , x, y, w, h, cspace, mode); + DBG("map(%p, %d,%d %dx%d) -> %p (%d bytes)", eo_obj, x, y, w, h, data, len); end: if (length) *length = len; - if (stride) *stride = str; + if (stride) *stride = s; return data; } @@ -803,7 +808,7 @@ _efl_canvas_image_efl_gfx_buffer_buffer_unmap(Eo *eo_obj, void *_pd EINA_UNUSED, if (!ENFN->image_data_unmap || !o->engine_data) return EINA_FALSE; - if (!ENFN->image_data_unmap(ENDT, >engine_data, data, length)) + if (!ENFN->image_data_unmap(ENDT, o->engine_data, data, length)) return EINA_FALSE; return EINA_TRUE; diff --git a/src/lib/evas/canvas/efl_canvas_proxy.c b/src/lib/evas/canvas/efl_canvas_proxy.c index 9648027..27d8170 100644 --- a/src/lib/evas/canvas/efl_canvas_proxy.c +++ b/src/lib/evas/canvas/efl_canvas_proxy.c @@ -57,7 +57,7 @@ _evas_image_proxy_source_set(Eo *eo_obj, Evas_Object *eo_src) } EOLIAN static Eina_Bool -_efl_canvas_proxy_source_set(Eo *eo_obj, void *pd EINA_UNUSED, Evas_Object *eo_src) +_efl_canvas_proxy_source_set(Eo *eo_obj, void *_pd EINA_UNUSED, Evas_Object *eo_src) { return _evas_image_proxy_source_set(eo_obj, eo_src); } @@ -70,7 +70,7 @@ _evas_image_proxy_source_get(const Eo *eo_obj) } EOLIAN static Evas_Object * -_efl_canvas_proxy_source_get(Eo *eo_obj, void *pd EINA_UNUSED) +_efl_canvas_proxy_source_get(Eo *eo_obj, void *_pd EINA_UNUSED) { return _evas_image_proxy_source_get(eo_obj); } @@ -94,7 +94,7 @@ _evas_image_proxy_source_clip_set(Eo *eo_obj, Eina_Bool source_clip) } EOLIAN static void -_efl_canvas_proxy_source_clip_set(Eo *eo_obj, void *pd EINA_UNUSED, Eina_Bool source_clip) +_efl_canvas_proxy_source_clip_set(Eo *eo_obj, void *_pd EINA_UNUSED, Eina_Bool source_clip) { return _evas_image_proxy_source_clip_set(eo_obj, source_clip); } @@ -107,7 +107,7 @@ _evas_image_proxy_source_clip_get(const Eo *eo_obj) } EOLIAN static Eina_Bool -_efl_canvas_proxy_source_clip_get(Eo *eo_obj, void *pd EINA_UNUSED) +_efl_canvas_proxy_source_clip_get(Eo *eo_obj, void *_pd EINA_UNUSED) { return _evas_image_proxy_source_clip_get(eo_obj); } @@ -131,7 +131,7 @@ _evas_image_proxy_source_events_set(Eo *eo_obj, Eina_Bool source_events) } EOLIAN static void -_efl_canvas_proxy_source_events_set(Eo *eo_obj, void *pd EINA_UNUSED, Eina_Bool repeat) +_efl_canvas_proxy_source_events_set(Eo *eo_obj, void *_pd EINA_UNUSED, Eina_Bool repeat) { return _evas_image_proxy_source_events_set(eo_obj, repeat); } @@ -144,7
[EGIT] [core/efl] master 21/25: emotion/libvlc: fix C89
jpeg pushed a commit to branch master. http://git.enlightenment.org/core/efl.git/commit/?id=7d3e96757d8467d9345ea83f53e77b4d98003ccf commit 7d3e96757d8467d9345ea83f53e77b4d98003ccf Author: Thomas GuillemDate: Fri Mar 25 09:05:36 2016 +0100 emotion/libvlc: fix C89 --- src/modules/emotion/libvlc/emotion_libvlc.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/modules/emotion/libvlc/emotion_libvlc.c b/src/modules/emotion/libvlc/emotion_libvlc.c index c18d5ed..d5fd847 100644 --- a/src/modules/emotion/libvlc/emotion_libvlc.c +++ b/src/modules/emotion/libvlc/emotion_libvlc.c @@ -733,7 +733,7 @@ static Eina_Bool em_file_open(void *video, const char *file) { - int ret; + int ret, i; Emotion_LibVLC *ev = video; libvlc_event_manager_t *event_m; @@ -766,7 +766,7 @@ em_file_open(void *video, EINA_SAFETY_ON_NULL_GOTO(ev->mp, error); event_m = libvlc_media_player_event_manager(ev->mp); - for (int i = 0; mp_events[i] != -1; ++i) + for (i = 0; mp_events[i] != -1; ++i) libvlc_event_attach(event_m, mp_events[i], libvlc_on_mp_event, ev); libvlc_media_player_set_video_title_display(ev->mp, @@ -801,7 +801,7 @@ em_file_close(void *video) libvlc_event_manager_t *event_m; event_m = libvlc_media_player_event_manager(ev->mp); -for (int i = 0; mp_events[i] != -1; ++i) +for (i = 0; mp_events[i] != -1; ++i) libvlc_event_detach(event_m, mp_events[i], libvlc_on_mp_event, ev); /* Abort libvlc callbacks */ --
[EGIT] [core/efl] master 24/25: emotion/libvlc: replace libvlc_mp_is_ready with ev->started
jpeg pushed a commit to branch master. http://git.enlightenment.org/core/efl.git/commit/?id=b12c2a2cfd6850d695c76f96827e1e110be4038a commit b12c2a2cfd6850d695c76f96827e1e110be4038a Author: Thomas GuillemDate: Fri Mar 25 09:05:39 2016 +0100 emotion/libvlc: replace libvlc_mp_is_ready with ev->started --- src/modules/emotion/libvlc/emotion_libvlc.c | 83 + 1 file changed, 36 insertions(+), 47 deletions(-) diff --git a/src/modules/emotion/libvlc/emotion_libvlc.c b/src/modules/emotion/libvlc/emotion_libvlc.c index 98f6fdf..d9500cd 100644 --- a/src/modules/emotion/libvlc/emotion_libvlc.c +++ b/src/modules/emotion/libvlc/emotion_libvlc.c @@ -283,17 +283,6 @@ evas_resize_cb(void *data, Evas *e EINA_UNUSED, Evas_Object *obj EINA_UNUSED, eo_event_callback_call(ev->obj, EMOTION_OBJECT_EVENT_FRAME_DECODE, NULL); } -/* Returns true if libvlc mediaplayer is ready to process commands. */ -static Eina_Bool -libvlc_mp_is_ready(Emotion_LibVLC *ev) -{ - libvlc_state_t state; - - if (!ev->mp) return EINA_FALSE; - state = libvlc_media_player_get_state(ev->mp); - return state == libvlc_Playing || state == libvlc_Paused; -} - /* Fetch all libvlc tracks. */ static int libvlc_fetch_tracks(Emotion_LibVLC *ev) @@ -619,7 +608,7 @@ em_size_get(void *video, *width = 0; *height = 0; - if (!libvlc_mp_is_ready(ev)) return; + if (!ev->started) return; track = libvlc_get_current_video_track(ev); if (track) @@ -634,7 +623,7 @@ em_pos_get(void *video) { Emotion_LibVLC *ev = video; - if (!libvlc_mp_is_ready(ev)) return 0.0; + if (!ev->started) return 0.0; return ev->pos; } @@ -645,7 +634,7 @@ em_pos_set(void *video, { Emotion_LibVLC *ev = video; - if (!libvlc_mp_is_ready(ev)) + if (!ev->started) { _emotion_seek_done(ev->obj); return; @@ -661,7 +650,7 @@ em_len_get(void *video) { Emotion_LibVLC *ev = video; - if (!libvlc_mp_is_ready(ev)) return 0.0; + if (!ev->started) return 0.0; return ev->len; } @@ -671,7 +660,7 @@ em_buffer_size_get(void *video) { Emotion_LibVLC *ev = video; - if (!libvlc_mp_is_ready(ev)) return 0.0; + if (!ev->started) return 0.0; return ev->buffer_cache; } @@ -681,7 +670,7 @@ em_fps_num_den_get(Emotion_LibVLC *ev, int *num, int *den) { libvlc_media_track_t *track; - if (!libvlc_mp_is_ready(ev)) return; + if (!ev->started) return; track = libvlc_get_current_video_track(ev); if (track) @@ -753,7 +742,7 @@ em_ratio_get(void *video) Emotion_LibVLC *ev = video; libvlc_media_track_t *track; - if (!libvlc_mp_is_ready(ev)) return 0.0; + if (!ev->started) return 0.0; track = libvlc_get_current_video_track(ev); if (track) @@ -771,7 +760,7 @@ em_video_handled(void *video) { Emotion_LibVLC *ev = video; - if (!libvlc_mp_is_ready(ev)) return 0.0; + if (!ev->started) return 0.0; return libvlc_video_get_track_count(ev->mp) > 0; } @@ -781,7 +770,7 @@ em_audio_handled(void *video) { Emotion_LibVLC *ev = video; - if (!libvlc_mp_is_ready(ev)) return 0.0; + if (!ev->started) return 0.0; return libvlc_audio_get_track_count(ev->mp) > 0; } @@ -791,7 +780,7 @@ em_seekable(void *video) { Emotion_LibVLC *ev = video; - if (!libvlc_mp_is_ready(ev)) return 0; + if (!ev->started) return 0; return libvlc_media_player_is_seekable(ev->mp); } @@ -835,7 +824,7 @@ em_event_feed(void *video, int event) Emotion_LibVLC *ev = video; unsigned int navigate; - if (!libvlc_mp_is_ready(ev)) return; + if (!ev->started) return; switch (event) { @@ -906,7 +895,7 @@ em_video_channel_count(void *video) { Emotion_LibVLC *ev = video; - if (!libvlc_mp_is_ready(ev)) return -1; + if (!ev->started) return -1; return libvlc_video_get_track_count(ev->mp); } @@ -917,7 +906,7 @@ em_video_channel_set(void *video, { Emotion_LibVLC *ev = video; - if (!libvlc_mp_is_ready(ev)) return; + if (!ev->started) return; if (channel < 0) libvlc_video_set_track(ev->mp, -1); @@ -936,7 +925,7 @@ em_video_channel_get(void *video) Emotion_LibVLC *ev = video; int id; - if (!libvlc_mp_is_ready(ev)) return -1; + if (!ev->started) return -1; id = libvlc_video_get_track(ev->mp); @@ -949,7 +938,7 @@ em_video_subtitle_file_set(void *video, { Emotion_LibVLC *ev = video; - if (!libvlc_mp_is_ready(ev)) return; + if (!ev->started) return; free(ev->subtitle_file); ev->subtitle_file = filepath ? strdup(filepath) : NULL; @@ -971,7 +960,7 @@ em_video_channel_name_get(void *video, Emotion_LibVLC *ev = video; libvlc_media_track_t *track; - if (!libvlc_mp_is_ready(ev)) return NULL; + if (!ev->started) return NULL; track = libvlc_get_track_at_pos(ev, channel, libvlc_track_video); if (track) @@ -990,7 +979,7 @@ em_video_channel_mute_set(void *video, return; ev->video_mute = mute; - if
[EGIT] [core/efl] master 07/25: Evas: Simplify direct access to image data
jpeg pushed a commit to branch master. http://git.enlightenment.org/core/efl.git/commit/?id=91e0bdb1e78b4d6505702600bde52e012b8d2679 commit 91e0bdb1e78b4d6505702600bde52e012b8d2679 Author: Jean-Philippe AndreDate: Mon Mar 21 21:08:29 2016 +0900 Evas: Simplify direct access to image data This should avoid issues with image_data_get from the engines, when we really just want to fetch the original data pointer. --- src/lib/evas/canvas/efl_canvas_image.c | 11 ++- src/lib/evas/canvas/evas_object_image.c | 4 ++-- src/lib/evas/include/evas_private.h | 2 +- src/modules/evas/engines/gl_cocoa/evas_engine.c | 16 ++-- src/modules/evas/engines/gl_generic/evas_engine.c | 16 ++-- src/modules/evas/engines/software_generic/evas_engine.c | 16 ++-- 6 files changed, 23 insertions(+), 42 deletions(-) diff --git a/src/lib/evas/canvas/efl_canvas_image.c b/src/lib/evas/canvas/efl_canvas_image.c index 6d088fe..14a0274 100644 --- a/src/lib/evas/canvas/efl_canvas_image.c +++ b/src/lib/evas/canvas/efl_canvas_image.c @@ -709,18 +709,11 @@ _efl_canvas_image_efl_gfx_buffer_buffer_data_get(Eo *eo_obj, void *_pd EINA_UNUS { Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS); Evas_Image_Data *o = eo_data_scope_get(eo_obj, EVAS_IMAGE_CLASS); - DATA32 *data = NULL; - if (!o->buffer_data_set || !o->engine_data || !ENFN->image_data_has) + if (!o->buffer_data_set || !o->engine_data || !ENFN->image_data_direct) return NULL; - if (ENFN->image_data_has(ENDT, o->engine_data, NULL)) - { -// FIXME: this is horrible code - need to store ptr somewhere safe -o->engine_data = ENFN->image_data_get(ENDT, o->engine_data, 0, , >load_error, NULL); - } - - return data; + return ENFN->image_data_direct(ENDT, o->engine_data, NULL); } static void diff --git a/src/lib/evas/canvas/evas_object_image.c b/src/lib/evas/canvas/evas_object_image.c index 92f58a1..12fa3b6 100644 --- a/src/lib/evas/canvas/evas_object_image.c +++ b/src/lib/evas/canvas/evas_object_image.c @@ -850,11 +850,11 @@ _evas_image_efl_file_save(const Eo *eo_obj, Evas_Image_Data *o, const char *file } } - if (!ENFN->image_data_has) + if (!ENFN->image_data_direct) pixels = ENFN->image_data_get(ENDT, pixels, 0, , >load_error, ); else { -if (ENFN->image_data_has(ENDT, pixels, )) +if (ENFN->image_data_direct(ENDT, pixels, )) { if ((want_cspace != (int) cspace) && (want_cspace != -1)) cspace = EVAS_COLORSPACE_ARGB; diff --git a/src/lib/evas/include/evas_private.h b/src/lib/evas/include/evas_private.h index 744d394..49b713d 100644 --- a/src/lib/evas/include/evas_private.h +++ b/src/lib/evas/include/evas_private.h @@ -1348,7 +1348,7 @@ struct _Evas_Func void *(*image_dirty_region) (void *data, void *image, int x, int y, int w, int h); void *(*image_data_get) (void *data, void *image, int to_write, DATA32 **image_data, int *err, Eina_Bool *tofree); void *(*image_data_put) (void *data, void *image, DATA32 *image_data); - Eina_Bool (*image_data_has) (void *data, void *image, Evas_Colorspace *cspace); + void *(*image_data_direct) (void *data, void *image, Evas_Colorspace *cspace); void (*image_data_preload_request) (void *data, void *image, const Eo *target); void (*image_data_preload_cancel) (void *data, void *image, const Eo *target); void *(*image_alpha_set)(void *data, void *image, int has_alpha); diff --git a/src/modules/evas/engines/gl_cocoa/evas_engine.c b/src/modules/evas/engines/gl_cocoa/evas_engine.c index f67ecd1..08b62b5 100644 --- a/src/modules/evas/engines/gl_cocoa/evas_engine.c +++ b/src/modules/evas/engines/gl_cocoa/evas_engine.c @@ -477,18 +477,14 @@ eng_image_file_colorspace_get(void *data EINA_UNUSED, void *image) return im->im->cache_entry.space; } -static Eina_Bool -eng_image_data_has(void *data EINA_UNUSED, void *image, Evas_Colorspace *cspace) +static void * +eng_image_data_direct(void *data EINA_UNUSED, void *image, Evas_Colorspace *cspace) { Evas_GL_Image *im = image; - if (!im || !im->im) return EINA_FALSE; - if (im->im->image.data) - { -if (cspace) *cspace = im->im->cache_entry.space; -return EINA_TRUE; - } - return EINA_FALSE; + if (!im || !im->im) return NULL; + if (cspace) *cspace = im->im->cache_entry.space; + return im->im->image.data; } static void @@ -1381,7 +1377,7 @@ module_open(Evas_Module *em) ORD(image_dirty_region); ORD(image_data_get); ORD(image_data_put); - ORD(image_data_has); + ORD(image_data_direct); ORD(image_data_preload_request); ORD(image_data_preload_cancel); ORD(image_alpha_set); diff --git
[EGIT] [core/efl] master 19/25: emotion/libvlc: fix video/audio/spu mute
jpeg pushed a commit to branch master. http://git.enlightenment.org/core/efl.git/commit/?id=941ccc43247fe23aba125180e9787c851a79b4d3 commit 941ccc43247fe23aba125180e9787c851a79b4d3 Author: Thomas GuillemDate: Fri Mar 25 09:05:34 2016 +0100 emotion/libvlc: fix video/audio/spu mute --- src/modules/emotion/libvlc/emotion_libvlc.c | 49 - 1 file changed, 27 insertions(+), 22 deletions(-) diff --git a/src/modules/emotion/libvlc/emotion_libvlc.c b/src/modules/emotion/libvlc/emotion_libvlc.c index b1a930e..4f4ffb3 100644 --- a/src/modules/emotion/libvlc/emotion_libvlc.c +++ b/src/modules/emotion/libvlc/emotion_libvlc.c @@ -69,6 +69,7 @@ struct _Emotion_LibVLC /* options */ intvideo_mute; intaudio_mute; + intspu_mute; intaudio_vol; Emotion_Visvis; @@ -701,7 +702,6 @@ em_add(const Emotion_Engine *api EINA_UNUSED, eina_lock_new(>lock); eina_condition_new(>wait, >lock); ev->ref_count = 1; - ev->audio_mute = -1; ev->audio_vol = -1; return ev; @@ -752,12 +752,15 @@ em_file_open(void *video, ev->m = libvlc_media_new_path(libvlc, file); EINA_SAFETY_ON_NULL_GOTO(ev->m, error); - if (ev->opt.no_audio) + if (ev->opt.no_audio || ev->audio_mute) libvlc_media_add_option(ev->m, ":no-audio"); - if (ev->opt.no_video) + if (ev->opt.no_video || ev->video_mute) libvlc_media_add_option(ev->m, ":no-video"); + if (ev->spu_mute) + libvlc_media_add_option(ev->m, ":no-spu"); + /* Create libvlc_media_player */ ev->mp = libvlc_media_player_new_from_media(ev->m); EINA_SAFETY_ON_NULL_GOTO(ev->mp, error); @@ -770,16 +773,11 @@ em_file_open(void *video, libvlc_position_disable, 0); /* Set sink callbacks */ - if (!ev->opt.no_video) - { -libvlc_video_set_format_callbacks(ev->mp, libvlc_video_on_format, NULL); -libvlc_video_set_callbacks(ev->mp, libvlc_video_on_lock, - libvlc_video_on_unlock, - libvlc_video_on_display, ev); - } + libvlc_video_set_format_callbacks(ev->mp, libvlc_video_on_format, NULL); + libvlc_video_set_callbacks(ev->mp, libvlc_video_on_lock, + libvlc_video_on_unlock, + libvlc_video_on_display, ev); - if (ev->audio_mute != -1) - libvlc_audio_set_mute(ev->mp, 1); if (ev->audio_vol != -1) libvlc_audio_set_volume(ev->mp, ev->audio_vol); @@ -1268,6 +1266,9 @@ em_video_channel_mute_set(void *video, Emotion_LibVLC *ev = video; ev->video_mute = mute; + + if (libvlc_mp_is_ready(ev)) + em_video_channel_set(video, mute ? -1 : 0); } static int @@ -1351,9 +1352,8 @@ em_audio_channel_mute_set(void *video, ev->audio_mute = mute; - if (!libvlc_mp_is_ready(ev)) return; - - libvlc_audio_set_mute(ev->mp, mute); + if (libvlc_mp_is_ready(ev)) + em_audio_channel_set(video, mute ? -1 : 0); } static int @@ -1361,10 +1361,7 @@ em_audio_channel_mute_get(void *video) { Emotion_LibVLC *ev = video; - if (!libvlc_mp_is_ready(ev)) - return ev->audio_mute; - - return libvlc_audio_get_mute(ev->mp); + return ev->audio_mute; } static void @@ -1454,14 +1451,22 @@ em_spu_channel_name_get(void *video, } static void -em_spu_channel_mute_set(void *video EINA_UNUSED, int mute EINA_UNUSED) +em_spu_channel_mute_set(void *video, int mute) { + Emotion_LibVLC *ev = video; + + ev->spu_mute = mute; + + if (libvlc_mp_is_ready(ev)) + em_spu_channel_set(video, mute ? -1 : 0); } static int -em_spu_channel_mute_get(void *video EINA_UNUSED) +em_spu_channel_mute_get(void *video) { - return 0; + Emotion_LibVLC *ev = video; + + return ev->spu_mute; } static int --
[EGIT] [core/efl] master 22/25: emotion/libvlc: log: print vlc module and id
jpeg pushed a commit to branch master. http://git.enlightenment.org/core/efl.git/commit/?id=50d9f63c2e8e3773f3e433168c3b8020ac192ee4 commit 50d9f63c2e8e3773f3e433168c3b8020ac192ee4 Author: Thomas GuillemDate: Fri Mar 25 09:05:37 2016 +0100 emotion/libvlc: log: print vlc module and id --- src/modules/emotion/libvlc/emotion_libvlc.c | 6 +- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/modules/emotion/libvlc/emotion_libvlc.c b/src/modules/emotion/libvlc/emotion_libvlc.c index d5fd847..e256a56 100644 --- a/src/modules/emotion/libvlc/emotion_libvlc.c +++ b/src/modules/emotion/libvlc/emotion_libvlc.c @@ -1673,6 +1673,10 @@ libvlc_log(void *data EINA_UNUSED, int level, const char *fmt, va_list args) { Eina_Log_Level eina_log_level; + const char *name, *header; + uintptr_t id; + + libvlc_log_get_object(ctx, , , ); switch (level) { case LIBVLC_DEBUG: @@ -1693,7 +1697,7 @@ libvlc_log(void *data EINA_UNUSED, int level, break; } eina_log_vprint(_emotion_libvlc_log_domain, eina_log_level, - __FILE__, __FUNCTION__, __LINE__, fmt, args); + "", name, id, fmt, args); } static libvlc_instance_t * --
[EGIT] [core/efl] master 02/25: Evas.Image: Move data_set/get to legacy file
jpeg pushed a commit to branch master. http://git.enlightenment.org/core/efl.git/commit/?id=83b8b8c958dffc4760d00a01275145b782b32ff2 commit 83b8b8c958dffc4760d00a01275145b782b32ff2 Author: Jean-Philippe AndreDate: Fri Mar 18 14:50:54 2016 +0900 Evas.Image: Move data_set/get to legacy file Those functions will be replaced by map/unmap --- src/lib/evas/canvas/evas_image_legacy.c | 178 + src/lib/evas/canvas/evas_image_private.h | 13 +++ src/lib/evas/canvas/evas_object_image.c | 190 --- 3 files changed, 191 insertions(+), 190 deletions(-) diff --git a/src/lib/evas/canvas/evas_image_legacy.c b/src/lib/evas/canvas/evas_image_legacy.c index a82f025..01c9353 100644 --- a/src/lib/evas/canvas/evas_image_legacy.c +++ b/src/lib/evas/canvas/evas_image_legacy.c @@ -470,6 +470,184 @@ evas_object_image_native_surface_get(const Evas_Object *eo_obj) return _evas_image_native_surface_get(eo_obj); } +EAPI void +evas_object_image_data_set(Eo *eo_obj, void *data) +{ + Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS); + Evas_Image_Data *o = eo_data_scope_get(eo_obj, EVAS_IMAGE_CLASS); + void *p_data; + Eina_Bool resize_call = EINA_FALSE; + + + evas_object_async_block(obj); + evas_render_rendering_wait(obj->layer->evas); + + _evas_image_cleanup(eo_obj, obj, o); + p_data = o->engine_data; + if (data) + { +if (o->engine_data) + { + o->engine_data = ENFN->image_data_put(ENDT, o->engine_data, data); + } +else + { + o->engine_data = ENFN->image_new_from_data(ENDT, +o->cur->image.w, +o->cur->image.h, +data, +o->cur->has_alpha, +o->cur->cspace); + } +if (o->engine_data) + { + int stride = 0; + + if (ENFN->image_scale_hint_set) + ENFN->image_scale_hint_set(ENDT, o->engine_data, o->scale_hint); + + if (ENFN->image_content_hint_set) + ENFN->image_content_hint_set(ENDT, o->engine_data, o->content_hint); + + if (ENFN->image_stride_get) + ENFN->image_stride_get(ENDT, o->engine_data, ); + else + stride = o->cur->image.w * 4; + + if (o->cur->image.stride != stride) + { + EINA_COW_IMAGE_STATE_WRITE_BEGIN(o, state_write) +state_write->image.stride = stride; + EINA_COW_IMAGE_STATE_WRITE_END(o, state_write); + } + } + o->written = EINA_TRUE; + } + else + { +if (o->engine_data) + ENFN->image_free(ENDT, o->engine_data); +o->load_error = EVAS_LOAD_ERROR_NONE; +if ((o->cur->image.w != 0) || (o->cur->image.h != 0)) + resize_call = EINA_TRUE; + +EINA_COW_IMAGE_STATE_WRITE_BEGIN(o, state_write) + { + state_write->image.w = 0; + state_write->image.h = 0; + state_write->image.stride = 0; + } +EINA_COW_IMAGE_STATE_WRITE_END(o, state_write); + +o->engine_data = NULL; + } +/* FIXME - in engine call above + if (o->engine_data) + o->engine_data = ENFN->image_alpha_set(ENDT, o->engine_data, o->cur->has_alpha); +*/ + if (o->pixels_checked_out > 0) o->pixels_checked_out--; + if (p_data != o->engine_data) + { +EVAS_OBJECT_WRITE_IMAGE_FREE_FILE_AND_KEY(o); +o->pixels_checked_out = 0; + } + if (resize_call) evas_object_inform_call_image_resize(eo_obj); +} + +EAPI void* +evas_object_image_data_get(const Eo *eo_obj, Eina_Bool for_writing) +{ + Evas_Image_Data *o = eo_data_scope_get(eo_obj, EVAS_IMAGE_CLASS); + int stride = 0; + void *pixels; + DATA32 *data; + + if (!o->engine_data) return NULL; + + Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS); + + if (for_writing) evas_object_async_block(obj); + if (for_writing) evas_render_rendering_wait(obj->layer->evas); + + data = NULL; + if (ENFN->image_scale_hint_set) + ENFN->image_scale_hint_set(ENDT, o->engine_data, o->scale_hint); + if (ENFN->image_content_hint_set) + ENFN->image_content_hint_set(ENDT, o->engine_data, o->content_hint); + pixels = ENFN->image_data_get(ENDT, o->engine_data, for_writing, , >load_error, NULL); + + /* if we fail to get engine_data, we have to return NULL */ + if (!pixels) return NULL; + + o->engine_data = pixels; + if (ENFN->image_stride_get) + ENFN->image_stride_get(ENDT, o->engine_data, ); + else + stride = o->cur->image.w * 4; + + if (o->cur->image.stride != stride) + { +
[EGIT] [core/efl] master 06/25: Efl.Canvas.Image: Implement raw data_set/copy/get
jpeg pushed a commit to branch master. http://git.enlightenment.org/core/efl.git/commit/?id=08c11608880038e36ebf94fa6db5a24049146de6 commit 08c11608880038e36ebf94fa6db5a24049146de6 Author: Jean-Philippe AndreDate: Mon Mar 21 20:15:20 2016 +0900 Efl.Canvas.Image: Implement raw data_set/copy/get No more refcount. This is only to initialize the data from an external buffer. data_get will only work if data_set was used (not even copy_set). --- src/lib/efl/interfaces/efl_gfx_buffer.eo | 50 ++- src/lib/evas/canvas/efl_canvas_image.c | 236 +++ src/lib/evas/canvas/efl_canvas_image.eo | 4 + src/lib/evas/canvas/evas_image_legacy.c | 2 +- src/lib/evas/canvas/evas_image_private.h | 1 + 5 files changed, 223 insertions(+), 70 deletions(-) diff --git a/src/lib/efl/interfaces/efl_gfx_buffer.eo b/src/lib/efl/interfaces/efl_gfx_buffer.eo index 87de79b..7585393 100644 --- a/src/lib/efl/interfaces/efl_gfx_buffer.eo +++ b/src/lib/efl/interfaces/efl_gfx_buffer.eo @@ -157,10 +157,9 @@ interface Efl.Gfx.Buffer () @in length: uint; [[Must be the same as returned by map.]] } } - /* note: not a property because the refcount needs to be explicit - * between set and get */ - /* FIXME: do we need writable flag? */ - buffer_set { + + /* FIXME: naming: buffer_set, buffer_attach, external_data_set, ...? */ + buffer_data_set { [[Set the pixels for this buffer, or allocate a new memory region. EFL will use $pixels directly, and update the GPU-side texture @@ -170,15 +169,8 @@ interface Efl.Gfx.Buffer () If the buffer already had pixel data, the previous image data will be dropped. This is the same as @.buffer_copy_set. - If $pixels is the return value of @.buffer_get then EFL will - decrement its internal reference count on the buffer data. Call - @.buffer_update_add to flush updates and indicate changes in - the pixel data. - The memory buffer $pixels must be large enough to hold $width x $height pixels encoded in the colorspace $cspace. - Alternatively $pixels must be larger than $height x $stride - in bytes. See also @.buffer_copy_set if you want EFL to copy the input buffer internally. @@ -202,18 +194,12 @@ interface Efl.Gfx.Buffer () If $pixels is $null, then a new empty buffer will be allocated. If the buffer already had pixel data, the previous image data will - be dropped. This is the same as @.buffer_set. + be dropped. This is the same as @.buffer_data_set. The memory buffer $pixels must be large enough to hold $width x $height pixels encoded in the colorspace $cspace. - Alternatively $pixels must be larger than $height x $stride - in bytes. - - $pixels should not be the return value of @.buffer_get. - There is no copy equivalent to this function, as you can easily - call @.buffer_get and allocate the proper buffer on your side, - followed by a memory copy and @.buffer_set. + $pixels should not be the return value of @.buffer_data_get. ]] params { @in pixels: const(void)* @nullable; [[If $null, allocates an empty buffer]] @@ -224,29 +210,15 @@ interface Efl.Gfx.Buffer () } return: bool @warn_unused; [[This function returns $false in case of failure.]] } - buffer_get { - [[Get a direct pointer to the internal pixel data. + buffer_data_get { + [[Get a direct pointer to the internal pixel data, if available. - This will increment an internal reference counter on the internal - buffer. If $to_write is $true, this may trigger a copy of the - internal pixel data, and return a writable memory block. + This will return $null unless @.buffer_data_set was used to pass in an + external data pointer. - Call @.buffer_size.get to know the value of $width and $height. - The memory buffer length in bytes is defined as $height x $stride. - - Warning: @.buffer_set MUST be called as soon as possible after - calling @.buffer_get. @.buffer_update_add should be called after - @.buffer_set if $to_write was $true and the pixel data has been - modified. Once @.buffer_set is called, the pointer returned by - @.buffer_get is not valid anymore. + Note: This is different from the legacy API data, which is now + replaced by map/unmap. ]] - params { -@in to_write: bool; [[If $true, requests write access]] -@out width: int @optional; -@out height: int @optional; -@out stride: int @optional; [[Returns the length
[EGIT] [core/efl] master 02/02: edje_cc: support hexadecimal color code
raster pushed a commit to branch master. http://git.enlightenment.org/core/efl.git/commit/?id=984a8f7f90e7457a3055101ec236a0f4288e179e commit 984a8f7f90e7457a3055101ec236a0f4288e179e Author: Jee-Yong UmDate: Mon Mar 28 15:36:41 2016 +0900 edje_cc: support hexadecimal color code Summary: Support hexadecimal color code in EDC. Four types of color code are acceptable. All values below mean 'Red'. (255 0 0 255) color: "#F00"; color: "#F00F"; color: "#FF"; color: "#FFFF"; Color code tables are usually provided with hexadecimal numbers. Supporting hexadecimal color code will allow developers to skip manual conversion hex to decimal. Test Plan: Test case will provided with seperated commit. Reviewers: cedric, jpeg, raster Reviewed By: raster Subscribers: raster Differential Revision: https://phab.enlightenment.org/D3831 --- src/bin/edje/edje_cc.h | 1 + src/bin/edje/edje_cc_handlers.c | 191 src/bin/edje/edje_cc_out.c | 99 + 3 files changed, 255 insertions(+), 36 deletions(-) diff --git a/src/bin/edje/edje_cc.h b/src/bin/edje/edje_cc.h index 159d7ca..65299b5 100644 --- a/src/bin/edje/edje_cc.h +++ b/src/bin/edje/edje_cc.h @@ -253,6 +253,7 @@ void edje_cc_handlers_pop_notify(const char *token); int get_param_index(char *str); void color_tree_root_free(void); +void convert_color_code(char *str, int *r, int *g, int *b, int *a); /* global vars */ extern Eina_List *ext_dirs; diff --git a/src/bin/edje/edje_cc_handlers.c b/src/bin/edje/edje_cc_handlers.c index 26f53ca..382f4bc 100644 --- a/src/bin/edje/edje_cc_handlers.c +++ b/src/bin/edje/edje_cc_handlers.c @@ -2803,14 +2803,34 @@ static void st_color_class_color(void) { Edje_Color_Class *cc; - - check_arg_count(4); + int nargs = get_arg_count(); cc = eina_list_data_get(eina_list_last(edje_file->color_classes)); - cc->r = parse_int_range(0, 0, 255); - cc->g = parse_int_range(1, 0, 255); - cc->b = parse_int_range(2, 0, 255); - cc->a = parse_int_range(3, 0, 255); + + if (nargs == 1) + { +int r, g, b, a; +char *str = parse_str(0); + +convert_color_code(str, , , , ); +cc->r = r; +cc->g = g; +cc->b = b; +cc->a = a; + } + else if (nargs == 4) + { +cc->r = parse_int_range(0, 0, 255); +cc->g = parse_int_range(1, 0, 255); +cc->b = parse_int_range(2, 0, 255); +cc->a = parse_int_range(3, 0, 255); + } + else + { +ERR("%s:%i. color code should be a string or a set of 4 integers.", +file_in, line - 1); +exit(-1); + } } /** @@ -2827,14 +2847,34 @@ static void st_color_class_color2(void) { Edje_Color_Class *cc; - - check_arg_count(4); + int nargs = get_arg_count(); cc = eina_list_data_get(eina_list_last(edje_file->color_classes)); - cc->r2 = parse_int_range(0, 0, 255); - cc->g2 = parse_int_range(1, 0, 255); - cc->b2 = parse_int_range(2, 0, 255); - cc->a2 = parse_int_range(3, 0, 255); + + if (nargs == 1) + { +int r, g, b, a; +char *str = parse_str(0); + +convert_color_code(str, , , , ); +cc->r2 = r; +cc->g2 = g; +cc->b2 = b; +cc->a2 = a; + } + else if (nargs == 4) + { +cc->r2 = parse_int_range(0, 0, 255); +cc->g2 = parse_int_range(1, 0, 255); +cc->b2 = parse_int_range(2, 0, 255); +cc->a2 = parse_int_range(3, 0, 255); + } + else + { +ERR("%s:%i. color code should be a string or a set of 4 integers.", +file_in, line - 1); +exit(-1); + } } /** @@ -2851,14 +2891,34 @@ static void st_color_class_color3(void) { Edje_Color_Class *cc; - - check_arg_count(4); + int nargs = get_arg_count(); cc = eina_list_data_get(eina_list_last(edje_file->color_classes)); - cc->r3 = parse_int_range(0, 0, 255); - cc->g3 = parse_int_range(1, 0, 255); - cc->b3 = parse_int_range(2, 0, 255); - cc->a3 = parse_int_range(3, 0, 255); + + if (nargs == 1) + { +int r, g, b, a; +char *str = parse_str(0); + +convert_color_code(str, , , , ); +cc->r3 = r; +cc->g3 = g; +cc->b3 = b; +cc->a3 = a; + } + else if (nargs == 4) + { +cc->r3 = parse_int_range(0, 0, 255); +cc->g3 = parse_int_range(1, 0, 255); +cc->b3 = parse_int_range(2, 0, 255); +cc->a3 = parse_int_range(3, 0, 255); + } + else + { +ERR("%s:%i. color code should be a string or a set of 4 integers.", +file_in, line - 1); +exit(-1); + } } /** @@ -8394,19 +8454,39 @@ st_collections_group_parts_part_description_color_class(void) static void st_collections_group_parts_part_description_color(void) { -
[EGIT] [core/efl] master 01/02: efl elm build: fix pc file requirements to be correctly named
raster pushed a commit to branch master. http://git.enlightenment.org/core/efl.git/commit/?id=f23f167d512cdf6d1525db5cb98df15f9d8a1972 commit f23f167d512cdf6d1525db5cb98df15f9d8a1972 Author: Carsten Haitzler (Rasterman)Date: Sat Mar 26 11:19:45 2016 +0900 efl elm build: fix pc file requirements to be correctly named this fixes ecore_drm, ecore_fb and ecore_wl2 requirements to be right have a - instead of an _. --- m4/efl.m4 | 9 + 1 file changed, 9 insertions(+) diff --git a/m4/efl.m4 b/m4/efl.m4 index d997915..7547c6e 100644 --- a/m4/efl.m4 +++ b/m4/efl.m4 @@ -159,6 +159,15 @@ case "m4_defn([DOWNOTHER])" in ecore_x) depname="ecore-x" ;; + ecore_wl2) + depname="ecore-wl2" + ;; + ecore_fb) + depname="ecore-fb" + ;; + ecore_drm) + depname="ecore-drm" + ;; esac requirements_pc_[]m4_defn([DOWNEFL])="${depname} >= ${PACKAGE_VERSION} ${requirements_pc_[][]m4_defn([DOWNEFL])}" requirements_cflags_[]m4_defn([DOWNEFL])="-I\$(top_srcdir)/src/lib/${libdirname} -I\$(top_builddir)/src/lib/${libdirname} ${requirements_cflags_[][]m4_defn([DOWNEFL])}" --
[EGIT] [tools/exactness-elm-data] master 01/01: Fix bad shots
jackdanielz pushed a commit to branch master. http://git.enlightenment.org/tools/exactness-elm-data.git/commit/?id=ca901c742e205088c6019afa4b6e2fd0235b9b22 commit ca901c742e205088c6019afa4b6e2fd0235b9b22 Author: Daniel ZaouiDate: Mon Mar 28 08:59:24 2016 +0300 Fix bad shots Even if the scroller has issues concerning its arrows colors, the shots have to be correct. --- default-profile/orig/flip_2+002.png | Bin 34143 -> 34064 bytes default-profile/orig/flip_2+003.png | Bin 34199 -> 34216 bytes default-profile/orig/flip_2+005.png | Bin 34199 -> 34216 bytes default-profile/orig/flip_2+006.png | Bin 34143 -> 34064 bytes default-profile/orig/flip_2+008.png | Bin 34143 -> 34064 bytes default-profile/orig/flip_interactive+004.png | Bin 147515 -> 147957 bytes 6 files changed, 0 insertions(+), 0 deletions(-) diff --git a/default-profile/orig/flip_2+002.png b/default-profile/orig/flip_2+002.png index 73be949..1c7830e 100644 Binary files a/default-profile/orig/flip_2+002.png and b/default-profile/orig/flip_2+002.png differ diff --git a/default-profile/orig/flip_2+003.png b/default-profile/orig/flip_2+003.png index 5a311a7..4ca7d71 100644 Binary files a/default-profile/orig/flip_2+003.png and b/default-profile/orig/flip_2+003.png differ diff --git a/default-profile/orig/flip_2+005.png b/default-profile/orig/flip_2+005.png index 5a311a7..4ca7d71 100644 Binary files a/default-profile/orig/flip_2+005.png and b/default-profile/orig/flip_2+005.png differ diff --git a/default-profile/orig/flip_2+006.png b/default-profile/orig/flip_2+006.png index 73be949..1c7830e 100644 Binary files a/default-profile/orig/flip_2+006.png and b/default-profile/orig/flip_2+006.png differ diff --git a/default-profile/orig/flip_2+008.png b/default-profile/orig/flip_2+008.png index 73be949..1c7830e 100644 Binary files a/default-profile/orig/flip_2+008.png and b/default-profile/orig/flip_2+008.png differ diff --git a/default-profile/orig/flip_interactive+004.png b/default-profile/orig/flip_interactive+004.png index a9ecaf4..c98e50a 100644 Binary files a/default-profile/orig/flip_interactive+004.png and b/default-profile/orig/flip_interactive+004.png differ --