aboutsummaryrefslogtreecommitdiffstats
path: root/src/examples
diff options
context:
space:
mode:
authorHermet Park <hermetpark@gmail.com>2019-03-11 16:05:08 +0900
committerHermet Park <hermetpark@gmail.com>2019-03-11 16:05:08 +0900
commit43e122d1de10c8c89d835101cc66794a14de8c84 (patch)
treef91e3da2638caa8ae2499fa28f73718a0ecc249a /src/examples
parentevas/vg: Adapt to the recent change in lottie api. (diff)
parentevas_canvas3d: add empty functions for missing APIs (diff)
downloadefl-43e122d1de10c8c89d835101cc66794a14de8c84.tar.gz
Merge branch 'master' into devs/hermet/lottie
Diffstat (limited to 'src/examples')
-rw-r--r--src/examples/ecore/efl_io_copier_example.c4
-rw-r--r--src/examples/ecore/efl_net_dialer_http_example.c4
-rw-r--r--src/examples/edje/meson.build3
-rw-r--r--src/examples/elementary/bg_cxx_example_02.cc3
-rw-r--r--src/examples/elementary/button_cxx_example_01.cc1
-rw-r--r--src/examples/elementary/combobox_example_01.c5
-rw-r--r--src/examples/elementary/efl_canvas_layout_text.c20
-rw-r--r--src/examples/elementary/efl_ui_grid_example_1.c3
-rw-r--r--src/examples/elementary/efl_ui_list_example_1.c31
-rw-r--r--src/examples/elementary/efl_ui_list_view_example_1.c1
-rw-r--r--src/examples/elementary/efl_ui_list_view_example_2.c1
-rw-r--r--src/examples/elementary/efl_ui_list_view_example_3.c1
-rw-r--r--src/examples/elementary/efl_ui_relative_layout_example_01.c3
-rw-r--r--src/examples/elementary/efl_ui_relative_layout_example_02.c3
-rw-r--r--src/examples/elementary/efl_ui_scroller_example.c3
-rw-r--r--src/examples/elementary/efl_ui_theme_example_01.c3
-rw-r--r--src/examples/elementary/efl_ui_theme_example_02.c3
-rw-r--r--src/examples/elementary/evas3d_map_example.c8
-rw-r--r--src/examples/elementary/evas3d_object_on_button_example.c10
-rw-r--r--src/examples/elementary/evas3d_scene_on_button_example.c9
-rw-r--r--src/examples/elementary/filemvc.c2
-rw-r--r--src/examples/elementary/hoversel_example_01.c18
-rw-r--r--src/examples/elementary/icon_cxx_example_01.cc4
-rw-r--r--src/examples/elementary/inwin_example.c2
-rw-r--r--src/examples/elementary/layout_property_bind.c33
-rw-r--r--src/examples/elementary/location_example_01.c9
-rw-r--r--src/examples/elementary/performance/camera_light.c14
-rw-r--r--src/examples/elementary/performance/graphical.c20
-rw-r--r--src/examples/elementary/performance/performance.c160
-rw-r--r--src/examples/elementary/performance/tools_private.h8
-rw-r--r--src/examples/elementary/popup_cxx_example.cc5
-rw-r--r--src/examples/elementary/radio_cxx_example_01.cc1
-rw-r--r--src/examples/elementary/slider_cxx_example.cc1
-rw-r--r--src/examples/elementary/sphere_hunter/evas_3d_sphere_hunter.c12
-rw-r--r--src/examples/elementary/toolbar_cxx_example_01.cc17
-rw-r--r--src/examples/elementary/web_example_01.c4
-rw-r--r--src/examples/elementary/web_example_02.c4
-rw-r--r--src/examples/evas.mk56
-rw-r--r--src/examples/evas/evas-3d-aabb.c4
-rw-r--r--src/examples/evas/evas-3d-colorpick.c2
-rw-r--r--src/examples/evas/evas-3d-cube2.c2
-rw-r--r--src/examples/evas/evas-3d-eet.c4
-rw-r--r--src/examples/evas/evas-3d-frustum.c4
-rw-r--r--src/examples/evas/evas-3d-hull.c2
-rw-r--r--src/examples/evas/evas-3d-md2.c4
-rw-r--r--src/examples/evas/evas-3d-mmap-set.c2
-rw-r--r--src/examples/evas/evas-3d-obj.c4
-rw-r--r--src/examples/evas/evas-3d-parallax-occlusion.c8
-rw-r--r--src/examples/evas/evas-3d-pick.c2
-rw-r--r--src/examples/evas/evas-3d-ply.c6
-rw-r--r--src/examples/evas/evas-3d-shadows.c10
-rw-r--r--src/examples/evas/evas-3d-static-lod.c4
-rw-r--r--src/examples/evas/evas-object-manipulation-eo.c17
-rw-r--r--src/examples/evas/evas-vg-batman.c6
-rw-r--r--src/examples/evas/evas-vg-simple.c38
-rw-r--r--src/examples/evas/evas_cxx_rectangle.cc4
-rw-r--r--src/examples/evas/evas_mono_box.cs73
-rw-r--r--src/examples/evas/evas_mono_image.cs93
-rw-r--r--src/examples/evas/evas_mono_image2.cs83
-rw-r--r--src/examples/evas/evas_mono_rectangle.cs47
-rw-r--r--src/examples/evas/evas_mono_table.cs77
-rw-r--r--src/examples/evas/evas_mono_text.cs127
-rw-r--r--src/examples/evas/shooter/evas-3d-shooter-macros.h8
-rw-r--r--src/examples/evas/shooter/evas-3d-shooter.c10
64 files changed, 308 insertions, 822 deletions
diff --git a/src/examples/ecore/efl_io_copier_example.c b/src/examples/ecore/efl_io_copier_example.c
index 25a81140bd..13f26b8577 100644
--- a/src/examples/ecore/efl_io_copier_example.c
+++ b/src/examples/ecore/efl_io_copier_example.c
@@ -664,7 +664,7 @@ efl_main(void *data EINA_UNUSED,
{
/* regular file, open with flags: read-only and close-on-exec */
input = efl_add_ref(EFL_IO_FILE_CLASS, NULL,
- efl_file_set(efl_added, input_fname, NULL), /* mandatory */
+ efl_file_set(efl_added, input_fname), /* mandatory */
efl_io_file_flags_set(efl_added, O_RDONLY), /* default */
efl_io_closer_close_on_exec_set(efl_added, EINA_TRUE), /* recommended, set *after* flags, or include O_CLOEXEC in flags -- be careful with _WIN32 that doesn't support it. */
efl_event_callback_array_add(efl_added, input_cbs(), NULL) /* optional */
@@ -940,7 +940,7 @@ efl_main(void *data EINA_UNUSED,
* create if did not exist and truncate if exist.
*/
output = efl_add_ref(EFL_IO_FILE_CLASS, NULL,
- efl_file_set(efl_added, output_fname, NULL), /* mandatory */
+ efl_file_set(efl_added, output_fname), /* mandatory */
efl_io_file_flags_set(efl_added, O_WRONLY | O_CREAT | O_TRUNC), /* mandatory for write */
efl_io_closer_close_on_exec_set(efl_added, EINA_TRUE), /* recommended, set *after* flags, or include O_CLOEXEC in flags -- be careful with _WIN32 that doesn't support it. */
efl_io_file_mode_set(efl_added, 0644), /* mandatory for write */
diff --git a/src/examples/ecore/efl_net_dialer_http_example.c b/src/examples/ecore/efl_net_dialer_http_example.c
index 70861dc438..02783dc165 100644
--- a/src/examples/ecore/efl_net_dialer_http_example.c
+++ b/src/examples/ecore/efl_net_dialer_http_example.c
@@ -321,7 +321,7 @@ efl_main(void *data EINA_UNUSED,
{
input = efl_add(EFL_IO_FILE_CLASS, loop,
efl_name_set(efl_added, "input"),
- efl_file_set(efl_added, input_fname, NULL),
+ efl_file_set(efl_added, input_fname),
efl_io_file_flags_set(efl_added, O_RDONLY),
efl_io_closer_close_on_exec_set(efl_added, EINA_TRUE), /* recommended, set *after* flags, or include O_CLOEXEC in flags -- be careful with _WIN32 that doesn't support it. */
efl_event_callback_add(efl_added, EFL_IO_READER_EVENT_EOS, _eos, NULL));
@@ -336,7 +336,7 @@ efl_main(void *data EINA_UNUSED,
{
output = efl_add(EFL_IO_FILE_CLASS, loop,
efl_name_set(efl_added, "output"),
- efl_file_set(efl_added, output_fname, NULL),
+ efl_file_set(efl_added, output_fname),
efl_io_file_mode_set(efl_added, 0644),
efl_io_file_flags_set(efl_added, O_WRONLY | O_TRUNC | O_CREAT),
efl_io_closer_close_on_exec_set(efl_added, EINA_TRUE)); /* recommended, set *after* flags, or include O_CLOEXEC in flags -- be careful with _WIN32 that doesn't support it. */
diff --git a/src/examples/edje/meson.build b/src/examples/edje/meson.build
index fce9230575..d73c83a199 100644
--- a/src/examples/edje/meson.build
+++ b/src/examples/edje/meson.build
@@ -91,8 +91,7 @@ codegen = custom_target('edje_cc_codegen_edc',
themes += custom_target('edje_codegen_codegen.edj',
input : codegen,
output : ['@BASENAME@_example_generated.c', '@BASENAME@_example_generated.h'],
- command : ['/usr/bin/env', 'EFL_RUN_IN_TREE=1', edje_codegen.full_path(),
- '--prefix=codegen_example', '@INPUT@',
+ command : edje_codegen_exe + [ '--prefix=codegen_example', '@INPUT@',
'example_group', '@OUTPUT0@', '@OUTPUT1@'],
depends : [edje_codegen, themes])
diff --git a/src/examples/elementary/bg_cxx_example_02.cc b/src/examples/elementary/bg_cxx_example_02.cc
index 71c3540d98..94c17e3dcf 100644
--- a/src/examples/elementary/bg_cxx_example_02.cc
+++ b/src/examples/elementary/bg_cxx_example_02.cc
@@ -31,7 +31,8 @@ efl_main(void *data EINA_UNUSED, const Efl_Event *ev)
efl::ui::Bg bg(instantiate, win);
bg.scale_type_set(EFL_GFX_IMAGE_SCALE_TYPE_FILL);
- bg.file_set(path, nullptr);
+ bg.file_set(path);
+ bg.load();
win.content_set(bg);
win.size_set({640, 400});
diff --git a/src/examples/elementary/button_cxx_example_01.cc b/src/examples/elementary/button_cxx_example_01.cc
index 8b0364744c..c818897fbb 100644
--- a/src/examples/elementary/button_cxx_example_01.cc
+++ b/src/examples/elementary/button_cxx_example_01.cc
@@ -1,6 +1,7 @@
// g++ -g `pkg-config --cflags --libs elementary-cxx efl-cxx eina-cxx eo-cxx ecore-cxx evas-cxx edje-cxx` button_cxx_example_01.cc -o button_cxx_example_01
#define EFL_CXXPERIMENTAL
+#include <Efl_Ui.h>
#include <Elementary.hh>
using efl::eo::instantiate;
diff --git a/src/examples/elementary/combobox_example_01.c b/src/examples/elementary/combobox_example_01.c
index 186e17e68c..ca450b26a4 100644
--- a/src/examples/elementary/combobox_example_01.c
+++ b/src/examples/elementary/combobox_example_01.c
@@ -1,7 +1,8 @@
//Compile with:
//gcc -o combobox_example_01 combobox_example_01.c -g `pkg-config --cflags --libs elementary`
-
-#define _GNU_SOURCE
+#ifndef _GNU_SOURCE
+# define _GNU_SOURCE
+#endif
#include <string.h>
#include <Elementary.h>
diff --git a/src/examples/elementary/efl_canvas_layout_text.c b/src/examples/elementary/efl_canvas_layout_text.c
index 8e89403d19..da0e089c01 100644
--- a/src/examples/elementary/efl_canvas_layout_text.c
+++ b/src/examples/elementary/efl_canvas_layout_text.c
@@ -10,6 +10,7 @@
#endif
#include <Efl.h>
+#include <Efl_Ui.h>
#include <Elementary.h>
#include <string.h>
@@ -39,17 +40,6 @@ static struct
static struct
{
- Efl_Text_Format_Wrap wrap;
- const char *desc;
-} group[] =
-{
- { EFL_TEXT_FORMAT_WRAP_NONE, "none" },
- { EFL_TEXT_FORMAT_WRAP_WORD, "word" },
- { EFL_TEXT_FORMAT_WRAP_CHAR, "char" },
- { EFL_TEXT_FORMAT_WRAP_MIXED, "mixed" }
-};
-static struct
-{
Efl_Canvas_Layout_Part_Text_Expand expand;
const char *desc;
} expands[] =
@@ -88,7 +78,7 @@ _on_key_down(void *data, const Efl_Event *event)
{
// edje group
group_itr = (group_itr + 1) % 2;
- efl_file_set(layout, edjefile, groups[group_itr]);
+ efl_file_simple_load(layout, edjefile, groups[group_itr]);
printf("Changed layout group to: %s\n", groups[group_itr]);
}
else if (!strcmp(key, "w"))
@@ -125,21 +115,21 @@ _on_key_down(void *data, const Efl_Event *event)
EAPI_MAIN void
efl_main(void *data EINA_UNUSED,
- const Efl_Event *ev)
+ const Efl_Event *ev EINA_UNUSED)
{
Eo *layout;
Eo *win;
win = efl_add(EFL_UI_WIN_CLASS, NULL,
- efl_ui_win_type_set(efl_added, EFL_UI_WIN_BASIC),
+ efl_ui_win_type_set(efl_added, EFL_UI_WIN_TYPE_BASIC),
efl_text_set(efl_added, "Efl Canvas_Layout"),
efl_ui_win_autodel_set(efl_added, EINA_TRUE),
efl_event_callback_add(efl_added, EFL_UI_WIN_EVENT_DELETE_REQUEST, _on_win_delete, NULL));
layout = efl_add(EFL_CANVAS_LAYOUT_CLASS, win);
- efl_file_set(layout, edjefile, groups[group_itr]);
+ efl_file_simple_load(layout, edjefile, groups[group_itr]);
efl_content_set(win, layout);
efl_gfx_entity_size_set(win, EINA_SIZE2D(110, 100));
diff --git a/src/examples/elementary/efl_ui_grid_example_1.c b/src/examples/elementary/efl_ui_grid_example_1.c
index b2960bb04b..92379fe6e4 100644
--- a/src/examples/elementary/efl_ui_grid_example_1.c
+++ b/src/examples/elementary/efl_ui_grid_example_1.c
@@ -7,6 +7,7 @@
#define EFL_EO_API_SUPPORT 1
#endif
+#include <Efl_Ui.h>
#include <Elementary.h>
#include <Efl.h>
#include <stdio.h>
@@ -39,7 +40,7 @@ elm_main(int argc, char **argv)
Grid_Event_Data *gd = calloc(sizeof(Grid_Event_Data *), 1);
win = efl_add(EFL_UI_WIN_CLASS, efl_main_loop_get(),
- efl_ui_win_type_set(efl_added, EFL_UI_WIN_BASIC),
+ efl_ui_win_type_set(efl_added, EFL_UI_WIN_TYPE_BASIC),
efl_text_set(efl_added, "Efl.Ui.Grid"),
efl_ui_win_autodel_set(efl_added, EINA_TRUE));
diff --git a/src/examples/elementary/efl_ui_list_example_1.c b/src/examples/elementary/efl_ui_list_example_1.c
index b52cc0e9ed..bf22dfb441 100644
--- a/src/examples/elementary/efl_ui_list_example_1.c
+++ b/src/examples/elementary/efl_ui_list_example_1.c
@@ -8,6 +8,7 @@
# define EFL_EO_API_SUPPORT 1
#endif
+#include <Efl_Ui.h>
#include <Elementary.h>
#include <Efl.h>
#include <Eio.h>
@@ -24,7 +25,7 @@ List_Scroll_Data priv_d;
static void
-_list_selected(void *data, const Efl_Event *ev)
+_list_selected(void *data EINA_UNUSED, const Efl_Event *ev)
{
Eo *list = ev->object;
Eo *item = ev->info, *tmp;
@@ -39,28 +40,28 @@ _list_selected(void *data, const Efl_Event *ev)
}
static void
-_list_unselected(void *data, const Efl_Event *ev)
+_list_unselected(void *data EINA_UNUSED, const Efl_Event *ev)
{
Eo *item = ev->info;
printf("list item [%p : %d] is %s\n", item, efl_ui_item_index_get(item), (efl_ui_item_selected_get(item)? "selected" : "unselected"));
}
static void
-_list_pressed(void *data, const Efl_Event *ev)
+_list_pressed(void *data EINA_UNUSED, const Efl_Event *ev)
{
Eo *item = ev->info;
printf("list item [%p : %d] is pressed\n", item, efl_ui_item_index_get(item));
}
static void
-_list_unpressed(void *data, const Efl_Event *ev)
+_list_unpressed(void *data EINA_UNUSED, const Efl_Event *ev)
{
Eo *item = ev->info;
printf("list item [%p : %d] is unpressed\n", item, efl_ui_item_index_get(item));
}
static void
-_list_longpressed(void *data, const Efl_Event *ev)
+_list_longpressed(void *data EINA_UNUSED, const Efl_Event *ev)
{
Eo *item = ev->info;
printf("list item [%p : %d] is longpressed\n", item, efl_ui_item_index_get(item));
@@ -74,13 +75,13 @@ _select_radio_changed(void *data, const Efl_Event *ev)
}
static void
-_anim_radio_changed(void *data, const Efl_Event *ev)
+_anim_radio_changed(void *data EINA_UNUSED, const Efl_Event *ev)
{
priv_d.anim = efl_ui_radio_state_value_get(ev->object);
}
static void
-_scrl_btn_clicked(void *data, const Efl_Event *ev)
+_scrl_btn_clicked(void *data EINA_UNUSED, const Efl_Event *ev EINA_UNUSED)
{
Efl_Ui_List_Item *item = efl_ui_list_last_selected_item_get(priv_d.list);
printf("show [%d:%p] [%d]\n", efl_ui_item_index_get(item), item, priv_d.anim);
@@ -88,7 +89,7 @@ _scrl_btn_clicked(void *data, const Efl_Event *ev)
}
static void
-_scrl_align_btn_clicked(void *data, const Efl_Event *ev)
+_scrl_align_btn_clicked(void *data EINA_UNUSED, const Efl_Event *ev EINA_UNUSED)
{
Efl_Ui_List_Item *item = efl_ui_list_last_selected_item_get(priv_d.list);
double align = efl_ui_range_value_get(priv_d.slider);
@@ -97,7 +98,7 @@ _scrl_align_btn_clicked(void *data, const Efl_Event *ev)
}
EAPI_MAIN int
-elm_main(int argc, char **argv)
+elm_main(int argc EINA_UNUSED, char **argv)
{
Eo *win, *list;
Eo *wbox, *ibox, *bbox, *rbox;
@@ -197,13 +198,13 @@ elm_main(int argc, char **argv)
break;
case 40:
- efl_file_set(efl_part(item, "background"), "./sky_01.jpg", NULL);
+ efl_file_simple_load(efl_part(item, "background"), "./sky_01.jpg", NULL);
efl_gfx_image_scale_type_set(efl_part(item, "background"), EFL_GFX_IMAGE_SCALE_TYPE_FIT_OUTSIDE);
efl_pack_at(list, item, 39);
break;
case 50:
- efl_file_set(efl_part(item, "background"), "./sky_01.jpg", NULL);
+ efl_file_simple_load(efl_part(item, "background"), "./sky_01.jpg", NULL);
efl_gfx_image_scale_type_set(efl_part(item, "background"), EFL_GFX_IMAGE_SCALE_TYPE_TILE);
efl_pack(list, item);
break;
@@ -235,24 +236,24 @@ elm_main(int argc, char **argv)
select_radio = radio = efl_add(EFL_UI_RADIO_CLASS, wbox);
efl_text_set(radio, "SINGLE");
- efl_ui_radio_state_value_set(radio, EFL_UI_SELECT_SINGLE);
+ efl_ui_radio_state_value_set(radio, EFL_UI_SELECT_MODE_SINGLE);
efl_event_callback_add(radio, EFL_UI_RADIO_EVENT_CHANGED, _select_radio_changed, list);
efl_pack_end(bbox, radio);
radio = efl_add(EFL_UI_RADIO_CLASS, wbox);
efl_text_set(radio, "SINGLE_ALWAYS");
- efl_ui_radio_state_value_set(radio, EFL_UI_SELECT_SINGLE_ALWAYS);
+ efl_ui_radio_state_value_set(radio, EFL_UI_SELECT_MODE_SINGLE_ALWAYS);
efl_ui_radio_group_add(radio, select_radio);
efl_event_callback_add(radio, EFL_UI_RADIO_EVENT_CHANGED, _select_radio_changed, list);
efl_pack_end(bbox, radio);
radio = efl_add(EFL_UI_RADIO_CLASS, wbox);
efl_text_set(radio, "MULTI");
- efl_ui_radio_state_value_set(radio, EFL_UI_SELECT_MULTI);
+ efl_ui_radio_state_value_set(radio, EFL_UI_SELECT_MODE_MULTI);
efl_ui_radio_group_add(radio, select_radio);
efl_event_callback_add(radio, EFL_UI_RADIO_EVENT_CHANGED, _select_radio_changed, list);
efl_pack_end(bbox, radio);
radio = efl_add(EFL_UI_RADIO_CLASS, wbox);
efl_text_set(radio, "NONE");
- efl_ui_radio_state_value_set(radio, EFL_UI_SELECT_NONE);
+ efl_ui_radio_state_value_set(radio, EFL_UI_SELECT_MODE_NONE);
efl_ui_radio_group_add(radio, select_radio);
efl_event_callback_add(radio, EFL_UI_RADIO_EVENT_CHANGED, _select_radio_changed, list);
efl_pack_end(bbox, radio);
diff --git a/src/examples/elementary/efl_ui_list_view_example_1.c b/src/examples/elementary/efl_ui_list_view_example_1.c
index 597d6c3ed1..3943a7793b 100644
--- a/src/examples/elementary/efl_ui_list_view_example_1.c
+++ b/src/examples/elementary/efl_ui_list_view_example_1.c
@@ -7,6 +7,7 @@
# define EFL_EO_API_SUPPORT 1
#endif
+#include <Efl_Ui.h>
#include <Elementary.h>
#include <Efl.h>
#include <Eio.h>
diff --git a/src/examples/elementary/efl_ui_list_view_example_2.c b/src/examples/elementary/efl_ui_list_view_example_2.c
index 8721342fd6..8e47d9222a 100644
--- a/src/examples/elementary/efl_ui_list_view_example_2.c
+++ b/src/examples/elementary/efl_ui_list_view_example_2.c
@@ -7,6 +7,7 @@
# define EFL_EO_API_SUPPORT 1
#endif
+#include <Efl_Ui.h>
#include <Elementary.h>
#include <Efl.h>
#include <Eio.h>
diff --git a/src/examples/elementary/efl_ui_list_view_example_3.c b/src/examples/elementary/efl_ui_list_view_example_3.c
index 5c2b3a8217..9cc4c8efde 100644
--- a/src/examples/elementary/efl_ui_list_view_example_3.c
+++ b/src/examples/elementary/efl_ui_list_view_example_3.c
@@ -10,6 +10,7 @@
#define ELM_INTERFACE_ATSPI_SELECTION_PROTECTED
#include <Eo.h>
+#include <Efl_Ui.h>
#include <Elementary.h>
#include <Efl.h>
#include <Eio.h>
diff --git a/src/examples/elementary/efl_ui_relative_layout_example_01.c b/src/examples/elementary/efl_ui_relative_layout_example_01.c
index 36ebd3f545..7ccec35651 100644
--- a/src/examples/elementary/efl_ui_relative_layout_example_01.c
+++ b/src/examples/elementary/efl_ui_relative_layout_example_01.c
@@ -7,6 +7,7 @@
#define EFL_EO_API_SUPPORT 1
#endif
+#include <Efl_Ui.h>
#include <Elementary.h>
#include <Efl.h>
@@ -16,7 +17,7 @@ elm_main(int argc, char **argv)
Eo *win, *layout, *btn1, *btn2, *btn3;
win = efl_add(EFL_UI_WIN_CLASS, efl_main_loop_get(),
- efl_ui_win_type_set(efl_added, EFL_UI_WIN_BASIC),
+ efl_ui_win_type_set(efl_added, EFL_UI_WIN_TYPE_BASIC),
efl_text_set(efl_added, "Efl.Ui.Relative_Layout"),
efl_ui_win_autodel_set(efl_added, EINA_TRUE));
diff --git a/src/examples/elementary/efl_ui_relative_layout_example_02.c b/src/examples/elementary/efl_ui_relative_layout_example_02.c
index db21b15aba..14af786cd6 100644
--- a/src/examples/elementary/efl_ui_relative_layout_example_02.c
+++ b/src/examples/elementary/efl_ui_relative_layout_example_02.c
@@ -7,6 +7,7 @@
#define EFL_EO_API_SUPPORT 1
#endif
+#include <Efl_Ui.h>
#include <Elementary.h>
#include <Efl.h>
@@ -16,7 +17,7 @@ elm_main(int argc, char **argv)
Eo *win, *layout, *btn1, *btn2;
win = efl_add(EFL_UI_WIN_CLASS, efl_main_loop_get(),
- efl_ui_win_type_set(efl_added, EFL_UI_WIN_BASIC),
+ efl_ui_win_type_set(efl_added, EFL_UI_WIN_TYPE_BASIC),
efl_text_set(efl_added, "Efl.Ui.Relative_Layout"),
efl_ui_win_autodel_set(efl_added, EINA_TRUE));
diff --git a/src/examples/elementary/efl_ui_scroller_example.c b/src/examples/elementary/efl_ui_scroller_example.c
index 4de4d216a3..e76254d8aa 100644
--- a/src/examples/elementary/efl_ui_scroller_example.c
+++ b/src/examples/elementary/efl_ui_scroller_example.c
@@ -4,6 +4,7 @@
#define EFL_BETA_API_SUPPORT
#define EFL_EO_API_SUPPORT
+#include <Efl_Ui.h>
#include <Elementary.h>
EAPI_MAIN void
@@ -24,7 +25,7 @@ efl_main(void *data EINA_UNUSED, const Efl_Event *ev)
content = efl_add(EFL_UI_IMAGE_CLASS, scroller);
snprintf(buf, sizeof(buf), "%s/images/plant_01.jpg", elm_app_data_dir_get());
- efl_file_set(content, buf, NULL);
+ efl_file_simple_load(content, buf, NULL);
efl_gfx_entity_size_set(content, EINA_SIZE2D(5000, 5000));
efl_content_set(scroller, content);
}
diff --git a/src/examples/elementary/efl_ui_theme_example_01.c b/src/examples/elementary/efl_ui_theme_example_01.c
index 601dd5c8af..29614c8f3b 100644
--- a/src/examples/elementary/efl_ui_theme_example_01.c
+++ b/src/examples/elementary/efl_ui_theme_example_01.c
@@ -6,6 +6,7 @@
#define EFL_EO_API_SUPPORT 1
#define EFL_UI_WIDGET_PROTECTED
+#include <Efl_Ui.h>
#include <Elementary.h>
#define EXAMPLE_EDJ_FILE_PATH "./efl_ui_theme_example.edj"
@@ -52,7 +53,7 @@ efl_main(void *data EINA_UNUSED, const Efl_Event *ev EINA_UNUSED)
efl_ui_theme_extension_add(default_theme, EXAMPLE_EDJ_FILE_PATH);
win = efl_add(EFL_UI_WIN_CLASS, efl_main_loop_get(),
- efl_ui_win_type_set(efl_added, EFL_UI_WIN_BASIC),
+ efl_ui_win_type_set(efl_added, EFL_UI_WIN_TYPE_BASIC),
efl_text_set(efl_added, "Efl.Ui.Theme example"),
efl_ui_win_autodel_set(efl_added, EINA_TRUE)
);
diff --git a/src/examples/elementary/efl_ui_theme_example_02.c b/src/examples/elementary/efl_ui_theme_example_02.c
index a8c81de1dc..b78dc73f0b 100644
--- a/src/examples/elementary/efl_ui_theme_example_02.c
+++ b/src/examples/elementary/efl_ui_theme_example_02.c
@@ -6,6 +6,7 @@
#define EFL_EO_API_SUPPORT 1
#define EFL_UI_WIDGET_PROTECTED
+#include <Efl_Ui.h>
#include <Elementary.h>
#define EXAMPLE_EDJ_FILE_PATH "./efl_ui_theme_example.edj"
@@ -52,7 +53,7 @@ efl_main(void *data EINA_UNUSED, const Efl_Event *ev EINA_UNUSED)
efl_ui_theme_overlay_add(default_theme, EXAMPLE_EDJ_FILE_PATH);
win = efl_add(EFL_UI_WIN_CLASS, efl_main_loop_get(),
- efl_ui_win_type_set(efl_added, EFL_UI_WIN_BASIC),
+ efl_ui_win_type_set(efl_added, EFL_UI_WIN_TYPE_BASIC),
efl_text_set(efl_added, "Efl.Ui.Theme example"),
efl_ui_win_autodel_set(efl_added, EINA_TRUE)
);
diff --git a/src/examples/elementary/evas3d_map_example.c b/src/examples/elementary/evas3d_map_example.c
index 5426d30966..6ce53290e3 100644
--- a/src/examples/elementary/evas3d_map_example.c
+++ b/src/examples/elementary/evas3d_map_example.c
@@ -1,5 +1,9 @@
-#define EFL_BETA_API_SUPPORT
-#define EFL_EO_API_SUPPORT
+#ifndef EFL_EO_API_SUPPORT
+# define EFL_EO_API_SUPPORT
+#endif
+#ifndef EFL_BETA_API_SUPPORT
+# define EFL_BETA_API_SUPPORT
+#endif
#include <Elementary.h>
diff --git a/src/examples/elementary/evas3d_object_on_button_example.c b/src/examples/elementary/evas3d_object_on_button_example.c
index e77d74be3d..8b6724aacd 100644
--- a/src/examples/elementary/evas3d_object_on_button_example.c
+++ b/src/examples/elementary/evas3d_object_on_button_example.c
@@ -5,10 +5,12 @@
* Compile with:
* gcc -o evas3d_object_on_button_example evas3d_object_on_button_example.c -g `pkg-config --libs --cflags evas ecore eo elementary`
*/
-
-
-#define EFL_BETA_API_SUPPORT
-#define EFL_EO_API_SUPPORT
+#ifndef EFL_BETA_API_SUPPORT
+# define EFL_BETA_API_SUPPORT
+#endif
+#ifndef EFL_EO_API_SUPPORT
+# define EFL_EO_API_SUPPORT
+#endif
#include <Eo.h>
#include <Evas.h>
diff --git a/src/examples/elementary/evas3d_scene_on_button_example.c b/src/examples/elementary/evas3d_scene_on_button_example.c
index 8f47c7e080..05817990ad 100644
--- a/src/examples/elementary/evas3d_scene_on_button_example.c
+++ b/src/examples/elementary/evas3d_scene_on_button_example.c
@@ -5,9 +5,12 @@
* Compile with:
* gcc -o evas3d_scene_on_button_example evas3d_scene_on_button_example.c -g `pkg-config --libs --cflags evas ecore eo elementary`
*/
-
-#define EFL_BETA_API_SUPPORT
-#define EFL_EO_API_SUPPORT
+#ifndef EFL_EO_API_SUPPORT
+# define EFL_EO_API_SUPPORT
+#endif
+#ifndef EFL_BETA_API_SUPPORT
+# define EFL_BETA_API_SUPPORT
+#endif
#define WIDTH 500
#define HEIGHT 500
diff --git a/src/examples/elementary/filemvc.c b/src/examples/elementary/filemvc.c
index 051d5f4ccc..2aa0a54e85 100644
--- a/src/examples/elementary/filemvc.c
+++ b/src/examples/elementary/filemvc.c
@@ -38,7 +38,7 @@ _cleanup_cb(void *data, Evas *e EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void
}
static int
-_filter_cb(void *data EINA_UNUSED, Efl_Io_Model *model, Eina_File_Direct_Info *info)
+_filter_cb(void *data EINA_UNUSED, Efl_Io_Model *model EINA_UNUSED, Eina_File_Direct_Info *info)
{
if (info->type == EINA_FILE_DIR && info->path[info->name_start] != '.') return 1;
diff --git a/src/examples/elementary/hoversel_example_01.c b/src/examples/elementary/hoversel_example_01.c
index 289996cf24..7ce97bb503 100644
--- a/src/examples/elementary/hoversel_example_01.c
+++ b/src/examples/elementary/hoversel_example_01.c
@@ -4,7 +4,6 @@
#include <Elementary.h>
static void _print_items(void *data, Evas_Object *obj, void *event_info);
-static void _free(void *data, Evas_Object *obj, void *event_info);
static void _add_item(void *data, Evas_Object *obj, void *event_info);
static void
@@ -108,21 +107,12 @@ static void
_add_item(void *data EINA_UNUSED, Evas_Object *obj, void *event_info EINA_UNUSED)
{
static int num = 0;
- char *str = malloc(sizeof(char) * 11);
- Elm_Object_Item *hoversel_it;
+ Eina_Slstr *str;
if(is_eng)
- snprintf(str, 11, "item %d", ++num);
+ str = eina_slstr_printf("item %d", ++num);
else
- snprintf(str, 11, "بند %d", ++num);
-
- hoversel_it = elm_hoversel_item_add(obj, str, NULL, ELM_ICON_NONE, NULL,
- str);
- elm_object_item_del_cb_set(hoversel_it, _free);
-}
+ str = eina_slstr_printf("بند %d", ++num);
-static void
-_free(void *data, Evas_Object *obj EINA_UNUSED, void *event_info EINA_UNUSED)
-{
- free(data);
+ elm_hoversel_item_add(obj, str, NULL, ELM_ICON_NONE, NULL, str);
}
diff --git a/src/examples/elementary/icon_cxx_example_01.cc b/src/examples/elementary/icon_cxx_example_01.cc
index 88f9f95502..6252ce1cc0 100644
--- a/src/examples/elementary/icon_cxx_example_01.cc
+++ b/src/examples/elementary/icon_cxx_example_01.cc
@@ -14,8 +14,8 @@ elm_main (int argc EINA_UNUSED, char **argv EINA_UNUSED)
efl::ui::Image icon(instantiate, win);
icon.icon_set("home");
- efl::eina::string_view path, group;
- icon.file_get(path, group);
+ efl::eina::string_view path = icon.file_get();
+ efl::eina::string_view group = icon.key_get();
std::cout << "path = " << path << ", group = "<< group;
std::cout << ", name = " << icon.icon_get() << std::endl;
diff --git a/src/examples/elementary/inwin_example.c b/src/examples/elementary/inwin_example.c
index 48b9820246..76dbffa2ee 100644
--- a/src/examples/elementary/inwin_example.c
+++ b/src/examples/elementary/inwin_example.c
@@ -134,7 +134,7 @@ elm_main(int argc EINA_UNUSED, char **argv EINA_UNUSED)
evas_object_smart_callback_add(o, "clicked", _btn_click_cb, NULL);
- if (!strncmp(elm_config_engine_get(), "shot", 4))
+ if (!strncmp(elm_config_preferred_engine_get(), "shot", 4))
ecore_timer_add(0.1, _screenshot_hack_cb, o);
evas_object_resize(win, 400, 400);
diff --git a/src/examples/elementary/layout_property_bind.c b/src/examples/elementary/layout_property_bind.c
index b5915ae62c..3277288c16 100644
--- a/src/examples/elementary/layout_property_bind.c
+++ b/src/examples/elementary/layout_property_bind.c
@@ -7,6 +7,7 @@
# define EFL_EO_API_SUPPORT 1
#endif
+#include <Efl_Ui.h>
#include <Elementary.h>
#include <Efl.h>
#include <Eio.h>
@@ -22,9 +23,24 @@ struct _Layout_Model_Data
Evas_Object *entry;
Evas_Object *img;
Evas_Object *bt;
+ Evas_Object *bxr;
};
typedef struct _Layout_Model_Data Layout_Model_Data;
+static Eina_Value
+_wait_for_image(Eo *o EINA_UNUSED, void *data, const Eina_Value v)
+{
+ Layout_Model_Data *priv = data;
+
+ priv->img = eina_value_object_get(&v);
+ elm_box_pack_end(priv->bxr, priv->img);
+ evas_object_size_hint_weight_set(priv->img, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
+ evas_object_size_hint_align_set(priv->img, EVAS_HINT_FILL, EVAS_HINT_FILL);
+ evas_object_show(priv->img);
+
+ return v;
+}
+
static void
_cleanup_cb(void *data, Evas *e EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void *event_info EINA_UNUSED)
{
@@ -46,7 +62,6 @@ _list_selected_cb(void *data EINA_UNUSED, const Efl_Event *event)
efl_ui_view_model_set(priv->bt, child);
}
-
static void
_update_cb(void *data, Evas_Object *obj EINA_UNUSED, void *ev EINA_UNUSED)
{
@@ -78,7 +93,6 @@ _label_init(Evas_Object *win, Evas_Object *box, const char *text)
return widget;
}
-
static void
_signal_cb(void *data EINA_UNUSED,
Evas_Object *obj EINA_UNUSED,
@@ -111,10 +125,10 @@ elm_main(int argc EINA_UNUSED, char **argv EINA_UNUSED)
if (argv[1] != NULL) dirname = argv[1];
else dirname = EFL_MODEL_TEST_FILENAME_PATH;
- priv->model = efl_add(EFL_IO_MODEL_CLASS, win, efl_io_model_path_set(efl_added, dirname));
+ priv->model = efl_add_ref(EFL_IO_MODEL_CLASS, win, efl_io_model_path_set(efl_added, dirname));
genlist = elm_genlist_add(win);
- priv->fileview = efl_add(ELM_VIEW_LIST_CLASS, win, elm_view_list_genlist_set(efl_added, genlist, ELM_GENLIST_ITEM_NONE, NULL));
+ priv->fileview = efl_add_ref(ELM_VIEW_LIST_CLASS, win, elm_view_list_genlist_set(efl_added, genlist, ELM_GENLIST_ITEM_NONE, NULL));
elm_view_list_property_connect(priv->fileview, "filename", "elm.text");
elm_view_list_model_set(priv->fileview, priv->model);
_widget_init(genlist);
@@ -123,6 +137,7 @@ elm_main(int argc EINA_UNUSED, char **argv EINA_UNUSED)
efl_event_callback_add(priv->fileview, ELM_VIEW_LIST_EVENT_MODEL_SELECTED, _list_selected_cb, priv);
bxr = elm_box_add(win);
+ priv->bxr = bxr;
_widget_init(bxr);
elm_object_part_content_set(panes, "right", bxr);
@@ -154,11 +169,9 @@ elm_main(int argc EINA_UNUSED, char **argv EINA_UNUSED)
efl_ui_property_bind(img_factory, "", "path"); //connect to "path" property
efl_ui_factory_bind(priv->bt, "icon", img_factory);
- priv->img = efl_ui_factory_create(img_factory, NULL, win);
- elm_box_pack_end(bxr, priv->img);
- evas_object_size_hint_weight_set(priv->img, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
- evas_object_size_hint_align_set(priv->img, EVAS_HINT_FILL, EVAS_HINT_FILL);
- evas_object_show(priv->img);
+ efl_future_then(win, efl_ui_factory_create(img_factory, NULL, win),
+ .success = _wait_for_image,
+ .data = priv);
evas_object_event_callback_add(win, EVAS_CALLBACK_DEL, _cleanup_cb, priv);
//showall
@@ -167,8 +180,8 @@ elm_main(int argc EINA_UNUSED, char **argv EINA_UNUSED)
evas_object_show(win);
elm_run();
+
elm_shutdown();
- ecore_shutdown();
return 0;
}
diff --git a/src/examples/elementary/location_example_01.c b/src/examples/elementary/location_example_01.c
index 96ca818069..b98371de36 100644
--- a/src/examples/elementary/location_example_01.c
+++ b/src/examples/elementary/location_example_01.c
@@ -1,7 +1,12 @@
//Compile with:
//gcc -o location_example_01 location_example_01.c -g `pkg-config --cflags --libs elementary elocation`
+#ifndef EFL_EO_API_SUPPORT
+# define EFL_EO_API_SUPPORT
+#endif
+#ifndef EFL_BETA_API_SUPPORT
+# define EFL_BETA_API_SUPPORT
+#endif
-#define EFL_BETA_API_SUPPORT
#include <Elementary.h>
#ifdef ELM_ELOCATION
#include <Elocation.h>
@@ -57,7 +62,7 @@ _print_address(Elocation_Address *address)
}
static Eina_Bool
-_position_changed(void *data, int ev_type, void *event)
+_position_changed(void *data EINA_UNUSED, int ev_type EINA_UNUSED, void *event)
{
Elocation_Position *position;
diff --git a/src/examples/elementary/performance/camera_light.c b/src/examples/elementary/performance/camera_light.c
index 3c8f93b981..98be8c24ef 100644
--- a/src/examples/elementary/performance/camera_light.c
+++ b/src/examples/elementary/performance/camera_light.c
@@ -226,7 +226,7 @@ init_panel_camera_light(Evas_Object *win, Eo *camera_node, Eo *light_node, doubl
}
static void
-_camera_light_changeX_cb(void *data, Evas_Object *obj, void *event_info)
+_camera_light_changeX_cb(void *data, Evas_Object *obj, void *event_info EINA_UNUSED)
{
Evas_Real x, y, z;
@@ -238,7 +238,7 @@ _camera_light_changeX_cb(void *data, Evas_Object *obj, void *event_info)
}
}
static void
-_camera_light_changeY_cb(void *data, Evas_Object *obj, void *event_info)
+_camera_light_changeY_cb(void *data, Evas_Object *obj, void *event_info EINA_UNUSED)
{
Evas_Real x, y, z;
@@ -250,7 +250,7 @@ _camera_light_changeY_cb(void *data, Evas_Object *obj, void *event_info)
}
}
static void
-_camera_light_changeZ_cb(void *data, Evas_Object *obj, void *event_info)
+_camera_light_changeZ_cb(void *data, Evas_Object *obj, void *event_info EINA_UNUSED)
{
Evas_Real x, y, z;
@@ -262,7 +262,7 @@ _camera_light_changeZ_cb(void *data, Evas_Object *obj, void *event_info)
}
}
static void
-_camera_light_angle_change_cb(void *data, Evas_Object *obj, void *event_info)
+_camera_light_angle_change_cb(void *data, Evas_Object *obj, void *event_info EINA_UNUSED)
{
Axis_Key *key = evas_object_data_get(obj, axiskeys);
Evas_Real aw = 0;
@@ -274,7 +274,7 @@ _camera_light_angle_change_cb(void *data, Evas_Object *obj, void *event_info)
}
}
static void
-_camera_light_axisX_change_cb(void *data, Evas_Object *obj, void *event_info)
+_camera_light_axisX_change_cb(void *data, Evas_Object *obj, void *event_info EINA_UNUSED)
{
Evas_Object *fsa = (Evas_Object*)data;
Axis_Key *key = evas_object_data_get(fsa, axiskeys);
@@ -282,7 +282,7 @@ _camera_light_axisX_change_cb(void *data, Evas_Object *obj, void *event_info)
key->x = elm_spinner_value_get(obj);
}
static void
-_camera_light_axisY_change_cb(void *data, Evas_Object *obj, void *event_info)
+_camera_light_axisY_change_cb(void *data, Evas_Object *obj, void *event_info EINA_UNUSED)
{
Evas_Object *fsa = (Evas_Object*)data;
Axis_Key *key = evas_object_data_get(fsa, axiskeys);
@@ -290,7 +290,7 @@ _camera_light_axisY_change_cb(void *data, Evas_Object *obj, void *event_info)
key->y = elm_spinner_value_get(obj);
}
static void
-_camera_light_axisZ_change_cb(void *data, Evas_Object *obj, void *event_info)
+_camera_light_axisZ_change_cb(void *data, Evas_Object *obj, void *event_info EINA_UNUSED)
{
Evas_Object *fsa = (Evas_Object*)data;
Axis_Key *key = evas_object_data_get(fsa, axiskeys);
diff --git a/src/examples/elementary/performance/graphical.c b/src/examples/elementary/performance/graphical.c
index 06959ea2e7..3c7caa20fc 100644
--- a/src/examples/elementary/performance/graphical.c
+++ b/src/examples/elementary/performance/graphical.c
@@ -1,5 +1,9 @@
-#define EFL_EO_API_SUPPORT
-#define EFL_BETA_API_SUPPORT
+#ifndef EFL_EO_API_SUPPORT
+# define EFL_EO_API_SUPPORT
+#endif
+#ifndef EFL_BETA_API_SUPPORT
+# define EFL_BETA_API_SUPPORT
+#endif
#include <math.h>
#include <stdlib.h>
@@ -323,7 +327,7 @@ _change_scene_setup()
}
else
{
- efl_file_set(globalGraphical.mesh, globalGraphical.model_path, NULL);
+ efl_file_simple_load(globalGraphical.mesh, globalGraphical.model_path, NULL);
evas_canvas3d_mesh_frame_material_set(globalGraphical.mesh, 0, globalGraphical.material);
evas_canvas3d_mesh_shader_mode_set(globalGraphical.mesh, EVAS_CANVAS3D_SHADER_MODE_PHONG);
}
@@ -427,7 +431,7 @@ _init_scene(Evas_Object *img)
globalGraphical.material = efl_add(EVAS_CANVAS3D_MATERIAL_CLASS, globalGraphical.evas);
globalGraphical.texture = efl_add(EVAS_CANVAS3D_TEXTURE_CLASS, globalGraphical.evas);
- efl_file_set(globalGraphical.texture, "target_texture.png", NULL);
+ efl_file_simple_load(globalGraphical.texture, "target_texture.png", NULL);
evas_canvas3d_texture_filter_set(globalGraphical.texture, EVAS_CANVAS3D_TEXTURE_FILTER_LINEAR, EVAS_CANVAS3D_TEXTURE_FILTER_LINEAR);
evas_canvas3d_texture_wrap_set(globalGraphical.texture, EVAS_CANVAS3D_WRAP_MODE_REPEAT, EVAS_CANVAS3D_WRAP_MODE_REPEAT);
evas_canvas3d_material_texture_set(globalGraphical.material, EVAS_CANVAS3D_MATERIAL_ATTRIB_DIFFUSE, globalGraphical.texture);
@@ -460,7 +464,7 @@ _init_scene(Evas_Object *img)
}
else
{
- efl_file_set(globalGraphical.mesh, globalGraphical.model_path, NULL);
+ efl_file_simple_load(globalGraphical.mesh, globalGraphical.model_path, NULL);
evas_canvas3d_mesh_frame_material_set(globalGraphical.mesh, 0, globalGraphical.material);
evas_canvas3d_mesh_shader_mode_set(globalGraphical.mesh, EVAS_CANVAS3D_SHADER_MODE_PHONG);
}
@@ -492,7 +496,7 @@ _init_scene(Evas_Object *img)
}
static Eina_Bool
-_xml_attr_data(void *data, const char *key, const char *value)
+_xml_attr_data(void *data EINA_UNUSED, const char *key, const char *value)
{
char *format = NULL, *tmp = NULL, *a = NULL;
int i;
@@ -533,8 +537,8 @@ _xml_attr_data(void *data, const char *key, const char *value)
}
static Eina_Bool
-_xml_get_data(void *data, Eina_Simple_XML_Type type, const char *content,
- unsigned offset, unsigned length)
+_xml_get_data(void *data EINA_UNUSED, Eina_Simple_XML_Type type, const char *content,
+ unsigned offset EINA_UNUSED, unsigned length)
{
char str[512];
switch (type)
diff --git a/src/examples/elementary/performance/performance.c b/src/examples/elementary/performance/performance.c
index 0ed4c5f559..cced019c4a 100644
--- a/src/examples/elementary/performance/performance.c
+++ b/src/examples/elementary/performance/performance.c
@@ -19,9 +19,6 @@
* @endverbatim
*/
-#define EFL_EO_API_SUPPORT
-#define EFL_BETA_API_SUPPORT
-
/*enable automation test*/
#ifdef ENABLE_ATPORT
#include "at_port.h"
@@ -33,6 +30,12 @@
#include <stdio.h>
#include <stdlib.h>
+#ifndef EFL_EO_API_SUPPORT
+# define EFL_EO_API_SUPPORT
+#endif
+#ifndef EFL_BETA_API_SUPPORT
+# define EFL_BETA_API_SUPPORT
+#endif
#include <Eo.h>
#include <Evas.h>
@@ -60,17 +63,15 @@ void _clear_buf(char *buf)
buf[i] = '\0';
}
-void _value_int_to_char(char *buf, int value, const char *description)
+Eina_Slstr * _value_int_to_char(int value, const char *description)
{
- _clear_buf(buf);
if (description)
- sprintf(buf, "%s %d", description, value);
- else
- sprintf(buf, "%d", value);
+ return eina_slstr_printf("%s %d", description, value);
+ return eina_slstr_printf("%d", value);
}
static Eina_Bool
-_timer_update(void *data)
+_timer_update(void *data EINA_UNUSED)
{
printf(" frame rate = %f fps\n", fps_frames / 10.0);
fps_frames = 0;
@@ -165,19 +166,19 @@ _on_mouse_down(void *data, Evas *e EINA_UNUSED, Evas_Object *obj,
}
}
static void
-_btnstart_cb(void *data, Evas_Object *obj, void *event_info)
+_btnstart_cb(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void *event_info EINA_UNUSED)
{
globalGraphical.change_scene_setup();
}
static void
-_btnexit_cb(void *data, Evas_Object *obj, void *event_info)
+_btnexit_cb(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void *event_info EINA_UNUSED)
{
elm_exit();
}
static void
-_btnstop_cb(void *data, Evas_Object *obj, void *event_info)
+_btnstop_cb(void *data, Evas_Object *obj, void *event_info EINA_UNUSED)
{
const char *status = NULL;
status = elm_object_text_get(obj);
@@ -193,7 +194,7 @@ _btnstop_cb(void *data, Evas_Object *obj, void *event_info)
}
}
static void
-_node_orientation_change_cb(void *data, Evas_Object *obj, void *event_info)
+_node_orientation_change_cb(void *data, Evas_Object *obj EINA_UNUSED, void *event_info EINA_UNUSED)
{
Elm_Object_Item *it;
Eina_List *l;
@@ -211,7 +212,7 @@ _node_orientation_change_cb(void *data, Evas_Object *obj, void *event_info)
}
}
static void
-_node_position_change_cb(void *data, Evas_Object *obj, void *event_info)
+_node_position_change_cb(void *data, Evas_Object *obj EINA_UNUSED, void *event_info EINA_UNUSED)
{
Elm_Object_Item *it;
Eina_List *l;
@@ -229,7 +230,7 @@ _node_position_change_cb(void *data, Evas_Object *obj, void *event_info)
}
}
static void
-_node_scale_change_cb(void *data, Evas_Object *obj, void *event_info)
+_node_scale_change_cb(void *data, Evas_Object *obj EINA_UNUSED, void *event_info EINA_UNUSED)
{
Elm_Object_Item *it;
Eina_List *l;
@@ -247,9 +248,9 @@ _node_scale_change_cb(void *data, Evas_Object *obj, void *event_info)
}
}
static void
-_countdec10_cb(void *data, Evas_Object *obj, void *event_info)
+_countdec10_cb(void *data, Evas_Object *obj EINA_UNUSED, void *event_info EINA_UNUSED)
{
- char buf[CONVERT];
+ Eina_Slstr *buf;
int tmp;
globalGraphical.count -= 10;
@@ -257,187 +258,188 @@ _countdec10_cb(void *data, Evas_Object *obj, void *event_info)
else
tmp = ((globalGraphical.count + 1) * (globalGraphical.count + 1));
- _value_int_to_char(buf, ((tmp <= 1) ? 0 : tmp), "quantity:");
+ buf = _value_int_to_char(((tmp <= 1) ? 0 : tmp), "quantity:");
elm_object_text_set((Evas_Object*)data, buf);
}
static void
-_countdec_cb(void *data, Evas_Object *obj, void *event_info)
+_countdec_cb(void *data, Evas_Object *obj EINA_UNUSED, void *event_info EINA_UNUSED)
{
- char buf[CONVERT];
- int tmp;
+ Eina_Slstr *buf;
+ int tmp;
+
globalGraphical.count--;
if (globalGraphical.count < 0) tmp = globalGraphical.count = 0;
else
tmp = ((globalGraphical.count + 1) * (globalGraphical.count + 1));
- _value_int_to_char(buf, ((tmp <= 1) ? 0 : tmp), "quantity:");
+ buf = _value_int_to_char(((tmp <= 1) ? 0 : tmp), "quantity:");
elm_object_text_set((Evas_Object*)data, buf);
}
static void
-_countinc_cb(void *data, Evas_Object *obj, void *event_info)
+_countinc_cb(void *data, Evas_Object *obj EINA_UNUSED, void *event_info EINA_UNUSED)
{
- char buf[CONVERT];
+ Eina_Slstr *buf;
globalGraphical.count++;
- _value_int_to_char(buf, ((globalGraphical.count + 1) * (globalGraphical.count + 1)), "quantity:");
+ buf = _value_int_to_char(((globalGraphical.count + 1) * (globalGraphical.count + 1)), "quantity:");
elm_object_text_set((Evas_Object*)data, buf);
}
static void
-_countinc10_cb(void *data, Evas_Object *obj, void *event_info)
+_countinc10_cb(void *data, Evas_Object *obj EINA_UNUSED, void *event_info EINA_UNUSED)
{
- char buf[CONVERT];
+ Eina_Slstr *buf;
globalGraphical.count += 10;
- _value_int_to_char(buf, ((globalGraphical.count + 1) * (globalGraphical.count + 1)), "quantity:");
+ buf = _value_int_to_char(((globalGraphical.count + 1) * (globalGraphical.count + 1)), "quantity:");
elm_object_text_set((Evas_Object*)data, buf);
}
static void
-_speeddec10_cb(void *data, Evas_Object *obj, void *event_info)
+_speeddec10_cb(void *data, Evas_Object *obj EINA_UNUSED, void *event_info EINA_UNUSED)
{
- char buf[CONVERT];
+ Eina_Slstr *buf;
globalGraphical.speed -= 10;
if (globalGraphical.speed <= 0) globalGraphical.speed = 10;
- _value_int_to_char(buf, globalGraphical.speed, "speed:");
+ buf = _value_int_to_char(globalGraphical.speed, "speed:");
elm_object_text_set((Evas_Object*)data, buf);
}
static void
-_speeddec_cb(void *data, Evas_Object *obj, void *event_info)
+_speeddec_cb(void *data, Evas_Object *obj EINA_UNUSED, void *event_info EINA_UNUSED)
{
- char buf[CONVERT];
+ Eina_Slstr *buf;
globalGraphical.speed--;
if (globalGraphical.speed <= 0) globalGraphical.speed = 10;
- _value_int_to_char(buf, globalGraphical.speed, "speed:");
+ buf = _value_int_to_char(globalGraphical.speed, "speed:");
elm_object_text_set((Evas_Object*)data, buf);
}
static void
-_speedinc_cb(void *data, Evas_Object *obj, void *event_info)
+_speedinc_cb(void *data, Evas_Object *obj EINA_UNUSED, void *event_info EINA_UNUSED)
{
- char buf[CONVERT];
+ Eina_Slstr *buf;
globalGraphical.speed++;
- _value_int_to_char(buf, globalGraphical.speed, "speed:");
+ buf = _value_int_to_char(globalGraphical.speed, "speed:");
elm_object_text_set((Evas_Object*)data, buf);
}
static void
-_speedinc10_cb(void *data, Evas_Object *obj, void *event_info)
+_speedinc10_cb(void *data, Evas_Object *obj EINA_UNUSED, void *event_info EINA_UNUSED)
{
- char buf[CONVERT];
+ Eina_Slstr *buf;
globalGraphical.speed += 10;
- _value_int_to_char(buf, globalGraphical.speed, "speed:");
+ buf = _value_int_to_char(globalGraphical.speed, "speed:");
elm_object_text_set((Evas_Object*)data, buf);
}
static void
-_precisiondec10_cb(void *data, Evas_Object *obj, void *event_info)
+_precisiondec10_cb(void *data, Evas_Object *obj EINA_UNUSED, void *event_info EINA_UNUSED)
{
- char buf[CONVERT];
+ Eina_Slstr *buf;
globalGraphical.precision -= 10;
if (globalGraphical.precision <= 0) globalGraphical.precision = 10;
- _value_int_to_char(buf, globalGraphical.precision, "precision:");
+ buf = _value_int_to_char(globalGraphical.precision, "precision:");
elm_object_text_set((Evas_Object*)data, buf);
}
static void
-_precisiondec_cb(void *data, Evas_Object *obj, void *event_info)
+_precisiondec_cb(void *data, Evas_Object *obj EINA_UNUSED, void *event_info EINA_UNUSED)
{
- char buf[CONVERT];
+ Eina_Slstr *buf;
globalGraphical.precision--;
if (globalGraphical.precision <= 0) globalGraphical.precision = 10;
- _value_int_to_char(buf, globalGraphical.precision, "precision:");
+ buf = _value_int_to_char(globalGraphical.precision, "precision:");
elm_object_text_set((Evas_Object*)data, buf);
}
static void
-_precisioninc_cb(void *data, Evas_Object *obj, void *event_info)
+_precisioninc_cb(void *data, Evas_Object *obj EINA_UNUSED, void *event_info EINA_UNUSED)
{
- char buf[CONVERT];
+ Eina_Slstr *buf;
globalGraphical.precision++;
- _value_int_to_char(buf, globalGraphical.precision, "precision:");
+ buf = _value_int_to_char(globalGraphical.precision, "precision:");
elm_object_text_set((Evas_Object*)data, buf);
}
static void
-_precisioninc10_cb(void *data, Evas_Object *obj, void *event_info)
+_precisioninc10_cb(void *data, Evas_Object *obj EINA_UNUSED, void *event_info EINA_UNUSED)
{
- char buf[CONVERT];
+ Eina_Slstr *buf;
globalGraphical.precision += 10;
- _value_int_to_char(buf, globalGraphical.precision, "precision:");
+ buf = _value_int_to_char(globalGraphical.precision, "precision:");
elm_object_text_set((Evas_Object*)data, buf);
-
}
static void
-_angledec10_cb(void *data, Evas_Object *obj, void *event_info)
+_angledec10_cb(void *data, Evas_Object *obj EINA_UNUSED, void *event_info EINA_UNUSED)
{
- char buf[CONVERT];
+ Eina_Slstr *buf;
globalGraphical.angle -= 10;
if (globalGraphical.angle <= 0) globalGraphical.angle = 10;
- _value_int_to_char(buf, globalGraphical.angle, "angle:");
+ buf = _value_int_to_char(globalGraphical.angle, "angle:");
elm_object_text_set((Evas_Object*)data, buf);
}
static void
-_angledec_cb(void *data, Evas_Object *obj, void *event_info)
+_angledec_cb(void *data, Evas_Object *obj EINA_UNUSED, void *event_info EINA_UNUSED)
{
- char buf[CONVERT];
+ Eina_Slstr *buf;
globalGraphical.angle--;
if (globalGraphical.angle <= 0) globalGraphical.angle = 10;
- _value_int_to_char(buf, globalGraphical.angle, "angle:");
+ buf = _value_int_to_char(globalGraphical.angle, "angle:");
elm_object_text_set((Evas_Object*)data, buf);
}
static void
-_angleinc_cb(void *data, Evas_Object *obj, void *event_info)
+_angleinc_cb(void *data, Evas_Object *obj EINA_UNUSED, void *event_info EINA_UNUSED)
{
- char buf[CONVERT];
+ Eina_Slstr *buf;
globalGraphical.angle++;
if (globalGraphical.angle >= 180) globalGraphical.angle = 180;
- _value_int_to_char(buf, globalGraphical.angle, "angle:");
+
+ buf = _value_int_to_char(globalGraphical.angle, "angle:");
elm_object_text_set((Evas_Object*)data, buf);
}
static void
-_angleinc10_cb(void *data, Evas_Object *obj, void *event_info)
+_angleinc10_cb(void *data, Evas_Object *obj EINA_UNUSED, void *event_info EINA_UNUSED)
{
- char buf[CONVERT];
+ Eina_Slstr *buf;
globalGraphical.angle += 10;
if (globalGraphical.angle >= 180) globalGraphical.angle = 180;
- _value_int_to_char(buf, globalGraphical.angle, "angle:");
+ buf = _value_int_to_char(globalGraphical.angle, "angle:");
elm_object_text_set((Evas_Object*)data, buf);
}
static void
-_shadow_enable(void *data, Evas_Object *obj, void *event_info)
+_shadow_enable(void *data EINA_UNUSED, Evas_Object *obj, void *event_info EINA_UNUSED)
{
if (elm_check_state_get(obj))
globalGraphical.flags.shadow_enable = EINA_TRUE;
@@ -446,7 +448,7 @@ _shadow_enable(void *data, Evas_Object *obj, void *event_info)
}
static void
-_colorpick_enable(void *data, Evas_Object *obj, void *event_info)
+_colorpick_enable(void *data EINA_UNUSED, Evas_Object *obj, void *event_info EINA_UNUSED)
{
if (elm_check_state_get(obj))
globalGraphical.flags.colorpick_enable = EINA_TRUE;
@@ -455,7 +457,7 @@ _colorpick_enable(void *data, Evas_Object *obj, void *event_info)
}
static void
-_fog_enable(void *data, Evas_Object *obj, void *event_info)
+_fog_enable(void *data EINA_UNUSED, Evas_Object *obj, void *event_info EINA_UNUSED)
{
if (elm_check_state_get(obj))
globalGraphical.flags.fog_enable = EINA_TRUE;
@@ -464,7 +466,7 @@ _fog_enable(void *data, Evas_Object *obj, void *event_info)
}
static void
-_blend_enable(void *data, Evas_Object *obj, void *event_info)
+_blend_enable(void *data EINA_UNUSED, Evas_Object *obj, void *event_info EINA_UNUSED)
{
if (elm_check_state_get(obj))
globalGraphical.flags.blend_enable = EINA_TRUE;
@@ -473,7 +475,7 @@ _blend_enable(void *data, Evas_Object *obj, void *event_info)
}
static void
-_cb_fps_enable(void *data, Evas_Object *obj, void *event_info)
+_cb_fps_enable(void *data, Evas_Object *obj, void *event_info EINA_UNUSED)
{
if (elm_check_state_get(obj))
{
@@ -578,7 +580,7 @@ EAPI_MAIN
Evas_Object *navigation = NULL;
Evas_Object *fs_node = NULL, *bt_orientation = NULL, *bt_position = NULL, *bt_scale = NULL;
Ecore_Timer *fps_timer = NULL;
- char buf[CONVERT];
+ Eina_Slstr *buf;
#ifdef ENABLE_ATPORT
at_port_h mf_at_port = NULL;
@@ -693,7 +695,7 @@ EAPI_MAIN
evas_object_show(controlbox);
vcount = elm_label_add(win);
- _value_int_to_char(buf, 121, "quantity:");
+ buf = _value_int_to_char(121, "quantity:");
elm_object_text_set(vcount, buf);
countdec10 = elm_button_add(win);
@@ -732,7 +734,7 @@ EAPI_MAIN
evas_object_smart_callback_add(countinc10, "clicked", _countinc10_cb, vcount);
vspeed = elm_label_add(win);
- _value_int_to_char(buf, 30, "speed:");
+ buf = _value_int_to_char(30, "speed:");
elm_object_text_set(vspeed, buf);
speeddec10 = elm_button_add(win);
@@ -771,7 +773,7 @@ EAPI_MAIN
evas_object_smart_callback_add(speedinc10, "clicked", _speedinc10_cb, vspeed);
vprecision = elm_label_add(win);
- _value_int_to_char(buf, 100, "precision:");
+ buf = _value_int_to_char(100, "precision:");
elm_object_text_set(vprecision, buf);
precisiondec10 = elm_button_add(win);
@@ -810,7 +812,7 @@ EAPI_MAIN
evas_object_smart_callback_add(precisioninc10, "clicked", _precisioninc10_cb, vprecision);
vangle = elm_label_add(win);
- _value_int_to_char(buf, 120, "angle:");
+ buf = _value_int_to_char(120, "angle:");
elm_object_text_set(vangle, buf);
angledec10 = elm_button_add(win);
@@ -914,13 +916,13 @@ EAPI_MAIN
image = init_graphical_window(image);
/*Update data for count, speed, precision, angle*/
- _value_int_to_char(buf, (globalGraphical.count + 1) * (globalGraphical.count + 1), "quantity:");
+ buf = _value_int_to_char((globalGraphical.count + 1) * (globalGraphical.count + 1), "quantity:");
elm_object_text_set(vcount, buf);
- _value_int_to_char(buf, globalGraphical.speed, "speed:");
+ buf = _value_int_to_char(globalGraphical.speed, "speed:");
elm_object_text_set(vspeed, buf);
- _value_int_to_char(buf, globalGraphical.precision, "precision:");
+ buf = _value_int_to_char(globalGraphical.precision, "precision:");
elm_object_text_set(vprecision, buf);
- _value_int_to_char(buf, globalGraphical.angle, "angle:");
+ buf = _value_int_to_char(globalGraphical.angle, "angle:");
elm_object_text_set(vangle, buf);
if (globalGraphical.model_path)
evas_object_smart_callback_call(fs_bt, "file,chosen", (void *)globalGraphical.model_path);
diff --git a/src/examples/elementary/performance/tools_private.h b/src/examples/elementary/performance/tools_private.h
index 05c3c26d0e..20aa80d073 100644
--- a/src/examples/elementary/performance/tools_private.h
+++ b/src/examples/elementary/performance/tools_private.h
@@ -1,5 +1,9 @@
-#define EFL_EO_API_SUPPORT
-#define EFL_BETA_API_SUPPORT
+#ifndef EFL_EO_API_SUPPORT
+# define EFL_EO_API_SUPPORT
+#endif
+#ifndef EFL_BETA_API_SUPPORT
+# define EFL_BETA_API_SUPPORT
+#endif
#include <math.h>
#include <stdlib.h>
diff --git a/src/examples/elementary/popup_cxx_example.cc b/src/examples/elementary/popup_cxx_example.cc
index b6c78322f9..a6a29ed955 100644
--- a/src/examples/elementary/popup_cxx_example.cc
+++ b/src/examples/elementary/popup_cxx_example.cc
@@ -3,6 +3,7 @@
#define EFL_CXXPERIMENTAL
#include <Evas.hh>
+#include <Efl_Ui.h>
#include <Elementary.hh>
#include <iostream>
@@ -207,11 +208,11 @@ efl_main(void *data EINA_UNUSED, const Efl_Event *ev EINA_UNUSED)
backwall_visible = !backwall_visible;
if (backwall_visible) {
- efl::eo::downcast<efl::File>(g_popup.part_get("backwall")).file_set("./sky_01.jpg", nullptr);
+ efl::eo::downcast<efl::File>(g_popup.part_get("backwall")).file_set("./sky_01.jpg");
backwall_btn.text_set("Unset Backwall");
}
else {
- efl::eo::downcast<efl::File>(g_popup.part_get("backwall")).file_set(nullptr, nullptr);
+ efl::eo::downcast<efl::File>(g_popup.part_get("backwall")).file_set(nullptr);
backwall_btn.text_set("Set Backwall");
}
}));
diff --git a/src/examples/elementary/radio_cxx_example_01.cc b/src/examples/elementary/radio_cxx_example_01.cc
index 5a3f30c75e..2ad30b2097 100644
--- a/src/examples/elementary/radio_cxx_example_01.cc
+++ b/src/examples/elementary/radio_cxx_example_01.cc
@@ -1,6 +1,7 @@
// g++ -g `pkg-config --cflags --libs elementary-cxx efl-cxx eina-cxx eo-cxx ecore-cxx evas-cxx edje-cxx` radio_cxx_example_01.cc -o radio_cxx_example_01
#define EFL_CXXPERIMENTAL
+#include <Efl_Ui.h>
#include <Elementary.hh>
#include <iostream>
diff --git a/src/examples/elementary/slider_cxx_example.cc b/src/examples/elementary/slider_cxx_example.cc
index ab37196352..1df1903bf5 100644
--- a/src/examples/elementary/slider_cxx_example.cc
+++ b/src/examples/elementary/slider_cxx_example.cc
@@ -2,6 +2,7 @@
#define EFL_CXXPERIMENTAL
+#include <Efl_Ui.h>
#include <Elementary.hh>
using namespace std::placeholders;
diff --git a/src/examples/elementary/sphere_hunter/evas_3d_sphere_hunter.c b/src/examples/elementary/sphere_hunter/evas_3d_sphere_hunter.c
index bceb165b83..7b789740e3 100644
--- a/src/examples/elementary/sphere_hunter/evas_3d_sphere_hunter.c
+++ b/src/examples/elementary/sphere_hunter/evas_3d_sphere_hunter.c
@@ -14,8 +14,12 @@
* edje_cc sphere_hunter.edc
* gcc -o evas_3d_sphere_hunter evas_3d_sphere_hunter.c -g `pkg-config --libs --cflags evas ecore elementary eina eo` -lm
*/
-
-#define EFL_BETA_API_SUPPORT
+#ifndef EFL_EO_API_SUPPORT
+# define EFL_EO_API_SUPPORT
+#endif
+#ifndef EFL_BETA_API_SUPPORT
+# define EFL_BETA_API_SUPPORT
+#endif
#include <Elementary.h>
#include <Ecore.h>
@@ -323,7 +327,7 @@ _sphere_init(int precision)
}
static void
-_restart_level(void *data, Evas_Object *btn, void *ev)
+_restart_level(void *data, Evas_Object *btn EINA_UNUSED, void *ev EINA_UNUSED)
{
Eina_List *l = NULL;
Eo *item = NULL;
@@ -778,7 +782,7 @@ _animate_cubes(void *data)
}
EAPI_MAIN int
-elm_main(int argc, char **argv)
+elm_main(int argc EINA_UNUSED, char **argv EINA_UNUSED)
{
Scene_Data data;
Eina_Bool r = EINA_TRUE;
diff --git a/src/examples/elementary/toolbar_cxx_example_01.cc b/src/examples/elementary/toolbar_cxx_example_01.cc
index 5a884b96f7..77ad3eb569 100644
--- a/src/examples/elementary/toolbar_cxx_example_01.cc
+++ b/src/examples/elementary/toolbar_cxx_example_01.cc
@@ -7,6 +7,7 @@
#warning This example requires yet unfinished EO APIs
+#include <Efl_Ui.h>
#include <Elementary.hh>
EAPI int
@@ -22,7 +23,7 @@ elm_main(int argc, char* argv[])
{
win_1.text_set("Toolbar");
win_1.win_name_set("toolbar");
- win_1.win_type_set(EFL_UI_WIN_BASIC);
+ win_1.win_type_set(EFL_UI_WIN_TYPE_BASIC);
});
#if 0
@@ -77,7 +78,7 @@ elm_main(int argc, char* argv[])
elm::Widget photo_1(elm_photo_add(win_1._eo_ptr()));
elm_photo_size_set(photo_1._eo_ptr(), 40);
- efl_file_set(photo_1._eo_ptr(), "/opt/e/share/elementary/images/plant_01.jpg", nullptr);
+ efl_file_simple_load(photo_1._eo_ptr(), "/opt/e/share/elementary/images/plant_01.jpg", nullptr);
photo_1.hint_weight_set(1, 1);
photo_1.hint_align_set(0.5, 0.5);
photo_1.visible_set(true);
@@ -92,7 +93,7 @@ elm_main(int argc, char* argv[])
elm_table_pack(table_1._eo_ptr(), photo_2._eo_ptr(), 1, 0, 1, 1);
elm::Widget photo_3(elm_photo_add(win_1._eo_ptr()));
elm_photo_size_set(photo_3._eo_ptr(), 20);
- efl_file_set(photo_3._eo_ptr(), "/opt/e/share/elementary/images/sky_01.jpg", nullptr);
+ efl_file_simple_load(photo_3._eo_ptr(), "/opt/e/share/elementary/images/sky_01.jpg", nullptr);
photo_3.hint_weight_set(1, 1);
photo_3.hint_align_set(0.5, 0.5);
photo_3.visible_set(true);
@@ -100,7 +101,7 @@ elm_main(int argc, char* argv[])
elm_table_pack(table_1._eo_ptr(), photo_3._eo_ptr(), 0, 1, 1, 1);
elm::Widget photo_4(elm_photo_add(win_1._eo_ptr()));
elm_photo_size_set(photo_4._eo_ptr(), 60);
- efl_file_set(photo_4._eo_ptr(), "/opt/e/share/elementary/images/sky_02.jpg", nullptr);
+ efl_file_simple_load(photo_4._eo_ptr(), "/opt/e/share/elementary/images/sky_02.jpg", nullptr);
photo_4.hint_weight_set(1, 1);
photo_4.hint_align_set(0.5, 0.5);
photo_4.visible_set(true);
@@ -111,22 +112,22 @@ elm_main(int argc, char* argv[])
win_1.content_set(box_1);
auto _item_2_selected_cb = std::bind([&] () {
- efl_file_set(photo_1._eo_ptr(), "/opt/e/share/elementary/images/rock_01.jpg", nullptr);
+ efl_file_simple_load(photo_1._eo_ptr(), "/opt/e/share/elementary/images/rock_01.jpg", nullptr);
});
efl::eolian::event_add(efl::ui::Selectable::selected_event, item_2, _item_2_selected_cb);
auto _item_3_selected_cb = std::bind([&] () {
- efl_file_set(photo_4._eo_ptr(), "/opt/e/share/elementary/images/wood_01.jpg", nullptr);
+ efl_file_simple_load(photo_4._eo_ptr(), "/opt/e/share/elementary/images/wood_01.jpg", nullptr);
});
efl::eolian::event_add(efl::ui::Selectable::selected_event, item_3, _item_3_selected_cb);
auto _item_4_selected_cb = std::bind([&] () {
- efl_file_set(photo_4._eo_ptr(), "/opt/e/share/elementary/images/sky_03.jpg", nullptr);
+ efl_file_simple_load(photo_4._eo_ptr(), "/opt/e/share/elementary/images/sky_03.jpg", nullptr);
});
efl::eolian::event_add(efl::ui::Selectable::selected_event, item_4, _item_4_selected_cb);
auto _item_5_selected_cb = std::bind([&] () {
- efl_file_set(photo_4._eo_ptr(), nullptr, nullptr);
+ efl_file_simple_load(photo_4._eo_ptr(), nullptr, nullptr);
});
efl::eolian::event_add(efl::ui::Selectable::selected_event, item_5, _item_5_selected_cb);
diff --git a/src/examples/elementary/web_example_01.c b/src/examples/elementary/web_example_01.c
index 82b53053dd..7e38bbfba1 100644
--- a/src/examples/elementary/web_example_01.c
+++ b/src/examples/elementary/web_example_01.c
@@ -1,8 +1,10 @@
/*
* gcc -o web_example_01 web_example_01.c `pkg-config --cflags --libs elementary ewebkit` -D_GNU_SOURCE
*/
+#ifndef _GNU_SOURCE
+# define _GNU_SOURCE
+#endif
-#define _GNU_SOURCE
#include <Elementary.h>
#ifdef HAVE_ELEMENTARY_WEB
#include <EWebKit.h>
diff --git a/src/examples/elementary/web_example_02.c b/src/examples/elementary/web_example_02.c
index 9cffc3f854..3658583cab 100644
--- a/src/examples/elementary/web_example_02.c
+++ b/src/examples/elementary/web_example_02.c
@@ -1,8 +1,10 @@
/*
* gcc -o web_example_02 web_example_02.c `pkg-config --cflags --libs elementary ewebkit` -D_GNU_SOURCE
*/
+#ifndef _GNU_SOURCE
+# define _GNU_SOURCE
+#endif
-#define _GNU_SOURCE
#include <Elementary.h>
#ifdef HAVE_ELEMENTARY_WEB
#include <EWebKit.h>
diff --git a/src/examples/evas.mk b/src/examples/evas.mk
index 034fc96f7c..fa6a693a98 100644
--- a/src/examples/evas.mk
+++ b/src/examples/evas.mk
@@ -225,62 +225,6 @@ $(AM_CPPFLAGS) @EVAS_CFLAGS@
endif
-if HAVE_CSHARP
-
-EXTRA_PROGRAMS += \
- evas/evas_mono_box_csharp \
- evas/evas_mono_image_csharp \
- evas/evas_mono_image2_csharp \
- evas/evas_mono_rectangle_csharp \
- evas/evas_mono_table_csharp \
- evas/evas_mono_text_csharp
-
-
-evas_evas_mono_box_csharp_SOURCES = \
- evas/evas_mono_box.cs
-
-evas/evas_mono_box_csharp$(EXEEXT): $(evas_evas_mono_box_csharp_SOURCES) $(am_dirstamp) $(top_builddir)/src/lib/efl_mono/libefl_mono.dll
- $(AM_V_MCS) $(MCS) $(MCSFLAGS) -r:$(abs_top_builddir)/src/lib/efl_mono/libefl_mono.dll -out:$@ $(filter %.cs, $(^))
-
-evas_evas_mono_image_csharp_SOURCES = \
- evas/evas_mono_image.cs
-
-evas/evas_mono_image_csharp$(EXEEXT): $(evas_evas_mono_image_csharp_SOURCES) $(am_dirstamp) $(top_builddir)/src/lib/efl_mono/libefl_mono.dll
- @rm -f $@
- $(AM_V_MCS) $(MCS) $(MCSFLAGS) -r:$(abs_top_builddir)/src/lib/efl_mono/libefl_mono.dll -out:$@ $(filter %.cs, $(^))
-
-evas_evas_mono_image2_csharp_SOURCES = \
- evas/evas_mono_image2.cs
-
-evas/evas_mono_image2_csharp$(EXEEXT): $(evas_evas_mono_image2_csharp_SOURCES) $(am_dirstamp) $(top_builddir)/src/lib/efl_mono/libefl_mono.dll
- @rm -f $@
- $(AM_V_MCS) $(MCS) $(MCSFLAGS) -r:$(abs_top_builddir)/src/lib/efl_mono/libefl_mono.dll -out:$@ $(filter %.cs, $(^))
-
-evas_evas_mono_rectangle_csharp_SOURCES = \
- evas/evas_mono_rectangle.cs
-
-evas/evas_mono_rectangle_csharp$(EXEEXT): $(evas_evas_mono_rectangle_csharp_SOURCES) $(am_dirstamp) $(top_builddir)/src/lib/efl_mono/libefl_mono.dll
- @rm -f $@
- $(AM_V_MCS) $(MCS) $(MCSFLAGS) -r:$(abs_top_builddir)/src/lib/efl_mono/libefl_mono.dll -out:$@ $(filter %.cs, $(^))
-
-evas_evas_mono_table_csharp_SOURCES = \
- evas/evas_mono_table.cs
-
-evas/evas_mono_table_csharp$(EXEEXT): $(evas_evas_mono_table_csharp_SOURCES) $(am_dirstamp) $(top_builddir)/src/lib/efl_mono/libefl_mono.dll
- @rm -f $@
- $(AM_V_MCS) $(MCS) $(MCSFLAGS) -r:$(abs_top_builddir)/src/lib/efl_mono/libefl_mono.dll -out:$@ $(filter %.cs, $(^))
-
-evas_evas_mono_text_csharp_SOURCES = \
- evas/evas_mono_text.cs
-
-evas/evas_mono_text_csharp$(EXEEXT): $(evas_evas_mono_text_csharp_SOURCES) $(am_dirstamp) $(top_builddir)/src/lib/efl_mono/libefl_mono.dll
- @rm -f $@
- $(AM_V_MCS) $(MCS) $(MCSFLAGS) -r:$(abs_top_builddir)/src/lib/efl_mono/libefl_mono.dll -out:$@ $(filter %.cs, $(^))
-
-endif
-
-
-
EVAS_SRCS = \
evas/evas-aspect-hints.c \
evas/evas-box.c \
diff --git a/src/examples/evas/evas-3d-aabb.c b/src/examples/evas/evas-3d-aabb.c
index dd4c1f0f27..fdb8a45278 100644
--- a/src/examples/evas/evas-3d-aabb.c
+++ b/src/examples/evas/evas-3d-aabb.c
@@ -170,12 +170,12 @@ main(void)
mesh = efl_add(EVAS_CANVAS3D_MESH_CLASS, evas);
material = efl_add(EVAS_CANVAS3D_MATERIAL_CLASS, evas);
- efl_file_set(mesh, model_path, NULL);
+ efl_file_simple_load(mesh, model_path, NULL);
evas_canvas3d_mesh_frame_material_set(mesh, 0, material);
evas_canvas3d_mesh_shader_mode_set(mesh, EVAS_CANVAS3D_SHADER_MODE_PHONG);
texture = efl_add(EVAS_CANVAS3D_TEXTURE_CLASS, evas);
- efl_file_set(texture, image_path, NULL);
+ efl_file_simple_load(texture, image_path, NULL);
evas_canvas3d_texture_filter_set(texture, EVAS_CANVAS3D_TEXTURE_FILTER_NEAREST, EVAS_CANVAS3D_TEXTURE_FILTER_NEAREST);
evas_canvas3d_texture_wrap_set(texture, EVAS_CANVAS3D_WRAP_MODE_REPEAT, EVAS_CANVAS3D_WRAP_MODE_REPEAT);
evas_canvas3d_material_texture_set(material, EVAS_CANVAS3D_MATERIAL_ATTRIB_DIFFUSE, texture);
diff --git a/src/examples/evas/evas-3d-colorpick.c b/src/examples/evas/evas-3d-colorpick.c
index 8c9ea3b54f..7b894cd23e 100644
--- a/src/examples/evas/evas-3d-colorpick.c
+++ b/src/examples/evas/evas-3d-colorpick.c
@@ -256,7 +256,7 @@ _init_sphere(void *this, const char *texture)
evas_canvas3d_mesh_color_pick_enable_set(sphere->mesh, EINA_TRUE);
sphere->texture = efl_add(EVAS_CANVAS3D_TEXTURE_CLASS, evas);
- efl_file_set(sphere->texture, texture, NULL);
+ efl_file_simple_load(sphere->texture, texture, NULL);
evas_canvas3d_texture_filter_set(sphere->texture, EVAS_CANVAS3D_TEXTURE_FILTER_NEAREST, EVAS_CANVAS3D_TEXTURE_FILTER_NEAREST);
evas_canvas3d_texture_wrap_set(sphere->texture, EVAS_CANVAS3D_WRAP_MODE_REPEAT, EVAS_CANVAS3D_WRAP_MODE_REPEAT);
evas_canvas3d_material_texture_set(sphere->material, EVAS_CANVAS3D_MATERIAL_ATTRIB_DIFFUSE, sphere->texture);
diff --git a/src/examples/evas/evas-3d-cube2.c b/src/examples/evas/evas-3d-cube2.c
index c8558b622b..b2d905e873 100644
--- a/src/examples/evas/evas-3d-cube2.c
+++ b/src/examples/evas/evas-3d-cube2.c
@@ -168,7 +168,7 @@ _mesh_setup(Scene_Data *data)
evas_canvas3d_texture_data_set(data->texture0, EVAS_COLORSPACE_ARGB8888, 4, 4, &pixels0[0]);
evas_canvas3d_texture_data_set(data->texture1, EVAS_COLORSPACE_ARGB8888, 4, 4, &pixels1[0]);
- efl_file_set(data->texture_normal, normal_map_path, NULL);
+ efl_file_simple_load(data->texture_normal, normal_map_path, NULL);
evas_canvas3d_material_texture_set(data->material0, EVAS_CANVAS3D_MATERIAL_ATTRIB_DIFFUSE, data->texture0);
evas_canvas3d_material_texture_set(data->material1, EVAS_CANVAS3D_MATERIAL_ATTRIB_DIFFUSE, data->texture1);
diff --git a/src/examples/evas/evas-3d-eet.c b/src/examples/evas/evas-3d-eet.c
index da94e06d7e..becd0bcadc 100644
--- a/src/examples/evas/evas-3d-eet.c
+++ b/src/examples/evas/evas-3d-eet.c
@@ -146,7 +146,7 @@ main(void)
mesh2 = efl_add(EVAS_CANVAS3D_MESH_CLASS, evas);
material = efl_add(EVAS_CANVAS3D_MATERIAL_CLASS, evas);
- efl_file_set(mesh, input_model_path, NULL);
+ efl_file_simple_load(mesh, input_model_path, NULL);
evas_canvas3d_mesh_frame_material_set(mesh, 0, material);
evas_canvas3d_mesh_shader_mode_set(mesh, EVAS_CANVAS3D_SHADER_MODE_PHONG);
@@ -165,7 +165,7 @@ main(void)
efl_file_save(mesh, output_model_path, NULL, NULL);
- efl_file_set(mesh2, output_model_path, NULL);
+ efl_file_simple_load(mesh2, output_model_path, NULL);
evas_canvas3d_mesh_shader_mode_set(mesh2, EVAS_CANVAS3D_SHADER_MODE_PHONG);
mesh_node = efl_add(EVAS_CANVAS3D_NODE_CLASS, evas, evas_canvas3d_node_type_set(efl_added, EVAS_CANVAS3D_NODE_TYPE_MESH));
diff --git a/src/examples/evas/evas-3d-frustum.c b/src/examples/evas/evas-3d-frustum.c
index 02f5bba05e..6e765bd399 100644
--- a/src/examples/evas/evas-3d-frustum.c
+++ b/src/examples/evas/evas-3d-frustum.c
@@ -352,7 +352,7 @@ _mesh_setup_model(Scene_Data *data)
data->material_model = efl_add(EVAS_CANVAS3D_MATERIAL_CLASS, evas);
data->texture_model = efl_add(EVAS_CANVAS3D_TEXTURE_CLASS, evas);
- efl_file_set(data->texture_model, texture_path, NULL);
+ efl_file_simple_load(data->texture_model, texture_path, NULL);
evas_canvas3d_texture_filter_set(data->texture_model, EVAS_CANVAS3D_TEXTURE_FILTER_NEAREST, EVAS_CANVAS3D_TEXTURE_FILTER_NEAREST);
evas_canvas3d_texture_wrap_set(data->texture_model, EVAS_CANVAS3D_WRAP_MODE_REPEAT, EVAS_CANVAS3D_WRAP_MODE_REPEAT);
@@ -367,7 +367,7 @@ _mesh_setup_model(Scene_Data *data)
evas_canvas3d_material_texture_set(data->material_model, EVAS_CANVAS3D_MATERIAL_ATTRIB_DIFFUSE, data->texture_model);
evas_canvas3d_material_shininess_set(data->material_model, 100.0);
- efl_file_set(data->mesh_model, mesh_path, NULL);
+ efl_file_simple_load(data->mesh_model, mesh_path, NULL);
evas_canvas3d_mesh_frame_material_set(data->mesh_model, 0, data->material_model);
evas_canvas3d_mesh_shader_mode_set(data->mesh_model, EVAS_CANVAS3D_SHADER_MODE_DIFFUSE);
}
diff --git a/src/examples/evas/evas-3d-hull.c b/src/examples/evas/evas-3d-hull.c
index 0e13705c36..e82f31bca7 100644
--- a/src/examples/evas/evas-3d-hull.c
+++ b/src/examples/evas/evas-3d-hull.c
@@ -87,7 +87,7 @@ int rr;
#define MODEL_MESH_INIT(name, model, shade) \
data->mesh_##name = efl_add(EVAS_CANVAS3D_MESH_CLASS, evas); \
- efl_file_set(data->mesh_##name, model, NULL); \
+ efl_file_simple_load(data->mesh_##name, model, NULL); \
evas_canvas3d_mesh_vertex_assembly_set(data->mesh_##name, EVAS_CANVAS3D_VERTEX_ASSEMBLY_TRIANGLES); \
evas_canvas3d_mesh_shader_mode_set(data->mesh_##name, EVAS_CANVAS3D_SHADER_MODE_##shade); \
evas_canvas3d_mesh_frame_material_set(data->mesh_##name, 0, data->material);
diff --git a/src/examples/evas/evas-3d-md2.c b/src/examples/evas/evas-3d-md2.c
index adfb6962a0..f97c183bd0 100644
--- a/src/examples/evas/evas-3d-md2.c
+++ b/src/examples/evas/evas-3d-md2.c
@@ -124,12 +124,12 @@ main(void)
mesh = efl_add(EVAS_CANVAS3D_MESH_CLASS, evas);
material = efl_add(EVAS_CANVAS3D_MATERIAL_CLASS, evas);
- efl_file_set(mesh, model_path, NULL);
+ efl_file_simple_load(mesh, model_path, NULL);
evas_canvas3d_mesh_frame_material_set(mesh, 0, material);
evas_canvas3d_mesh_shader_mode_set(mesh, EVAS_CANVAS3D_SHADER_MODE_PHONG);
texture = efl_add(EVAS_CANVAS3D_TEXTURE_CLASS, evas);
- efl_file_set(texture, image_path, NULL);
+ efl_file_simple_load(texture, image_path, NULL);
evas_canvas3d_texture_filter_set(texture, EVAS_CANVAS3D_TEXTURE_FILTER_NEAREST, EVAS_CANVAS3D_TEXTURE_FILTER_NEAREST);
evas_canvas3d_texture_wrap_set(texture, EVAS_CANVAS3D_WRAP_MODE_REPEAT, EVAS_CANVAS3D_WRAP_MODE_REPEAT);
evas_canvas3d_material_texture_set(material, EVAS_CANVAS3D_MATERIAL_ATTRIB_DIFFUSE, texture);
diff --git a/src/examples/evas/evas-3d-mmap-set.c b/src/examples/evas/evas-3d-mmap-set.c
index 360555501e..149217d95a 100644
--- a/src/examples/evas/evas-3d-mmap-set.c
+++ b/src/examples/evas/evas-3d-mmap-set.c
@@ -33,7 +33,7 @@
snprintf(buffer, PATH_MAX, "%s%s", template_path, #extention); \
extention##_file = eina_file_open(buffer , 0); \
mesh_##extention = efl_add(EVAS_CANVAS3D_MESH_CLASS, evas); \
- efl_file_mmap_set(mesh_##extention, extention##_file, NULL); \
+ efl_file_simple_mmap_load(mesh_##extention, extention##_file, NULL); \
evas_canvas3d_mesh_frame_material_set(mesh_##extention, 0, material); \
evas_canvas3d_mesh_shader_mode_set(mesh_##extention, EVAS_CANVAS3D_SHADER_MODE_PHONG); \
node_##extention = efl_add(EVAS_CANVAS3D_NODE_CLASS, evas, evas_canvas3d_node_type_set(efl_added, EVAS_CANVAS3D_NODE_TYPE_MESH)); \
diff --git a/src/examples/evas/evas-3d-obj.c b/src/examples/evas/evas-3d-obj.c
index 65f57ecffd..91126fbfa0 100644
--- a/src/examples/evas/evas-3d-obj.c
+++ b/src/examples/evas/evas-3d-obj.c
@@ -47,7 +47,7 @@
#define ADD_OBJ_MESH(path, Y, Z, num, shade_mode, name_of_material) \
mesh[num] = efl_add(EVAS_CANVAS3D_MESH_CLASS, evas); \
snprintf(full_file_path, sizeof(full_file_path), "%s.obj", path); \
- efl_file_set(mesh[num], full_file_path, NULL); \
+ efl_file_simple_load(mesh[num], full_file_path, NULL); \
evas_canvas3d_mesh_frame_material_set(mesh[num], 0, name_of_material); \
evas_canvas3d_mesh_shader_mode_set(mesh[num], shade_mode); \
mesh_node[num] = efl_add(EVAS_CANVAS3D_NODE_CLASS, evas, evas_canvas3d_node_type_set(efl_added, EVAS_CANVAS3D_NODE_TYPE_MESH)); \
@@ -65,7 +65,7 @@
#define ADD_TEXTURE(name, path) \
name = efl_add(EVAS_CANVAS3D_TEXTURE_CLASS, evas); \
- efl_file_set(name, path, NULL); \
+ efl_file_simple_load(name, path, NULL); \
evas_canvas3d_texture_filter_set(name, EVAS_CANVAS3D_TEXTURE_FILTER_NEAREST, \
EVAS_CANVAS3D_TEXTURE_FILTER_NEAREST); \
evas_canvas3d_texture_wrap_set(name, EVAS_CANVAS3D_WRAP_MODE_REPEAT, \
diff --git a/src/examples/evas/evas-3d-parallax-occlusion.c b/src/examples/evas/evas-3d-parallax-occlusion.c
index 83188c0538..1d2cc75263 100644
--- a/src/examples/evas/evas-3d-parallax-occlusion.c
+++ b/src/examples/evas/evas-3d-parallax-occlusion.c
@@ -138,9 +138,9 @@ _mesh_setup(Scene_Data *data)
data->texture_rocks = efl_add(EVAS_CANVAS3D_TEXTURE_CLASS, evas);
data->texture_rocks_n = efl_add(EVAS_CANVAS3D_TEXTURE_CLASS, evas);
- efl_file_set(data->texture_rocks, rock_diffuse, NULL);
+ efl_file_simple_load(data->texture_rocks, rock_diffuse, NULL);
evas_canvas3d_texture_wrap_set(data->texture_rocks, EVAS_CANVAS3D_WRAP_MODE_REPEAT, EVAS_CANVAS3D_WRAP_MODE_REPEAT);
- efl_file_set(data->texture_rocks_n, rock_n_and_height_map, NULL);
+ efl_file_simple_load(data->texture_rocks_n, rock_n_and_height_map, NULL);
evas_canvas3d_texture_wrap_set(data->texture_rocks_n, EVAS_CANVAS3D_WRAP_MODE_REPEAT, EVAS_CANVAS3D_WRAP_MODE_REPEAT);
evas_canvas3d_material_texture_set(data->material_rocks, EVAS_CANVAS3D_MATERIAL_ATTRIB_NORMAL, data->texture_rocks_n);
@@ -160,9 +160,9 @@ _mesh_setup(Scene_Data *data)
data->texture_wood = efl_add(EVAS_CANVAS3D_TEXTURE_CLASS, evas);
data->texture_four_n = efl_add(EVAS_CANVAS3D_TEXTURE_CLASS, evas);
- efl_file_set(data->texture_wood, wood_diffuse, NULL);
+ efl_file_simple_load(data->texture_wood, wood_diffuse, NULL);
evas_canvas3d_texture_wrap_set(data->texture_wood, EVAS_CANVAS3D_WRAP_MODE_REPEAT, EVAS_CANVAS3D_WRAP_MODE_REPEAT);
- efl_file_set(data->texture_four_n, wood_n_and_height_map, NULL);
+ efl_file_simple_load(data->texture_four_n, wood_n_and_height_map, NULL);
evas_canvas3d_texture_wrap_set(data->texture_four_n, EVAS_CANVAS3D_WRAP_MODE_REPEAT, EVAS_CANVAS3D_WRAP_MODE_REPEAT);
evas_canvas3d_material_texture_set(data->material_wood, EVAS_CANVAS3D_MATERIAL_ATTRIB_NORMAL, data->texture_four_n);
diff --git a/src/examples/evas/evas-3d-pick.c b/src/examples/evas/evas-3d-pick.c
index 1e2f3d6ead..20230d0112 100644
--- a/src/examples/evas/evas-3d-pick.c
+++ b/src/examples/evas/evas-3d-pick.c
@@ -143,7 +143,7 @@ main(void)
material = efl_add(EVAS_CANVAS3D_MATERIAL_CLASS, evas);
texture_diffuse = efl_add(EVAS_CANVAS3D_TEXTURE_CLASS, evas);
- efl_file_set(texture_diffuse, image_path, NULL);
+ efl_file_simple_load(texture_diffuse, image_path, NULL);
evas_canvas3d_texture_filter_set(texture_diffuse, EVAS_CANVAS3D_TEXTURE_FILTER_LINEAR, EVAS_CANVAS3D_TEXTURE_FILTER_LINEAR);
evas_canvas3d_material_texture_set(material, EVAS_CANVAS3D_MATERIAL_ATTRIB_DIFFUSE, texture_diffuse);
evas_canvas3d_material_enable_set(material, EVAS_CANVAS3D_MATERIAL_ATTRIB_AMBIENT, EINA_TRUE);
diff --git a/src/examples/evas/evas-3d-ply.c b/src/examples/evas/evas-3d-ply.c
index 821195b30e..7769a45442 100644
--- a/src/examples/evas/evas-3d-ply.c
+++ b/src/examples/evas/evas-3d-ply.c
@@ -159,7 +159,7 @@ main(void)
material = efl_add(EVAS_CANVAS3D_MATERIAL_CLASS, evas);
texture = efl_add(EVAS_CANVAS3D_TEXTURE_CLASS, evas);
- efl_file_set(texture, image_path, NULL);
+ efl_file_simple_load(texture, image_path, NULL);
evas_canvas3d_texture_filter_set(texture, EVAS_CANVAS3D_TEXTURE_FILTER_NEAREST, EVAS_CANVAS3D_TEXTURE_FILTER_NEAREST);
evas_canvas3d_texture_wrap_set(texture, EVAS_CANVAS3D_WRAP_MODE_REPEAT, EVAS_CANVAS3D_WRAP_MODE_REPEAT);
evas_canvas3d_material_texture_set(material, EVAS_CANVAS3D_MATERIAL_ATTRIB_DIFFUSE, texture);
@@ -182,7 +182,7 @@ main(void)
mesh[i] = efl_add(EVAS_CANVAS3D_MESH_CLASS, evas);
snprintf(buffer, PATH_MAX, "%s%s", input_template, file_name[i % 8]);
- efl_file_set(mesh[i], buffer, NULL);
+ efl_file_simple_load(mesh[i], buffer, NULL);
evas_canvas3d_mesh_frame_material_set(mesh[i], 0, material);
evas_canvas3d_mesh_shader_mode_set(mesh[i], draw_mode[(i % 8)]);
@@ -191,7 +191,7 @@ main(void)
if (i > 15)
{
- efl_file_set(mesh[i], buffer, NULL);
+ efl_file_simple_load(mesh[i], buffer, NULL);
evas_canvas3d_mesh_frame_material_set(mesh[i], 0, material);
evas_canvas3d_mesh_shader_mode_set(mesh[i], draw_mode[(i % 8)]);
}
diff --git a/src/examples/evas/evas-3d-shadows.c b/src/examples/evas/evas-3d-shadows.c
index ae06a3631a..16733183f4 100644
--- a/src/examples/evas/evas-3d-shadows.c
+++ b/src/examples/evas/evas-3d-shadows.c
@@ -262,12 +262,12 @@ _fence_setup(Body_3D *fence)
Eo *texture = efl_add(EVAS_CANVAS3D_TEXTURE_CLASS, evas);
evas_canvas3d_texture_atlas_enable_set(texture, EINA_FALSE);
- efl_file_set(texture, PACKAGE_EXAMPLES_DIR EVAS_IMAGE_FOLDER "/grid.png", NULL);
+ efl_file_simple_load(texture, PACKAGE_EXAMPLES_DIR EVAS_IMAGE_FOLDER "/grid.png", NULL);
evas_canvas3d_texture_filter_set(texture, EVAS_CANVAS3D_TEXTURE_FILTER_NEAREST, EVAS_CANVAS3D_TEXTURE_FILTER_NEAREST);
evas_canvas3d_texture_wrap_set(texture, EVAS_CANVAS3D_WRAP_MODE_REPEAT, EVAS_CANVAS3D_WRAP_MODE_REPEAT);
Eo *texture1 = efl_add(EVAS_CANVAS3D_TEXTURE_CLASS, evas);
evas_canvas3d_texture_atlas_enable_set(texture1, EINA_FALSE);
- efl_file_set(texture1, PACKAGE_EXAMPLES_DIR EVAS_IMAGE_FOLDER "/grid_n.png", NULL);
+ efl_file_simple_load(texture1, PACKAGE_EXAMPLES_DIR EVAS_IMAGE_FOLDER "/grid_n.png", NULL);
evas_canvas3d_texture_filter_set(texture1, EVAS_CANVAS3D_TEXTURE_FILTER_NEAREST, EVAS_CANVAS3D_TEXTURE_FILTER_NEAREST);
evas_canvas3d_texture_wrap_set(texture1, EVAS_CANVAS3D_WRAP_MODE_REPEAT, EVAS_CANVAS3D_WRAP_MODE_REPEAT);
fence->material = efl_add(EVAS_CANVAS3D_MATERIAL_CLASS, evas);
@@ -344,7 +344,7 @@ static void
_model_setup(Body_3D *model)
{
model->texture = efl_add(EVAS_CANVAS3D_TEXTURE_CLASS, evas);
- efl_file_set(model->texture, image_path, NULL);
+ efl_file_simple_load(model->texture, image_path, NULL);
evas_canvas3d_texture_filter_set(model->texture, EVAS_CANVAS3D_TEXTURE_FILTER_NEAREST, EVAS_CANVAS3D_TEXTURE_FILTER_NEAREST);
evas_canvas3d_texture_wrap_set(model->texture, EVAS_CANVAS3D_WRAP_MODE_REPEAT, EVAS_CANVAS3D_WRAP_MODE_REPEAT);
model->material = efl_add(EVAS_CANVAS3D_MATERIAL_CLASS, evas);
@@ -358,7 +358,7 @@ _model_setup(Body_3D *model)
model->mesh = efl_add(EVAS_CANVAS3D_MESH_CLASS, evas);
- efl_file_set(model->mesh, model_path, NULL);
+ efl_file_simple_load(model->mesh, model_path, NULL);
evas_canvas3d_mesh_frame_material_set(model->mesh, 0, model->material);
evas_canvas3d_mesh_shader_mode_set(model->mesh, EVAS_CANVAS3D_SHADER_MODE_PHONG);
@@ -373,7 +373,7 @@ static void
_billboard_setup(Scene_Data *data)
{
data->billboard.texture = efl_add(EVAS_CANVAS3D_TEXTURE_CLASS, evas);
- efl_file_set(data->billboard.texture, b_image_path, NULL);
+ efl_file_simple_load(data->billboard.texture, b_image_path, NULL);
evas_canvas3d_texture_filter_set(data->billboard.texture, EVAS_CANVAS3D_TEXTURE_FILTER_NEAREST, EVAS_CANVAS3D_TEXTURE_FILTER_NEAREST);
evas_canvas3d_texture_wrap_set(data->billboard.texture, EVAS_CANVAS3D_WRAP_MODE_REPEAT, EVAS_CANVAS3D_WRAP_MODE_REPEAT);
diff --git a/src/examples/evas/evas-3d-static-lod.c b/src/examples/evas/evas-3d-static-lod.c
index d7672a48b5..92e3b1a1a9 100644
--- a/src/examples/evas/evas-3d-static-lod.c
+++ b/src/examples/evas/evas-3d-static-lod.c
@@ -179,14 +179,14 @@ _mesh_setup(Scene_Data *data)
Eo *mesh = efl_add(EVAS_CANVAS3D_MESH_CLASS, evas);
Eina_Stringshare *str = eina_stringshare_printf("%s%d%s", model_path,
i, ".obj");
- efl_file_set(mesh, str, NULL);
+ efl_file_simple_load(mesh, str, NULL);
evas_canvas3d_mesh_frame_material_set(mesh, 0, data->material);
evas_canvas3d_mesh_shader_mode_set(mesh, EVAS_CANVAS3D_SHADER_MODE_PHONG);
evas_canvas3d_mesh_lod_boundary_set(mesh, distances[i], distances[i + 1]);
evas_canvas3d_node_mesh_add(data->lod_mesh_node1, mesh);
mesh = efl_add(EVAS_CANVAS3D_MESH_CLASS, evas);
- efl_file_set(mesh, str, NULL);
+ efl_file_simple_load(mesh, str, NULL);
evas_canvas3d_mesh_frame_material_set(mesh, 0, data->material);
evas_canvas3d_mesh_shader_mode_set(mesh, EVAS_CANVAS3D_SHADER_MODE_PHONG);
evas_canvas3d_mesh_lod_boundary_set(mesh, m_distances[i], m_distances[i + 1]);
diff --git a/src/examples/evas/evas-object-manipulation-eo.c b/src/examples/evas/evas-object-manipulation-eo.c
index 551d2873f7..4d4c37fa90 100644
--- a/src/examples/evas/evas-object-manipulation-eo.c
+++ b/src/examples/evas/evas-object-manipulation-eo.c
@@ -122,15 +122,15 @@ _on_keydown(void *data EINA_UNUSED,
printf("Toggling clipping ");
Evas_Object *clip = NULL;
- clip = efl_canvas_object_clip_get(d.img);
+ clip = efl_canvas_object_clipper_get(d.img);
if (clip == d.clipper)
{
- efl_canvas_object_clip_set(d.img, NULL);
+ efl_canvas_object_clipper_set(d.img, NULL);
printf("off\n");
}
else
{
- efl_canvas_object_clip_set(d.img, d.clipper);
+ efl_canvas_object_clipper_set(d.img, d.clipper);
printf("on\n");
}
return;
@@ -193,8 +193,9 @@ main(void)
* So it's possible to decrement refcount, and 'image' object
* will be deleted automatically by parent.*/
- efl_file_set(d.img, img_path, NULL);
- err = efl_file_load_error_get(d.img);
+ if (efl_file_set(d.img, img_path)) goto panic;
+
+ err = efl_file_load(d.img);
if (err != EVAS_LOAD_ERROR_NONE)
{
@@ -211,8 +212,8 @@ main(void)
/* border on the image's clipper, here just to emphasize its position */
d.clipper_border = efl_add(EFL_CANVAS_IMAGE_CLASS, d.canvas);
- efl_file_set(d.clipper_border, border_img_path, NULL);
- err = efl_file_load_error_get(d.clipper_border);
+ if (efl_file_set(d.clipper_border, border_img_path)) goto panic;
+ err = efl_file_load(d.clipper_border);
if (err != EVAS_LOAD_ERROR_NONE)
{
@@ -236,7 +237,7 @@ main(void)
efl_gfx_entity_size_set(d.clipper, EINA_SIZE2D(WIDTH / 2, HEIGHT / 2));
efl_gfx_entity_visible_set(d.clipper, EINA_TRUE);
- efl_canvas_object_clip_set(d.img, d.clipper);
+ efl_canvas_object_clipper_set(d.img, d.clipper);
printf("%s", commands);
diff --git a/src/examples/evas/evas-vg-batman.c b/src/examples/evas/evas-vg-batman.c
index 650709f250..da9176cc93 100644
--- a/src/examples/evas/evas-vg-batman.c
+++ b/src/examples/evas/evas-vg-batman.c
@@ -133,7 +133,7 @@ main(void)
for (i = 0; i < sizeof (batmans_path) / sizeof (batmans_path[0]); i++)
{
batmans_vg[i] = evas_vg_shape_add(vg);
- evas_vg_node_origin_set(batmans_vg[i], 100, 150);
+ efl_canvas_vg_node_origin_set(batmans_vg[i], 100, 150);
if(i % 2)
{
@@ -162,7 +162,7 @@ main(void)
Eina_Matrix3 matrix;
eina_matrix3_identity(&matrix);
eina_matrix3_scale(&matrix, 1.1, 1.1);
- evas_vg_node_transformation_set(root, &matrix);
+ efl_canvas_vg_node_transformation_set(root, &matrix);
circle = evas_vg_shape_add(root);
evas_vg_shape_append_circle(circle, WIDTH / 2, HEIGHT / 2, 200);
@@ -172,7 +172,7 @@ main(void)
batman = evas_vg_shape_add(root);
evas_vg_node_color_set(batman, 0, 0, 0, 255);
- evas_vg_node_origin_set(batman, 100, 150);
+ efl_canvas_vg_node_origin_set(batman, 100, 150);
evas_vg_shape_append_move_to(batman, 256, 213);
evas_vg_shape_dup(batman, batmans_vg[0]);
diff --git a/src/examples/evas/evas-vg-simple.c b/src/examples/evas/evas-vg-simple.c
index 36b8baaf55..47889ae024 100644
--- a/src/examples/evas/evas-vg-simple.c
+++ b/src/examples/evas/evas-vg-simple.c
@@ -152,15 +152,15 @@ _added_transformation(Efl_VG *shape, Eina_Matrix3 *m)
Eina_Matrix3 new_m;
const Eina_Matrix3 *old_m;
- old_m = evas_vg_node_transformation_get(shape);
+ old_m = efl_canvas_vg_node_transformation_get(shape);
if (old_m)
{
eina_matrix3_compose(m, old_m, &new_m);
- evas_vg_node_transformation_set(shape, &new_m);
+ efl_canvas_vg_node_transformation_set(shape, &new_m);
}
else
{
- evas_vg_node_transformation_set(shape, m);
+ efl_canvas_vg_node_transformation_set(shape, m);
}
}
@@ -317,7 +317,7 @@ _1_basic_shape_test()
evas_vg_shape_append_line_to(shape, 100, 0);
evas_vg_shape_stroke_color_set(shape, 255, 0, 0, 255);
evas_vg_shape_stroke_width_set(shape, 5);
- evas_vg_node_origin_set(shape, 50, 50);
+ efl_canvas_vg_node_origin_set(shape, 50, 50);
evas_vg_shape_stroke_cap_set(shape, EFL_GFX_CAP_ROUND);
d.shape_list = eina_list_append(d.shape_list, shape);
@@ -325,7 +325,7 @@ _1_basic_shape_test()
evas_vg_shape_dup(new_shape, shape);
evas_vg_shape_stroke_color_set(new_shape, 0, 100, 0, 100);
evas_vg_shape_append_line_to(new_shape, 100, 50);
- evas_vg_node_origin_set(new_shape, 200, 50);
+ efl_canvas_vg_node_origin_set(new_shape, 200, 50);
evas_vg_shape_stroke_cap_set(new_shape, EFL_GFX_CAP_SQUARE);
d.shape_list = eina_list_append(d.shape_list, new_shape);
@@ -333,7 +333,7 @@ _1_basic_shape_test()
evas_vg_shape_dup(new_shape, shape);
evas_vg_shape_stroke_color_set(new_shape, 0, 0, 255, 255);
evas_vg_shape_append_line_to(new_shape, 50, 50);
- evas_vg_node_origin_set(new_shape, 350, 50);
+ efl_canvas_vg_node_origin_set(new_shape, 350, 50);
evas_vg_shape_stroke_cap_set(new_shape, EFL_GFX_CAP_ROUND);
evas_vg_shape_stroke_join_set(new_shape, EFL_GFX_JOIN_ROUND);
d.shape_list = eina_list_append(d.shape_list, new_shape);
@@ -343,21 +343,21 @@ _1_basic_shape_test()
evas_vg_shape_append_rect(shape, 0, 0, 100 , 100, 10, 10);
evas_vg_shape_stroke_color_set(shape, 255, 0, 0, 255);
evas_vg_shape_stroke_width_set(shape, 5);
- evas_vg_node_origin_set(shape, 50, 150);
+ efl_canvas_vg_node_origin_set(shape, 50, 150);
d.shape_list = eina_list_append(d.shape_list, shape);
new_shape = evas_vg_shape_add(container);
evas_vg_shape_dup(new_shape, shape);
evas_vg_shape_stroke_color_set(new_shape, 0, 0, 0, 0);
evas_vg_node_color_set(new_shape, 0, 0, 100, 100);
- evas_vg_node_origin_set(new_shape, 200, 150);
+ efl_canvas_vg_node_origin_set(new_shape, 200, 150);
d.shape_list = eina_list_append(d.shape_list, new_shape);
new_shape = evas_vg_shape_add(container);
evas_vg_shape_dup(new_shape, shape);
evas_vg_shape_stroke_color_set(new_shape, 100, 0, 0, 100);
evas_vg_node_color_set(new_shape, 0, 100, 100, 100);
- evas_vg_node_origin_set(new_shape, 350, 150);
+ efl_canvas_vg_node_origin_set(new_shape, 350, 150);
d.shape_list = eina_list_append(d.shape_list, new_shape);
// Circle
@@ -365,21 +365,21 @@ _1_basic_shape_test()
evas_vg_shape_append_circle(shape, 50, 50, 50);
evas_vg_shape_stroke_color_set(shape, 255, 0, 0, 255);
evas_vg_shape_stroke_width_set(shape, 5);
- evas_vg_node_origin_set(shape, 50, 300);
+ efl_canvas_vg_node_origin_set(shape, 50, 300);
d.shape_list = eina_list_append(d.shape_list, shape);
new_shape = evas_vg_shape_add(container);
evas_vg_shape_dup(new_shape, shape);
evas_vg_shape_stroke_color_set(new_shape, 0, 0, 0, 0);
evas_vg_node_color_set(new_shape, 0, 0, 255, 255);
- evas_vg_node_origin_set(new_shape, 200, 300);
+ efl_canvas_vg_node_origin_set(new_shape, 200, 300);
d.shape_list = eina_list_append(d.shape_list, new_shape);
new_shape = evas_vg_shape_add(container);
evas_vg_shape_dup(new_shape, shape);
evas_vg_shape_stroke_color_set(new_shape, 150, 0, 0, 150);
evas_vg_node_color_set(new_shape, 0, 0, 200, 200);
- evas_vg_node_origin_set(new_shape, 350, 300);
+ efl_canvas_vg_node_origin_set(new_shape, 350, 300);
d.shape_list = eina_list_append(d.shape_list, new_shape);
// Arc
@@ -389,14 +389,14 @@ _1_basic_shape_test()
evas_vg_shape_stroke_cap_set(shape, EFL_GFX_CAP_ROUND);
evas_vg_shape_stroke_color_set(shape, 255, 0, 0, 255);
evas_vg_shape_stroke_width_set(shape, 5);
- evas_vg_node_origin_set(shape, 50, 450);
+ efl_canvas_vg_node_origin_set(shape, 50, 450);
d.shape_list = eina_list_append(d.shape_list, shape);
new_shape = evas_vg_shape_add(container);
evas_vg_shape_append_arc(new_shape, 0, 0, 100, 100, 90, 200);
evas_vg_shape_stroke_color_set(new_shape, 0, 0, 0, 0);
evas_vg_node_color_set(new_shape, 0, 0, 200, 200);
- evas_vg_node_origin_set(new_shape, 200, 450);
+ efl_canvas_vg_node_origin_set(new_shape, 200, 450);
d.shape_list = eina_list_append(d.shape_list, new_shape);
new_shape = evas_vg_shape_add(container);
@@ -404,7 +404,7 @@ _1_basic_shape_test()
evas_vg_shape_append_line_to(new_shape, 50, 50);
evas_vg_shape_stroke_color_set(new_shape, 0, 0, 0, 0);
evas_vg_node_color_set(new_shape, 0, 0, 200, 200);
- evas_vg_node_origin_set(new_shape, 350, 450);
+ efl_canvas_vg_node_origin_set(new_shape, 350, 450);
d.shape_list = eina_list_append(d.shape_list, new_shape);
evas_object_vg_root_node_set(d.vg, container);
@@ -480,18 +480,18 @@ _2_interpolation_test()
evas_vg_shape_append_svg_path(shape, morph1[0]);
evas_vg_shape_stroke_color_set(shape, 255, 0, 0, 255);
evas_vg_shape_stroke_width_set(shape, 5);
- evas_vg_node_origin_set(shape, 100, 100);
+ efl_canvas_vg_node_origin_set(shape, 100, 100);
d.shape_list = eina_list_append(d.shape_list, shape);
shape = evas_vg_shape_add(d.vg);
evas_vg_shape_append_svg_path(shape, morph1[1]);
evas_vg_shape_stroke_color_set(shape, 0, 0, 255, 255);
evas_vg_shape_stroke_width_set(shape, 10);
- evas_vg_node_origin_set(shape, 150, 150);
+ efl_canvas_vg_node_origin_set(shape, 150, 150);
d.shape_list = eina_list_append(d.shape_list, shape);
shape = evas_vg_shape_add(d.vg);
- evas_vg_node_origin_set(shape, 150, 150);
+ efl_canvas_vg_node_origin_set(shape, 150, 150);
d.shape_list = eina_list_append(d.shape_list, shape);
evas_object_vg_root_node_set(d.vg, shape);
@@ -522,7 +522,7 @@ _main_menu()
shape = evas_vg_shape_add(d.vg);
evas_vg_shape_append_svg_path(shape, batman);
evas_vg_node_color_set(shape, 10, 0, 0, 10);
- evas_vg_node_origin_set(shape, 0, 100);
+ efl_canvas_vg_node_origin_set(shape, 0, 100);
evas_object_vg_root_node_set(d.vg, shape);
diff --git a/src/examples/evas/evas_cxx_rectangle.cc b/src/examples/evas/evas_cxx_rectangle.cc
index 464bed96aa..7966d62e1b 100644
--- a/src/examples/evas/evas_cxx_rectangle.cc
+++ b/src/examples/evas/evas_cxx_rectangle.cc
@@ -14,8 +14,8 @@
#include <Eina.hh>
#include <Eo.hh>
-#include "canvas/evas_canvas.eo.hh"
-#include "canvas/evas_image.eo.hh"
+#include "canvas/evas_canvas_eo.hh"
+#include "canvas/evas_image_eo.hh"
#include "canvas/evas_rectangle.eo.hh"
#define WIDTH (320)
diff --git a/src/examples/evas/evas_mono_box.cs b/src/examples/evas/evas_mono_box.cs
deleted file mode 100644
index dbfd15e372..0000000000
--- a/src/examples/evas/evas_mono_box.cs
+++ /dev/null
@@ -1,73 +0,0 @@
-using System;
-using System.Runtime.InteropServices;
-using System.Runtime.CompilerServices;
-
-public class MyBox : Evas.Box
-{
- public MyBox(Efl.Object parent) : base(parent) {}
-
- [DllImport("evas")] static extern void evas_obj_box_layout_vertical(IntPtr obj, IntPtr data, IntPtr privdata);
- [DllImport("evas")] static extern void evas_obj_box_layout_horizontal(IntPtr obj, IntPtr data, IntPtr privdata);
- [DllImport("evas")] static extern void evas_object_box_layout_horizontal(IntPtr obj, IntPtr data, IntPtr privdata);
- [DllImport("evas")] static extern IntPtr evas_object_evas_get(IntPtr obj);
- [DllImport("evas")] static extern void evas_event_freeze(IntPtr obj);
- [DllImport("evas")] static extern void evas_event_thaw(IntPtr obj);
-
- override public void CalculateGroup()
- {
- IntPtr evas = evas_object_evas_get(NativeHandle);
- evas_event_freeze(evas);
- Console.WriteLine("called group_calculate");
- /* layouting_set(true); */
- evas_obj_box_layout_vertical(NativeHandle, IntPtr.Zero, IntPtr.Zero);
- /* layouting_set(false); */
- /* children_changed_set(false); */
- evas_event_thaw(evas);
- }
-}
-
-class TestMain
-{
- static void Main(string[] args)
- {
- Efl.All.Init();
-
- Efl.Loop loop = new Efl.Loop();
-
-
- EcoreEvas ecore_evas = new EcoreEvas();
-
- Efl.Canvas.Object canvas = ecore_evas.canvas;
- canvas.SetVisible(true);
-
- Efl.Object parent = canvas.GetParent();
- System.Diagnostics.Debug.Assert(parent.NativeHandle != IntPtr.Zero);
-
- Evas.Box box = new MyBox(canvas);
- Eina.Size2D size = new Eina.Size2D();
-
- size.W = 320;
- size.H = 240;
-
- box.SetSize(size);
- box.SetVisible(true);
-
- Efl.Canvas.Rectangle rect = new Efl.Canvas.Rectangle(canvas);
- rect.SetColor(0, 0, 255, 255);
- size.W = 320;
- size.H = 120;
- rect.SetSize(size);
- rect.SetVisible(true);
- box.Append(rect);
-
- Efl.Canvas.Rectangle rect2 = new Efl.Canvas.Rectangle(canvas);
- rect2.SetColor(0, 255, 0, 255);
- rect2.SetSize(size);
- rect2.SetVisible(true);
- box.Append(rect2);
-
- loop.Begin();
-
- Efl.All.Shutdown();
- }
-}
diff --git a/src/examples/evas/evas_mono_image.cs b/src/examples/evas/evas_mono_image.cs
deleted file mode 100644
index 865aa42502..0000000000
--- a/src/examples/evas/evas_mono_image.cs
+++ /dev/null
@@ -1,93 +0,0 @@
-using System;
-using System.Runtime.CompilerServices;
-
-class TestMain
-{
- static int WIDTH = 320;
- static int HEIGHT = 240;
-
- Evas.Image image;
-
-
- static string ImagePath([CallerFilePath] string folder="")
- {
- return System.IO.Path.GetDirectoryName(folder);
- }
-
- public TestMain(Evas.Image image)
- {
- this.image = image;
- }
-
- static void Main(string[] args)
- {
- Efl.All.Init();
-
- Efl.Loop loop = new Efl.Loop();
-
- EcoreEvas ecore_evas = new EcoreEvas();
- Eina.Size2D size = new Eina.Size2D();
-
- Efl.Canvas.Object canvas = ecore_evas.canvas;
- canvas.SetVisible(true);
-
- Efl.Object parent = canvas.GetParent();
- System.Diagnostics.Debug.Assert(parent.NativeHandle != IntPtr.Zero);
-
- Efl.Canvas.Rectangle bg = new Efl.Canvas.Rectangle(canvas);
- bg.SetColor(255, 255, 255, 255);
- size.W = WIDTH;
- size.H = HEIGHT;
- bg.SetSize(size);
- bg.SetVisible(true);
-
- string valid_path = args[0];
- Evas.Image image = new Evas.Image(canvas);
- image.SetFile(valid_path, null);
-
- /* FIXME evas-image uses error handling code from
- * evas_object_image_load_error_get, which seems to be not available
- * Efl.image.load.State state = image.load_error_get(); */
-
- // FIXME missing move
- Eina.Rect rect = new Eina.Rect();
-
- rect.X = 0;
- rect.Y = 0;
- rect.W = WIDTH / 2;
- rect.H = HEIGHT / 2;
- image.SetFill(rect);
-
- size.W = WIDTH / 2;
- size.H = HEIGHT / 2;
- image.SetSize(size);
- image.SetVisible(true);
-
- rect = image.GetFill();
- rect.Y -= 50;
- rect.W += 100;
- image.SetFill(rect);
-
- TestMain listener = new TestMain(image);
-
- // TODO handle key events in order to alter the image like the C
- // example. Meanwhile, just set some w fill
- /* EventListener callback = new EventListener(); */
-
- /* bg.key_focus_set(true); */
- /* bg.event_callback_priority_add(Evas.Callback_Type.Key_down, */
- /* Efl.Callback_Priority.Default, */
- /* callback, null); */
-
- loop.Begin();
-
- Efl.All.Shutdown();
- }
-
- public void on_key_down(object sender, EventArgs e)
- {
- Console.WriteLine("on_key_down called");
- }
-}
-
-
diff --git a/src/examples/evas/evas_mono_image2.cs b/src/examples/evas/evas_mono_image2.cs
deleted file mode 100644
index 0ad8fb0872..0000000000
--- a/src/examples/evas/evas_mono_image2.cs
+++ /dev/null
@@ -1,83 +0,0 @@
-using System;
-using System.Runtime.InteropServices;
-using System.Runtime.CompilerServices;
-
-class TestMain
-{
- static int WIDTH = 320;
- static int HEIGHT = 240;
-
-
- static void Main(string[] args)
- {
- Efl.All.Init();
-
- Efl.Loop loop = new Efl.Loop();
-
- EcoreEvas ecore_evas = new EcoreEvas();
-
- Eina.Size2D size = new Eina.Size2D();
- Eina.Position2D pos = new Eina.Position2D();
-
- Efl.Canvas.Object canvas = ecore_evas.canvas;
- canvas.SetVisible(true);
-
- Efl.Canvas.Rectangle bg = new Efl.Canvas.Rectangle(canvas);
- bg.SetColor(255, 255, 255, 255);
- pos.X = 0;
- pos.Y = 0;
- bg.SetPosition(pos);
- size.W = WIDTH;
- size.H = HEIGHT;
- bg.SetSize(size);
- bg.SetVisible(true);
-
- string path = args[0];
- Evas.Image logo = new Evas.Image(canvas);
- logo.SetFillAuto(true);
-
- // TODO add preloaded support (depends on events)
-
- logo.SetFile(path, null);
- size.W = WIDTH / 2;
- size.H = HEIGHT / 2;
- logo.SetSize(size);
-
- // TODO add a bunch of key/mouse handlers
-
- logo.SetVisible(true);
-
- int[] pixels = new int[(WIDTH/4) * (HEIGHT / 4)];
- System.Random generator = new System.Random();
- for (int i = 0; i < pixels.Length; i++) {
- pixels[i] = generator.Next();
- }
-
- Evas.Image noise_img = new Evas.Image(canvas);
- size.W = WIDTH / 4;
- size.H = HEIGHT / 4;
- noise_img.SetSize(size);
- // FIXME Add a way to set the pixels.
- // noise_img.data_set(pixels);
- noise_img.SetFillAuto(true);
- pos.X = WIDTH * 5 / 8;
- pos.Y = HEIGHT / 8;
- noise_img.SetPosition(pos);
- noise_img.SetVisible(true);
- Console.WriteLine("Creating noise image with sizez %d, %d", WIDTH/4, HEIGHT/4);
-
- Efl.Canvas.Proxy proxy_img = new Efl.Canvas.Proxy(canvas);
- proxy_img.SetSource(noise_img);
- pos.X = WIDTH / 2;
- pos.Y = HEIGHT / 2;
- proxy_img.SetPosition(pos);
- size.W = WIDTH / 2;
- size.H = HEIGHT / 2;
- proxy_img.SetSize(size);
- proxy_img.SetVisible(true);
-
- loop.Begin();
- }
-}
-
-
diff --git a/src/examples/evas/evas_mono_rectangle.cs b/src/examples/evas/evas_mono_rectangle.cs
deleted file mode 100644
index 85afbd2e61..0000000000
--- a/src/examples/evas/evas_mono_rectangle.cs
+++ /dev/null
@@ -1,47 +0,0 @@
-using System;
-
-class TestMain
-{
- private static int[,] colors = new int[,] {
- {255, 0, 0},
- {0, 255, 0},
- {0, 0, 255}
- };
-
- static void Main(string[] args)
- {
- int color_index = 0;
-
- Efl.All.Init();
-
- Efl.Loop loop = new Efl.Loop();
- EcoreEvas ecore_evas = new EcoreEvas();
- Efl.Canvas.Object canvas = ecore_evas.canvas;
- canvas.SetVisible(true);
-
- Efl.Object parent = canvas.GetParent();
- System.Diagnostics.Debug.Assert(parent.NativeHandle != IntPtr.Zero);
-
- Efl.Canvas.Rectangle rect = new Efl.Canvas.Rectangle(canvas);
- rect.SetColor(colors[0, 0], colors[0, 1], colors[0, 2], 255);
- Eina.Size2D size = new Eina.Size2D();
- size.W = 640;
- size.H = 480;
- rect.SetSize(size);
- rect.SetVisible(true);
-
- canvas.KeyDownEvt += (object sender, Efl.Input.InterfaceKeyDownEvt_Args e) => {
- color_index = (color_index + 1) % 3;
- Console.WriteLine("Key Down");
- Console.WriteLine("Got key obj at {0}", e.arg.NativeHandle.ToString("X"));
- Console.WriteLine("Got key_get() == [{0}]", e.arg.GetKey());
- rect.SetColor(colors[color_index, 0],
- colors[color_index, 1],
- colors[color_index, 2], 255);
- };
-
- loop.Begin();
-
- Efl.All.Shutdown();
- }
-}
diff --git a/src/examples/evas/evas_mono_table.cs b/src/examples/evas/evas_mono_table.cs
deleted file mode 100644
index 25c3d5e78a..0000000000
--- a/src/examples/evas/evas_mono_table.cs
+++ /dev/null
@@ -1,77 +0,0 @@
-using System;
-using System.Runtime.InteropServices;
-using System.Runtime.CompilerServices;
-
-class TestMain
-{
- static int WIDTH = 100;
- static int HEIGHT = 150;
-
- static void Main(string[] args)
- {
- Efl.All.Init();
-
- Efl.Loop loop = new Efl.Loop();
-
- EcoreEvas ecore_evas = new EcoreEvas();
-
- Eina.Size2D size = new Eina.Size2D();
- size.W = WIDTH;
- size.H = HEIGHT;
-
- Eina.Size2D hint = new Eina.Size2D();
-
- Efl.Canvas.Object canvas = ecore_evas.canvas;
- canvas.SetVisible(true);
-
- Efl.Object parent = canvas.GetParent();
- System.Diagnostics.Debug.Assert(parent.NativeHandle != IntPtr.Zero);
-
- Efl.Canvas.Rectangle bg = new Efl.Canvas.Rectangle(canvas);
- bg.SetColor(255, 255, 255, 255);
- bg.SetSize(size);
- bg.SetVisible(true);
-
-
- Evas.Table table = new Evas.Table(canvas);
- table.SetHomogeneous(Evas.ObjectTable.HomogeneousMode.None);
- table.SetPadding(0, 0);
- table.SetSize(size);
- table.SetVisible(true);
-
- Efl.Canvas.Rectangle rect = new Efl.Canvas.Rectangle(canvas);
- rect.SetColor(255, 0, 0, 255);
- hint.W = 100;
- hint.H = 50;
- rect.SetHintSizeMin(hint);
- rect.SetVisible(true);
- table.Pack(rect, 1, 1, 2, 1);
-
- rect = new Efl.Canvas.Rectangle(canvas);
- rect.SetColor(0, 255, 0, 255);
- hint.W = 50;
- hint.H = 100;
- rect.SetHintSizeMin(hint);
- rect.SetVisible(true);
- table.Pack(rect, 1, 2, 1, 2);
-
- rect = new Efl.Canvas.Rectangle(canvas);
- rect.SetColor(0, 0, 255, 255);
- hint.W = 50;
- hint.H = 50;
- rect.SetHintSizeMin(hint);
- rect.SetVisible(true);
- table.Pack(rect, 2, 2, 1, 1);
-
- rect = new Efl.Canvas.Rectangle(canvas);
- rect.SetColor(255, 255, 0, 255);
- rect.SetHintSizeMin(hint);
- rect.SetVisible(true);
- table.Pack(rect, 2, 3, 1, 1);
-
- loop.Begin();
-
- Efl.All.Shutdown();
- }
-}
-
diff --git a/src/examples/evas/evas_mono_text.cs b/src/examples/evas/evas_mono_text.cs
deleted file mode 100644
index 52b89f2f10..0000000000
--- a/src/examples/evas/evas_mono_text.cs
+++ /dev/null
@@ -1,127 +0,0 @@
-using System;
-using System.Linq;
-using System.Collections.Generic;
-
-static class Extensions
-{
- public static IEnumerable<T> Circle<T>(this IEnumerable<T> list, int index=0)
- {
- var count = list.Count();
- index = index % count;
-
- while (true) {
- yield return list.ElementAt(index);
- index = (index + 1) % count;
- }
- }
-}
-
-class TestMain
-{
- static int WIDTH = 320;
- static int HEIGHT = 240;
-
- private EcoreEvas ecore_evas;
- private Efl.Canvas.Object canvas;
- private Efl.Canvas.Rectangle bg;
- private Evas.Text text;
- private Evas.Image border;
-
- public TestMain(String border_file) {
- ecore_evas = new EcoreEvas();
- Eina.Size2D size = new Eina.Size2D();
- Eina.Position2D position = new Eina.Position2D();
- canvas = ecore_evas.canvas;
- canvas.SetVisible(true);
-
- bg = new Efl.Canvas.Rectangle(canvas);
- bg.SetColor(255, 255, 255, 255);
- position.X = 0;
- position.Y = 0;
- bg.SetPosition(position);
- size.W = WIDTH;
- size.H = HEIGHT;
- bg.SetSize(size);
- bg.SetVisible(true);
- bg.SetKeyFocus(true);
-
- /* ((Efl.Input.Interface)bg).KeyDownEvt += On_KeyDown; */
- bg.KeyDownEvt += On_KeyDown;
-
- text = new Evas.Text(canvas);
- text.SetStyle(Evas.TextStyleType.OutlineSoftShadow);
-
- text.SetColor(0, 0, 0, 255);
- text.SetGlowColor(255, 0, 0, 255);
- text.SetOutlineColor(0, 0, 255, 255);
- text.SetShadowColor(0, 255,255, 255);
- text.SetFont("Courier", 30);
-
- text.SetText("sample text");
- size.W = 3*WIDTH / 4;
- size.H = HEIGHT / 4;
- text.SetSize(size);
- position.X = WIDTH / 8;
- position.Y = 3 * HEIGHT / 8;
- text.SetPosition(position);
- text.SetVisible(true);
-
- Efl.Font.Size font_size = 0;
- String font = String.Empty;
- text.GetFont(out font, out font_size);
- Console.WriteLine("Adding text object with font {0} and size {1}", font, size);
-
- // setup border
- border = new Evas.Image(canvas);
- border.SetFile(border_file, null);
- border.SetBorder(3, 3, 3, 3);
- border.SetBorderCenterFill(0);
-
- size.W = 3 * WIDTH / 4 + 3;
- size.H = HEIGHT / 4 + 3;
- border.SetSize(size);
- position.X = WIDTH / 8 - 3;
- position.Y = 3 * HEIGHT / 8 - 3;
- border.SetPosition(position);
- border.SetVisible(true);
-
-
- }
-
- private void On_KeyDown(object sender, Efl.Input.InterfaceKeyDownEvt_Args e)
- {
- var key = e.arg.GetKey();
-
- if (key == "h") {
- Console.WriteLine(commands);
- } else if (key == "t") {
- Evas.TextStyleType type = text.GetStyle();
- type = (Evas.TextStyleType)(((int)type + 1) % 10); // 10 hardcoded from C example
- text.SetStyle(type);
- }
- }
-
- static string commands = @"commands are:
- t - change text's current style
- h - print help";
-
-
- static void Main(string[] args)
- {
- Efl.All.Init();
-
- String border_path = "./src/examples/evas/resources/images/red.png";
-
- if (args.Length >= 1)
- border_path = args[0];
-
- Efl.Loop loop = new Efl.Loop();
- TestMain t = new TestMain(border_path);
-
- loop.Begin();
-
- Efl.All.Shutdown();
- }
-}
-
-
diff --git a/src/examples/evas/shooter/evas-3d-shooter-macros.h b/src/examples/evas/shooter/evas-3d-shooter-macros.h
index 9cb92a6cf8..94980ec2e3 100644
--- a/src/examples/evas/shooter/evas-3d-shooter-macros.h
+++ b/src/examples/evas/shooter/evas-3d-shooter-macros.h
@@ -150,13 +150,13 @@ typedef struct _vec2
#define MATERIAL_TEXTURE_SET(Object, Name, file, image) \
- efl_file_set(data->mesh_##Name, file, NULL); \
+ efl_file_simple_load(data->mesh_##Name, file, NULL); \
\
SETUP_DEFAULT_MESH(Object, Name, PHONG) \
data->texture_diffuse_##Object = efl_add(EVAS_CANVAS3D_TEXTURE_CLASS, evas); \
\
evas_canvas3d_texture_atlas_enable_set(data->texture_diffuse_##Object, EINA_FALSE); \
- efl_file_set(data->texture_diffuse_##Object, image, NULL); \
+ efl_file_simple_load(data->texture_diffuse_##Object, image, NULL); \
evas_canvas3d_texture_filter_set(data->texture_diffuse_##Object, EVAS_CANVAS3D_TEXTURE_FILTER_NEAREST, \
EVAS_CANVAS3D_TEXTURE_FILTER_NEAREST); \
evas_canvas3d_texture_wrap_set(data->texture_diffuse_##Object, EVAS_CANVAS3D_WRAP_MODE_REPEAT, EVAS_CANVAS3D_WRAP_MODE_REPEAT); \
@@ -175,7 +175,7 @@ typedef struct _vec2
data->texture_diffuse_##Object = efl_add(EVAS_CANVAS3D_TEXTURE_CLASS, evas); \
\
evas_canvas3d_texture_atlas_enable_set(data->texture_diffuse_##Object, EINA_FALSE); \
- efl_file_set(data->texture_diffuse_##Object, image, NULL); \
+ efl_file_simple_load(data->texture_diffuse_##Object, image, NULL); \
evas_canvas3d_texture_filter_set(data->texture_diffuse_##Object, EVAS_CANVAS3D_TEXTURE_FILTER_NEAREST, \
EVAS_CANVAS3D_TEXTURE_FILTER_NEAREST); \
evas_canvas3d_texture_wrap_set(data->texture_diffuse_##Object, EVAS_CANVAS3D_WRAP_MODE_REPEAT, EVAS_CANVAS3D_WRAP_MODE_REPEAT); \
@@ -190,7 +190,7 @@ typedef struct _vec2
data->texture_normal_##Object = efl_add(EVAS_CANVAS3D_TEXTURE_CLASS, evas); \
\
evas_canvas3d_texture_atlas_enable_set(data->texture_normal_##Object, EINA_FALSE); \
- efl_file_set(data->texture_normal_##Object, normal, NULL); \
+ efl_file_simple_load(data->texture_normal_##Object, normal, NULL); \
evas_canvas3d_texture_filter_set(data->texture_normal_##Object, EVAS_CANVAS3D_TEXTURE_FILTER_NEAREST, \
EVAS_CANVAS3D_TEXTURE_FILTER_NEAREST); \
evas_canvas3d_texture_wrap_set(data->texture_normal_##Object, EVAS_CANVAS3D_WRAP_MODE_REPEAT, EVAS_CANVAS3D_WRAP_MODE_REPEAT); \
diff --git a/src/examples/evas/shooter/evas-3d-shooter.c b/src/examples/evas/shooter/evas-3d-shooter.c
index ae6bedee7f..1c4deb4d7e 100644
--- a/src/examples/evas/shooter/evas-3d-shooter.c
+++ b/src/examples/evas/shooter/evas-3d-shooter.c
@@ -133,14 +133,14 @@ _key_down(void *data,
if (!scene->blending)
{
scene->blending = EINA_TRUE;
- efl_file_set(scene->texture_diffuse_carpet, gazebo_t_trans_path, NULL);
+ efl_file_simple_load(scene->texture_diffuse_carpet, gazebo_t_trans_path, NULL);
evas_canvas3d_mesh_blending_enable_set(scene->mesh_carpet, EINA_TRUE);
evas_canvas3d_mesh_blending_func_set(scene->mesh_carpet, EVAS_CANVAS3D_BLEND_FUNC_SRC_ALPHA, EVAS_CANVAS3D_BLEND_FUNC_ONE_MINUS_SRC_ALPHA);
}
else
{
scene->blending = EINA_FALSE;
- efl_file_set(scene->texture_diffuse_carpet, gazebo_t_path, NULL);
+ efl_file_simple_load(scene->texture_diffuse_carpet, gazebo_t_path, NULL);
evas_canvas3d_mesh_blending_enable_set(scene->mesh_carpet, EINA_FALSE);
}
}
@@ -733,7 +733,7 @@ _mesh_setup_gun_planet(Scene_Data *data)
ADD_MESH(tommy, tommy, 0.0, 0.3, 1.0)
SETUP_MESH_NODE(tommy)
- efl_file_set(data->mesh_tommy, gun_path, NULL);
+ efl_file_simple_load(data->mesh_tommy, gun_path, NULL);
efl_file_save(data->mesh_tommy, "try.obj", NULL, NULL);
evas_canvas3d_mesh_shader_mode_set(data->mesh_tommy, EVAS_CANVAS3D_SHADER_MODE_PHONG);
evas_canvas3d_mesh_frame_material_set(data->mesh_tommy, 0, data->material_tommy);
@@ -763,7 +763,7 @@ _mesh_setup_gun_planet(Scene_Data *data)
if (data->blending)
{
evas_canvas3d_texture_atlas_enable_set(data->texture_diffuse_carpet, EINA_FALSE);
- efl_file_set(data->texture_diffuse_carpet, gazebo_t_trans_path, NULL);
+ efl_file_simple_load(data->texture_diffuse_carpet, gazebo_t_trans_path, NULL);
evas_canvas3d_mesh_blending_enable_set(data->mesh_carpet, EINA_TRUE);
evas_canvas3d_mesh_blending_func_set(data->mesh_carpet, EVAS_CANVAS3D_BLEND_FUNC_SRC_ALPHA, EVAS_CANVAS3D_BLEND_FUNC_ONE_MINUS_SRC_ALPHA);
}
@@ -888,7 +888,7 @@ _mesh_setup_column(Scene_Data *data, int index)
data->texture_diffuse_column = efl_add(EVAS_CANVAS3D_TEXTURE_CLASS, evas);
- efl_file_set(data->texture_diffuse_column, red_brick_path, NULL);
+ efl_file_simple_load(data->texture_diffuse_column, red_brick_path, NULL);
evas_canvas3d_texture_atlas_enable_set(data->texture_diffuse_column, EINA_FALSE);
evas_canvas3d_texture_filter_set(data->texture_diffuse_column, EVAS_CANVAS3D_TEXTURE_FILTER_NEAREST, EVAS_CANVAS3D_TEXTURE_FILTER_NEAREST);
evas_canvas3d_texture_wrap_set(data->texture_diffuse_column, EVAS_CANVAS3D_WRAP_MODE_REPEAT, EVAS_CANVAS3D_WRAP_MODE_REPEAT);