[EGIT] [core/efl] master 01/01: elm_part_helper: Change macro name for default content part

2017-11-28 Thread Jaehyun Cho
jaehyun pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=4b18e754de9070c748a0ce5a7f4a3c6aa42a92ad

commit 4b18e754de9070c748a0ce5a7f4a3c6aa42a92ad
Author: Jaehyun Cho 
Date:   Wed Nov 29 13:43:21 2017 +0900

elm_part_helper: Change macro name for default content part
---
 src/lib/elementary/efl_ui_button.c  | 2 +-
 src/lib/elementary/efl_ui_flip.c| 2 +-
 src/lib/elementary/efl_ui_frame.c   | 2 +-
 src/lib/elementary/efl_ui_popup.c   | 2 +-
 src/lib/elementary/efl_ui_radio.c   | 2 +-
 src/lib/elementary/efl_ui_slider.c  | 2 +-
 src/lib/elementary/efl_ui_win.c | 2 +-
 src/lib/elementary/elc_ctxpopup.c   | 2 +-
 src/lib/elementary/elc_fileselector_entry.c | 2 +-
 src/lib/elementary/elc_player.c | 2 +-
 src/lib/elementary/elc_popup.c  | 2 +-
 src/lib/elementary/elm_entry.c  | 2 +-
 src/lib/elementary/elm_inwin.c  | 2 +-
 src/lib/elementary/elm_mapbuf.c | 2 +-
 src/lib/elementary/elm_notify.c | 2 +-
 src/lib/elementary/elm_part_helper.h| 2 +-
 src/lib/elementary/elm_scroller.c   | 2 +-
 src/lib/elementary/elm_widget.c | 2 +-
 18 files changed, 18 insertions(+), 18 deletions(-)

diff --git a/src/lib/elementary/efl_ui_button.c 
b/src/lib/elementary/efl_ui_button.c
index 36eaebd5bf..2f820baae3 100644
--- a/src/lib/elementary/efl_ui_button.c
+++ b/src/lib/elementary/efl_ui_button.c
@@ -409,7 +409,7 @@ _efl_ui_button_class_constructor(Efl_Class *klass)
 
 ELM_WIDGET_KEY_DOWN_DEFAULT_IMPLEMENT(efl_ui_button, Efl_Ui_Button_Data)
 ELM_PART_TEXT_DEFAULT_IMPLEMENT(efl_ui_button, Efl_Ui_Button_Data)
-ELM_PART_CONTENT_DEFAULT_SET(efl_ui_button, _content_aliases[0].real_part)
+ELM_PART_CONTENT_DEFAULT_GET(efl_ui_button, _content_aliases[0].real_part)
 ELM_PART_CONTENT_DEFAULT_IMPLEMENT(efl_ui_button, Efl_Ui_Button_Data)
 
 /* Efl.Part begin */
diff --git a/src/lib/elementary/efl_ui_flip.c b/src/lib/elementary/efl_ui_flip.c
index c001567b5d..feb83ffdb9 100644
--- a/src/lib/elementary/efl_ui_flip.c
+++ b/src/lib/elementary/efl_ui_flip.c
@@ -2353,7 +2353,7 @@ ELM_PART_OVERRIDE(efl_ui_flip, EFL_UI_FLIP, 
Efl_Ui_Flip_Data)
 ELM_PART_OVERRIDE_CONTENT_SET(efl_ui_flip, EFL_UI_FLIP, Efl_Ui_Flip_Data)
 ELM_PART_OVERRIDE_CONTENT_GET(efl_ui_flip, EFL_UI_FLIP, Efl_Ui_Flip_Data)
 ELM_PART_OVERRIDE_CONTENT_UNSET(efl_ui_flip, EFL_UI_FLIP, Efl_Ui_Flip_Data)
-ELM_PART_CONTENT_DEFAULT_SET(efl_ui_flip, "front")
+ELM_PART_CONTENT_DEFAULT_GET(efl_ui_flip, "front")
 #include "efl_ui_flip_part.eo.c"
 
 /* Efl.Part end */
diff --git a/src/lib/elementary/efl_ui_frame.c 
b/src/lib/elementary/efl_ui_frame.c
index 2ca12ad428..b1cab58135 100644
--- a/src/lib/elementary/efl_ui_frame.c
+++ b/src/lib/elementary/efl_ui_frame.c
@@ -215,7 +215,7 @@ _efl_ui_frame_class_constructor(Efl_Class *klass)
 
 ELM_PART_TEXT_DEFAULT_IMPLEMENT(efl_ui_frame, Efl_Ui_Frame_Data)
 ELM_PART_MARKUP_DEFAULT_IMPLEMENT(efl_ui_frame, Efl_Ui_Frame_Data)
-ELM_PART_CONTENT_DEFAULT_SET(efl_ui_frame, "elm.swallow.content")
+ELM_PART_CONTENT_DEFAULT_GET(efl_ui_frame, "elm.swallow.content")
 ELM_PART_CONTENT_DEFAULT_IMPLEMENT(efl_ui_frame, Efl_Ui_Frame_Data)
 
 /* Internal EO APIs and hidden overrides */
diff --git a/src/lib/elementary/efl_ui_popup.c 
b/src/lib/elementary/efl_ui_popup.c
index 0975386735..7f8fbe133b 100644
--- a/src/lib/elementary/efl_ui_popup.c
+++ b/src/lib/elementary/efl_ui_popup.c
@@ -253,7 +253,7 @@ _efl_ui_popup_content_unset(Eo *obj, Efl_Ui_Popup_Data *pd 
EINA_UNUSED, const ch
 
 /* Standard widget overrides */
 
-ELM_PART_CONTENT_DEFAULT_SET(efl_ui_popup, "elm.swallow.content")
+ELM_PART_CONTENT_DEFAULT_GET(efl_ui_popup, "elm.swallow.content")
 ELM_PART_CONTENT_DEFAULT_IMPLEMENT(efl_ui_popup, Efl_Ui_Popup_Data)
 
 /* Efl.Part begin */
diff --git a/src/lib/elementary/efl_ui_radio.c 
b/src/lib/elementary/efl_ui_radio.c
index f0b4f563fd..56b901f80c 100644
--- a/src/lib/elementary/efl_ui_radio.c
+++ b/src/lib/elementary/efl_ui_radio.c
@@ -366,7 +366,7 @@ _efl_ui_radio_efl_access_state_set_get(Eo *obj, 
Efl_Ui_Radio_Data *pd EINA_UNUSE
 
 /* Part APIs */
 
-ELM_PART_CONTENT_DEFAULT_SET(efl_ui_radio, "elm.swallow.content")
+ELM_PART_CONTENT_DEFAULT_GET(efl_ui_radio, "elm.swallow.content")
 ELM_PART_CONTENT_DEFAULT_IMPLEMENT(efl_ui_radio, Efl_Ui_Radio_Data)
 
 /* Internal EO APIs and hidden overrides */
diff --git a/src/lib/elementary/efl_ui_slider.c 
b/src/lib/elementary/efl_ui_slider.c
index b5da71ef2a..0af9a787f2 100644
--- a/src/lib/elementary/efl_ui_slider.c
+++ b/src/lib/elementary/efl_ui_slider.c
@@ -1355,7 +1355,7 @@ 
_efl_ui_slider_efl_access_widget_action_elm_actions_get(Eo *obj EINA_UNUSED, Efl
 
 ELM_PART_TEXT_DEFAULT_IMPLEMENT(efl_ui_slider, Efl_Ui_Slider_Data)
 ELM_PART_MARKUP_DEFAULT_IMPLEMENT(efl_ui_slider, Efl_Ui_Slider_Data)
-ELM_PART_CONTENT_DEFAULT_SET(efl_ui_slider, _content_aliases[0].real_part)

[EGIT] [core/efl] feature/eo_theme 02/07: efl_ui_widget: find new edc resource for efl_ui_widgets

2017-11-28 Thread Sungtaek Hong
jpeg pushed a commit to branch feature/eo_theme.

http://git.enlightenment.org/core/efl.git/commit/?id=9be5ffc877ff5cc124b1b886e8bd7ee9b6a52f6b

commit 9be5ffc877ff5cc124b1b886e8bd7ee9b6a52f6b
Author: Sungtaek Hong 
Date:   Tue Nov 14 19:59:42 2017 +0900

efl_ui_widget: find new edc resource for efl_ui_widgets

new eo widgets(efl_ui_ prefix) finds new edc group in
data/elementary/themes/edc/efl/*.edc.
New group name is "klass/group:style" and "base" group name and
"default" style name can be omitted.

for now, separator for style is ':' but needs to be decided.
---
 data/elementary/themes/Makefile.am |  25 +-
 data/elementary/themes/default.edc |  25 +-
 data/elementary/themes/edc/efl/bg.edc  |  11 +
 data/elementary/themes/edc/efl/border.edc  |  21 ++
 data/elementary/themes/edc/efl/button.edc  |   8 +
 data/elementary/themes/edc/efl/calendar.edc|   3 +
 data/elementary/themes/edc/efl/check.edc   |   7 +
 data/elementary/themes/edc/efl/cursor.edc  |  91 ++
 data/elementary/themes/edc/efl/focus.edc   |   7 +
 data/elementary/themes/edc/efl/frame.edc   |   3 +
 .../elementary/themes/edc/efl/multibuttonentry.edc |  19 ++
 data/elementary/themes/edc/{elm => efl}/nstate.edc |   4 +-
 data/elementary/themes/edc/efl/panes.edc   |  44 +++
 data/elementary/themes/edc/efl/photocam.edc|   3 +
 data/elementary/themes/edc/efl/progress.edc|  20 ++
 data/elementary/themes/edc/efl/radio.edc   |   3 +
 data/elementary/themes/edc/efl/scroller.edc|  12 +
 data/elementary/themes/edc/efl/slider.edc  |  73 +
 data/elementary/themes/edc/efl/text.edc| 328 +
 data/elementary/themes/edc/efl/textpath.edc|   3 +
 data/elementary/themes/edc/efl/tooltip.edc |  15 +
 data/elementary/themes/edc/efl/uiclock.edc | 223 ++
 data/elementary/themes/edc/efl/video.edc   |   3 +
 data/elementary/themes/edc/efl/win.edc |   3 +
 src/lib/elementary/efl_ui_panes.c  |  68 -
 src/lib/elementary/efl_ui_slider.c |  12 +-
 src/lib/elementary/efl_ui_text.c   |  79 +++--
 src/lib/elementary/efl_ui_win.c|  20 +-
 src/lib/elementary/elm_priv.h  |   3 +-
 src/lib/elementary/elm_spinner.c   |   7 +-
 src/lib/elementary/elm_theme.c |  26 +-
 src/lib/elementary/elm_widget.c|  10 +
 src/lib/elementary/els_cursor.c|   6 +-
 src/lib/elementary/elu_ews_wm.c|   8 +-
 34 files changed, 1105 insertions(+), 88 deletions(-)

diff --git a/data/elementary/themes/Makefile.am 
b/data/elementary/themes/Makefile.am
index f1ee7b15e8..758f7781c2 100644
--- a/data/elementary/themes/Makefile.am
+++ b/data/elementary/themes/Makefile.am
@@ -130,7 +130,6 @@ elementary/themes/edc/elm/menu.edc \
 elementary/themes/edc/elm/multibuttonentry.edc \
 elementary/themes/edc/elm/naviframe.edc \
 elementary/themes/edc/elm/notify.edc \
-elementary/themes/edc/elm/nstate.edc \
 elementary/themes/edc/elm/panel.edc \
 elementary/themes/edc/elm/panes.edc \
 elementary/themes/edc/elm/photocam.edc \
@@ -1016,8 +1015,28 @@ elementary/themes/snd/kbd-tap5.wav \
 elementary/themes/snd/kbd-tap.wav
 
 efl_ui_themes_files = \
-elementary/themes/edc/efl/button.edc
-
+elementary/themes/edc/efl/bg.edc \
+elementary/themes/edc/efl/border.edc \
+elementary/themes/edc/efl/button.edc \
+elementary/themes/edc/efl/calendar.edc \
+elementary/themes/edc/efl/check.edc \
+elementary/themes/edc/efl/uiclock.edc \
+elementary/themes/edc/efl/cursor.edc \
+elementary/themes/edc/efl/focus.edc \
+elementary/themes/edc/efl/frame.edc \
+elementary/themes/edc/efl/multibuttonentry.edc \
+elementary/themes/edc/efl/nstate.edc \
+elementary/themes/edc/efl/panes.edc \
+elementary/themes/edc/efl/photocam.edc \
+elementary/themes/edc/efl/progress.edc \
+elementary/themes/edc/efl/radio.edc \
+elementary/themes/edc/efl/scroller.edc \
+elementary/themes/edc/efl/slider.edc \
+elementary/themes/edc/efl/text.edc \
+elementary/themes/edc/efl/textpath.edc \
+elementary/themes/edc/efl/tooltip.edc \
+elementary/themes/edc/efl/video.edc \
+elementary/themes/edc/efl/win.edc
 
 elementary_fdo_actions_128_files = \
elementary/themes/fdo/actions/128/address-book-new.png \
diff --git a/data/elementary/themes/default.edc 
b/data/elementary/themes/default.edc
index 9d615295b1..d3254be0e2 100644
--- a/data/elementary/themes/default.edc
+++ b/data/elementary/themes/default.edc
@@ -13,7 +13,6 @@ collections {
 // elm
 #include "edc/elm/bg.edc"
 #include "edc/elm/button.edc"
-#include "edc/elm/nstate.edc"
 // XXX: mobile mode needs invisible scrollers... make signals that do this
 #include "edc/elm/scroller.edc"
 // XXX: mobile mode needs different entry setup
@@ -167,5 

[EGIT] [core/efl] feature/eo_theme 07/07: edje: Implement Efl.File.load_error

2017-11-28 Thread Jean-Philippe ANDRÉ
jpeg pushed a commit to branch feature/eo_theme.

http://git.enlightenment.org/core/efl.git/commit/?id=bba8c16ea5e0890593e44edc5f892ab42e8de9ea

commit bba8c16ea5e0890593e44edc5f892ab42e8de9ea
Author: Jean-Philippe Andre 
Date:   Wed Nov 29 12:05:10 2017 +0900

edje: Implement Efl.File.load_error

Don't create a new function with the same name, it's absurd.
---
 src/lib/edje/edje_legacy.c | 13 +
 src/lib/edje/edje_load.c   | 17 ++---
 src/lib/edje/edje_object.eo| 17 +
 src/lib/efl/interfaces/efl_file.eo | 14 --
 4 files changed, 20 insertions(+), 41 deletions(-)

diff --git a/src/lib/edje/edje_legacy.c b/src/lib/edje/edje_legacy.c
index d3f19ea9cd..a4520ba0b5 100644
--- a/src/lib/edje/edje_legacy.c
+++ b/src/lib/edje/edje_legacy.c
@@ -2,6 +2,19 @@
 
 #include "edje_private.h"
 
+EAPI Edje_Load_Error
+edje_object_load_error_get(const Eo *obj)
+{
+   Efl_Image_Load_Error p = efl_file_load_error_get(obj);
+   Edje *ed;
+
+   if (p != EFL_IMAGE_LOAD_ERROR_NONE) return EDJE_LOAD_ERROR_DOES_NOT_EXIST;
+
+   ed = _edje_fetch(obj);
+   if (!ed) return EDJE_LOAD_ERROR_GENERIC;
+   return ed->load_error;
+}
+
 EAPI Eina_Bool
 edje_object_part_geometry_get(const Edje_Object *obj, const char *part, int 
*x, int *y, int *w, int *h)
 {
diff --git a/src/lib/edje/edje_load.c b/src/lib/edje/edje_load.c
index 94f8c0e401..59b1e18ce2 100644
--- a/src/lib/edje/edje_load.c
+++ b/src/lib/edje/edje_load.c
@@ -167,9 +167,9 @@ _edje_object_efl_file_file_get(Eo *obj EINA_UNUSED, Edje 
*ed, const char **file,
 }
 
 EOLIAN Efl_Image_Load_Error
-_edje_object_load_error_get(Eo *obj, Edje *ed)
+_edje_object_efl_file_load_error_get(Eo *obj, Edje *ed)
 {
-   Efl_Image_Load_Error p = efl_file_load_error_get(obj);
+   Efl_Image_Load_Error p = efl_file_load_error_get(efl_super(obj, 
EDJE_OBJECT_CLASS));
 
if (p != EFL_IMAGE_LOAD_ERROR_NONE) return p;
switch (ed->load_error)
@@ -188,19 +188,6 @@ _edje_object_load_error_get(Eo *obj, Edje *ed)
  }
 }
 
-EAPI Edje_Load_Error
-edje_object_load_error_get(const Eo *obj)
-{
-   Efl_Image_Load_Error p = efl_file_load_error_get(obj);
-   Edje *ed;
-
-   if (p != EFL_IMAGE_LOAD_ERROR_NONE) return EDJE_LOAD_ERROR_DOES_NOT_EXIST;
-
-   ed = _edje_fetch(obj);
-   if (!ed) return EDJE_LOAD_ERROR_GENERIC;
-   return ed->load_error;
-}
-
 EAPI const char *
 edje_load_error_str(Edje_Load_Error error)
 {
diff --git a/src/lib/edje/edje_object.eo b/src/lib/edje/edje_object.eo
index 53f2b6a4cc..991214 100644
--- a/src/lib/edje/edje_object.eo
+++ b/src/lib/edje/edje_object.eo
@@ -85,22 +85,6 @@ class Edje.Object (Efl.Canvas.Group, Efl.File, 
Efl.Container, Efl.Part,
 $true will remove it (if it was issued 
before).]]
  }
   }
-  @property load_error {
- get {
-[[Gets the (last) file loading error for a given Edje object
-
-  This function is meant to be used after an Edje EDJ file
-  loading, what takes place with the $file_set() function. If that
-  function does not return $true, one should check for the reason
-  of failure with this one.
-]]
-legacy: null;
- }
- values {
-error: Efl.Image.Load.Error(Efl.Image.Load.Error.generic);
-   [[The load error code.]]
- }
-  }
 
   access_part_iterate @beta {
  [[Iterates over all accessibility-enabled part names.]]
@@ -204,6 +188,7 @@ class Edje.Object (Efl.Canvas.Group, Efl.File, 
Efl.Container, Efl.Part,
   Efl.Ui.Base.language { set; get; }
   Efl.Ui.Base.scale { set; get; }
   Efl.Ui.Base.base_scale { get; }
+  Efl.File.load_error { get; }
   Efl.File.mmap { get; set; }
   Efl.Container.content_remove;
   Efl.Part.part; [[Returns @Efl.Canvas.Layout.Part.]]
diff --git a/src/lib/efl/interfaces/efl_file.eo 
b/src/lib/efl/interfaces/efl_file.eo
index 35ac1fa4ec..e351a5eaa3 100644
--- a/src/lib/efl/interfaces/efl_file.eo
+++ b/src/lib/efl/interfaces/efl_file.eo
@@ -6,13 +6,7 @@ mixin Efl.File {
methods {
   @property load_error {
  get {
-[[Gets the (last) file loading error for a given Edje object
-
-  This function is meant to be used after an Edje EDJ file
-  loading, what takes place with the $file_set() function. If that
-  function does not return $true, one should check for the reason
-  of failure with this one.
-]]
+[[Gets the (last) file loading error for a given object.]]
  }
  values {
 error: Efl.Image.Load.Error(Efl.Image.Load.Error.none); [[The load 
error code.]]
@@ -105,9 +99,8 @@ mixin Efl.File {
 
You can specify some flags when saving the image.  Currently
acceptable flags are $quality and $compress. Eg.:
-   "quality=100 compress=9"]]
-
-

[EGIT] [core/efl] feature/eo_theme 04/07: efl_ui_widget: find theme just once in layout inherited widget

2017-11-28 Thread Sungtaek Hong
jpeg pushed a commit to branch feature/eo_theme.

http://git.enlightenment.org/core/efl.git/commit/?id=0ab10ddd4068c34b872417962fd741722018a10e

commit 0ab10ddd4068c34b872417962fd741722018a10e
Author: Sungtaek Hong 
Date:   Tue Nov 14 22:03:25 2017 +0900

efl_ui_widget: find theme just once in layout inherited widget

When a widget inherits layout in tries to set theme in group_add or in
constructor. When another widget inherits the previous widget, it sets
layout again with new klass name. This sets klass in the widget and
sets layout in super class, so that it can set layout only once.

Test Plan: Run efl_ui_widget related elementary test.

Reviewers: jpeg, cedric, woohyun, singh.amitesh

Differential Revision: https://phab.enlightenment.org/D5473
---
 src/lib/elementary/efl_ui_bg.c |  8 ++-
 src/lib/elementary/efl_ui_button.c |  8 ++-
 src/lib/elementary/efl_ui_calendar.c   |  8 +--
 src/lib/elementary/efl_ui_check.c  |  5 ++--
 src/lib/elementary/efl_ui_clock.c  | 12 +++---
 src/lib/elementary/efl_ui_frame.c  |  7 +-
 src/lib/elementary/efl_ui_multibuttonentry.c   |  8 +--
 src/lib/elementary/efl_ui_nstate.c |  5 ++--
 src/lib/elementary/efl_ui_panes.c  |  8 +--
 src/lib/elementary/efl_ui_progressbar.c|  8 +--
 src/lib/elementary/efl_ui_radio.c  |  5 ++--
 src/lib/elementary/efl_ui_slider.c |  8 +--
 src/lib/elementary/efl_ui_video.c  |  8 ++-
 src/lib/elementary/elm_code_widget.c   | 28 --
 .../clock_input_ctxpopup/clock_input_ctxpopup.c|  5 +++-
 15 files changed, 97 insertions(+), 34 deletions(-)

diff --git a/src/lib/elementary/efl_ui_bg.c b/src/lib/elementary/efl_ui_bg.c
index 3a38c4a284..38ac41a37c 100644
--- a/src/lib/elementary/efl_ui_bg.c
+++ b/src/lib/elementary/efl_ui_bg.c
@@ -97,10 +97,13 @@ _on_resize(void *data,
 EOLIAN static void
 _efl_ui_bg_efl_canvas_group_group_add(Eo *obj, Efl_Ui_Bg_Data *priv)
 {
+   ELM_WIDGET_DATA_GET_OR_RETURN(obj, wd);
 
priv->rect = evas_object_rectangle_add(evas_object_evas_get(obj));
evas_object_color_set(priv->rect, 0, 0, 0, 0);
 
+   if (!elm_widget_theme_klass_get(obj))
+ elm_widget_theme_klass_set(obj, "bg");
efl_canvas_group_add(efl_super(obj, MY_CLASS));
elm_widget_sub_object_parent_add(obj);
elm_widget_can_focus_set(obj, EINA_FALSE);
@@ -109,7 +112,10 @@ _efl_ui_bg_efl_canvas_group_group_add(Eo *obj, 
Efl_Ui_Bg_Data *priv)
 
evas_object_event_callback_add(obj, EVAS_CALLBACK_RESIZE, _on_resize, obj);
 
-   if (!elm_layout_theme_set(obj, "bg", "base", elm_widget_style_get(obj)))
+   if (!efl_ui_widget_theme_object_set(obj, wd->resize_obj,
+   elm_widget_theme_klass_get(obj),
+   elm_widget_theme_element_get(obj),
+   elm_widget_theme_style_get(obj)))
  CRI("Failed to set layout!");
elm_layout_content_set(obj, "elm.swallow.rectangle", priv->rect);
 }
diff --git a/src/lib/elementary/efl_ui_button.c 
b/src/lib/elementary/efl_ui_button.c
index 36eaebd5bf..879d420409 100644
--- a/src/lib/elementary/efl_ui_button.c
+++ b/src/lib/elementary/efl_ui_button.c
@@ -270,6 +270,8 @@ _efl_ui_button_efl_canvas_group_group_add(Eo *obj, 
Efl_Ui_Button_Data *_pd EINA_
 {
ELM_WIDGET_DATA_GET_OR_RETURN(obj, wd);
 
+   if (!elm_widget_theme_klass_get(obj))
+ elm_widget_theme_klass_set(obj, "button");
efl_canvas_group_add(efl_super(obj, MY_CLASS));
elm_widget_sub_object_parent_add(obj);
 
@@ -292,7 +294,11 @@ _efl_ui_button_efl_canvas_group_group_add(Eo *obj, 
Efl_Ui_Button_Data *_pd EINA_
  (_elm_access_info_get(obj), ELM_ACCESS_STATE, _access_state_cb, obj);
 
elm_widget_can_focus_set(obj, EINA_TRUE);
-   if (!elm_layout_theme_set(obj, "button", "base", elm_widget_style_get(obj)))
+
+   if (!efl_ui_widget_theme_object_set(obj, wd->resize_obj,
+   elm_widget_theme_klass_get(obj),
+   elm_widget_theme_element_get(obj),
+   elm_widget_theme_style_get(obj)))
  CRI("Failed to set layout!");
 }
 
diff --git a/src/lib/elementary/efl_ui_calendar.c 
b/src/lib/elementary/efl_ui_calendar.c
index df5e9d6a38..1a8f43f5f5 100644
--- a/src/lib/elementary/efl_ui_calendar.c
+++ b/src/lib/elementary/efl_ui_calendar.c
@@ -1000,8 +1000,12 @@ _efl_ui_calendar_constructor_internal(Eo *obj, 
Efl_Ui_Calendar_Data *priv)
 
elm_widget_can_focus_set(obj, EINA_TRUE);
 
-   if (!elm_layout_theme_set(obj, "calendar", "base",
- elm_object_style_get(obj)))
+   if (!elm_widget_theme_klass_get(obj))
+ elm_widget_theme_klass_set(obj, "calendar");
+   if 

[EGIT] [core/efl] feature/eo_theme 03/07: efl_ui_widget: use elm_widget_element_update to set subobj edc

2017-11-28 Thread Sungtaek Hong
jpeg pushed a commit to branch feature/eo_theme.

http://git.enlightenment.org/core/efl.git/commit/?id=a088b73bc0cb6385776db1736ba1266c65d6d47d

commit a088b73bc0cb6385776db1736ba1266c65d6d47d
Author: Sungtaek Hong 
Date:   Tue Nov 14 20:38:49 2017 +0900

efl_ui_widget: use elm_widget_element_update to set subobj edc

affected widget list:
efl_ui_clock: test, ampm
efl_ui_multibuttonentry: guidetext, label, closedbutton
efl_ui_slider: popup(indicator)
efl_ui_text: scroller, handler, magnifier, cursor, selection, anchor
---
 src/lib/elementary/efl_ui_clock.c|   2 +
 src/lib/elementary/efl_ui_clock_private.h|   9 ++
 src/lib/elementary/efl_ui_layout.c   |  11 ++
 src/lib/elementary/efl_ui_layout.eo  |   1 +
 src/lib/elementary/efl_ui_multibuttonentry.c |  34 ++---
 src/lib/elementary/efl_ui_progressbar.c  |  68 +-
 src/lib/elementary/efl_ui_slider.c   | 178 +--
 src/lib/elementary/efl_ui_slider_interval.c  |   1 +
 src/lib/elementary/efl_ui_text.c |  79 +---
 src/lib/elementary/efl_ui_win.c  |   1 +
 10 files changed, 247 insertions(+), 137 deletions(-)

diff --git a/src/lib/elementary/efl_ui_clock.c 
b/src/lib/elementary/efl_ui_clock.c
index bd11bc8d60..b32e7aa8dd 100644
--- a/src/lib/elementary/efl_ui_clock.c
+++ b/src/lib/elementary/efl_ui_clock.c
@@ -517,6 +517,8 @@ _efl_ui_clock_elm_widget_theme_apply(Eo *obj, 
Efl_Ui_Clock_Data *sd)
for (idx = 0; idx < EFL_UI_CLOCK_TYPE_COUNT; idx++)
  {
 field = sd->field_list + idx;
+// TODO: Different group name for each field_obj may be needed.
+elm_widget_element_update(obj, field->item_obj, PART_NAME_ARRAY[idx]);
 if (field->fmt_exist && field->visible)
   {
  snprintf(buf, sizeof(buf), EDC_PART_FIELD_ENABLE_SIG_STR,
diff --git a/src/lib/elementary/efl_ui_clock_private.h 
b/src/lib/elementary/efl_ui_clock_private.h
index 94c9d702e7..e37a8ceff3 100644
--- a/src/lib/elementary/efl_ui_clock_private.h
+++ b/src/lib/elementary/efl_ui_clock_private.h
@@ -33,6 +33,15 @@ typedef struct _Format_Map   Format_Map;
 #define EFL_UI_CLOCK_MAX_FORMAT_LEN   64
 #define EFL_UI_CLOCK_MAX_FIELD_FORMAT_LEN 3
 
+const char *PART_NAME_ARRAY[EFL_UI_CLOCK_TYPE_COUNT] = { "text",
+ "text",
+ "text",
+ "text",
+ "text",
+ "text",
+ "text",
+ "ampm"};
+
 struct _Efl_Ui_Clock_Module_Data
 {
Evas_Object *base;
diff --git a/src/lib/elementary/efl_ui_layout.c 
b/src/lib/elementary/efl_ui_layout.c
index 353caa945f..aabff8ca2e 100644
--- a/src/lib/elementary/efl_ui_layout.c
+++ b/src/lib/elementary/efl_ui_layout.c
@@ -2071,6 +2071,17 @@ EOLIAN static void 
_efl_ui_layout_class_constructor(Efl_Class *klass)
evas_smart_legacy_type_register(MY_CLASS_NAME_LEGACY, klass);
 }
 
+EOLIAN static Efl_Object*
+_efl_ui_layout_efl_object_finalize(Eo *obj, Efl_Ui_Layout_Data *pd EINA_UNUSED)
+{
+   Eo *eo;
+
+   eo = efl_finalize(efl_super(obj, MY_CLASS));
+   efl_ui_widget_theme_apply(eo);
+
+   return eo;
+}
+
 EOLIAN static void
 _efl_ui_layout_efl_canvas_layout_signal_message_send(Eo *obj, 
Efl_Ui_Layout_Data *pd EINA_UNUSED, int id, const Eina_Value msg)
 {
diff --git a/src/lib/elementary/efl_ui_layout.eo 
b/src/lib/elementary/efl_ui_layout.eo
index 7bb5aa0ca1..7f75a747e9 100644
--- a/src/lib/elementary/efl_ui_layout.eo
+++ b/src/lib/elementary/efl_ui_layout.eo
@@ -45,6 +45,7 @@ class Efl.Ui.Layout (Elm.Widget, Efl.Part, Efl.Container, 
Efl.File,
implements {
   class.constructor;
   Efl.Object.constructor;
+  Efl.Object.finalize;
   Efl.File.file { get; set; }
   Efl.File.mmap { get; set; }
   Efl.Canvas.Group.group_calculate;
diff --git a/src/lib/elementary/efl_ui_multibuttonentry.c 
b/src/lib/elementary/efl_ui_multibuttonentry.c
index 0ff7c5e555..577faeb7f8 100644
--- a/src/lib/elementary/efl_ui_multibuttonentry.c
+++ b/src/lib/elementary/efl_ui_multibuttonentry.c
@@ -35,6 +35,11 @@ static const char SIG_UNFOCUSED[] = "unfocused";
 static const char SIG_EXPANDED[] = "expanded";
 static const char SIG_CONTRACTED[] = "contracted";
 static const char SIG_EXPAND_STATE_CHANGED[] = "expand,state,changed";
+
+static const char PART_NAME_BUTTON[] = "btn";
+static const char PART_NAME_GUIDE_TEXT[] = "guidetext";
+static const char PART_NAME_LABEL[] = "label";
+static const char PART_NAME_CLOSED_BUTTON[] = "closedbutton";
 static const Evas_Smart_Cb_Description _smart_callbacks[] = {
{SIG_ITEM_SELECTED, ""},
{SIG_ITEM_ADDED, ""},
@@ -117,20 +122,13 @@ 

[EGIT] [core/efl] feature/eo_theme 01/07: efl_ui_widget: add new internal EAPI for new group name

2017-11-28 Thread Sungtaek Hong
jpeg pushed a commit to branch feature/eo_theme.

http://git.enlightenment.org/core/efl.git/commit/?id=589c7924e937a611625082626839205277c90a5d

commit 589c7924e937a611625082626839205277c90a5d
Author: Sungtaek Hong 
Date:   Tue Nov 14 18:42:48 2017 +0900

efl_ui_widget: add new internal EAPI for new group name

theme_klass: set/get klass name used for resize_obj
theme_element: set/get group name used for resize_obj
theme_style: set/get style name used for resize_obj
element_update: automatically sets and apply theme for
 sub object of widget.
---
 src/lib/elementary/efl_ui_layout.c  |  29 +++
 src/lib/elementary/efl_ui_panes.c   |   5 +-
 src/lib/elementary/efl_ui_progressbar.c |   5 +-
 src/lib/elementary/efl_ui_slider.c  |   9 +--
 src/lib/elementary/elc_hoversel.c   |   4 +-
 src/lib/elementary/elm_bubble.c |   5 +-
 src/lib/elementary/elm_index.c  |   5 +-
 src/lib/elementary/elm_scroller.c   |   8 +-
 src/lib/elementary/elm_separator.c  |   5 +-
 src/lib/elementary/elm_widget.c | 133 
 src/lib/elementary/elm_widget.h |  10 +++
 src/lib/elementary/elm_widget_layout.h  |   2 -
 12 files changed, 177 insertions(+), 43 deletions(-)

diff --git a/src/lib/elementary/efl_ui_layout.c 
b/src/lib/elementary/efl_ui_layout.c
index 15534c7b7d..353caa945f 100644
--- a/src/lib/elementary/efl_ui_layout.c
+++ b/src/lib/elementary/efl_ui_layout.c
@@ -362,8 +362,10 @@ _efl_ui_layout_theme_internal(Eo *obj, Efl_Ui_Layout_Data 
*sd)
if (!sd->file_set)
  {
 ret = elm_widget_theme_object_set
-(obj, wd->resize_obj, sd->klass, sd->group,
- elm_widget_style_get(obj));
+(obj, wd->resize_obj,
+elm_widget_theme_klass_get(obj), 
+elm_widget_theme_element_get(obj),
+elm_widget_theme_style_get(obj));
  }
 
if (ret)
@@ -682,9 +684,6 @@ _efl_ui_layout_efl_canvas_group_group_del(Eo *obj, 
Efl_Ui_Layout_Data *sd)
eina_hash_free(sd->factories);
sd->factories = NULL;
 
-   eina_stringshare_del(sd->klass);
-   eina_stringshare_del(sd->group);
-
/* let's make our Edje object the *last* to be processed, since it
 * may (smart) parent other sub objects here */
EINA_LIST_FOREACH(wd->subobjs, l, child)
@@ -799,6 +798,7 @@ _efl_ui_layout_efl_file_mmap_get(Eo *obj, 
Efl_Ui_Layout_Data *sd EINA_UNUSED, co
 EOLIAN static Efl_Ui_Theme_Apply
 _efl_ui_layout_theme_set(Eo *obj, Efl_Ui_Layout_Data *sd, const char *klass, 
const char *group, const char *style)
 {
+   Eina_Bool changed = EINA_FALSE;
ELM_WIDGET_DATA_GET_OR_RETURN(obj, wd, EINA_FALSE);
 
if (!wd->legacy && efl_finalized_get(obj))
@@ -808,11 +808,14 @@ _efl_ui_layout_theme_set(Eo *obj, Efl_Ui_Layout_Data *sd, 
const char *klass, con
  }
 
if (sd->file_set) sd->file_set = EINA_FALSE;
-   eina_stringshare_replace(&(sd->klass), klass);
-   eina_stringshare_replace(&(sd->group), group);
-   eina_stringshare_replace(&(wd->style), style);
 
-   return _efl_ui_layout_theme_internal(obj, sd);
+   changed |= elm_widget_theme_klass_set(obj, klass);
+   changed |= elm_widget_theme_element_set(obj, group);
+   changed |= elm_widget_theme_style_set(obj, style);
+
+   if (changed)
+ return efl_ui_widget_theme_apply(obj);
+   return EFL_UI_THEME_APPLY_SUCCESS;
 }
 
 EOLIAN static void
@@ -2376,7 +2379,7 @@ elm_layout_theme_set(Evas_Object *obj, const char *klass, 
const char *group, con
 /* Efl.Part implementation */
 
 EOLIAN static Eo *
-_efl_ui_layout_efl_part_part(const Eo *obj, Efl_Ui_Layout_Data *sd, const char 
*part)
+_efl_ui_layout_efl_part_part(const Eo *obj, Efl_Ui_Layout_Data *sd 
EINA_UNUSED, const char *part)
 {
Efl_Canvas_Layout_Part_Type type;
 
@@ -2397,7 +2400,7 @@ _efl_ui_layout_efl_part_part(const Eo *obj, 
Efl_Ui_Layout_Data *sd, const char *
   const char *file = NULL, *key = NULL;
   efl_file_get(wd->resize_obj, , );
   WRN("Layout has a background but it's not a swallow: '%s'",
-  sd->group);
+  elm_widget_theme_element_get(obj));
}
  return efl_part(efl_super(obj, MY_CLASS), part);
   }
@@ -2407,7 +2410,7 @@ _efl_ui_layout_efl_part_part(const Eo *obj, 
Efl_Ui_Layout_Data *sd, const char *
 
if (type >= EFL_CANVAS_LAYOUT_PART_TYPE_LAST)
  {
-ERR("Invalid type found for part '%s' in group '%s'", part, sd->group);
+ERR("Invalid type found for part '%s' in group '%s'", part, 
elm_widget_theme_element_get(obj));
 return NULL;
  }
 
@@ -2422,7 +2425,7 @@ _efl_ui_layout_efl_part_part(const Eo *obj, 
Efl_Ui_Layout_Data *sd, const char *
   case EFL_CANVAS_LAYOUT_PART_TYPE_SWALLOW:
 return ELM_PART_IMPLEMENT(EFL_UI_LAYOUT_PART_CONTENT_CLASS, obj, part);
   case EFL_CANVAS_LAYOUT_PART_TYPE_NONE:
-   

[EGIT] [core/efl] feature/eo_theme 05/07: efl_ui_widget: make Elm.Widget.theme, Elm.Widget.theme_object internal

2017-11-28 Thread Sungtaek Hong
jpeg pushed a commit to branch feature/eo_theme.

http://git.enlightenment.org/core/efl.git/commit/?id=9d94d7c6331ce2171b9034a475c8483c6528e4cd

commit 9d94d7c6331ce2171b9034a475c8483c6528e4cd
Author: Sungtaek Hong 
Date:   Fri Nov 17 17:24:39 2017 +0900

efl_ui_widget: make Elm.Widget.theme, Elm.Widget.theme_object internal
---
 src/lib/elementary/efl_ui_bg.c   |  2 +-
 src/lib/elementary/efl_ui_button.c   |  2 +-
 src/lib/elementary/efl_ui_calendar.c |  2 +-
 src/lib/elementary/efl_ui_clock.c|  2 +-
 src/lib/elementary/efl_ui_frame.c|  2 +-
 src/lib/elementary/efl_ui_multibuttonentry.c |  2 +-
 src/lib/elementary/efl_ui_panes.c|  2 +-
 src/lib/elementary/efl_ui_progressbar.c  |  2 +-
 src/lib/elementary/efl_ui_slider.c   |  6 ++---
 src/lib/elementary/efl_ui_text.c |  2 +-
 src/lib/elementary/efl_ui_video.c|  2 +-
 src/lib/elementary/efl_ui_win.c  | 18 ++---
 src/lib/elementary/elm_widget.c  | 40 +---
 src/lib/elementary/elm_widget.eo | 20 --
 src/lib/elementary/els_cursor.c  |  6 ++---
 15 files changed, 37 insertions(+), 73 deletions(-)

diff --git a/src/lib/elementary/efl_ui_bg.c b/src/lib/elementary/efl_ui_bg.c
index 38ac41a37c..79991a2179 100644
--- a/src/lib/elementary/efl_ui_bg.c
+++ b/src/lib/elementary/efl_ui_bg.c
@@ -112,7 +112,7 @@ _efl_ui_bg_efl_canvas_group_group_add(Eo *obj, 
Efl_Ui_Bg_Data *priv)
 
evas_object_event_callback_add(obj, EVAS_CALLBACK_RESIZE, _on_resize, obj);
 
-   if (!efl_ui_widget_theme_object_set(obj, wd->resize_obj,
+   if (!elm_widget_theme_object_set(obj, wd->resize_obj,
elm_widget_theme_klass_get(obj),
elm_widget_theme_element_get(obj),
elm_widget_theme_style_get(obj)))
diff --git a/src/lib/elementary/efl_ui_button.c 
b/src/lib/elementary/efl_ui_button.c
index 879d420409..2f194ea52a 100644
--- a/src/lib/elementary/efl_ui_button.c
+++ b/src/lib/elementary/efl_ui_button.c
@@ -295,7 +295,7 @@ _efl_ui_button_efl_canvas_group_group_add(Eo *obj, 
Efl_Ui_Button_Data *_pd EINA_
 
elm_widget_can_focus_set(obj, EINA_TRUE);
 
-   if (!efl_ui_widget_theme_object_set(obj, wd->resize_obj,
+   if (!elm_widget_theme_object_set(obj, wd->resize_obj,
elm_widget_theme_klass_get(obj),
elm_widget_theme_element_get(obj),
elm_widget_theme_style_get(obj)))
diff --git a/src/lib/elementary/efl_ui_calendar.c 
b/src/lib/elementary/efl_ui_calendar.c
index 1a8f43f5f5..3e629a75b3 100644
--- a/src/lib/elementary/efl_ui_calendar.c
+++ b/src/lib/elementary/efl_ui_calendar.c
@@ -1002,7 +1002,7 @@ _efl_ui_calendar_constructor_internal(Eo *obj, 
Efl_Ui_Calendar_Data *priv)
 
if (!elm_widget_theme_klass_get(obj))
  elm_widget_theme_klass_set(obj, "calendar");
-   if (!efl_ui_widget_theme_object_set(obj, wd->resize_obj,
+   if (!elm_widget_theme_object_set(obj, wd->resize_obj,
elm_widget_theme_klass_get(obj),
elm_widget_theme_element_get(obj),
elm_widget_theme_style_get(obj)))
diff --git a/src/lib/elementary/efl_ui_clock.c 
b/src/lib/elementary/efl_ui_clock.c
index fea20899bf..f3aa340b90 100644
--- a/src/lib/elementary/efl_ui_clock.c
+++ b/src/lib/elementary/efl_ui_clock.c
@@ -828,7 +828,7 @@ _efl_ui_clock_efl_canvas_group_group_add(Eo *obj, 
Efl_Ui_Clock_Data *priv)
efl_canvas_group_add(efl_super(obj, MY_CLASS));
elm_widget_sub_object_parent_add(obj);
 
-   if (!efl_ui_widget_theme_object_set(obj, wd->resize_obj,
+   if (!elm_widget_theme_object_set(obj, wd->resize_obj,
elm_widget_theme_klass_get(obj),
elm_widget_theme_element_get(obj),
elm_widget_theme_style_get(obj)))
diff --git a/src/lib/elementary/efl_ui_frame.c 
b/src/lib/elementary/efl_ui_frame.c
index e3679af604..3e3fcb7f5c 100644
--- a/src/lib/elementary/efl_ui_frame.c
+++ b/src/lib/elementary/efl_ui_frame.c
@@ -131,7 +131,7 @@ _efl_ui_frame_efl_canvas_group_group_add(Eo *obj, 
Efl_Ui_Frame_Data *_pd EINA_UN
 
elm_widget_can_focus_set(obj, EINA_FALSE);
 
-   if (!efl_ui_widget_theme_object_set(obj, wd->resize_obj,
+   if (!elm_widget_theme_object_set(obj, wd->resize_obj,
elm_widget_theme_klass_get(obj),
elm_widget_theme_element_get(obj),
elm_widget_theme_style_get(obj)))
diff --git a/src/lib/elementary/efl_ui_multibuttonentry.c 
b/src/lib/elementary/efl_ui_multibuttonentry.c
index 0ae8c20bfa..a8ba259286 100644
--- 

[EGIT] [core/efl] feature/eo_theme 06/07: elm_code_widget: change efl_add to legacy_add

2017-11-28 Thread Sungtaek Hong
jpeg pushed a commit to branch feature/eo_theme.

http://git.enlightenment.org/core/efl.git/commit/?id=0882213915b57806b0f086b03cbe6ee4259bc545

commit 0882213915b57806b0f086b03cbe6ee4259bc545
Author: Sungtaek Hong 
Date:   Tue Nov 28 20:50:53 2017 +0900

elm_code_widget: change efl_add to legacy_add

Summary:
elm_code_widget is legacy add, thus efl_add is not available.

Signed-off-by: Sungtaek Hong 

Reviewers: jpeg, cedric, ajwillia.ms, woohyun

Differential Revision: https://phab.enlightenment.org/D5548
---
 src/bin/elementary/test_code.c  | 32 +
 src/lib/elementary/elm_code_widget.c|  3 ++-
 src/tests/elementary/elm_code_test_widget.c |  2 +-
 3 files changed, 27 insertions(+), 10 deletions(-)

diff --git a/src/bin/elementary/test_code.c b/src/bin/elementary/test_code.c
index 235adde00b..571b086824 100644
--- a/src/bin/elementary/test_code.c
+++ b/src/bin/elementary/test_code.c
@@ -59,7 +59,11 @@ _elm_code_test_welcome_setup(Evas_Object *parent)
Elm_Code_Widget *widget;
 
code = elm_code_create();
-   widget = efl_add(ELM_CODE_WIDGET_CLASS, parent, 
elm_obj_code_widget_code_set(efl_added, code));
+   widget = elm_code_widget_add(parent, code);
+   evas_object_size_hint_weight_set(widget, EVAS_HINT_EXPAND, 
EVAS_HINT_EXPAND);
+   evas_object_size_hint_align_set(widget, EVAS_HINT_FILL, EVAS_HINT_FILL);
+   evas_object_show(widget);
+
efl_event_callback_add(widget, _CODE_EVENT_LINE_LOAD_DONE, 
_elm_code_test_line_done_cb, NULL);
efl_event_callback_add(widget, ELM_OBJ_CODE_WIDGET_EVENT_LINE_CLICKED, 
_elm_code_test_line_clicked_cb, code);
 
@@ -90,7 +94,11 @@ _elm_code_test_editor_setup(Evas_Object *parent, Eina_Bool 
log)
Elm_Code_Widget *widget;
 
code = elm_code_create();
-   widget = efl_add(ELM_CODE_WIDGET_CLASS, parent, 
elm_obj_code_widget_code_set(efl_added, code));
+   widget = elm_code_widget_add(parent, code);
+   evas_object_size_hint_weight_set(widget, EVAS_HINT_EXPAND, 
EVAS_HINT_EXPAND);
+   evas_object_size_hint_align_set(widget, EVAS_HINT_FILL, EVAS_HINT_FILL);
+   evas_object_show(widget);
+
elm_obj_code_widget_font_set(widget, NULL, 14);
elm_obj_code_widget_editable_set(widget, EINA_TRUE);
elm_obj_code_widget_show_whitespace_set(widget, EINA_TRUE);
@@ -118,7 +126,11 @@ _elm_code_test_syntax_setup(Evas_Object *parent)
Elm_Code_Widget *widget;
 
code = elm_code_create();
-   widget = efl_add(ELM_CODE_WIDGET_CLASS, parent, 
elm_obj_code_widget_code_set(efl_added, code));
+   widget = elm_code_widget_add(parent, code);
+   evas_object_size_hint_weight_set(widget, EVAS_HINT_EXPAND, 
EVAS_HINT_EXPAND);
+   evas_object_size_hint_align_set(widget, EVAS_HINT_FILL, EVAS_HINT_FILL);
+   evas_object_show(widget);
+
elm_obj_code_widget_editable_set(widget, EINA_TRUE);
elm_obj_code_widget_syntax_enabled_set(widget, EINA_TRUE);
elm_obj_code_widget_code_get(widget)->file->mime = "text/x-csrc";
@@ -144,12 +156,13 @@ _elm_code_test_mirror_setup(Elm_Code *code, char 
*font_name, Evas_Object *parent
 {
Elm_Code_Widget *widget;
 
-   widget = efl_add(ELM_CODE_WIDGET_CLASS, parent, 
elm_obj_code_widget_code_set(efl_added, code));
-   elm_obj_code_widget_font_set(widget, font_name, 11);
-   elm_obj_code_widget_line_numbers_set(widget, EINA_TRUE);
-
+   widget = elm_code_widget_add(parent, code);
evas_object_size_hint_weight_set(widget, EVAS_HINT_EXPAND, 
EVAS_HINT_EXPAND);
evas_object_size_hint_align_set(widget, EVAS_HINT_FILL, EVAS_HINT_FILL);
+   evas_object_show(widget);
+
+   elm_obj_code_widget_font_set(widget, font_name, 11);
+   elm_obj_code_widget_line_numbers_set(widget, EINA_TRUE);
 
return widget;
 }
@@ -161,7 +174,10 @@ _elm_code_test_diff_inline_setup(Evas_Object *parent)
Elm_Code *code;
 
code = elm_code_create();
-   diff = efl_add(ELM_CODE_WIDGET_CLASS, parent, 
elm_obj_code_widget_code_set(efl_added, code));
+   diff = elm_code_widget_add(parent, code);
+   evas_object_size_hint_weight_set(diff, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
+   evas_object_size_hint_align_set(diff, EVAS_HINT_FILL, EVAS_HINT_FILL);
+   evas_object_show(diff);
 
elm_code_parser_standard_add(code, ELM_CODE_PARSER_STANDARD_DIFF);
elm_code_file_open(code, PACKAGE_DATA_DIR "/testdiff.diff");
diff --git a/src/lib/elementary/elm_code_widget.c 
b/src/lib/elementary/elm_code_widget.c
index 2fd8e258f4..fd9f59c9f6 100644
--- a/src/lib/elementary/elm_code_widget.c
+++ b/src/lib/elementary/elm_code_widget.c
@@ -2040,7 +2040,8 @@ _elm_code_widget_code_set(Eo *obj, Elm_Code_Widget_Data 
*pd, Elm_Code *code)
 
pd->code = code;
 
-   code->widgets = eina_list_append(code->widgets, obj);
+   if (code)
+ code->widgets = eina_list_append(code->widgets, obj);
 }
 
 EOLIAN static Elm_Code *
diff --git a/src/tests/elementary/elm_code_test_widget.c 
b/src/tests/elementary/elm_code_test_widget.c
index 

[EGIT] [core/efl] master 01/01: evas: Remove duplicated code

2017-11-28 Thread Yeongjong Lee
raster pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=c1e9d9f2f03518a74d57c4724a21086e0c6d70c4

commit c1e9d9f2f03518a74d57c4724a21086e0c6d70c4
Author: Yeongjong Lee 
Date:   Wed Nov 29 11:48:21 2017 +0900

evas: Remove duplicated code

Reviewers: raster, cedric

Reviewed By: raster

Subscribers: jpeg

Differential Revision: https://phab.enlightenment.org/D5552
---
 src/lib/evas/include/evas_inline.x | 27 ---
 1 file changed, 8 insertions(+), 19 deletions(-)

diff --git a/src/lib/evas/include/evas_inline.x 
b/src/lib/evas/include/evas_inline.x
index 69ea105c1a..fd00dbe2aa 100644
--- a/src/lib/evas/include/evas_inline.x
+++ b/src/lib/evas/include/evas_inline.x
@@ -230,25 +230,14 @@ evas_object_is_active(Evas_Object *eo_obj, 
Evas_Object_Protected_Data *obj)
 int fx, fy;
 fx = e->framespace.x;
 fy = e->framespace.y;
-if (obj->is_smart)
-  {
- int mapsmt = 0;
- if (obj->map->cur.map && obj->map->cur.usemap) mapsmt = 1;
- if (!mapsmt) return 1;
- if (evas_object_is_in_output_rect(eo_obj, obj, -fx, -fy,
-   e->output.w, e->output.h) ||
- evas_object_was_in_output_rect(eo_obj, obj, -fx, -fy,
-e->output.w, e->output.h))
-   return 1;
-  }
-else
-  {
- if (evas_object_is_in_output_rect(eo_obj, obj, -fx, -fy,
-   e->output.w, e->output.h) ||
- evas_object_was_in_output_rect(eo_obj, obj, -fx, -fy,
-e->output.w, e->output.h))
-   return 1;
-  }
+if (obj->is_smart && !(obj->map->cur.map && obj->map->cur.usemap))
+  return 1;
+
+if (evas_object_is_in_output_rect(eo_obj, obj, -fx, -fy,
+  e->output.w, e->output.h) ||
+evas_object_was_in_output_rect(eo_obj, obj, -fx, -fy,
+   e->output.w, e->output.h))
+  return 1;
  }
/* FIXME: forcing object with proxies to stay active,
   need to be smarter and only do that when really needed. */

-- 




[EGIT] [core/efl] master 01/01: test: Adjust eo flag for popup test cases

2017-11-28 Thread Jean-Philippe ANDRÉ
jpeg pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=6946ff631876ee8c1e034a3eb4e8d7e552ef6153

commit 6946ff631876ee8c1e034a3eb4e8d7e552ef6153
Author: Jean-Philippe Andre 
Date:   Wed Nov 29 11:47:43 2017 +0900

test: Adjust eo flag for popup test cases
---
 src/bin/elementary/test.c | 10 +-
 1 file changed, 5 insertions(+), 5 deletions(-)

diff --git a/src/bin/elementary/test.c b/src/bin/elementary/test.c
index ecdd52170e..f23b37d4ee 100644
--- a/src/bin/elementary/test.c
+++ b/src/bin/elementary/test.c
@@ -1047,11 +1047,11 @@ add_tests:
ADD_TEST(NULL, "Popups", "Tooltip 3", test_tooltip3);
ADD_TEST(NULL, "Popups", "Tooltip 4", test_tooltip4);
ADD_TEST(NULL, "Popups", "Popup", test_popup);
-   ADD_TEST(NULL, "Popups", "UI.Popup", test_ui_popup);
-   ADD_TEST(NULL, "Popups", "UI.Popup.Alert", test_ui_popup_alert);
-   ADD_TEST(NULL, "Popups", "UI.Popup.Alert.Scroll", 
test_ui_popup_alert_scroll);
-   ADD_TEST(NULL, "Popups", "UI.Popup.Alert.Text", test_ui_popup_alert_text);
-   ADD_TEST(NULL, "Popups", "UI.Popup.Anchor", test_ui_popup_anchor);
+   ADD_TEST_EO(NULL, "Popups", "Efl.Ui.Popup", test_ui_popup);
+   ADD_TEST_EO(NULL, "Popups", "Efl.Ui.Popup.Alert", test_ui_popup_alert);
+   ADD_TEST_EO(NULL, "Popups", "Efl.Ui.Popup.Alert.Scroll", 
test_ui_popup_alert_scroll);
+   ADD_TEST_EO(NULL, "Popups", "Efl.Ui.Popup.Alert.Text", 
test_ui_popup_alert_text);
+   ADD_TEST_EO(NULL, "Popups", "Efl.Ui.Popup.Anchor", test_ui_popup_anchor);
 
//--//
ADD_TEST(NULL, "Times & Dates", "Calendar", test_calendar);

-- 




[EGIT] [apps/ephoto] master 01/01: Make the name of the ephoto gadget "Slideshow"

2017-11-28 Thread Stephen Houston
okra pushed a commit to branch master.

http://git.enlightenment.org/apps/ephoto.git/commit/?id=8db0480b4eb599f90e475fe95d2d6595fa7a3716

commit 8db0480b4eb599f90e475fe95d2d6595fa7a3716
Author: Stephen Houston 
Date:   Tue Nov 28 16:24:38 2017 -0600

Make the name of the ephoto gadget "Slideshow"
---
 data/desktop/meson.build   | 4 ++--
 data/desktop/slideshow.desktop | 6 ++
 2 files changed, 8 insertions(+), 2 deletions(-)

diff --git a/data/desktop/meson.build b/data/desktop/meson.build
index 8b33cab..80289ac 100644
--- a/data/desktop/meson.build
+++ b/data/desktop/meson.build
@@ -16,5 +16,5 @@ dep_e = dependency('enlightenment')
 release = dep_e.get_pkgconfig_variable('release')
 module_arch = '@0@-@1@-@2@'.format(host_os, host_machine.cpu_family(), release)
 dir_gadgets = join_paths([dir_lib, 'enlightenment/gadgets', module_arch])
-install_data('ephoto.desktop',
-install_dir: join_paths([dir_gadgets, 'ephoto']))
+install_data('slideshow.desktop',
+install_dir: join_paths([dir_gadgets, 'slideshow']))
diff --git a/data/desktop/slideshow.desktop b/data/desktop/slideshow.desktop
new file mode 100644
index 000..44da979
--- /dev/null
+++ b/data/desktop/slideshow.desktop
@@ -0,0 +1,6 @@
+[Desktop Entry]
+Encoding=UTF-8
+Type=Application
+Name=Slideshow
+Icon=ephoto
+Exec=ephoto

-- 




[EGIT] [apps/ephoto] master 01/01: Improve Wizard appearance of gadget and add fileselector for slideshow path.

2017-11-28 Thread Stephen Houston
okra pushed a commit to branch master.

http://git.enlightenment.org/apps/ephoto.git/commit/?id=292881981e0129763e77d2d9c9e217e2396245fa

commit 292881981e0129763e77d2d9c9e217e2396245fa
Author: Stephen Houston 
Date:   Tue Nov 28 16:03:11 2017 -0600

Improve Wizard appearance of gadget and add fileselector for slideshow path.
---
 src/bin/ephoto.c   | 27 ---
 src/bin/ephoto_slideshow.c | 39 ---
 2 files changed, 44 insertions(+), 22 deletions(-)

diff --git a/src/bin/ephoto.c b/src/bin/ephoto.c
index 8cbf01a..41e06e1 100644
--- a/src/bin/ephoto.c
+++ b/src/bin/ephoto.c
@@ -5,7 +5,8 @@ static void _ephoto_display_usage(void);
 int
 main(int argc, char *argv[])
 {
-   int gadget = 0, r = 0;
+   int gadget = 0, id_num = 0, r = 0;
+   char buf[4096];
 
elm_init(argc, (char **)argv);
eio_init();
@@ -30,9 +31,29 @@ main(int argc, char *argv[])
elm_policy_set(ELM_POLICY_QUIT, ELM_POLICY_QUIT_LAST_WINDOW_CLOSED);
 
if (getenv("E_GADGET_ID"))
- gadget = 1;
+ {
+gadget = 1;
+snprintf(buf, sizeof(buf), "%s", getenv("E_GADGET_ID"));
+id_num = atoi(buf);
+ }
+   if (id_num < 0)
+ {
+Evas_Object *win, *icon;
 
-   if (argc > 2)
+win = elm_win_add(NULL, "ephoto", ELM_WIN_BASIC);
+elm_win_title_set(win, "Ephoto");
+elm_win_alpha_set(win, 1);
+elm_win_autodel_set(win, 1);
+evas_object_size_hint_aspect_set(win, EVAS_ASPECT_CONTROL_BOTH, 1, 1);
+
+icon = elm_image_add(win);
+elm_image_file_set(icon, PACKAGE_DATA_DIR "/images/ephoto.png", NULL);
+elm_win_resize_object_add(win, icon);
+evas_object_show(icon);
+
+evas_object_show(win);
+ }
+   else if (argc > 2)
  {
 printf("Too Many Arguments!\n");
 _ephoto_display_usage();
diff --git a/src/bin/ephoto_slideshow.c b/src/bin/ephoto_slideshow.c
index 7bfe66f..f72735b 100644
--- a/src/bin/ephoto_slideshow.c
+++ b/src/bin/ephoto_slideshow.c
@@ -799,7 +799,7 @@ _gadget_settings_save(void *data, Evas_Object *obj 
EINA_UNUSED,
spinner = evas_object_data_get(popup, "timeout");
 
ss->ephoto->config->slideshow_timeout = elm_spinner_value_get(spinner);
-   path = elm_object_text_get(fentry);
+   path = elm_fileselector_path_get(fentry);
if (ecore_file_is_dir(path))
  ephoto_directory_set(ss->ephoto, path, NULL, EINA_FALSE, EINA_TRUE);
 
@@ -811,7 +811,7 @@ _gadget_settings(void *data, Evas_Object *obj EINA_UNUSED,
   void *event_info EINA_UNUSED)
 {
Ephoto_Slideshow *ss = data;
-   Evas_Object *popup, *but, *table, *fentry, *label, *spinner;
+   Evas_Object *popup, *but, *table, *fentry, *label, *spinner, *rect;
char buf[PATH_MAX];
 
popup = elm_win_add(ss->ephoto->win, "win", ELM_WIN_BASIC);
@@ -819,26 +819,20 @@ _gadget_settings(void *data, Evas_Object *obj EINA_UNUSED,
evas_object_data_set(popup, "slideshow", ss);
 
table = elm_table_add(popup);
+   elm_table_homogeneous_set(table, EINA_FALSE);
EPHOTO_EXPAND(table);
EPHOTO_FILL(table);
elm_win_resize_object_add(popup, table);
evas_object_show(table);
 
-   label = elm_label_add(table);
-   elm_object_text_set(label, _("Directory:"));
-   EPHOTO_FILL(label);
-   elm_table_pack(table, label, 0, 0, 1, 1);
-   evas_object_show(label);
-
-   fentry = elm_entry_add(table);
-   elm_entry_single_line_set(fentry, EINA_TRUE);
-   elm_entry_editable_set(fentry, EINA_TRUE);
-   elm_entry_scrollable_set(fentry, EINA_TRUE);
-   elm_object_text_set(fentry, ss->ephoto->config->directory);
-   evas_object_size_hint_weight_set(fentry, EVAS_HINT_EXPAND, 0.0);
+   fentry = elm_fileselector_add(table);
+   elm_fileselector_is_save_set(fentry, EINA_FALSE);
+   elm_fileselector_expandable_set(fentry, EINA_FALSE);
+   elm_fileselector_path_set(fentry, ss->ephoto->config->directory);
+   elm_fileselector_buttons_ok_cancel_set(fentry, EINA_FALSE);
+   evas_object_size_hint_weight_set(fentry, EVAS_HINT_EXPAND, 
EVAS_HINT_EXPAND);
evas_object_size_hint_align_set(fentry, EVAS_HINT_FILL, EVAS_HINT_FILL);
-   evas_object_size_hint_min_set(fentry, 300, 75);
-   elm_table_pack(table, fentry, 1, 0, 1, 1);
+   elm_table_pack(table, fentry, 0, 0, 2, 5);
evas_object_show(fentry);
evas_object_data_set(popup, "fentry", fentry);
 
@@ -847,7 +841,7 @@ _gadget_settings(void *data, Evas_Object *obj EINA_UNUSED,
snprintf(buf, PATH_MAX, "%s:", _("Show Each Slide For"));
elm_object_text_set(label, buf);
EPHOTO_FILL(label);
-   elm_table_pack(table, label, 0, 1, 1, 1);
+   elm_table_pack(table, label, 0, 5, 1, 1);
evas_object_show(label);
 
spinner = elm_spinner_add(table);
@@ -858,16 +852,23 @@ _gadget_settings(void *data, Evas_Object *obj EINA_UNUSED,
elm_spinner_step_set(spinner, 1);
elm_spinner_value_set(spinner, ss->ephoto->config->slideshow_timeout);
elm_spinner_min_max_set(spinner, 1, 60);
-   

[EGIT] [apps/ephoto] master 01/01: Ephoto: Add a gadget config so that ephoto can work as an Enlightenment sandboxed gadget.

2017-11-28 Thread Stephen Houston
okra pushed a commit to branch master.

http://git.enlightenment.org/apps/ephoto.git/commit/?id=aec1b6516d65930c82ea892c0654b15deacd8bce

commit aec1b6516d65930c82ea892c0654b15deacd8bce
Author: Stephen Houston 
Date:   Tue Nov 28 15:01:48 2017 -0600

Ephoto: Add a gadget config so that ephoto can work as an Enlightenment 
sandboxed gadget.
---
 data/desktop/meson.build   |  16 ++
 meson.build|   4 +
 src/bin/ephoto.c   |  22 +--
 src/bin/ephoto.h   |   6 +-
 src/bin/ephoto_main.c  | 422 +
 src/bin/ephoto_slideshow.c | 155 ++---
 src/bin/meson.build|   3 +-
 7 files changed, 410 insertions(+), 218 deletions(-)

diff --git a/data/desktop/meson.build b/data/desktop/meson.build
index eb44075..8b33cab 100644
--- a/data/desktop/meson.build
+++ b/data/desktop/meson.build
@@ -2,3 +2,19 @@ install_data('ephoto.desktop',
  install_dir: join_paths(dir_data, 'applications'))
 install_data('ephoto.png',
  install_dir: join_paths(dir_data, 'icons'))
+host_os = host_machine.system()
+if host_os == 'linux'
+if cc.has_header_symbol('features.h', '__UCLIBC__')
+host_os = 'linux-uclibc'
+elif cc.has_header_symbol('features.h', '__dietlibc__')
+host_os = 'linux-dietlibc'
+else
+host_os = 'linux-gnu'
+endif
+endif
+dep_e = dependency('enlightenment')
+release = dep_e.get_pkgconfig_variable('release')
+module_arch = '@0@-@1@-@2@'.format(host_os, host_machine.cpu_family(), release)
+dir_gadgets = join_paths([dir_lib, 'enlightenment/gadgets', module_arch])
+install_data('ephoto.desktop',
+install_dir: join_paths([dir_gadgets, 'ephoto']))
diff --git a/meson.build b/meson.build
index 87f081a..2665538 100644
--- a/meson.build
+++ b/meson.build
@@ -17,6 +17,7 @@ elm  = dependency('elementary', required: true,  version: 
efl_version)
 edje = dependency('edje',   required: true,  version: efl_version)
 eipc = dependency('ecore-ipc',  required: true,  version: efl_version)
 exif = dependency('libexif',required: false, version: '>= 0.6.0')
+depe = dependency('enlightenment', required: false)
 # check for windows dependency
 if build_machine.system() == 'windows'
win = dependency('evil', version: efl_version)
@@ -66,6 +67,9 @@ endif
 if exif.found() == true
 cfg.set   ('HAVE_LIBEXIF', 1)
 endif
+if depe.found() == true
+cfg.set   ('HAVE_E'  , 1)
+endif
 if get_option('nls') == true
 if cc.has_header('locale.h') == true
 if cc.has_header('libintl.h') == true
diff --git a/src/bin/ephoto.c b/src/bin/ephoto.c
index 826648f..8cbf01a 100644
--- a/src/bin/ephoto.c
+++ b/src/bin/ephoto.c
@@ -2,16 +2,17 @@
 
 static void _ephoto_display_usage(void);
 
-EAPI_MAIN int
-elm_main(int argc, char **argv)
+int
+main(int argc, char *argv[])
 {
-   int r = 0;
+   int gadget = 0, r = 0;
 
+   elm_init(argc, (char **)argv);
eio_init();
elm_need_efreet();
elm_language_set("");
elm_app_compile_data_dir_set(PACKAGE_DATA_DIR);
-   elm_app_info_set(elm_main, "ephoto", "themes/ephoto.edj");
+   elm_app_info_set(main, "ephoto", "themes/ephoto.edj");
 #if HAVE_GETTEXT && ENABLE_NLS
elm_app_compile_locale_set(LOCALEDIR);
bindtextdomain(PACKAGE, elm_app_locale_dir_get());
@@ -28,6 +29,9 @@ elm_main(int argc, char **argv)
 
elm_policy_set(ELM_POLICY_QUIT, ELM_POLICY_QUIT_LAST_WINDOW_CLOSED);
 
+   if (getenv("E_GADGET_ID"))
+ gadget = 1;
+
if (argc > 2)
  {
 printf("Too Many Arguments!\n");
@@ -37,7 +41,7 @@ elm_main(int argc, char **argv)
  }
else if (argc < 2)
  {
-Evas_Object *win = ephoto_window_add(NULL);
+Evas_Object *win = ephoto_window_add(NULL, gadget);
 
 if (!win)
   {
@@ -61,7 +65,7 @@ elm_main(int argc, char **argv)
  r = 1;
  goto end;
   }
-Evas_Object *win = ephoto_window_add(real);
+Evas_Object *win = ephoto_window_add(real, gadget);
 
 free(real);
 if (!win)
@@ -71,12 +75,12 @@ elm_main(int argc, char **argv)
   }
  }
 
-   elm_run();
-
+   ecore_main_loop_begin();
 end:
e_thumb_shutdown();
efreet_mime_shutdown();
eio_shutdown();
+   elm_shutdown();
 
return r;
 }
@@ -89,5 +93,3 @@ _ephoto_display_usage(void)
  "ephoto filename : Specifies a file to open\n"
  "ephoto dirname  : Specifies a directory to 
open\n");
 }
-
-ELM_MAIN()
diff --git a/src/bin/ephoto.h b/src/bin/ephoto.h
index dc62990..b8a5393 100644
--- a/src/bin/ephoto.h
+++ b/src/bin/ephoto.h
@@ -21,6 +21,9 @@
 # include 
 # include 
 # include 
+#if HAVE_ENLIGHTENMENT
+# include 
+#endif
 
 #if HAVE_GETTEXT
 # include 
@@ -45,7 +48,7 @@ typedef enum _Ephoto_Sort Ephoto_Sort;
 typedef enum _Ephoto_Ipc_Domain   Ephoto_Ipc_Domain;
 
 

[EGIT] [enlightenment/modules/cpu] master 01/01: Updating danish translation

2017-11-28 Thread maxerba
maxerba pushed a commit to branch master.

http://git.enlightenment.org/enlightenment/modules/cpu.git/commit/?id=5949690d2c21bfa9cccd21047828d0b48cfbf2d0

commit 5949690d2c21bfa9cccd21047828d0b48cfbf2d0
Author: maxerba 
Date:   Tue Nov 28 17:54:56 2017 +0100

Updating danish translation
---
 po/da.po | 45 +
 1 file changed, 25 insertions(+), 20 deletions(-)

diff --git a/po/da.po b/po/da.po
index d5fc2e1..4d8bc74 100644
--- a/po/da.po
+++ b/po/da.po
@@ -1,46 +1,51 @@
-# Danish translation for enlightenment
-# Copyright (c) 2009 Rosetta Contributors and Canonical Ltd 2009
-# This file is distributed under the same license as the enlightenment package.
-# FIRST AUTHOR , 2009.
+# Danish translation for cpu
+# Copyright (C) YEAR $COPYRIGHT_HOLDER
+# This file is distributed under the same license as the cpu package.
+# Schleiss , 2009.
+# scootergrisen, 2017.
 #
 msgid ""
 msgstr ""
-"Project-Id-Version: enlightenment\n"
-"Report-Msgid-Bugs-To: FULL NAME \n"
-"POT-Creation-Date: 2009-11-05 16:07+0800\n"
-"PO-Revision-Date: 2009-11-24 16:25+\n"
-"Last-Translator: Schleiss \n"
-"Language-Team: Danish \n"
+"Project-Id-Version: cpu\n"
+"Report-Msgid-Bugs-To: enlightenment-de...@lists.sourceforge.net\n"
+"POT-Creation-Date: 2013-08-24 11:50+0200\n"
+"PO-Revision-Date: 2017-11-28 00:00+\n"
+"Last-Translator: scootergrisen\n"
+"Language-Team: Danish\n"
+"Language: da\n"
 "MIME-Version: 1.0\n"
 "Content-Type: text/plain; charset=UTF-8\n"
 "Content-Transfer-Encoding: 8bit\n"
-"X-Launchpad-Export-Date: 2009-11-25 04:49+\n"
-"X-Generator: Launchpad (build Unknown)\n"
+"Plural-Forms: nplurals=2; plural=(n != 1);\n"
 
-#: ../src/e_mod_main.c:132
+#: src/e_mod_main.c:132
 msgid "Cpu"
 msgstr "Cpu"
 
-#: ../src/e_mod_main.c:366
+#: src/e_mod_main.c:374
 msgid "Fast (0.5 sec)"
 msgstr "Hurtig (0,5 sek.)"
 
-#: ../src/e_mod_main.c:373
+#: src/e_mod_main.c:381
 msgid "Medium (1 sec)"
-msgstr "Mellem (1 sek.)"
+msgstr "Medium (1 sek.)"
 
-#: ../src/e_mod_main.c:380
+#: src/e_mod_main.c:388
 msgid "Normal (2 sec)"
 msgstr "Normal (2 sek.)"
 
-#: ../src/e_mod_main.c:387
+#: src/e_mod_main.c:395
 msgid "Slow (5 sec)"
 msgstr "Langsom (5 sek.)"
 
-#: ../src/e_mod_main.c:394
+#: src/e_mod_main.c:402
 msgid "Very Slow (30 sec)"
 msgstr "Meget langsom (30 sek.)"
 
-#: ../src/e_mod_main.c:405
+#: src/e_mod_main.c:409
 msgid "Time Between Updates"
 msgstr "Tid mellem opdateringer"
+
+#: src/e_mod_main.c:415
+msgid "Merge CPU's into single Statistic"
+msgstr "Saml CPU'er i Ă©n statistik"

-- 




[EGIT] [enlightenment/modules/wlan] master 01/01: Updating danish translation

2017-11-28 Thread maxerba
maxerba pushed a commit to branch master.

http://git.enlightenment.org/enlightenment/modules/wlan.git/commit/?id=3c525972df8cdefcc118f15c43d0fe6ea7cac88c

commit 3c525972df8cdefcc118f15c43d0fe6ea7cac88c
Author: maxerba 
Date:   Tue Nov 28 17:56:32 2017 +0100

Updating danish translation
---
 po/da.po | 65 
 1 file changed, 33 insertions(+), 32 deletions(-)

diff --git a/po/da.po b/po/da.po
index cf404c4..1e00e82 100644
--- a/po/da.po
+++ b/po/da.po
@@ -1,59 +1,60 @@
-# Danish translation for enlightenment
-# Copyright (c) 2009 Rosetta Contributors and Canonical Ltd 2009
-# This file is distributed under the same license as the enlightenment package.
-# FIRST AUTHOR , 2009.
+# Danish translation for wlan
+# Copyright (C) YEAR $COPYRIGHT_HOLDER
+# This file is distributed under the same license as the wlan package.
+# Kris , 2009.
+# scootergrisen, 2017.
 #
 msgid ""
 msgstr ""
-"Project-Id-Version: enlightenment\n"
-"Report-Msgid-Bugs-To: FULL NAME \n"
-"POT-Creation-Date: 2009-11-05 16:07+0800\n"
-"PO-Revision-Date: 2009-11-03 08:50+\n"
-"Last-Translator: Kris \n"
-"Language-Team: Danish \n"
+"Project-Id-Version: wlan\n"
+"Report-Msgid-Bugs-To: enlightenment-de...@lists.sourceforge.net\n"
+"POT-Creation-Date: 2014-05-24 09:18+0200\n"
+"PO-Revision-Date: 2017-11-28 00:00+\n"
+"Last-Translator: scootergrisen\n"
+"Language-Team: Danish\n"
+"Language: da\n"
 "MIME-Version: 1.0\n"
 "Content-Type: text/plain; charset=UTF-8\n"
 "Content-Transfer-Encoding: 8bit\n"
-"X-Launchpad-Export-Date: 2009-11-12 04:50+\n"
-"X-Generator: Launchpad (build Unknown)\n"
+"Plural-Forms: nplurals=2; plural=(n != 1);\n"
 
-#: ../src/e_mod_config.c:44
-msgid "Wlan Configuration"
-msgstr ""
+#: src/e_mod_config.c:38
+msgid "Wlan Settings"
+msgstr "Wlan-indstillinger"
 
-#: ../src/e_mod_config.c:117
+#: src/e_mod_config.c:100
 msgid "General Settings"
 msgstr "Generelle indstillinger"
 
-#: ../src/e_mod_config.c:119
+#: src/e_mod_config.c:103
 msgid "Always Show Text"
 msgstr "Vis altid tekst"
 
-#: ../src/e_mod_config.c:121
+#: src/e_mod_config.c:106
 msgid "Show Text On Mouse Over"
-msgstr ""
+msgstr "Vis tekst nĂ¥r musen holdes over"
 
-#: ../src/e_mod_config.c:124
+#: src/e_mod_config.c:109
 msgid "Show Text As Percent"
-msgstr ""
+msgstr "Vis tekst som procent"
 
-#: ../src/e_mod_config.c:128
+#: src/e_mod_config.c:113
 msgid "Check Interval:"
-msgstr ""
+msgstr "Tjekinterval:"
 
-#: ../src/e_mod_config.c:131
+#: src/e_mod_config.c:116
 #, c-format
 msgid "%1.0f seconds"
-msgstr ""
+msgstr "%1.0f sekunder"
 
-#: ../src/e_mod_config.c:138
+#: src/e_mod_config.c:123
 msgid "Device Settings"
-msgstr ""
+msgstr "Enhedsindstillinger"
 
-#: ../src/e_mod_main.c:107
+#: src/e_mod_main.c:98
 msgid "Wlan"
-msgstr ""
+msgstr "Wlan"
 
-#: ../src/e_mod_main.c:165
-msgid "Configuration"
-msgstr "Konfiguration"
+#: src/e_mod_main.c:135
+msgid "Settings"
+msgstr "Indstillinger"

-- 




[EGIT] [core/efl] master 01/01: elementary: Remove set but unused variables

2017-11-28 Thread Christopher Michael
devilhorns pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=edc6ee86800d45e081fd6e18311ad9befed1fcc1

commit edc6ee86800d45e081fd6e18311ad9befed1fcc1
Author: Chris Michael 
Date:   Tue Nov 28 11:42:01 2017 -0500

elementary: Remove set but unused variables

Signed-off-by: Chris Michael 
---
 src/lib/elementary/efl_ui_focus_manager_calc.c | 4 
 1 file changed, 4 deletions(-)

diff --git a/src/lib/elementary/efl_ui_focus_manager_calc.c 
b/src/lib/elementary/efl_ui_focus_manager_calc.c
index a5c6ea5af4..e48cf262e5 100644
--- a/src/lib/elementary/efl_ui_focus_manager_calc.c
+++ b/src/lib/elementary/efl_ui_focus_manager_calc.c
@@ -1358,8 +1358,6 @@ 
_efl_ui_focus_manager_calc_efl_ui_focus_manager_focus_set(Eo *obj, Efl_Ui_Focus_
Node *node, *last;
Efl_Ui_Focus_Object *last_focusable = NULL;
Efl_Ui_Focus_Manager *redirect_manager;
-   Eo *focusable;
-   Node_Type type;
 
EINA_SAFETY_ON_NULL_RETURN(focus);
 
@@ -1417,8 +1415,6 @@ 
_efl_ui_focus_manager_calc_efl_ui_focus_manager_focus_set(Eo *obj, Efl_Ui_Focus_
  }
 
redirect_manager = node->redirect_manager;
-   type = node->type;
-   focusable = node->focusable;
 
last = eina_list_last_data_get(pd->focus_stack);
if (last)

-- 




[EGIT] [core/enlightenment] master 01/01: conf-randr: No need to set this variable twice

2017-11-28 Thread Christopher Michael
devilhorns pushed a commit to branch master.

http://git.enlightenment.org/core/enlightenment.git/commit/?id=3a7f13256085fcf79c42a2d23c2c0c69e4a1dd78

commit 3a7f13256085fcf79c42a2d23c2c0c69e4a1dd78
Author: Chris Michael 
Date:   Tue Nov 28 11:17:07 2017 -0500

conf-randr: No need to set this variable twice

Signed-off-by: Chris Michael 
---
 src/modules/conf_randr/e_int_config_randr2.c | 1 -
 1 file changed, 1 deletion(-)

diff --git a/src/modules/conf_randr/e_int_config_randr2.c 
b/src/modules/conf_randr/e_int_config_randr2.c
index f724ecd4f..1530c214a 100644
--- a/src/modules/conf_randr/e_int_config_randr2.c
+++ b/src/modules/conf_randr/e_int_config_randr2.c
@@ -1155,7 +1155,6 @@ _basic_apply(E_Config_Dialog *cfd EINA_UNUSED, 
E_Config_Dialog_Data *cfdata)
 printf("APPLY %s  rel to %s\n", cs->id, cs2->rel_to);
 if (cs2->rel_to) cs->rel_to = eina_stringshare_add(cs2->rel_to);
 cs->rel_align = cs2->rel_align;
-cs->mode_refresh = cs2->mode_refresh;
 cs->mode_w = cs2->mode_w;
 cs->mode_h = cs2->mode_h;
 cs->mode_refresh = cs2->mode_refresh;

-- 




[EGIT] [website/www-content] master 01/01: Wiki page main-loop.md changed with summary [created] by Xavi Artigas

2017-11-28 Thread Xavi Artigas
WWW-www.enlightenment.org pushed a commit to branch master.

http://git.enlightenment.org/website/www-content.git/commit/?id=2d8ea67e4929d4a78a291e44a0e679935f8af338

commit 2d8ea67e4929d4a78a291e44a0e679935f8af338
Author: Xavi Artigas 
Date:   Tue Nov 28 07:40:44 2017 -0800

Wiki page main-loop.md changed with summary [created] by Xavi Artigas
---
 pages/develop/guides/c/core/main-loop.md.txt | 173 +++
 1 file changed, 173 insertions(+)

diff --git a/pages/develop/guides/c/core/main-loop.md.txt 
b/pages/develop/guides/c/core/main-loop.md.txt
new file mode 100644
index 0..52b0b324c
--- /dev/null
+++ b/pages/develop/guides/c/core/main-loop.md.txt
@@ -0,0 +1,173 @@
+---
+~~Title: Main Loop Programming Guide~~
+---
+
+# Main Loop Programming Guide #
+
+The EFL is event-driven. This means that execution is usually spent inside an 
internal EFL *Main Loop*, and the application is notified through function 
callbacks of virtually any event happening on the computer. This is typically 
more efficient than *polling* for events, in which the application has to 
repeatedly ask if a certain event has occurred. The reason is that when nothing 
is happening (no events are pending) the main loop enters the *idle state* in 
which the CPU consumes very l [...]
+
+The EFL manages, among other things, timers, file descriptors, user interface 
events and it even provides a simple mechanism for applications to perform 
conventional data polling if desired.
+
+## Prerequisites ##
+
+* Read the [Introduction to Eo](eo-intro.md) to know how Eo objects are 
created and destroyed.
+
+* Read the [Events Programming Guide](events.md) to know how to register 
callbacks to be triggered by events.
+
+## Timers ##
+
+Timers allow events to be triggered periodically after the given time has 
elapsed. After an event callback has been registered with the timer, it will be 
called at regular intervals.
+
+See usage examples in the EFL examples repository: 
[``reference/c/core/src/core_idler.c``](https://git.enlightenment.org/tools/examples.git/tree/reference/c/core/src/core_idler.c)
 and 
[``reference/c/core/src/core_poll.c``](https://git.enlightenment.org/tools/examples.git/tree/reference/c/core/src/core_poll.c).
+
+### Creating and Destroying Timers ###
+
+Timers are Eo objects and are instantiated and destroyed with ``efl_add()`` 
like all other Eo objects (see [Introduction to Eo](eo-intro.md)). Their class 
is `EFL_LOOP_TIMER_CLASS`:
+
+```c
+timer_object = efl_add(EFL_LOOP_TIMER_CLASS, ...);
+```
+
+Timers do not need to have a parent. However, it is convenient to create them 
under the application Main Loop, for instance, so the parent takes care of 
destroying the timer.
+
+If you want to manually destroy a timer, though, use the regular 
``efl_unref()`` or ``efl_del()``.
+
+### The Timer Callback ###
+
+Register the callback using ``efl_event_callback_add()`` and the 
``EFL_LOOP_TIMER_EVENT_TICK`` event as explained in the [Events Programming 
Guide](events.md).
+
+```c
+efl_event_callback_add(timer_object, EFL_LOOP_TIMER_EVENT_TICK, _timer_cb, 
NULL);
+```
+
+The callback has the usual event handler signature:
+
+```c
+static void
+_timer_cb(void *data, const Efl_Event *event)
+{
+   Efl_Loop_Timer *timer = event->object;
+
+   [...]
+}
+```
+
+Notice how the timer object is recovered from the event structure.
+
+### Configuring a Timer ###
+
+The ``interval`` property controls the amount of time between triggers of the 
callback, in *seconds*:
+
+```c
+efl_loop_timer_interval_set(timer_object, seconds);
+efl_loop_timer_interval_get(timer_object);
+```
+
+The time left before the next trigger of the timer can be retrieved through 
the ``pending`` read-only property:
+
+```c
+efl_loop_timer_pending_get(timer_object);
+```
+
+The current interval can be reset with:
+
+```c
+efl_loop_timer_reset(timer_object);
+```
+
+Finally, the current interval can be extended, effectively delaying all future 
triggers of the timer by the given amount of *seconds*:
+
+```c
+efl_loop_timer_delay(timer_object, seconds);
+```
+
+## File Descriptor Monitors ##
+
+EFL can monitor the system's file descriptor activity through ``Efl.Loop.Fd`` 
objects and trigger relevant events.
+
+See usage examples in the EFL examples repository: 
[``reference/c/core/src/core_loop.c``](https://git.enlightenment.org/tools/examples.git/tree/reference/c/core/src/core_loop.c)
+
+### Creating and Destroying FD Monitors ###
+
+FD monitors are Eo objects that wrap system file descriptors, and are 
instantiated and destroyed with ``efl_add()`` like all other Eo objects (see 
[Introduction to Eo](eo-intro.md)). Their class is `EFL_LOOP_FD_CLASS,`:
+
+```c
+fd_object = efl_add(EFL_LOOP_FD_CLASS, ...);
+```
+
+To destroy an FD monitor, use the regular ``efl_unref()`` or ``efl_del()``.
+
+### FD Monitor callbacks ###
+
+Register to receive events on the FD monitor object with the usual 
``efl_event_callback_add()``:
+

[EGIT] [website/www-content] master 01/01: Wiki page sidebar changed with summary [] by Gareth Halfacree

2017-11-28 Thread Gareth Halfacree
WWW-www.enlightenment.org pushed a commit to branch master.

http://git.enlightenment.org/website/www-content.git/commit/?id=e48c9d6c91ca41d079968527b47122f697f2daf6

commit e48c9d6c91ca41d079968527b47122f697f2daf6
Author: Gareth Halfacree 
Date:   Tue Nov 28 07:31:05 2017 -0800

Wiki page sidebar changed with summary [] by Gareth Halfacree
---
 pages/develop/sidebar.txt | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/pages/develop/sidebar.txt b/pages/develop/sidebar.txt
index 17261a933..e4bf4bb7c 100644
--- a/pages/develop/sidebar.txt
+++ b/pages/develop/sidebar.txt
@@ -3,8 +3,8 @@
   * [[/develop/start.md] | Developing with EFL]]
 
 === Setup ===
-  * [[/develop/setup/start.md | Setting Up a Development Environment [TODO]]]
-* [[/develop/setup/c/start.md | Setting up a C Development Environment 
[TODO]]]
+  * [[/develop/setup/start.md | Setting Up EFL [TODO]]]
+* [[/develop/setup/c/start.md | EFL for C Development [TODO]]]
 
 === Tutorials ===
   * [[/develop/legacy/tutorials/start | Stable API Tutorials]]

-- 




[EGIT] [website/www-content] master 01/01: Wiki page start.md changed with summary [] by Gareth Halfacree

2017-11-28 Thread Gareth Halfacree
WWW-www.enlightenment.org pushed a commit to branch master.

http://git.enlightenment.org/website/www-content.git/commit/?id=ca28dcc85405e718dae586e53a7159002c378086

commit ca28dcc85405e718dae586e53a7159002c378086
Author: Gareth Halfacree 
Date:   Tue Nov 28 07:29:39 2017 -0800

Wiki page start.md changed with summary [] by Gareth Halfacree
---
 pages/develop/setup/c/start.md.txt | 13 -
 1 file changed, 12 insertions(+), 1 deletion(-)

diff --git a/pages/develop/setup/c/start.md.txt 
b/pages/develop/setup/c/start.md.txt
index ce0188b43..5e12c425f 100644
--- a/pages/develop/setup/c/start.md.txt
+++ b/pages/develop/setup/c/start.md.txt
@@ -4,4 +4,15 @@
 
 # Setting Up a C Development Environment #
 
-TODO
\ No newline at end of file
+Installing the Enlightenment Foundation Libraries for C development is a 
simple task on common platforms. The following documentation walks you through 
the process step-by-step, beginning with selecting your development platform's 
operating system.
+
+## Operating Systems ##
+
+* Ubuntu
+* Arch Linux
+* Debian
+* Fedora
+* FreeBSD
+* openSUSE
+* Yocto
+* Mac OS X 

-- 




[EGIT] [website/www-content] master 01/01: Wiki page sidebar changed with summary [] by Gareth Halfacree

2017-11-28 Thread Gareth Halfacree
WWW-www.enlightenment.org pushed a commit to branch master.

http://git.enlightenment.org/website/www-content.git/commit/?id=fcef72637b3273446b30400c7f44d412027fabfd

commit fcef72637b3273446b30400c7f44d412027fabfd
Author: Gareth Halfacree 
Date:   Tue Nov 28 07:30:42 2017 -0800

Wiki page sidebar changed with summary [] by Gareth Halfacree
---
 pages/develop/sidebar.txt | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/pages/develop/sidebar.txt b/pages/develop/sidebar.txt
index 68097a075..17261a933 100644
--- a/pages/develop/sidebar.txt
+++ b/pages/develop/sidebar.txt
@@ -4,7 +4,7 @@
 
 === Setup ===
   * [[/develop/setup/start.md | Setting Up a Development Environment [TODO]]]
-* [[/develop/setup/c/start.md | Setting up a C Development Environment 
[TODO]]
+* [[/develop/setup/c/start.md | Setting up a C Development Environment 
[TODO]]]
 
 === Tutorials ===
   * [[/develop/legacy/tutorials/start | Stable API Tutorials]]

-- 




[EGIT] [website/www-content] master 01/01: Wiki page sidebar changed with summary [] by Gareth Halfacree

2017-11-28 Thread Gareth Halfacree
WWW-www.enlightenment.org pushed a commit to branch master.

http://git.enlightenment.org/website/www-content.git/commit/?id=de7e4f8b80f5535a0a6300259c893fe2d2926fa7

commit de7e4f8b80f5535a0a6300259c893fe2d2926fa7
Author: Gareth Halfacree 
Date:   Tue Nov 28 07:30:30 2017 -0800

Wiki page sidebar changed with summary [] by Gareth Halfacree
---
 pages/develop/sidebar.txt | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/pages/develop/sidebar.txt b/pages/develop/sidebar.txt
index 85c668c22..68097a075 100644
--- a/pages/develop/sidebar.txt
+++ b/pages/develop/sidebar.txt
@@ -3,7 +3,8 @@
   * [[/develop/start.md] | Developing with EFL]]
 
 === Setup ===
-  * [[/develop/setup/c/ | Setting Up a C Development Environment [TODO]]]
+  * [[/develop/setup/start.md | Setting Up a Development Environment [TODO]]]
+* [[/develop/setup/c/start.md | Setting up a C Development Environment 
[TODO]]
 
 === Tutorials ===
   * [[/develop/legacy/tutorials/start | Stable API Tutorials]]

-- 




[EGIT] [website/www-content] master 01/01: Wiki page start.md changed with summary [] by Gareth Halfacree

2017-11-28 Thread Gareth Halfacree
WWW-www.enlightenment.org pushed a commit to branch master.

http://git.enlightenment.org/website/www-content.git/commit/?id=817af972b506424c7ad68e94ce29f4b8640dd409

commit 817af972b506424c7ad68e94ce29f4b8640dd409
Author: Gareth Halfacree 
Date:   Tue Nov 28 07:23:53 2017 -0800

Wiki page start.md changed with summary [] by Gareth Halfacree
---
 pages/develop/setup/c/start.md.txt | 6 +-
 1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/pages/develop/setup/c/start.md.txt 
b/pages/develop/setup/c/start.md.txt
index cbab1714f..ce0188b43 100644
--- a/pages/develop/setup/c/start.md.txt
+++ b/pages/develop/setup/c/start.md.txt
@@ -1,3 +1,7 @@
-# Setting up for development with C #
+---
+~~Title: Setting Up a C Development Environment~~
+---
+
+# Setting Up a C Development Environment #
 
 TODO
\ No newline at end of file

-- 




[EGIT] [website/www-content] master 01/01: Wiki page start.md changed with summary [created] by Gareth Halfacree

2017-11-28 Thread Gareth Halfacree
WWW-www.enlightenment.org pushed a commit to branch master.

http://git.enlightenment.org/website/www-content.git/commit/?id=51323ed9ff8beb07d09bee07275c5b9af467eaad

commit 51323ed9ff8beb07d09bee07275c5b9af467eaad
Author: Gareth Halfacree 
Date:   Tue Nov 28 07:22:57 2017 -0800

Wiki page start.md changed with summary [created] by Gareth Halfacree
---
 pages/develop/setup/start.md.txt | 16 
 1 file changed, 16 insertions(+)

diff --git a/pages/develop/setup/start.md.txt b/pages/develop/setup/start.md.txt
new file mode 100644
index 0..91dba4f87
--- /dev/null
+++ b/pages/develop/setup/start.md.txt
@@ -0,0 +1,16 @@
+---
+~~Title: Setting Up a Development Environment~~
+~~NOCACHE~~
+---
+
+# Setting Up a Development Environment #
+
+To develop applications using the Enlightenment Foundation Libraries (EFL) you 
will need a development environment which includes a copy of the EFL itself, a 
toolchain for compilation, and an integrated development environment (IDE) or 
text editor. The following pages demonstrate how to set up a development 
environment on a range of platforms.
+
+## Languages ##
+
+EFL can be used in a variety of programming languages, and the instructions 
for setting up a development environment differ from language to language. The 
currently documented languages are:
+
+* [C](https://www.enlightenment.org/develop/setup/c/start.md)
+
+Documentation for developers working in other languages will be added in the 
future.
\ No newline at end of file

-- 




[EGIT] [website/www-content] master 01/01: Wiki page sidebar changed with summary [] by Gareth Halfacree

2017-11-28 Thread Gareth Halfacree
WWW-www.enlightenment.org pushed a commit to branch master.

http://git.enlightenment.org/website/www-content.git/commit/?id=79b17ed1a4ed5b73f5184855a102e66597f0f725

commit 79b17ed1a4ed5b73f5184855a102e66597f0f725
Author: Gareth Halfacree 
Date:   Tue Nov 28 07:14:56 2017 -0800

Wiki page sidebar changed with summary [] by Gareth Halfacree
---
 pages/develop/sidebar.txt | 7 ++-
 1 file changed, 6 insertions(+), 1 deletion(-)

diff --git a/pages/develop/sidebar.txt b/pages/develop/sidebar.txt
index 82217609f..85c668c22 100644
--- a/pages/develop/sidebar.txt
+++ b/pages/develop/sidebar.txt
@@ -17,6 +17,11 @@
 * [[/develop/tutorials/c/eo-inherit | Class Inheritance]]
 * [[/develop/tutorials/c/eo-multiinherit | Multiple Inheritance]]
 
-=== APIs ===
+=== Programming Guides ===
+  * [[/develop/legacy/program_guide/start | Stable API Programming Guides]]
+  * [[develop/guides/start.md | Beta API Programming Guides]]
+* [[/develop/guides/c/eina/start.md | Eina Programming Guide]]
+
+=== API Reference ===
   * [[/develop/legacy/api/c | C API [Stable]]]
   * [[/develop/api/ | C API [Beta]]]

-- 




[EGIT] [website/www-content] master 01/01: Wiki page sidebar changed with summary [] by Gareth Halfacree

2017-11-28 Thread Gareth Halfacree
WWW-www.enlightenment.org pushed a commit to branch master.

http://git.enlightenment.org/website/www-content.git/commit/?id=b117dc2fc115e306ab9d9a68dd86784f528aa2dc

commit b117dc2fc115e306ab9d9a68dd86784f528aa2dc
Author: Gareth Halfacree 
Date:   Tue Nov 28 07:10:43 2017 -0800

Wiki page sidebar changed with summary [] by Gareth Halfacree
---
 pages/develop/sidebar.txt | 23 +--
 1 file changed, 13 insertions(+), 10 deletions(-)

diff --git a/pages/develop/sidebar.txt b/pages/develop/sidebar.txt
index 71ad1ad42..82217609f 100644
--- a/pages/develop/sidebar.txt
+++ b/pages/develop/sidebar.txt
@@ -1,19 +1,22 @@
 ~~NOCACHE~~
+=== Introduction ===
+  * [[/develop/start.md] | Developing with EFL]]
 
 === Setup ===
-  * [[/develop/setup/c/ | Setting up C development [TODO]]]
+  * [[/develop/setup/c/ | Setting Up a C Development Environment [TODO]]]
 
 === Tutorials ===
   * [[/develop/legacy/tutorials/start | Stable API Tutorials]]
-
-  * [[/develop/tutorials/c/hello-world | Hello World [Beta]]]
-  * [[/develop/tutorials/c/eo-intro | EFL Objects [Beta]]]
-* [[/develop/tutorials/c/eo-refcount | Reference Counting]]
-* [[/develop/tutorials/c/eo-classes | Creating New Classes]]
-* [[/develop/tutorials/c/eo-inherit | Class Inheritance]]
-* [[/develop/tutorials/c/eo-multiinherit | Multiple Inheritance]]
+  * [[/develop/tutorials/start.md | Beta API Tutorials]]
+* [[/develop/tutorials/c/start.md | Beta API Tutorials [C]]]
+  * [[/develop/tutorials/c/hello-world | Hello World]]
+  * EO and Eolian
+* [[/develop/tutorials/c/eo-intro | EFL Objects]]
+* [[/develop/tutorials/c/eo-refcount | Reference Counting]]
+* [[/develop/tutorials/c/eo-classes | Creating New Classes]]
+* [[/develop/tutorials/c/eo-inherit | Class Inheritance]]
+* [[/develop/tutorials/c/eo-multiinherit | Multiple Inheritance]]
 
 === APIs ===
-  * [[/develop/legacy/api/c | C Stable API]]
-
+  * [[/develop/legacy/api/c | C API [Stable]]]
   * [[/develop/api/ | C API [Beta]]]

-- 




[EGIT] [website/www-content] master 01/01: Wiki page start.md changed with summary [] by Gareth Halfacree

2017-11-28 Thread Gareth Halfacree
WWW-www.enlightenment.org pushed a commit to branch master.

http://git.enlightenment.org/website/www-content.git/commit/?id=11235f89951f28ad34f1b1f9b960a41cb3ced005

commit 11235f89951f28ad34f1b1f9b960a41cb3ced005
Author: Gareth Halfacree 
Date:   Tue Nov 28 07:04:48 2017 -0800

Wiki page start.md changed with summary [] by Gareth Halfacree
---
 pages/develop/tutorials/c/start.md.txt | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/pages/develop/tutorials/c/start.md.txt 
b/pages/develop/tutorials/c/start.md.txt
index 38d2b3fac..f23150d56 100644
--- a/pages/develop/tutorials/c/start.md.txt
+++ b/pages/develop/tutorials/c/start.md.txt
@@ -11,7 +11,7 @@ The following tutorials are designed to build on each other, 
introducing concept
 > The tutorials in this section use the latest beta release of the API, as 
 > noted in [Developing with the Enlightenment Foundation 
 > Libraries](https://www.enlightenment.org/develop/start.md#Current_vs._Beta). 
 > Versions of these tutorials written for the current release can be found in 
 > the [Legacy section of the 
 > website](https://www.enlightenment.org/develop/legacy/tutorial/start).
 
 * [Hello 
World](https://www.enlightenment.org/develop/tutorials/c/hello-world.md)
-* Introduction to Eo
+* Eo and Eolian
   * [Creating and Destroying Objects with 
Eo](https://www.enlightenment.org/develop/tutorials/c/eo-intro.md)
   * [Reference Counting in 
Eo](https://www.enlightenment.org/develop/tutorials/c/eo-refcount.md)
   * [Creating New Classes with 
Eolian](https://www.enlightenment.org/develop/tutorials/c/eo-classes.md)

-- 




[EGIT] [website/www-content] master 01/01: Wiki page start.md changed with summary [] by Gareth Halfacree

2017-11-28 Thread Gareth Halfacree
WWW-www.enlightenment.org pushed a commit to branch master.

http://git.enlightenment.org/website/www-content.git/commit/?id=144b71c3bcf13254325c3e07aee96f969e81a068

commit 144b71c3bcf13254325c3e07aee96f969e81a068
Author: Gareth Halfacree 
Date:   Tue Nov 28 06:59:02 2017 -0800

Wiki page start.md changed with summary [] by Gareth Halfacree
---
 pages/develop/tutorials/c/start.md.txt | 11 ++-
 1 file changed, 6 insertions(+), 5 deletions(-)

diff --git a/pages/develop/tutorials/c/start.md.txt 
b/pages/develop/tutorials/c/start.md.txt
index f0df921c8..38d2b3fac 100644
--- a/pages/develop/tutorials/c/start.md.txt
+++ b/pages/develop/tutorials/c/start.md.txt
@@ -11,8 +11,9 @@ The following tutorials are designed to build on each other, 
introducing concept
 > The tutorials in this section use the latest beta release of the API, as 
 > noted in [Developing with the Enlightenment Foundation 
 > Libraries](https://www.enlightenment.org/develop/start.md#Current_vs._Beta). 
 > Versions of these tutorials written for the current release can be found in 
 > the [Legacy section of the 
 > website](https://www.enlightenment.org/develop/legacy/tutorial/start).
 
 * [Hello 
World](https://www.enlightenment.org/develop/tutorials/c/hello-world.md)
-* [Introduction to Eo: Creating and Destroying 
Objects](https://www.enlightenment.org/develop/tutorials/c/eo-intro.md)
-* [Reference Counting in 
Eo](https://www.enlightenment.org/develop/tutorials/c/eo-refcount.md)
-* [Creating New Classes with 
Eolian](https://www.enlightenment.org/develop/tutorials/c/eo-classes.md)
-* [Class Inheritance with 
Eolian](https://www.enlightenment.org/develop/tutorials/c/eo-inherit.md)
-* [Multiple Class Inheritance with 
Eolian](https://www.enlightenment.org/develop/tutorials/c/eo-multiinherit.md)
\ No newline at end of file
+* Introduction to Eo
+  * [Creating and Destroying Objects with 
Eo](https://www.enlightenment.org/develop/tutorials/c/eo-intro.md)
+  * [Reference Counting in 
Eo](https://www.enlightenment.org/develop/tutorials/c/eo-refcount.md)
+  * [Creating New Classes with 
Eolian](https://www.enlightenment.org/develop/tutorials/c/eo-classes.md)
+  * [Class Inheritance with 
Eolian](https://www.enlightenment.org/develop/tutorials/c/eo-inherit.md)
+  * [Multiple Class Inheritance with 
Eolian](https://www.enlightenment.org/develop/tutorials/c/eo-multiinherit.md)
\ No newline at end of file

-- 




[EGIT] [website/www-content] master 01/01: Wiki page start.md changed with summary [] by Gareth Halfacree

2017-11-28 Thread Gareth Halfacree
WWW-www.enlightenment.org pushed a commit to branch master.

http://git.enlightenment.org/website/www-content.git/commit/?id=7ca9d82d7d42dccf029b254aa28c646ca903cb3e

commit 7ca9d82d7d42dccf029b254aa28c646ca903cb3e
Author: Gareth Halfacree 
Date:   Tue Nov 28 06:50:00 2017 -0800

Wiki page start.md changed with summary [] by Gareth Halfacree
---
 pages/develop/tutorials/c/start.md.txt | 46 +++---
 1 file changed, 4 insertions(+), 42 deletions(-)

diff --git a/pages/develop/tutorials/c/start.md.txt 
b/pages/develop/tutorials/c/start.md.txt
index ad2e42ff9..f0df921c8 100644
--- a/pages/develop/tutorials/c/start.md.txt
+++ b/pages/develop/tutorials/c/start.md.txt
@@ -5,52 +5,14 @@
 
 # EFL C Tutorials #
 
-If you are just beginning your journey into programming with the Enlightenment 
Foundation Libraries (EFL), then these tutorials will help you on your way. 
Designed for those who have prior programming experience but who have not 
necessarily used EFL before, the tutorials will walk you through writing 
programs which build on EFL from the basic - a traditional "Hello World" 
example - through to the more advanced.
-
-If you have not yet done so, visit [Developing with the Enlightenment 
Foundation Libraries](https://www.enlightenment.org/develop/start.md) for 
background on EFL and details on how to set up your development environment.
-
-## Current vs. Beta ##
-
-The documentation on this section of the website is written with a focus on 
the next-generation release, currently in beta. While this means that the 
documentation is only partial in places, it will get you started with the very 
latest revision of EFL and all the new and improved features it brings.
-
-Documentation on the current version of EFL can be found in the [Legacy 
section](https://www.enlightenment.org/develop/legacy/). When working through 
the documentation on the site, keep in mind that if a document is located in 
``/develop/legacy`` it is referring to the current release of EFL; if it is 
located in any other section of ``/develop`` it is referring to the beta 
release.
-
-Versions of these tutorials written for the current release can be found in 
the [Legacy section of the 
website](https://www.enlightenment.org/develop/legacy/tutorial/start).
-
-## Tutorials ##
-
 The following tutorials are designed to build on each other, introducing 
concepts in a logical manner and working towards full understanding of EFL's 
capabilities. Most users should approach them in the order in which they are 
presented; only those with previous EFL experience should skip ahead.
 
+> **NOTE:**
+> The tutorials in this section use the latest beta release of the API, as 
noted in [Developing with the Enlightenment Foundation 
Libraries](https://www.enlightenment.org/develop/start.md#Current_vs._Beta). 
Versions of these tutorials written for the current release can be found in the 
[Legacy section of the 
website](https://www.enlightenment.org/develop/legacy/tutorial/start).
+
 * [Hello 
World](https://www.enlightenment.org/develop/tutorials/c/hello-world.md)
 * [Introduction to Eo: Creating and Destroying 
Objects](https://www.enlightenment.org/develop/tutorials/c/eo-intro.md)
 * [Reference Counting in 
Eo](https://www.enlightenment.org/develop/tutorials/c/eo-refcount.md)
 * [Creating New Classes with 
Eolian](https://www.enlightenment.org/develop/tutorials/c/eo-classes.md)
 * [Class Inheritance with 
Eolian](https://www.enlightenment.org/develop/tutorials/c/eo-inherit.md)
-* [Multiple Class Inheritance with 
Eolian](https://www.enlightenment.org/develop/tutorials/c/eo-multiinherit.md)
-
-## IRC Channels ##
-
-The official Enlightenment IRC channels, hosted on the Freenode network, are 
often the quickest way to communicate with fellow developers. Available in 
English, German, French, and Korean, the channels are accessible 24/7 and are 
open to both developers and end-users.
-
-Connection information is as follows:
-
-| IRC Server   | Port | Channel | Topic   |
-|--|--|-|-|
-| irc.freenode.net | 6667 | #e  | General |
-| irc.freenode.net | 6667 | #e.py   | Python-related  |
-| irc.freenode.net | 6667 | #e.bsd  | BSD-related |
-| irc.freenode.net | 6667 | #e.de   | General - German|
-| irc.freenode.net | 6667 | #e.fr   | General - French|
-| irc.freenode.net | 6667 | #e.kr   | General - Korean|
-
-## Mailing Lists ##
-
-The Enlightenment Project maintains several mailing lists, full details of 
which are available on the [Contact 
page](https://www.enlightenment.org/contact). The developer-focused lists, 
which are available in English only, are as follows:
-
-| Mailing List 
| Archive   
| Topic|

[EGIT] [website/www-content] master 01/01: Wiki page start.md changed with summary [] by Gareth Halfacree

2017-11-28 Thread Gareth Halfacree
WWW-www.enlightenment.org pushed a commit to branch master.

http://git.enlightenment.org/website/www-content.git/commit/?id=0fc71ee9edc9caf89f8633243426dad6d6f3e361

commit 0fc71ee9edc9caf89f8633243426dad6d6f3e361
Author: Gareth Halfacree 
Date:   Tue Nov 28 06:47:46 2017 -0800

Wiki page start.md changed with summary [] by Gareth Halfacree
---
 pages/develop/tutorials/start.md.txt | 39 +++-
 1 file changed, 3 insertions(+), 36 deletions(-)

diff --git a/pages/develop/tutorials/start.md.txt 
b/pages/develop/tutorials/start.md.txt
index d06d9b237..03033ec76 100644
--- a/pages/develop/tutorials/start.md.txt
+++ b/pages/develop/tutorials/start.md.txt
@@ -9,44 +9,11 @@ If you are just beginning your journey into programming with 
the Enlightenment F
 
 If you have not yet done so, visit [Developing with the Enlightenment 
Foundation Libraries](https://www.enlightenment.org/develop/start.md) for 
background on EFL and details on how to set up your development environment.
 
-## Current vs. Beta ##
-
-The documentation on this section of the website is written with a focus on 
the next-generation release, currently in beta. While this means that the 
documentation is only partial in places, it will get you started with the very 
latest revision of EFL and all the new and improved features it brings.
-
-Documentation on the current version of EFL can be found in the [Legacy 
section](https://www.enlightenment.org/develop/legacy/). When working through 
the documentation on the site, keep in mind that if a document is located in 
``/develop/legacy`` it is referring to the current release of EFL; if it is 
located in any other section of ``/develop`` it is referring to the beta 
release.
-
-Versions of these tutorials written for the current release can be found in 
the [Legacy section of the 
website](https://www.enlightenment.org/develop/legacy/tutorial/start).
-
+> **NOTE:**
+> The tutorials in this section use the latest beta release of the API, as 
noted in [Developing with the Enlightenment Foundation 
Libraries](https://www.enlightenment.org/develop/start.md#Current_vs._Beta). 
Versions of these tutorials written for the current release can be found in the 
[Legacy section of the 
website](https://www.enlightenment.org/develop/legacy/tutorial/start).
 
 ## Languages ##
 
 EFL is available for a variety of programming languages, enabling developers 
in a wide range of ecosystems to benefit from its features. Tutorials are 
currently available in the following languages:
 
-* [C](c/start.md)
-
-## IRC Channels ##
-
-The official Enlightenment IRC channels, hosted on the Freenode network, are 
often the quickest way to communicate with fellow developers. Available in 
English, German, French, and Korean, the channels are accessible 24/7 and are 
open to both developers and end-users.
-
-Connection information is as follows:
-
-| IRC Server   | Port | Channel | Topic   |
-|--|--|-|-|
-| irc.freenode.net | 6667 | #e  | General |
-| irc.freenode.net | 6667 | #e.py   | Python-related  |
-| irc.freenode.net | 6667 | #e.bsd  | BSD-related |
-| irc.freenode.net | 6667 | #e.de   | General - German|
-| irc.freenode.net | 6667 | #e.fr   | General - French|
-| irc.freenode.net | 6667 | #e.kr   | General - Korean|
-
-## Mailing Lists ##
-
-The Enlightenment Project maintains several mailing lists, full details of 
which are available on the [Contact 
page](https://www.enlightenment.org/contact). The developer-focused lists, 
which are available in English only, are as follows:
-
-| Mailing List 
| Archive   
| Topic|
-|--|---|--|
-| 
[enlightenment-devel](http://lists.sourceforge.net/lists/listinfo/enlightenment-devel)
   | 
[SourceForge](http://sourceforge.net/mailarchive/forum.php?forum_name=enlightenment-devel)
| E/EFL development discussion |
-| 
[enlightenment-announce](http://lists.sourceforge.net/lists/listinfo/enlightenment-announce)
 | 
[SourceForge](http://sourceforge.net/mailarchive/forum.php?forum_name=enlightenment-announce)
 | E/EFL announcements  |
-| 
[enlightenment-intl](http://lists.sourceforge.net/lists/listinfo/enlightenment-intl)
 | 
[SourceForge](http://sourceforge.net/mailarchive/forum.php?forum_name=enlightenment-intl)
 | Internationalization changes |
-| [enlightenment-git](mailto:git@lists.enlightenment.org?body=subscribe)   
|   
| 

[EGIT] [apps/rage] master 01/01: implement metadata for mpris so evene thumbs work for non-thumbed files

2017-11-28 Thread Carsten Haitzler (Rasterman)
raster pushed a commit to branch master.

http://git.enlightenment.org/apps/rage.git/commit/?id=8d0775986922ec256b304dc937fc74434e22d27b

commit 8d0775986922ec256b304dc937fc74434e22d27b
Author: Carsten Haitzler (Rasterman) 
Date:   Tue Nov 28 14:32:59 2017 +0900

implement metadata for mpris so evene thumbs work for non-thumbed files

this allows us to port to artfiles always too... this way
music-control displays the albumart. music-control is a bit broken in
that it doesnt keep aspect ratio etc. of these. need to fix that over
there but... it's coming together.
---
 src/bin/mpris.c | 144 +---
 src/bin/mpris.h |   1 +
 src/bin/thumb.c |   8 
 src/bin/video.c | 132 ++-
 src/bin/video.h |   5 +-
 5 files changed, 261 insertions(+), 29 deletions(-)

diff --git a/src/bin/mpris.c b/src/bin/mpris.c
index 2820c12..ab9c0ec 100644
--- a/src/bin/mpris.c
+++ b/src/bin/mpris.c
@@ -45,7 +45,6 @@ 
https://specifications.freedesktop.org/mpris-spec/latest/Player_Interface.html
  * 
  * Not implemented:
  * Tracklist objects
- * Metadata
  * SetPosition (requires Tracklist objects)
  * 
  * In rage generally and here:
@@ -677,14 +676,140 @@ SETTER(shuffle)
return eldbus_message_method_return_new(msg);
 }
 
-/*
 GETTER(metadata)
 {
-   // XXX: return metadata
-   eldbus_message_iter_arguments_append(iter, "a{sv}", NULL);
+   Inf *inf = evas_object_data_get(mainwin, "inf");
+   Eldbus_Message_Iter *array = NULL, *entry = NULL, *var, *var2;
+   uint64_t len = 0;
+   char *buf = NULL;
+   const char *s;
+
+   // XXX: TODO:
+   // mpris:trackid
+
+   eldbus_message_iter_arguments_append(iter, "a{sv}", );
+
+   s = video_file_get(inf->vid);
+   if (s)
+ {
+if (s[0] == '/')
+  {
+ buf = alloca(strlen(s) + sizeof("file://") + 1);
+ sprintf(buf, "file://%s", s);
+  }
+else if (strstr(s, "://"))
+  {
+ buf = alloca(strlen(s) + 1);
+ strcpy(buf, s);
+  }
+else
+  {
+ char cwd[PATH_MAX];
+
+ if (getcwd(cwd, sizeof(cwd) - 1))
+   {
+  cwd[sizeof(cwd) - 1] = 0;
+  buf = alloca(strlen(cwd) + 1 + strlen(s) + sizeof("file://") 
+ 1);
+  sprintf(buf, "file://%s/%s", cwd, s);
+   }
+  }
+ }
+   if (buf)
+ {
+eldbus_message_iter_arguments_append(array, "{sv}", );
+eldbus_message_iter_basic_append(entry, 's', "xesam:url");
+var = eldbus_message_iter_container_new(entry, 'v', "s");
+eldbus_message_iter_basic_append(var, 's', buf);
+eldbus_message_iter_container_close(entry, var);
+eldbus_message_iter_container_close(array, entry);
+ }
+
+   s = video_artfile_get(inf->vid);
+   if (s)
+ {
+buf = alloca(strlen(s) + sizeof("file://") + 1);
+sprintf(buf, "file://%s", s);
+eldbus_message_iter_arguments_append(array, "{sv}", );
+eldbus_message_iter_basic_append(entry, 's', "mpris:artUrl");
+var = eldbus_message_iter_container_new(entry, 'v', "s");
+eldbus_message_iter_basic_append(var, 's', buf);
+eldbus_message_iter_container_close(entry, var);
+eldbus_message_iter_container_close(array, entry);
+ }
+
+   s = video_title_get(inf->vid);
+   if (!s) s = video_meta_title_get(inf->vid);
+   if (s)
+ {
+eldbus_message_iter_arguments_append(array, "{sv}", );
+eldbus_message_iter_basic_append(entry, 's', "xesam:title");
+var = eldbus_message_iter_container_new(entry, 'v', "s");
+eldbus_message_iter_basic_append(var, 's', buf);
+eldbus_message_iter_container_close(entry, var);
+eldbus_message_iter_container_close(array, entry);
+ }
+
+   s = video_meta_album_get(inf->vid);
+   if (s)
+ {
+eldbus_message_iter_arguments_append(array, "{sv}", );
+eldbus_message_iter_basic_append(entry, 's', "xesam:album");
+var = eldbus_message_iter_container_new(entry, 'v', "s");
+eldbus_message_iter_basic_append(var, 's', buf);
+eldbus_message_iter_container_close(entry, var);
+eldbus_message_iter_container_close(array, entry);
+ }
+
+   s = video_meta_artist_get(inf->vid);
+   if (s)
+ {
+eldbus_message_iter_arguments_append(array, "{sv}", );
+eldbus_message_iter_basic_append(entry, 's', "xesam:artist");
+var = eldbus_message_iter_container_new(entry, 'v', "as");
+eldbus_message_iter_arguments_append(var, "as", );
+eldbus_message_iter_basic_append(var2, 's', s);
+eldbus_message_iter_container_close(var, var2);
+eldbus_message_iter_container_close(entry, var);
+eldbus_message_iter_container_close(array, entry);
+ }
+
+   s = video_meta_comment_get(inf->vid);
+   if (s)
+ {
+

[EGIT] [core/efl] master 02/02: efl_ui_spin: Support value change using mouse wheel.

2017-11-28 Thread Woochan Lee
jaehyun pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=e8238522be7a096aa1b2287ef343564a425b67cb

commit e8238522be7a096aa1b2287ef343564a425b67cb
Author: Woochan Lee 
Date:   Tue Nov 28 20:03:06 2017 +0900

efl_ui_spin: Support value change using mouse wheel.

Summary:
Enable value change using wheel.

(Up, Down key value change will be supported after D4933 dicussing.)

Test Plan: elementary_test efl_ui_spin test sample.

Reviewers: Jaehyun_Cho, jpeg, woohyun

Reviewed By: Jaehyun_Cho

Subscribers: cedric, jpeg

Differential Revision: https://phab.enlightenment.org/D5546
---
 src/bin/elementary/test_ui_spin.c |  6 ++
 src/lib/elementary/efl_ui_spin.c  | 21 +
 src/lib/elementary/efl_ui_spin.eo |  1 +
 3 files changed, 24 insertions(+), 4 deletions(-)

diff --git a/src/bin/elementary/test_ui_spin.c 
b/src/bin/elementary/test_ui_spin.c
index be41b75f5f..ba0a166adf 100644
--- a/src/bin/elementary/test_ui_spin.c
+++ b/src/bin/elementary/test_ui_spin.c
@@ -22,15 +22,13 @@ _spin_max_reached_cb(void *data EINA_UNUSED, const 
Efl_Event *ev)
 static void
 _inc_clicked(void *data, const Efl_Event *ev EINA_UNUSED)
 {
-   int val = (int)efl_ui_range_value_get(data);
-   efl_ui_range_value_set(data, ++val);
+   efl_ui_range_value_set(data, (efl_ui_range_value_get(data) + 
efl_ui_range_step_get(data)));
 }
 
 static void
 _dec_clicked(void *data, const Efl_Event *ev EINA_UNUSED)
 {
-   int val = (int)efl_ui_range_value_get(data);
-   efl_ui_range_value_set(data, --val);
+   efl_ui_range_value_set(data, (efl_ui_range_value_get(data) - 
efl_ui_range_step_get(data)));
 }
 
 void
diff --git a/src/lib/elementary/efl_ui_spin.c b/src/lib/elementary/efl_ui_spin.c
index 13dbadc872..dadb404041 100644
--- a/src/lib/elementary/efl_ui_spin.c
+++ b/src/lib/elementary/efl_ui_spin.c
@@ -163,6 +163,27 @@ _efl_ui_spin_elm_widget_theme_apply(Eo *obj, 
Efl_Ui_Spin_Data *sd EINA_UNUSED)
return EFL_UI_THEME_APPLY_SUCCESS;
 }
 
+EOLIAN static Eina_Bool
+_efl_ui_spin_elm_widget_widget_event(Eo *obj, Efl_Ui_Spin_Data *sd, const 
Efl_Event *eo_event, Evas_Object *src EINA_UNUSED)
+{
+   Eo *ev = eo_event->info;
+
+   if (efl_input_processed_get(ev)) return EINA_FALSE;
+
+   if (eo_event->desc == EFL_EVENT_POINTER_WHEEL)
+ {
+   if (efl_input_pointer_wheel_delta_get(ev) < 0)
+ efl_ui_range_value_set(obj, (efl_ui_range_value_get(obj) + sd->step));
+   else
+ efl_ui_range_value_set(obj, (efl_ui_range_value_get(obj) - sd->step));
+ }
+   else
+ return EINA_FALSE;
+
+   efl_input_processed_set(ev, EINA_TRUE);
+   return EINA_TRUE;
+}
+
 EOLIAN static Eo *
 _efl_ui_spin_efl_object_constructor(Eo *obj, Efl_Ui_Spin_Data *sd)
 {
diff --git a/src/lib/elementary/efl_ui_spin.eo 
b/src/lib/elementary/efl_ui_spin.eo
index df2e2bd1dc..fae80d1e40 100644
--- a/src/lib/elementary/efl_ui_spin.eo
+++ b/src/lib/elementary/efl_ui_spin.eo
@@ -13,6 +13,7 @@ class Efl.Ui.Spin (Efl.Ui.Layout, Efl.Ui.Range, Efl.Ui.Format,
   Efl.Object.finalize;
   Efl.Object.destructor;
   Elm.Widget.theme_apply;
+  Elm.Widget.widget_event;
   Efl.Ui.Range.range_min_max { get; set; }
   Efl.Ui.Range.range_step { get; set; }
   Efl.Ui.Range.range_value { get; set; }

-- 




[EGIT] [core/efl] master 01/02: test_part_bg: Clean up code.

2017-11-28 Thread Woochan Lee
jaehyun pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=434be7dbfa708247baec25ddc300201185c2110f

commit 434be7dbfa708247baec25ddc300201185c2110f
Author: Woochan Lee 
Date:   Tue Nov 28 20:02:53 2017 +0900

test_part_bg: Clean up code.

Summary:
Add spin class in ther test list.
Clean up code.

Reviewers: Jaehyun_Cho, jpeg, taxi2se

Reviewed By: Jaehyun_Cho

Subscribers: cedric, jpeg

Differential Revision: https://phab.enlightenment.org/D5545
---
 src/bin/elementary/test_part_bg.c | 48 ---
 1 file changed, 25 insertions(+), 23 deletions(-)

diff --git a/src/bin/elementary/test_part_bg.c 
b/src/bin/elementary/test_part_bg.c
index cdad4845f7..26ba4dc7eb 100644
--- a/src/bin/elementary/test_part_bg.c
+++ b/src/bin/elementary/test_part_bg.c
@@ -3,7 +3,9 @@
 #endif
 #include 
 
-const Efl_Class *content_class[17];
+#define MAX_NUM_OF_CONTENT 18
+
+const Efl_Class *content_class[MAX_NUM_OF_CONTENT];
 
 
 static void
@@ -65,12 +67,12 @@ _create_box_contents(Evas_Object *box)
   efl_pack_end(box, efl_added));
 
radio_group = radio = efl_add(EFL_UI_RADIO_CLASS, hbox,
-  efl_pack_end(hbox, efl_added),
-  efl_gfx_size_hint_weight_set(efl_added, 0, 0),
-  efl_ui_radio_state_value_set(efl_added, 0));
+ efl_pack_end(hbox, efl_added),
+ efl_gfx_size_hint_weight_set(efl_added, 0, 0),
+ efl_ui_radio_state_value_set(efl_added, 0));
 
content = efl_add(EFL_UI_BOX_CLASS, hbox,
-   efl_pack_end(hbox, efl_added));
+ efl_pack_end(hbox, efl_added));
evas_object_data_set(radio, "data", content);
 
content = efl_add(EFL_UI_TEXT_CLASS, content,
@@ -78,23 +80,23 @@ _create_box_contents(Evas_Object *box)
  efl_ui_text_interactive_editable_set(efl_added, 
EINA_FALSE),
  efl_pack_end(content, efl_added));
 
-   for (i = 0; i < (sizeof(content_class) / sizeof(content_class[0])) ; i++)
+   for (i = 0; i < MAX_NUM_OF_CONTENT; i++)
  {
 if (!content_class[i]) continue;
 
 hbox = efl_add(EFL_UI_BOX_CLASS, box,
efl_ui_direction_set(efl_added, EFL_UI_DIR_HORIZONTAL),
efl_pack_end(box, efl_added));
-   
+
 radio = efl_add(EFL_UI_RADIO_CLASS, hbox,
 efl_ui_radio_group_add(efl_added, radio_group),
 efl_pack_end(hbox, efl_added),
 efl_ui_radio_state_value_set(efl_added, i + 1),
-efl_gfx_size_hint_weight_set(efl_added, 0, 0)
-);
+efl_gfx_size_hint_weight_set(efl_added, 0, 0));
 
 content = efl_add(content_class[i], hbox,
   efl_pack_end(hbox, efl_added));
+
 if (efl_isa(content, efl_text_interface_get()))
   efl_text_set(content, "text");
 
@@ -138,30 +140,30 @@ test_part_background(void *data EINA_UNUSED, Evas_Object 
*obj EINA_UNUSED, void
content_class[14] = EFL_UI_IMAGE_CLASS;
content_class[15] = EFL_UI_IMAGE_ZOOMABLE_CLASS;
content_class[16] = EFL_UI_NSTATE_CLASS;
-   //content_class[17] = EFL_UI_SPINNER_CLASS;
+   content_class[17] = EFL_UI_SPIN_CLASS;
 
win = efl_add(EFL_UI_WIN_CLASS, NULL,
  efl_text_set(efl_added, "Widget Part Background"),
  efl_ui_win_autodel_set(efl_added, EINA_TRUE));
 
vbox = efl_add(EFL_UI_BOX_CLASS, win,
- efl_gfx_size_hint_weight_set(efl_added, 1, 1),
- efl_content_set(win, efl_added));
+  efl_gfx_size_hint_weight_set(efl_added, 1, 1),
+  efl_content_set(win, efl_added));
 
hbox = efl_add(EFL_UI_BOX_CLASS, vbox,
- efl_ui_direction_set(efl_added, EFL_UI_DIR_HORIZONTAL),
-  efl_gfx_size_hint_weight_set(efl_added, 1.0, 
0.0),
- efl_pack_end(vbox, efl_added));
+  efl_ui_direction_set(efl_added, EFL_UI_DIR_HORIZONTAL),
+  efl_gfx_size_hint_weight_set(efl_added, 1.0, 0.0),
+  efl_pack_end(vbox, efl_added));
 
reset_btn = efl_add(EFL_UI_BUTTON_CLASS, hbox,
-  efl_pack_end(hbox, efl_added),
-  efl_text_set(efl_added, "reset"));
+   efl_pack_end(hbox, efl_added),
+   efl_text_set(efl_added, "reset"));
color_btn = efl_add(EFL_UI_BUTTON_CLASS, hbox,
-  efl_pack_end(hbox, efl_added),
-  efl_text_set(efl_added, "color"));
+   efl_pack_end(hbox, efl_added),
+   efl_text_set(efl_added, "color"));
scale_btn = efl_add(EFL_UI_BUTTON_CLASS, 

[EGIT] [tools/examples] master 01/01: core: Add Efl_Io_File example into efl-core reference

2017-11-28 Thread Andy Williams
ajwillia-ms pushed a commit to branch master.

http://git.enlightenment.org/tools/examples.git/commit/?id=bc275959dd4124ba96e87e444a38614d1453be43

commit bc275959dd4124ba96e87e444a38614d1453be43
Author: Andy Williams 
Date:   Tue Nov 28 09:21:09 2017 +

core: Add Efl_Io_File example into efl-core reference

Refactor the copier code into a separate method for clarity.
---
 reference/c/core/src/core_io.c | 98 --
 1 file changed, 86 insertions(+), 12 deletions(-)

diff --git a/reference/c/core/src/core_io.c b/reference/c/core/src/core_io.c
index e70ee7f..3808fb8 100644
--- a/reference/c/core/src/core_io.c
+++ b/reference/c/core/src/core_io.c
@@ -2,6 +2,7 @@
 #define EFL_BETA_API_SUPPORT 1
 
 #include 
+#include 
 
 #include 
 #include 
@@ -9,13 +10,77 @@
 /*
  * Efl.IO examples.
  *
- * This IO example simply copies data from a source (stdin) to a
- * destination (stdout) using an Efl.Io.Copier.
+ * This IO example shows the use of various IO APIs. First we use Efl.Io.File
+ * to read and write a standard file. Then we set up a copier to copy data from
+ * a source (stdin) to a destination (stdout) using an Efl.Io.Copier.
  */
 
 Eo *_copier = NULL;
 
 static void
+_io_write(const char *filename)
+{
+   Eina_Slice content = EINA_SLICE_STR("1. Some dummy content\n2. \n3. With 
more...\n");
+   Efl_Io_File *file;
+
+   file = efl_add(EFL_IO_FILE_CLASS, NULL,
+  efl_file_set(efl_added, filename, NULL), // mandatory
+  efl_io_file_flags_set(efl_added, O_WRONLY | O_CREAT), // 
write and create - default is read
+  efl_io_file_mode_set(efl_added, 0644), // neccessary if we 
use O_CREAT
+  efl_io_closer_close_on_destructor_set(efl_added, 
EINA_TRUE)); // recommended
+
+   if (!file)
+ return;
+
+   printf("Loaded file %s for read on fd %d\n", filename, 
efl_io_reader_fd_get(file));
+
+   if (efl_io_writer_write(file, , NULL) != EINA_ERROR_NO_ERROR)
+ fprintf(stderr, "Failed to write test file\n");
+   else
+ printf("Wrote content to file\n");
+
+   efl_del(file);
+}
+
+static void
+_io_read(const char *filename)
+{
+   EINA_RW_SLICE_DECLARE(content, 1024);
+   Efl_Io_File *file;
+
+   file = efl_add(EFL_IO_FILE_CLASS, NULL,
+  efl_file_set(efl_added, filename, NULL), // mandatory
+  efl_io_closer_close_on_destructor_set(efl_added, 
EINA_TRUE)); // recommended
+
+   if (!file)
+ return;
+
+   printf("Loaded file %s for write on fd %d\n", filename, 
efl_io_reader_fd_get(file));
+
+   if (efl_io_reader_read(file, ) != EINA_ERROR_NO_ERROR)
+ fprintf(stderr, "Failed to read test file\n");
+   else
+ {
+char *string = eina_rw_slice_strdup(content);
+printf("Read content from file: %s\n", string);
+free(string);
+ }
+
+efl_del(file);
+}
+
+static void
+_io_test()
+{
+const char *filename = "/tmp/efl_core_io_test.tmp";
+
+_io_write(filename);
+_io_read(filename);
+
+eina_file_unlink(filename);
+}
+
+static void
 _copier_done(void *data EINA_UNUSED, const Efl_Event *event)
 {
fprintf(stderr, "INFO: %s done\n", efl_name_get(event->object));
@@ -38,17 +103,10 @@ EFL_CALLBACKS_ARRAY_DEFINE(copier_cbs,
{ EFL_IO_COPIER_EVENT_DONE, _copier_done },
{ EFL_IO_COPIER_EVENT_ERROR, _copier_error });
 
-EAPI_MAIN void
-efl_main(void *data EINA_UNUSED, const Efl_Event *ev)
+static void
+_copier_test(Efl_Loop *loop)
 {
-   Eo *input, *output, *loop;
-
-   /*
-* Some objects such as the Efl.Io.Copier require a main loop,
-* thus their parent must be a loop provider.
-* We use the application's main loop itself.
-*/
-   loop = ev->object;
+   Eo *input, *output;
 
// set up our objects to copy, use stdin and stdout
input = efl_add(EFL_IO_STDIN_CLASS, loop);
@@ -69,5 +127,21 @@ efl_main(void *data EINA_UNUSED, const Efl_Event *ev)
printf("Type something here and press enter, it will be copied to 
stdout...\n");
printf("  (press Ctrl-D to exit)\n");
 }
+
+EAPI_MAIN void
+efl_main(void *data EINA_UNUSED, const Efl_Event *ev)
+{
+   Efl_Loop *loop;
+
+   _io_test();
+
+   /*
+* Some objects such as the Efl.Io.Copier require a main loop,
+* thus their parent must be a loop provider.
+* We use the application's main loop itself.
+*/
+   loop = ev->object;
+   _copier_test(loop);
+}
 EFL_MAIN()
 

-- 




[EGIT] [core/efl] master 05/29: efl_ui_popup_alert: add Efl.Ui.Popup.Alert class

2017-11-28 Thread Taehyub Kim
jaehyun pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=d3a14d08b09a2200b9a85c7ad4d93914a14f6de2

commit d3a14d08b09a2200b9a85c7ad4d93914a14f6de2
Author: Taehyub Kim 
Date:   Wed Aug 23 15:50:18 2017 +0900

efl_ui_popup_alert: add Efl.Ui.Popup.Alert class

Summary:
Add initial code for Efl.Ui.Popup.Alert class.
It supports setting title and buttons.

Test Plan: 1. run elementary_test -to efluipopupalert

Reviewers: Jaehyun_Cho, jpeg, cedric, thiepha, Blackmole, woohyun

Differential Revision: https://phab.enlightenment.org/D5108
---
 data/elementary/objects/test.edc|  32 
 data/elementary/themes/edc/elm/popup.edc| 163 ++
 src/Makefile_Elementary.am  |   3 +
 src/bin/elementary/test.c   |   2 +
 src/bin/elementary/test_popup.c |  44 +
 src/lib/elementary/Elementary.h |   1 +
 src/lib/elementary/efl_ui_popup_alert.c | 218 
 src/lib/elementary/efl_ui_popup_alert.eo|  40 +
 src/lib/elementary/efl_ui_popup_alert_private.h |  22 +++
 9 files changed, 525 insertions(+)

diff --git a/data/elementary/objects/test.edc b/data/elementary/objects/test.edc
index 9e95ffd8be..834bea4e27 100644
--- a/data/elementary/objects/test.edc
+++ b/data/elementary/objects/test.edc
@@ -901,4 +901,36 @@ collections {
 
   }
}
+   group { "efl_ui_popup_scroll_content";
+  parts {
+ rect { "base";
+desc { "default";
+   min: 200 200;
+   color: 255 0 0 255;
+}
+ }
+ rect { "top";
+desc { "default";
+   fixed: 0 1;
+   min: 100 20;
+   color: 255 255 0 255;
+   rel1.to: "base";
+   rel2.to: "base";
+   rel2.relative: 1.0 0.0;
+   align: 0.5 0;
+}
+ }
+ rect { "bottom";
+desc { "default";
+  fixed: 0 1;
+  min: 100 20;
+  color: 255 255 0 255;
+  rel1.to: "base";
+  rel2.to: "base";
+  rel1.relative: 0.0 1.0;
+  align: 0.5 1.0;
+   }
+ }
+  }
+   }
 }
diff --git a/data/elementary/themes/edc/elm/popup.edc 
b/data/elementary/themes/edc/elm/popup.edc
index 7fb127b812..cb534a837a 100644
--- a/data/elementary/themes/edc/elm/popup.edc
+++ b/data/elementary/themes/edc/elm/popup.edc
@@ -141,6 +141,14 @@ group { name: "elm/label/base/popup/default";
  tag: "whitecolor" "+ color=#fff";
  tag: "tab" "\t";
   }
+  style { name: "popup_title_style_ellipsis";
+ base: "font="FNBD" font_size=10 text_class=label align=center 
color=#fff color_class=popup_title_text style=shadow,bottom 
shadow_color=#0080 ellipsis=1.0 wrap=mixed";
+ tag: "br" "\n";
+ tag: "hilight" "+ font="FNBD" text_class=label_light";
+ tag: "b" "+ font="FNBD" text_class=label_light";
+ tag: "whitecolor" "+ color=#fff";
+ tag: "tab" "\t";
+  }
}
parts {
   part { name: "elm.text"; type: TEXTBLOCK; mouse_events: 0;
@@ -533,6 +541,91 @@ group { "elm/popup/base/view";
}
 }
 
+group { "elm/popup/base/alert";
+   images.image: "rounded_square.png" COMP;
+   parts {
+  image { "bg";
+ desc { "default";
+min: 100 100;
+image.border: 15 15 15 15;
+image.normal: "rounded_square.png";
+  }
+  }
+  spacer { "base";
+ desc { "default";
+rel.to: "bg";
+rel1.offset: 10 10;
+rel2.offset: -11 -11;
+ }
+  }
+  rect { "title_bg";
+ desc { "default";
+fixed: 0 1;
+min: 0 0;
+rel.to: "base";
+rel2.relative: 1.0 0.0;
+align: 0.5 0.0;
+color: 0 0 0 0;
+ }
+ desc { "title_visible";
+inherit: "default";
+min: 0 20;
+ }
+  }
+  textblock { "elm.text.title";
+ scale;
+ desc { "default";
+fixed: 1 1;
+text {
+  style: "popup_title_style_ellipsis";
+}
+rel.to: "title_bg";
+hid;
+ }
+ desc { "title_visible";
+inherit: "default";
+vis;
+ }
+  }
+  swallow { "buttons";
+ desc { "default";
+fixed: 0 1;
+rel.to: "base";
+rel1.relative: 0.0 1.0;
+align: 0.5 1.0;
+min: 0 0;
+ }
+ desc { "button_visible";
+inherit: "default";
+min: 0 30;
+ }
+  }
+  swallow { "elm.swallow.content";
+ desc { "default";
+rel1.to_x: "base";
+rel1.to_y: "title_bg";
+rel2.to_x: "base";
+

[EGIT] [core/efl] master 18/29: efl_ui_popup: Code refactoring to replace legacy APIs

2017-11-28 Thread Jaehyun Cho
jaehyun pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=b85cebdb96aad217b50f90b6c08660ec0f31f4ac

commit b85cebdb96aad217b50f90b6c08660ec0f31f4ac
Author: Jaehyun Cho 
Date:   Tue Oct 24 18:34:36 2017 +0900

efl_ui_popup: Code refactoring to replace legacy APIs
---
 src/lib/elementary/efl_ui_popup.c  | 139 ++--
 src/lib/elementary/efl_ui_popup.eo |   1 -
 src/lib/elementary/efl_ui_popup_alert.c|  73 +++---
 src/lib/elementary/efl_ui_popup_alert.eo   |   1 -
 src/lib/elementary/efl_ui_popup_alert_scroll.c |  87 ---
 src/lib/elementary/efl_ui_popup_alert_scroll.eo|   1 -
 .../elementary/efl_ui_popup_alert_scroll_private.h |  13 +-
 src/lib/elementary/efl_ui_popup_alert_text.c   |  31 +--
 src/lib/elementary/efl_ui_popup_alert_text.eo  |   1 -
 .../elementary/efl_ui_popup_alert_text_private.h   |   6 +-
 src/lib/elementary/efl_ui_popup_anchor.c   | 251 ++---
 src/lib/elementary/efl_ui_popup_anchor.eo  |   1 -
 src/lib/elementary/efl_ui_popup_anchor_private.h   |   2 +-
 src/lib/elementary/efl_ui_popup_private.h  |  10 +-
 14 files changed, 285 insertions(+), 332 deletions(-)

diff --git a/src/lib/elementary/efl_ui_popup.c 
b/src/lib/elementary/efl_ui_popup.c
index dc23b28b6a..6f225da034 100644
--- a/src/lib/elementary/efl_ui_popup.c
+++ b/src/lib/elementary/efl_ui_popup.c
@@ -11,16 +11,15 @@
 
 #define MY_CLASS EFL_UI_POPUP_CLASS
 #define MY_CLASS_NAME "Efl.Ui.Popup"
-#define MY_CLASS_NAME_LEGACY "elm_popup"
 
 static void
 _bg_clicked_cb(void *data,
-  Evas_Object *o EINA_UNUSED,
-  const char *emission EINA_UNUSED,
-  const char *source EINA_UNUSED)
+   Eo *o EINA_UNUSED,
+   const char *emission EINA_UNUSED,
+   const char *source EINA_UNUSED)
 {
-   Evas_Object *obj = data;
-   efl_event_callback_legacy_call(obj, EFL_UI_POPUP_EVENT_BG_CLICKED, NULL);
+   Eo *obj = data;
+   efl_event_callback_call(obj, EFL_UI_POPUP_EVENT_BG_CLICKED, NULL);
 }
 
 EOLIAN static void
@@ -31,41 +30,44 @@ _efl_ui_popup_efl_gfx_position_set(Eo *obj, 
Efl_Ui_Popup_Data *pd EINA_UNUSED, E
 }
 
 static void
-_calc_align(Evas_Object *obj)
+_calc_align(Eo *obj)
 {
Efl_Ui_Popup_Data *pd = efl_data_scope_get(obj, MY_CLASS);
 
-   Evas_Coord x, y, w, h;
-   evas_object_geometry_get(pd->win_parent, , , , );
+   Eina_Rect p_geom = efl_gfx_geometry_get(pd->win_parent);
 
-   x = 0;
-   y = 0;
+   efl_gfx_position_set(pd->event_bg, EINA_POSITION2D(0, 0));
+   efl_gfx_size_set(pd->event_bg, EINA_SIZE2D(p_geom.w, p_geom.h));
 
-   evas_object_move(pd->event_bg, x, y);
-   evas_object_resize(pd->event_bg, w, h);
+   Eina_Rect o_geom = efl_gfx_geometry_get(obj);
 
Evas_Coord pw, ph;
-   evas_object_geometry_get(obj, NULL, NULL, , );
+   pw = p_geom.w;
+   ph = p_geom.h;
+
+   Evas_Coord ow, oh;
+   ow = o_geom.w;
+   oh = o_geom.h;
 
switch (pd->align)
  {
-case EFL_UI_POPUP_ALIGN_CENTER:
-   efl_gfx_position_set(efl_super(obj, MY_CLASS), EINA_POSITION2D(x + 
((w - pw ) / 2), y + ((h - ph) / 2)));
-break;
-case EFL_UI_POPUP_ALIGN_LEFT:
-   efl_gfx_position_set(efl_super(obj, MY_CLASS), EINA_POSITION2D(x, y 
+ ((h - ph) / 2)));
-break;
-case EFL_UI_POPUP_ALIGN_RIGHT:
-   efl_gfx_position_set(efl_super(obj, MY_CLASS), EINA_POSITION2D(x + 
(w - pw), ((h - ph) / 2)));
-break;
-case EFL_UI_POPUP_ALIGN_TOP:
-   efl_gfx_position_set(efl_super(obj, MY_CLASS), EINA_POSITION2D(x + 
((w - pw) / 2), y));
-break;
-case EFL_UI_POPUP_ALIGN_BOTTOM:
-   efl_gfx_position_set(efl_super(obj, MY_CLASS), EINA_POSITION2D(x + 
((w - pw) / 2), y + (h - ph)));
-break;
-default:
-break;
+  case EFL_UI_POPUP_ALIGN_CENTER:
+ efl_gfx_position_set(efl_super(obj, MY_CLASS), EINA_POSITION2D((pw - 
ow ) / 2, (ph - oh) / 2));
+ break;
+  case EFL_UI_POPUP_ALIGN_LEFT:
+ efl_gfx_position_set(efl_super(obj, MY_CLASS), EINA_POSITION2D(0, (ph 
- oh) / 2));
+ break;
+  case EFL_UI_POPUP_ALIGN_RIGHT:
+ efl_gfx_position_set(efl_super(obj, MY_CLASS), EINA_POSITION2D(pw - 
ow, (ph - oh) / 2));
+ break;
+  case EFL_UI_POPUP_ALIGN_TOP:
+ efl_gfx_position_set(efl_super(obj, MY_CLASS), EINA_POSITION2D((pw - 
ow) / 2, 0));
+ break;
+  case EFL_UI_POPUP_ALIGN_BOTTOM:
+ efl_gfx_position_set(efl_super(obj, MY_CLASS), EINA_POSITION2D((pw - 
ow) / 2, ph - oh));
+ break;
+  default:
+ break;
  }
 }
 
@@ -76,9 +78,8 @@ _parent_geom_cb(void *data, const Efl_Event *ev EINA_UNUSED)
 }
 
 EOLIAN static void
-_efl_ui_popup_elm_widget_widget_parent_set(Eo *obj, Efl_Ui_Popup_Data *pd 
EINA_UNUSED, Evas_Object *parent EINA_UNUSED)

[EGIT] [core/efl] master 16/29: efl_ui_popup: replace title_set to efl_text_set with efl_part

2017-11-28 Thread JinYong Park
jaehyun pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=2b2bc50e8bd35a358c113a67ae31ced85b0c8e7c

commit 2b2bc50e8bd35a358c113a67ae31ced85b0c8e7c
Author: JinYong Park 
Date:   Tue Oct 24 20:13:04 2017 +0900

efl_ui_popup: replace title_set to efl_text_set with efl_part

Summary: Replace Efl.Ui.Popup.Alert's title set method to using 
efl_text_set with efl_part

Test Plan: elementary_test -to efluipopupalert

Reviewers: jpeg, Jaehyun_Cho, woohyun, herb

Reviewed By: Jaehyun_Cho

Subscribers: cedric

Differential Revision: https://phab.enlightenment.org/D5359
---
 src/Makefile_Elementary.am|  1 +
 src/bin/elementary/test_popup.c   |  6 +--
 src/lib/elementary/efl_ui_popup_alert.c   | 77 +--
 src/lib/elementary/efl_ui_popup_alert.eo  | 12 +
 src/lib/elementary/efl_ui_popup_alert_part.eo | 10 
 5 files changed, 76 insertions(+), 30 deletions(-)

diff --git a/src/Makefile_Elementary.am b/src/Makefile_Elementary.am
index f62e9f2d9d..b6602554c2 100644
--- a/src/Makefile_Elementary.am
+++ b/src/Makefile_Elementary.am
@@ -35,6 +35,7 @@ elm_public_eolian_files = \
lib/elementary/efl_ui_text.eo \
lib/elementary/efl_ui_popup.eo \
lib/elementary/efl_ui_popup_alert.eo \
+   lib/elementary/efl_ui_popup_alert_part.eo \
lib/elementary/efl_ui_popup_alert_scroll.eo \
lib/elementary/efl_ui_popup_alert_scroll_part.eo \
lib/elementary/efl_ui_popup_alert_text.eo \
diff --git a/src/bin/elementary/test_popup.c b/src/bin/elementary/test_popup.c
index 1f85961f8a..4975a0f6f1 100644
--- a/src/bin/elementary/test_popup.c
+++ b/src/bin/elementary/test_popup.c
@@ -1136,7 +1136,7 @@ test_efl_ui_popup_alert(void *data EINA_UNUSED, 
Evas_Object *obj EINA_UNUSED, vo
 
Evas_Object *efl_ui_popup= efl_add(EFL_UI_POPUP_ALERT_CLASS, win);
 
-   efl_ui_popup_alert_title_set(efl_ui_popup, "title");
+   efl_text_set(efl_part(efl_ui_popup, "title"), "title");
 
evas_object_resize(efl_ui_popup, 160, 160);
evas_object_show(efl_ui_popup);
@@ -1168,7 +1168,7 @@ test_efl_ui_popup_alert_scroll(void *data EINA_UNUSED, 
Evas_Object *obj EINA_UNU
 
Evas_Object *efl_ui_popup= efl_add(EFL_UI_POPUP_ALERT_SCROLL_CLASS, win);
 
-   efl_ui_popup_alert_title_set(efl_ui_popup, "title");
+   efl_text_set(efl_part(efl_ui_popup, "title"), "title");
 
evas_object_resize(efl_ui_popup, 160, 160);
evas_object_show(efl_ui_popup);
@@ -1203,7 +1203,7 @@ test_efl_ui_popup_alert_text(void *data EINA_UNUSED, 
Evas_Object *obj EINA_UNUSE
 
Evas_Object *efl_ui_popup= efl_add(EFL_UI_POPUP_ALERT_TEXT_CLASS, win);
 
-   efl_ui_popup_alert_title_set(efl_ui_popup, "title");
+   efl_text_set(efl_part(efl_ui_popup, "title"), "title");
 
evas_object_resize(efl_ui_popup, 160, 160);
evas_object_show(efl_ui_popup);
diff --git a/src/lib/elementary/efl_ui_popup_alert.c 
b/src/lib/elementary/efl_ui_popup_alert.c
index 6c7a9a57a1..2b38d34ba3 100644
--- a/src/lib/elementary/efl_ui_popup_alert.c
+++ b/src/lib/elementary/efl_ui_popup_alert.c
@@ -6,6 +6,8 @@
 
 #include "elm_priv.h"
 #include "efl_ui_popup_alert_private.h"
+#include "efl_ui_popup_alert_part.eo.h"
+#include "elm_part_helper.h"
 
 #define MY_CLASS EFL_UI_POPUP_ALERT_CLASS
 #define MY_CLASS_NAME "Efl.Ui.Popup.Alert"
@@ -27,30 +29,61 @@ _efl_ui_popup_alert_elm_layout_sizing_eval(Eo *obj, 
Efl_Ui_Popup_Alert_Data *pd
evas_object_geometry_get(obj, NULL, NULL, , );
 }
 
-EOLIAN static void
-_efl_ui_popup_alert_title_set(Eo *obj, Efl_Ui_Popup_Alert_Data *pd, const char 
*text)
+static Eina_Bool
+_efl_ui_popup_alert_text_set(Eo *obj, Efl_Ui_Popup_Alert_Data *pd, const char 
*part, const char *label)
 {
-   if (pd->title_text)
+   if (part && !strcmp(part, "title"))
  {
-eina_stringshare_del(pd->title_text);
-pd->title_text = NULL;
+if (pd->title_text)
+  {
+ eina_stringshare_del(pd->title_text);
+ pd->title_text = NULL;
+  }
+
+pd->title_text = eina_stringshare_add(label);
+elm_object_part_text_set(obj, "elm.text.title", label);
+elm_layout_signal_emit(obj, "elm,title,show", "elm");
+
+ELM_WIDGET_DATA_GET_OR_RETURN(obj, wd, EINA_FALSE);
+edje_object_message_signal_process(wd->resize_obj);
+elm_layout_sizing_eval(obj);
  }
+   else
+ efl_text_set(efl_part(efl_super(obj, MY_CLASS), part), label);
 
-   pd->title_text = eina_stringshare_add(text);
-   elm_object_part_text_set(obj, "elm.text.title", text);
-   elm_layout_signal_emit(obj, "elm,title,show", "elm");
+   return EINA_TRUE;
+}
 
-   ELM_WIDGET_DATA_GET_OR_RETURN(obj, wd);
-   edje_object_message_signal_process(wd->resize_obj);
-   elm_layout_sizing_eval(obj);
+const char *
+_efl_ui_popup_alert_text_get(Eo *obj EINA_UNUSED, Efl_Ui_Popup_Alert_Data *pd, 
const char *part)
+{
+   if (part && 

[EGIT] [core/efl] master 15/29: test_popup: Fix Efl Ui Popup Anchor test title

2017-11-28 Thread Jaehyun Cho
jaehyun pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=0f9b5d360c8e23e7362039f35c99232b2645f4e0

commit 0f9b5d360c8e23e7362039f35c99232b2645f4e0
Author: Jaehyun Cho 
Date:   Tue Oct 24 12:20:53 2017 +0900

test_popup: Fix Efl Ui Popup Anchor test title
---
 src/bin/elementary/test_popup.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/bin/elementary/test_popup.c b/src/bin/elementary/test_popup.c
index 960cbab8a8..1f85961f8a 100644
--- a/src/bin/elementary/test_popup.c
+++ b/src/bin/elementary/test_popup.c
@@ -1243,7 +1243,7 @@ test_efl_ui_popup_anchor(void *data EINA_UNUSED, 
Evas_Object *obj EINA_UNUSED, v
Evas_Object *win, *layout, *tbl, *btn;
char buf[PATH_MAX];
 
-   win = elm_win_util_standard_add("Efl UI AnchorPopup", "Efl UI AnchorPopup");
+   win = elm_win_util_standard_add("Efl UI Popup Anchor", "Efl UI Popup 
Anchor");
elm_win_autodel_set(win, EINA_TRUE);
 
evas_object_resize(win, 500, 500);

-- 




[EGIT] [core/efl] master 17/29: efl_ui_popup: remove parent_window_get method

2017-11-28 Thread JinYong Park
jaehyun pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=0928335fbc02f04a1fe6730b2ffde419fc4be9e4

commit 0928335fbc02f04a1fe6730b2ffde419fc4be9e4
Author: JinYong Park 
Date:   Tue Oct 24 20:13:21 2017 +0900

efl_ui_popup: remove parent_window_get method

Summary: remove Efl.Ui.Popup's internal method "parent_window_get"

Test Plan: elementary_test -to efluipopup

Reviewers: jpeg, Jaehyun_Cho, woohyun, herb

Reviewed By: Jaehyun_Cho

Subscribers: cedric

Differential Revision: https://phab.enlightenment.org/D5363
---
 src/lib/elementary/efl_ui_popup.c|  6 --
 src/lib/elementary/efl_ui_popup.eo   |  8 
 src/lib/elementary/efl_ui_popup_anchor.c | 34 
 3 files changed, 30 insertions(+), 18 deletions(-)

diff --git a/src/lib/elementary/efl_ui_popup.c 
b/src/lib/elementary/efl_ui_popup.c
index 344105436a..dc23b28b6a 100644
--- a/src/lib/elementary/efl_ui_popup.c
+++ b/src/lib/elementary/efl_ui_popup.c
@@ -112,12 +112,6 @@ _efl_ui_popup_efl_container_content_unset(Eo *obj, 
Efl_Ui_Popup_Data *pd EINA_UN
return efl_content_unset(efl_part(obj, "elm.swallow.content"));
 }
 
-EOLIAN static Efl_Canvas_Object *
-_efl_ui_popup_parent_window_get(Eo *obj EINA_UNUSED, Efl_Ui_Popup_Data *pd)
-{
-   return pd->win_parent;
-}
-
 EOLIAN static void
 _efl_ui_popup_align_set(Eo *obj EINA_UNUSED, Efl_Ui_Popup_Data *pd, 
Efl_Ui_Popup_Align type)
 {
diff --git a/src/lib/elementary/efl_ui_popup.eo 
b/src/lib/elementary/efl_ui_popup.eo
index 06aefd019c..7af22ae33f 100644
--- a/src/lib/elementary/efl_ui_popup.eo
+++ b/src/lib/elementary/efl_ui_popup.eo
@@ -10,14 +10,6 @@ enum Efl.Ui.Popup.Align {
 class Efl.Ui.Popup(Efl.Ui.Layout)
 {
methods {
-   @property parent_window @protected {
- get {
-[[Get the parent window of Popup.]]
- }
- values {
-window: Efl.Canvas.Object;
- }
-  }
   bg_set {
  params {
 @in file: string; [[The image file path.]]
diff --git a/src/lib/elementary/efl_ui_popup_anchor.c 
b/src/lib/elementary/efl_ui_popup_anchor.c
index 8ec41bc991..20ff3d80fa 100644
--- a/src/lib/elementary/efl_ui_popup_anchor.c
+++ b/src/lib/elementary/efl_ui_popup_anchor.c
@@ -24,7 +24,12 @@ _anchor_calc(Evas_Object *obj)
Evas_Coord_Size parent_size = {0, 0};
Eina_Position2D pos = {0, 0};
 
-   Evas_Object *parent = efl_ui_popup_parent_window_get(obj);
+   Evas_Object *parent = efl_provider_find(obj, EFL_UI_WIN_CLASS);
+   if (!parent)
+ {
+ERR("Cannot find window parent");
+return;
+ }
 
evas_object_geometry_get(sd->anchor, _geom.x, _geom.y, 
_geom.w, _geom.h);
evas_object_geometry_get(obj, NULL, NULL, _size.w, _size.h);
@@ -209,7 +214,14 @@ _anchor_del_cb(void *data, const Efl_Event *ev EINA_UNUSED)
 {
EFL_UI_POPUP_ANCHOR_DATA_GET(data, sd);
 
-   efl_event_callback_del(efl_ui_popup_parent_window_get(data), 
EFL_GFX_EVENT_RESIZE, _anchor_geom_cb, data);
+   Evas_Object *parent = efl_provider_find(data, EFL_UI_WIN_CLASS);
+   if (!parent)
+ {
+ERR("Cannot find window parent");
+return;
+ }
+
+   efl_event_callback_del(parent, EFL_GFX_EVENT_RESIZE, _anchor_geom_cb, data);
 
sd->anchor = NULL;
efl_ui_popup_align_set(efl_super(data, MY_CLASS), sd->align);
@@ -222,7 +234,14 @@ _anchor_detach(Evas_Object *obj)
 
if (sd->anchor == NULL) return;
 
-   efl_event_callback_del(efl_ui_popup_parent_window_get(obj), 
EFL_GFX_EVENT_RESIZE, _anchor_geom_cb, obj);
+   Evas_Object *parent = efl_provider_find(obj, EFL_UI_WIN_CLASS);
+   if (!parent)
+ {
+ERR("Cannot find window parent");
+return;
+ }
+
+   efl_event_callback_del(parent, EFL_GFX_EVENT_RESIZE, _anchor_geom_cb, obj);
efl_event_callback_del(sd->anchor, EFL_GFX_EVENT_RESIZE, _anchor_geom_cb, 
obj);
efl_event_callback_del(sd->anchor, EFL_GFX_EVENT_MOVE, _anchor_geom_cb, 
obj);
efl_event_callback_del(sd->anchor, EFL_EVENT_DEL, _anchor_del_cb, obj);
@@ -242,7 +261,14 @@ _efl_ui_popup_anchor_anchor_set(Eo *obj, 
Efl_Ui_Popup_Anchor_Data *pd, Evas_Obje
 
 _anchor_calc(obj);
 
-efl_event_callback_add(efl_ui_popup_parent_window_get(obj), 
EFL_GFX_EVENT_RESIZE, _anchor_geom_cb, obj);
+Evas_Object *parent = efl_provider_find(obj, EFL_UI_WIN_CLASS);
+if (!parent)
+  {
+  ERR("Cannot find window parent");
+  return;
+  }
+
+efl_event_callback_add(parent, EFL_GFX_EVENT_RESIZE, _anchor_geom_cb, 
obj);
 efl_event_callback_add(anchor, EFL_GFX_EVENT_RESIZE, _anchor_geom_cb, 
obj);
 efl_event_callback_add(anchor, EFL_GFX_EVENT_MOVE, _anchor_geom_cb, 
obj);
 efl_event_callback_add(anchor, EFL_EVENT_DEL, _anchor_del_cb, obj);

-- 




[EGIT] [core/efl] master 21/29: efl_ui_popup: add timeout signal

2017-11-28 Thread Taehyub Kim
jaehyun pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=8301e66d878cf73ef08ce271b24eccd220f3a8f6

commit 8301e66d878cf73ef08ce271b24eccd220f3a8f6
Author: Taehyub Kim 
Date:   Thu Oct 26 16:32:58 2017 +0900

efl_ui_popup: add timeout signal

Summary: add the timeout signal for user notification

Reviewers: Jaehyun_Cho, jpeg, cedric, Blackmole, thiepha, woohyun

Reviewed By: Jaehyun_Cho

Differential Revision: https://phab.enlightenment.org/D5372
---
 src/lib/elementary/efl_ui_popup.c  | 1 +
 src/lib/elementary/efl_ui_popup.eo | 1 +
 2 files changed, 2 insertions(+)

diff --git a/src/lib/elementary/efl_ui_popup.c 
b/src/lib/elementary/efl_ui_popup.c
index 7d59be8a7c..c8f4b56092 100644
--- a/src/lib/elementary/efl_ui_popup.c
+++ b/src/lib/elementary/efl_ui_popup.c
@@ -131,6 +131,7 @@ static Eina_Bool
 _timer_cb(void *data)
 {
Eo *popup = data;
+   efl_event_callback_call(popup, EFL_UI_POPUP_EVENT_TIMEOUT, NULL);
efl_del(popup);
 
return ECORE_CALLBACK_CANCEL;
diff --git a/src/lib/elementary/efl_ui_popup.eo 
b/src/lib/elementary/efl_ui_popup.eo
index 8f2a23778d..39be8faec2 100644
--- a/src/lib/elementary/efl_ui_popup.eo
+++ b/src/lib/elementary/efl_ui_popup.eo
@@ -67,5 +67,6 @@ class Efl.Ui.Popup(Efl.Ui.Layout)
}
events {
   bg,clicked; [[This is called whenever the user click background of 
popup.]]
+  timeout; [[This is called when popup times out.]]
}
 }

-- 




[EGIT] [core/efl] master 19/29: efl_ui_popup: Replace group_add/del with constructor/destructor

2017-11-28 Thread Jaehyun Cho
jaehyun pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=a44e8cec395cb482e0f1668f16291198b0e0cd59

commit a44e8cec395cb482e0f1668f16291198b0e0cd59
Author: Jaehyun Cho 
Date:   Tue Oct 24 21:29:15 2017 +0900

efl_ui_popup: Replace group_add/del with constructor/destructor
---
 src/lib/elementary/efl_ui_popup.c   | 27 -
 src/lib/elementary/efl_ui_popup.eo  |  2 ++
 src/lib/elementary/efl_ui_popup_alert.c | 18 ++---
 src/lib/elementary/efl_ui_popup_alert.eo|  2 ++
 src/lib/elementary/efl_ui_popup_alert_scroll.c  | 24 +++---
 src/lib/elementary/efl_ui_popup_alert_scroll.eo |  1 +
 src/lib/elementary/efl_ui_popup_alert_text.c| 24 +++---
 src/lib/elementary/efl_ui_popup_alert_text.eo   |  1 +
 src/lib/elementary/efl_ui_popup_anchor.c| 18 -
 src/lib/elementary/efl_ui_popup_anchor.eo   |  1 +
 10 files changed, 67 insertions(+), 51 deletions(-)

diff --git a/src/lib/elementary/efl_ui_popup.c 
b/src/lib/elementary/efl_ui_popup.c
index 6f225da034..7d59be8a7c 100644
--- a/src/lib/elementary/efl_ui_popup.c
+++ b/src/lib/elementary/efl_ui_popup.c
@@ -188,12 +188,14 @@ _efl_ui_popup_timeout_get(Eo *obj EINA_UNUSED, 
Efl_Ui_Popup_Data *pd)
return pd->timeout;
 }
 
-EOLIAN static void
-_efl_ui_popup_efl_canvas_group_group_add(Eo *obj, Efl_Ui_Popup_Data *pd)
+EOLIAN static Eo *
+_efl_ui_popup_efl_object_constructor(Eo *obj, Efl_Ui_Popup_Data *pd)
 {
-   ELM_WIDGET_DATA_GET_OR_RETURN(obj, wd);
+   ELM_WIDGET_DATA_GET_OR_RETURN(obj, wd, NULL);
+
+   obj = efl_constructor(efl_super(obj, MY_CLASS));
+   efl_canvas_object_type_set(obj, MY_CLASS_NAME);
 
-   efl_canvas_group_add(efl_super(obj, MY_CLASS));
elm_widget_sub_object_parent_add(obj);
 
elm_widget_can_focus_set(obj, EINA_TRUE);
@@ -204,19 +206,25 @@ _efl_ui_popup_efl_canvas_group_group_add(Eo *obj, 
Efl_Ui_Popup_Data *pd)
evas_object_smart_member_add(pd->event_bg, obj);
evas_object_stack_below(pd->event_bg, wd->resize_obj);
 
-   edje_object_signal_callback_add(pd->event_bg, "elm,action,clicked", "*", 
_bg_clicked_cb, obj);
+   edje_object_signal_callback_add(pd->event_bg, "elm,action,clicked", "*",
+   _bg_clicked_cb, obj);
 
pd->align = EFL_UI_POPUP_ALIGN_CENTER;
+
+   return obj;
 }
 
 EOLIAN static void
-_efl_ui_popup_efl_canvas_group_group_del(Eo *obj, Efl_Ui_Popup_Data *pd)
+_efl_ui_popup_efl_object_destructor(Eo *obj, Efl_Ui_Popup_Data *pd)
 {
ELM_SAFE_DEL(pd->event_bg);
-   efl_event_callback_del(pd->win_parent, EFL_GFX_EVENT_RESIZE, 
_parent_geom_cb, obj);
-   efl_event_callback_del(pd->win_parent, EFL_GFX_EVENT_MOVE, _parent_geom_cb, 
obj);
 
-   efl_canvas_group_del(efl_super(obj, MY_CLASS));
+   efl_event_callback_del(pd->win_parent, EFL_GFX_EVENT_RESIZE, 
_parent_geom_cb,
+  obj);
+   efl_event_callback_del(pd->win_parent, EFL_GFX_EVENT_MOVE, _parent_geom_cb,
+  obj);
+
+   efl_destructor(efl_super(obj, MY_CLASS));
 }
 
 EOLIAN static void
@@ -277,7 +285,6 @@ _efl_ui_popup_bg_repeat_events_get(Eo *obj EINA_UNUSED, 
Efl_Ui_Popup_Data *pd)
 /* Internal EO APIs and hidden overrides */
 
 #define EFL_UI_POPUP_EXTRA_OPS \
-   EFL_CANVAS_GROUP_ADD_DEL_OPS(efl_ui_popup), \
ELM_LAYOUT_SIZING_EVAL_OPS(efl_ui_popup)
 
 #include "efl_ui_popup.eo.c"
diff --git a/src/lib/elementary/efl_ui_popup.eo 
b/src/lib/elementary/efl_ui_popup.eo
index cf70162e84..8f2a23778d 100644
--- a/src/lib/elementary/efl_ui_popup.eo
+++ b/src/lib/elementary/efl_ui_popup.eo
@@ -57,6 +57,8 @@ class Efl.Ui.Popup(Efl.Ui.Layout)
   }
}
implements {
+  Efl.Object.constructor;
+  Efl.Object.destructor;
   Efl.Gfx.position { set; }
   Efl.Gfx.visible { set; }
   Elm.Widget.widget_parent { set; }
diff --git a/src/lib/elementary/efl_ui_popup_alert.c 
b/src/lib/elementary/efl_ui_popup_alert.c
index 64d1ff6b92..bfb2c3d4e2 100644
--- a/src/lib/elementary/efl_ui_popup_alert.c
+++ b/src/lib/elementary/efl_ui_popup_alert.c
@@ -212,19 +212,24 @@ _efl_ui_popup_alert_button_set(Eo *obj, 
Efl_Ui_Popup_Alert_Data *pd, Efl_Ui_Popu
elm_layout_sizing_eval(obj);
 }
 
-EOLIAN static void
-_efl_ui_popup_alert_efl_canvas_group_group_add(Eo *obj, 
Efl_Ui_Popup_Alert_Data *pd EINA_UNUSED)
+EOLIAN static Eo *
+_efl_ui_popup_alert_efl_object_constructor(Eo *obj,
+   Efl_Ui_Popup_Alert_Data *pd 
EINA_UNUSED)
 {
-   ELM_WIDGET_DATA_GET_OR_RETURN(obj, wd);
+   ELM_WIDGET_DATA_GET_OR_RETURN(obj, wd, NULL);
+
+   obj = efl_constructor(efl_super(obj, MY_CLASS));
+   efl_canvas_object_type_set(obj, MY_CLASS_NAME);
 
-   efl_canvas_group_add(efl_super(obj, MY_CLASS));
elm_widget_sub_object_parent_add(obj);
 
elm_layout_theme_set(efl_super(obj, MY_CLASS), "popup", "base", "alert");
+
+   return obj;
 }
 
 EOLIAN static void

[EGIT] [core/efl] master 29/29: efl_ui_popup: Replace Efl.Container to Efl.Content to rebase

2017-11-28 Thread Jaehyun Cho
jaehyun pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=a3ad64dcd03a523050356e01c2f267442f07fdb6

commit a3ad64dcd03a523050356e01c2f267442f07fdb6
Author: Jaehyun Cho 
Date:   Mon Nov 27 18:50:11 2017 +0900

efl_ui_popup: Replace Efl.Container to Efl.Content to rebase
---
 src/lib/elementary/efl_ui_popup.c  | 23 +-
 src/lib/elementary/efl_ui_popup.eo |  6 +++---
 src/lib/elementary/efl_ui_popup_alert_part.eo  |  4 ++--
 .../elementary/efl_ui_popup_alert_scroll_part.eo   |  4 ++--
 src/lib/elementary/efl_ui_popup_alert_text_part.eo |  4 ++--
 src/lib/elementary/efl_ui_popup_part.eo|  4 ++--
 6 files changed, 16 insertions(+), 29 deletions(-)

diff --git a/src/lib/elementary/efl_ui_popup.c 
b/src/lib/elementary/efl_ui_popup.c
index 114daa09c6..0975386735 100644
--- a/src/lib/elementary/efl_ui_popup.c
+++ b/src/lib/elementary/efl_ui_popup.c
@@ -98,24 +98,6 @@ _efl_ui_popup_elm_widget_widget_parent_set(Eo *obj, 
Efl_Ui_Popup_Data *pd EINA_U
efl_event_callback_add(pd->win_parent, EFL_GFX_EVENT_MOVE, _parent_geom_cb, 
obj);
 }
 
-EOLIAN static Eina_Bool
-_efl_ui_popup_efl_container_content_set(Eo *obj, Efl_Ui_Popup_Data *pd 
EINA_UNUSED, Eo *content)
-{
-   return efl_content_set(efl_part(obj, "elm.swallow.content"), content);
-}
-
-EOLIAN static Eo*
-_efl_ui_popup_efl_container_content_get(Eo *obj, Efl_Ui_Popup_Data *pd 
EINA_UNUSED)
-{
-   return efl_content_get(efl_part(obj, "elm.swallow.content"));
-}
-
-EOLIAN static Eo*
-_efl_ui_popup_efl_container_content_unset(Eo *obj, Efl_Ui_Popup_Data *pd 
EINA_UNUSED)
-{
-   return efl_content_unset(efl_part(obj, "elm.swallow.content"));
-}
-
 EOLIAN static void
 _efl_ui_popup_align_set(Eo *obj EINA_UNUSED, Efl_Ui_Popup_Data *pd, 
Efl_Ui_Popup_Align type)
 {
@@ -269,6 +251,11 @@ _efl_ui_popup_content_unset(Eo *obj, Efl_Ui_Popup_Data *pd 
EINA_UNUSED, const ch
return efl_content_unset(efl_part(efl_super(obj, MY_CLASS), part));
 }
 
+/* Standard widget overrides */
+
+ELM_PART_CONTENT_DEFAULT_SET(efl_ui_popup, "elm.swallow.content")
+ELM_PART_CONTENT_DEFAULT_IMPLEMENT(efl_ui_popup, Efl_Ui_Popup_Data)
+
 /* Efl.Part begin */
 
 ELM_PART_OVERRIDE_CONTENT_SET(efl_ui_popup, EFL_UI_POPUP, Efl_Ui_Popup_Data)
diff --git a/src/lib/elementary/efl_ui_popup.eo 
b/src/lib/elementary/efl_ui_popup.eo
index 48407fff7e..85bec78996 100644
--- a/src/lib/elementary/efl_ui_popup.eo
+++ b/src/lib/elementary/efl_ui_popup.eo
@@ -7,7 +7,7 @@ enum Efl.Ui.Popup.Align {
 bottom
 }
 
-class Efl.Ui.Popup(Efl.Ui.Layout)
+class Efl.Ui.Popup(Efl.Ui.Layout, Efl.Content)
 {
methods {
   @property align {
@@ -44,8 +44,8 @@ class Efl.Ui.Popup(Efl.Ui.Layout)
   Efl.Gfx.position { set; }
   Efl.Gfx.visible { set; }
   Elm.Widget.widget_parent { set; }
-  Efl.Container.content { get; set; }
-  Efl.Container.content_unset;
+  Efl.Content.content { get; set; }
+  Efl.Content.content_unset;
   Efl.Part.part;
}
events {
diff --git a/src/lib/elementary/efl_ui_popup_alert_part.eo 
b/src/lib/elementary/efl_ui_popup_alert_part.eo
index 3fc255d602..fa9d04fffb 100644
--- a/src/lib/elementary/efl_ui_popup_alert_part.eo
+++ b/src/lib/elementary/efl_ui_popup_alert_part.eo
@@ -3,8 +3,8 @@ class Efl.Ui.Popup.Alert.Part (Efl.Ui.Layout.Part_Content, 
Efl.Ui.Layout.Part_Te
[[Efl UI Popup Alert internal part class]]
data: null;
implements {
-  Efl.Container.content { get; set; }
-  Efl.Container.content_unset;
+  Efl.Content.content { get; set; }
+  Efl.Content.content_unset;
   Efl.Text.text { get; set; }
}
 }
diff --git a/src/lib/elementary/efl_ui_popup_alert_scroll_part.eo 
b/src/lib/elementary/efl_ui_popup_alert_scroll_part.eo
index 24d980893b..984f91161a 100644
--- a/src/lib/elementary/efl_ui_popup_alert_scroll_part.eo
+++ b/src/lib/elementary/efl_ui_popup_alert_scroll_part.eo
@@ -3,8 +3,8 @@ class Efl.Ui.Popup.Alert.Scroll.Part 
(Efl.Ui.Layout.Part_Content, Efl.Ui.Layout.
[[Efl UI Popup Alert Scroll internal part class]]
data: null;
implements {
-  Efl.Container.content { get; set; }
-  Efl.Container.content_unset;
+  Efl.Content.content { get; set; }
+  Efl.Content.content_unset;
   Efl.Text.text { set; get; }
}
 }
diff --git a/src/lib/elementary/efl_ui_popup_alert_text_part.eo 
b/src/lib/elementary/efl_ui_popup_alert_text_part.eo
index f9e5fda8a3..e915644219 100644
--- a/src/lib/elementary/efl_ui_popup_alert_text_part.eo
+++ b/src/lib/elementary/efl_ui_popup_alert_text_part.eo
@@ -3,8 +3,8 @@ class Efl.Ui.Popup.Alert.Text.Part (Efl.Ui.Layout.Part_Content, 
Efl.Ui.Layout.Pa
[[Efl UI Popup Alert Text internal part class]]
data: null;
implements {
-  Efl.Container.content { get; set; }
-  Efl.Container.content_unset;
+  Efl.Content.content { get; set; }
+  Efl.Content.content_unset;
   Efl.Text.text { get; set; }
}
 }

[EGIT] [core/efl] master 09/29: efl_ui_popup: use efl_data_scope_get instead of using 'self' object

2017-11-28 Thread JinYong Park
jaehyun pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=0365bf1e139f704be2fef79506cd4c732a31b12a

commit 0365bf1e139f704be2fef79506cd4c732a31b12a
Author: JinYong Park 
Date:   Thu Aug 31 15:21:04 2017 +0900

efl_ui_popup: use efl_data_scope_get instead of using 'self' object

Summary:
Use efl_data_scope_get to get Efl_Ui_Popup_Data structure.
There is no reason using "self" object in Efl_Ui_Popup_Data.

Reviewers: Jaehyun_Cho, herb, thiepha, woohyun, jpeg, cedric

Reviewed By: cedric

Differential Revision: https://phab.enlightenment.org/D5128
---
 src/lib/elementary/efl_ui_popup.c | 34 +++
 src/lib/elementary/efl_ui_popup_private.h |  1 -
 2 files changed, 16 insertions(+), 19 deletions(-)

diff --git a/src/lib/elementary/efl_ui_popup.c 
b/src/lib/elementary/efl_ui_popup.c
index 7de893e5de..a81ff67909 100644
--- a/src/lib/elementary/efl_ui_popup.c
+++ b/src/lib/elementary/efl_ui_popup.c
@@ -30,8 +30,10 @@ _efl_ui_popup_efl_gfx_position_set(Eo *obj, 
Efl_Ui_Popup_Data *pd EINA_UNUSED, E
 }
 
 static void
-_calc_align(Efl_Ui_Popup_Data *pd)
+_calc_align(Evas_Object *obj)
 {
+   Efl_Ui_Popup_Data *pd = efl_data_scope_get(obj, MY_CLASS);
+
Evas_Coord x, y, w, h;
evas_object_geometry_get(pd->win_parent, , , , );
 
@@ -42,39 +44,37 @@ _calc_align(Efl_Ui_Popup_Data *pd)
evas_object_resize(pd->event_bg, w, h);
 
Evas_Coord pw, ph;
-   evas_object_geometry_get(pd->self, NULL, NULL, , );
+   evas_object_geometry_get(obj, NULL, NULL, , );
 
Efl_Ui_Popup_Align align;
-   align = efl_ui_popup_align_get(pd->self);
+   align = efl_ui_popup_align_get(obj);
 
switch (align)
  {
 case EFL_UI_POPUP_ALIGN_CENTER:
-   evas_object_move(pd->self, x + ((w - pw ) / 2), y + ((h - ph) / 2));
+   evas_object_move(obj, x + ((w - pw ) / 2), y + ((h - ph) / 2));
 break;
 case EFL_UI_POPUP_ALIGN_LEFT:
-   evas_object_move(pd->self, x, y + ((h - ph) / 2));
+   evas_object_move(obj, x, y + ((h - ph) / 2));
 break;
 case EFL_UI_POPUP_ALIGN_RIGHT:
-   evas_object_move(pd->self, x + (w - pw), ((h - ph) / 2));
+   evas_object_move(obj, x + (w - pw), ((h - ph) / 2));
 break;
 case EFL_UI_POPUP_ALIGN_TOP:
-   evas_object_move(pd->self, x + ((w - pw) / 2), y);
+   evas_object_move(obj, x + ((w - pw) / 2), y);
 break;
 case EFL_UI_POPUP_ALIGN_BOTTOM:
-   evas_object_move(pd->self, x + ((w - pw) / 2), y + (h - ph));
+   evas_object_move(obj, x + ((w - pw) / 2), y + (h - ph));
 break;
 default:
 break;
  }
 }
 
-
 static void
 _parent_geom_cb(void *data, const Efl_Event *ev EINA_UNUSED)
 {
-   Efl_Ui_Popup_Data *pd = data;
-   _calc_align(pd);
+   _calc_align(data);
 }
 
 EOLIAN static void
@@ -92,8 +92,8 @@ _efl_ui_popup_elm_widget_widget_parent_set(Eo *obj, 
Efl_Ui_Popup_Data *pd EINA_U
evas_object_move(pd->event_bg, x, y);
evas_object_resize(pd->event_bg, w, h);
 
-   efl_event_callback_add(pd->win_parent, EFL_GFX_EVENT_RESIZE, 
_parent_geom_cb, pd);
-   efl_event_callback_add(pd->win_parent, EFL_GFX_EVENT_MOVE, _parent_geom_cb, 
pd);
+   efl_event_callback_add(pd->win_parent, EFL_GFX_EVENT_RESIZE, 
_parent_geom_cb, obj);
+   efl_event_callback_add(pd->win_parent, EFL_GFX_EVENT_MOVE, _parent_geom_cb, 
obj);
 }
 
 EOLIAN static Eina_Bool
@@ -131,7 +131,7 @@ EOLIAN static void
 _efl_ui_popup_align_set(Eo *obj EINA_UNUSED, Efl_Ui_Popup_Data *pd, 
Efl_Ui_Popup_Align type)
 {
pd->align = type;
-   _calc_align(pd);
+   _calc_align(obj);
 }
 
 EOLIAN static Efl_Ui_Popup_Align
@@ -148,8 +148,6 @@ _efl_ui_popup_efl_canvas_group_group_add(Eo *obj, 
Efl_Ui_Popup_Data *pd)
efl_canvas_group_add(efl_super(obj, MY_CLASS));
elm_widget_sub_object_parent_add(obj);
 
-   pd->self = obj;
-   
elm_widget_can_focus_set(obj, EINA_TRUE);
elm_layout_theme_set(obj, "popup", "base", "view");
 
@@ -167,8 +165,8 @@ EOLIAN static void
 _efl_ui_popup_efl_canvas_group_group_del(Eo *obj, Efl_Ui_Popup_Data *pd)
 {
ELM_SAFE_FREE(pd->event_bg, evas_object_del);
-   efl_event_callback_del(pd->win_parent, EFL_GFX_EVENT_RESIZE, 
_parent_geom_cb, pd);
-   efl_event_callback_del(pd->win_parent, EFL_GFX_EVENT_MOVE, _parent_geom_cb, 
pd);
+   efl_event_callback_del(pd->win_parent, EFL_GFX_EVENT_RESIZE, 
_parent_geom_cb, obj);
+   efl_event_callback_del(pd->win_parent, EFL_GFX_EVENT_MOVE, _parent_geom_cb, 
obj);
 
efl_canvas_group_del(efl_super(obj, MY_CLASS));
 }
diff --git a/src/lib/elementary/efl_ui_popup_private.h 
b/src/lib/elementary/efl_ui_popup_private.h
index dd979b318e..e87151edd1 100644
--- a/src/lib/elementary/efl_ui_popup_private.h
+++ b/src/lib/elementary/efl_ui_popup_private.h
@@ -4,7 +4,6 @@
 typedef struct _Efl_Ui_Popup_Data Efl_Ui_Popup_Data;
 struct _Efl_Ui_Popup_Data
 {
-   Evas_Object 

[EGIT] [core/efl] master 06/29: efl_ui_popup: cover the corner case of popup sizing evaluation

2017-11-28 Thread Taehyub Kim
jaehyun pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=b1eac4c46ba00528ae28a8b41c490dff95c66140

commit b1eac4c46ba00528ae28a8b41c490dff95c66140
Author: Taehyub Kim 
Date:   Thu Aug 31 13:17:56 2017 +0900

efl_ui_popup: cover the corner case of popup sizing evaluation

Summary: cover the corner case of popup sizing evaluation

Test Plan: 1. run elementary_test -to efluipopup

Reviewers: Jaehyun_Cho, jpeg, thiepha, Blackmole, woohyun, cedric

Reviewed By: Jaehyun_Cho

Differential Revision: https://phab.enlightenment.org/D5146
---
 src/lib/elementary/efl_ui_popup.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/lib/elementary/efl_ui_popup.c 
b/src/lib/elementary/efl_ui_popup.c
index 1f405769f5..7de893e5de 100644
--- a/src/lib/elementary/efl_ui_popup.c
+++ b/src/lib/elementary/efl_ui_popup.c
@@ -191,7 +191,7 @@ _efl_ui_popup_elm_layout_sizing_eval(Eo *obj, 
Efl_Ui_Popup_Data *pd EINA_UNUSED)
  evas_object_resize(obj, minw, h);
else if ((minw < w) && (minh > h))
  evas_object_resize(obj, w, minh);
-   else if ((minw > w) && (minh > h))
+   else if ((minw >= w) && (minh >= h))
  evas_object_resize(obj, minw, minh);
 }
 

-- 




[EGIT] [core/efl] master 28/29: efl_ui_popup_alert: Remove expandable property for now

2017-11-28 Thread Jaehyun Cho
jaehyun pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=dcb7093c4c6681680bb3a78cc611c8443ac101d9

commit dcb7093c4c6681680bb3a78cc611c8443ac101d9
Author: Jaehyun Cho 
Date:   Mon Nov 27 15:31:37 2017 +0900

efl_ui_popup_alert: Remove expandable property for now

It needs more time to stabilize expandable property.
So the expandable property is removed for now.
The expandable property will be added later.
---
 src/bin/elementary/test_ui_popup.c |  6 --
 src/lib/elementary/efl_ui_popup_alert_scroll.c | 97 +-
 src/lib/elementary/efl_ui_popup_alert_scroll.eo| 17 
 .../elementary/efl_ui_popup_alert_scroll_private.h |  8 +-
 src/lib/elementary/efl_ui_popup_alert_text.c   | 44 +-
 src/lib/elementary/efl_ui_popup_alert_text.eo  | 16 
 .../elementary/efl_ui_popup_alert_text_private.h   |  6 +-
 7 files changed, 6 insertions(+), 188 deletions(-)

diff --git a/src/bin/elementary/test_ui_popup.c 
b/src/bin/elementary/test_ui_popup.c
index 770ff93f7c..3db83fb123 100644
--- a/src/bin/elementary/test_ui_popup.c
+++ b/src/bin/elementary/test_ui_popup.c
@@ -383,9 +383,6 @@ test_ui_popup_alert_scroll(void *data EINA_UNUSED, 
Evas_Object *obj EINA_UNUSED,
efl_ui_popup_alert_button_set(efl_ui_popup, 
EFL_UI_POPUP_ALERT_BUTTON_NEGATIVE, "No");
efl_ui_popup_alert_button_set(efl_ui_popup, EFL_UI_POPUP_ALERT_BUTTON_USER, 
"Cancel");
 
-   efl_ui_popup_alert_scroll_expandable_set(efl_ui_popup, EINA_TRUE, 
EINA_TRUE);
-   efl_gfx_size_hint_max_set(efl_ui_popup, EINA_SIZE2D(300, 180));
-
efl_event_callback_add(efl_ui_popup, EFL_UI_POPUP_ALERT_EVENT_CLICKED, 
efl_ui_popup_alert_clicked_cb, NULL);
 }
 
@@ -413,9 +410,6 @@ test_ui_popup_alert_text(void *data EINA_UNUSED, 
Evas_Object *obj EINA_UNUSED, v
efl_ui_popup_alert_button_set(efl_ui_popup, 
EFL_UI_POPUP_ALERT_BUTTON_NEGATIVE, "No");
efl_ui_popup_alert_button_set(efl_ui_popup, EFL_UI_POPUP_ALERT_BUTTON_USER, 
"Cancel");
 
-   efl_ui_popup_alert_text_expandable_set(efl_ui_popup, EINA_TRUE);
-   efl_gfx_size_hint_max_set(efl_ui_popup, EINA_SIZE2D(100, 180));
-
efl_event_callback_add(efl_ui_popup, EFL_UI_POPUP_ALERT_EVENT_CLICKED, 
efl_ui_popup_alert_clicked_cb, NULL);
 }
 
diff --git a/src/lib/elementary/efl_ui_popup_alert_scroll.c 
b/src/lib/elementary/efl_ui_popup_alert_scroll.c
index ac57b3d6b4..ed790db052 100644
--- a/src/lib/elementary/efl_ui_popup_alert_scroll.c
+++ b/src/lib/elementary/efl_ui_popup_alert_scroll.c
@@ -12,63 +12,9 @@
 #define MY_CLASS EFL_UI_POPUP_ALERT_SCROLL_CLASS
 #define MY_CLASS_NAME "Efl.Ui.Popup.Alert.Scroll"
 
-static void
-_scroller_sizing_eval(Eo *obj, Efl_Ui_Popup_Alert_Scroll_Data *pd, Eina_Size2D 
min)
-{
-   Eina_Rect geom = efl_gfx_geometry_get(obj);
-
-   pd->is_sizing_eval = EINA_TRUE;
-
-   if (pd->is_expandable_w && !pd->is_expandable_h)
- {
-if ((pd->max_scroll.w > -1) && (min.w > pd->max_scroll.w))
-  {
- elm_scroller_content_min_limit(pd->scroller, EINA_FALSE, 
EINA_FALSE);
- efl_gfx_size_set(obj, EINA_SIZE2D(pd->max_scroll.w, geom.h));
-  }
- }
-   else if (!pd->is_expandable_w && pd->is_expandable_h)
- {
-if ((pd->max_scroll.h > -1) && (min.h > pd->max_scroll.h))
-  {
- elm_scroller_content_min_limit(pd->scroller, EINA_FALSE, 
EINA_FALSE);
- efl_gfx_size_set(obj, EINA_SIZE2D(geom.w, pd->max_scroll.h));
-  }
- }
-   else if (pd->is_expandable_w && pd->is_expandable_h)
- {
-Eina_Bool wdir, hdir;
-wdir = hdir = EINA_FALSE;
-
-if ((pd->max_scroll.w > -1) && (min.w > pd->max_scroll.w))
-  wdir = 1;
-if ((pd->max_scroll.h > -1) && (min.h > pd->max_scroll.h))
-  hdir = 1;
-if (wdir && !hdir)
-  {
- elm_scroller_content_min_limit(pd->scroller, EINA_FALSE, 
EINA_TRUE);
- efl_gfx_size_set(obj, EINA_SIZE2D(pd->max_scroll.w, geom.h));
-  }
-else if (!wdir && hdir)
-  {
- elm_scroller_content_min_limit(pd->scroller, EINA_TRUE, 
EINA_FALSE);
- efl_gfx_size_set(obj, EINA_SIZE2D(geom.w, pd->max_scroll.h));
-  }
-else if(wdir && hdir)
-  {
- elm_scroller_content_min_limit(pd->scroller, EINA_FALSE, 
EINA_FALSE);
- efl_gfx_size_set(obj, pd->max_scroll);
-  }
- }
-
-   pd->is_sizing_eval = EINA_FALSE;
-}
-
 EOLIAN static void
-_efl_ui_popup_alert_scroll_elm_layout_sizing_eval(Eo *obj, 
Efl_Ui_Popup_Alert_Scroll_Data *pd)
+_efl_ui_popup_alert_scroll_elm_layout_sizing_eval(Eo *obj, 
Efl_Ui_Popup_Alert_Scroll_Data *pd EINA_UNUSED)
 {
-   if (pd->is_sizing_eval) return;
-
elm_layout_sizing_eval(efl_super(obj, MY_CLASS));
 
ELM_WIDGET_DATA_GET_OR_RETURN(obj, wd);
@@ -78,8 +24,6 @@ _efl_ui_popup_alert_scroll_elm_layout_sizing_eval(Eo *obj, 
Efl_Ui_Popup_Alert_Sc

[EGIT] [core/efl] master 08/29: efl_ui_popup_alert_text: add Efl.Ui.Popup.Alert.Text Class

2017-11-28 Thread Taehyub Kim
jaehyun pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=3dccf133bbfa3869217578219870e65687f4092c

commit 3dccf133bbfa3869217578219870e65687f4092c
Author: Taehyub Kim 
Date:   Thu Aug 31 13:20:05 2017 +0900

efl_ui_popup_alert_text: add Efl.Ui.Popup.Alert.Text Class

Summary:
Add initial code for Efl.Ui.Popup.Alert.Text Class.
It supports setting texts on the content area.

Test Plan: 1. run elementary_text -to efluipopupalerttext

Reviewers: Jaehyun_Cho, jpeg, thiepha, cedric, woohyun, Blackmole

Reviewed By: Jaehyun_Cho

Differential Revision: https://phab.enlightenment.org/D5124
---
 src/Makefile_Elementary.am |   4 +
 src/bin/elementary/test.c  |   2 +
 src/bin/elementary/test_popup.c|  33 
 src/lib/elementary/Elementary.h|   1 +
 src/lib/elementary/efl_ui_popup_alert_text.c   | 182 +
 src/lib/elementary/efl_ui_popup_alert_text.eo  |  24 +++
 src/lib/elementary/efl_ui_popup_alert_text_part.eo |  10 ++
 .../elementary/efl_ui_popup_alert_text_private.h   |  15 ++
 8 files changed, 271 insertions(+)

diff --git a/src/Makefile_Elementary.am b/src/Makefile_Elementary.am
index 5c5c607501..cbee49167e 100644
--- a/src/Makefile_Elementary.am
+++ b/src/Makefile_Elementary.am
@@ -37,6 +37,8 @@ elm_public_eolian_files = \
lib/elementary/efl_ui_popup_alert.eo \
lib/elementary/efl_ui_popup_alert_scroll.eo \
lib/elementary/efl_ui_popup_alert_scroll_part.eo \
+   lib/elementary/efl_ui_popup_alert_text.eo \
+   lib/elementary/efl_ui_popup_alert_text_part.eo \
lib/elementary/efl_ui_text_editable.eo \
lib/elementary/efl_ui_text_async.eo \
lib/elementary/efl_ui_textpath.eo \
@@ -292,6 +294,7 @@ includesunstable_HEADERS = \
lib/elementary/efl_ui_popup_private.h \
lib/elementary/efl_ui_popup_alert_private.h \
lib/elementary/efl_ui_popup_alert_scroll_private.h \
+   lib/elementary/efl_ui_popup_alert_text_private.h \
lib/elementary/elm_widget_index.h \
lib/elementary/elm_widget_inwin.h \
lib/elementary/elm_widget_label.h \
@@ -704,6 +707,7 @@ lib_elementary_libelementary_la_SOURCES = \
lib/elementary/efl_ui_popup.c \
lib/elementary/efl_ui_popup_alert.c \
lib/elementary/efl_ui_popup_alert_scroll.c \
+   lib/elementary/efl_ui_popup_alert_text.c \
lib/elementary/efl_ui_grid.c \
lib/elementary/efl_ui_grid_static.c \
lib/elementary/efl_ui_grid_private.h \
diff --git a/src/bin/elementary/test.c b/src/bin/elementary/test.c
index f5450f2a15..f5666e52ff 100644
--- a/src/bin/elementary/test.c
+++ b/src/bin/elementary/test.c
@@ -277,6 +277,7 @@ void test_popup(void *data, Evas_Object *obj, void 
*event_info);
 void test_efl_ui_popup(void *data, Evas_Object *obj, void *event_info);
 void test_efl_ui_popup_alert(void *data, Evas_Object *obj, void *event_info);
 void test_efl_ui_popup_alert_scroll(void *data, Evas_Object *obj, void 
*event_info);
+void test_efl_ui_popup_alert_text(void *data, Evas_Object *obj, void 
*event_info);
 void test_dayselector(void *data, Evas_Object *obj, void *event_info);
 void test_image(void *data, Evas_Object *obj, void *event_info);
 void test_image_scale_type(void *data, Evas_Object *obj, void *event_info);
@@ -1048,6 +1049,7 @@ add_tests:
ADD_TEST(NULL, "Popups", "Efl UI Popup", test_efl_ui_popup);
ADD_TEST(NULL, "Popups", "Efl UI Popup Alert", test_efl_ui_popup_alert);
ADD_TEST(NULL, "Popups", "Efl UI Popup Alert Scroll", 
test_efl_ui_popup_alert_scroll);
+   ADD_TEST(NULL, "Popups", "Efl UI Popup Alert Text", 
test_efl_ui_popup_alert_text);
 
//--//
ADD_TEST(NULL, "Times & Dates", "Calendar", test_calendar);
diff --git a/src/bin/elementary/test_popup.c b/src/bin/elementary/test_popup.c
index 299644f17d..afc29a5858 100644
--- a/src/bin/elementary/test_popup.c
+++ b/src/bin/elementary/test_popup.c
@@ -1172,3 +1172,36 @@ test_efl_ui_popup_alert_scroll(void *data EINA_UNUSED, 
Evas_Object *obj EINA_UNU
 
efl_event_callback_add(efl_ui_popup, EFL_UI_POPUP_ALERT_EVENT_CLICKED, 
efl_ui_popup_alert_clicked_cb, NULL);
 }
+
+void
+test_efl_ui_popup_alert_text(void *data EINA_UNUSED, Evas_Object *obj 
EINA_UNUSED, void *event_info EINA_UNUSED)
+{
+   Evas_Object *win;
+
+   win = elm_win_util_standard_add("Efl UI Popup Alert Text", "Efl UI Popup 
Alert Text");
+   elm_win_autodel_set(win, EINA_TRUE);
+
+   evas_object_resize(win, 320, 320);
+   evas_object_show(win);
+
+   Evas_Object *efl_ui_popup= efl_add(EFL_UI_POPUP_ALERT_TEXT_CLASS, win);
+
+   efl_ui_popup_alert_title_set(efl_ui_popup, "title");
+
+   evas_object_resize(efl_ui_popup, 160, 160);
+   evas_object_show(efl_ui_popup);
+
+   efl_text_set(efl_ui_popup,
+"This is Text Popup This is Text Popup 

[EGIT] [core/efl] master 12/29: efl_ui_popup: remove unnecessary function call

2017-11-28 Thread JinYong Park
jaehyun pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=a7082df12b9d72880e308be4c81152de596ee028

commit a7082df12b9d72880e308be4c81152de596ee028
Author: JinYong Park 
Date:   Tue Sep 19 16:23:43 2017 +0900

efl_ui_popup: remove unnecessary function call

Summary:
In _calc_align function, it could get align property through 
Efl_Ui_Popup_Data *pd directly,
but call align_get function previously.

Reviewers: Jaehyun_Cho, herb, thiepha, jpeg, cedric, woohyun

Reviewed By: Jaehyun_Cho

Differential Revision: https://phab.enlightenment.org/D5207
---
 src/lib/elementary/efl_ui_popup.c | 5 +
 1 file changed, 1 insertion(+), 4 deletions(-)

diff --git a/src/lib/elementary/efl_ui_popup.c 
b/src/lib/elementary/efl_ui_popup.c
index 5db1415260..2deb6a29f4 100644
--- a/src/lib/elementary/efl_ui_popup.c
+++ b/src/lib/elementary/efl_ui_popup.c
@@ -47,10 +47,7 @@ _calc_align(Evas_Object *obj)
Evas_Coord pw, ph;
evas_object_geometry_get(obj, NULL, NULL, , );
 
-   Efl_Ui_Popup_Align align;
-   align = efl_ui_popup_align_get(obj);
-
-   switch (align)
+   switch (pd->align)
  {
 case EFL_UI_POPUP_ALIGN_CENTER:
efl_gfx_position_set(efl_super(obj, MY_CLASS), EINA_POSITION2D(x + 
((w - pw ) / 2), y + ((h - ph) / 2)));

-- 




[EGIT] [core/efl] master 25/29: efl_ui_popup: Rename bg_set with backwall_set

2017-11-28 Thread Jaehyun Cho
jaehyun pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=91df6723c929dc91ccf040ba5021c1142d1a6a17

commit 91df6723c929dc91ccf040ba5021c1142d1a6a17
Author: Jaehyun Cho 
Date:   Mon Oct 30 20:34:42 2017 +0900

efl_ui_popup: Rename bg_set with backwall_set

Since "background" is used as a basic part property, "backwall" is used
to indicate the area behind efl_ui_popup.
---
 data/elementary/themes/edc/elm/popup.edc  |  2 +-
 src/bin/elementary/test_ui_popup.c| 32 +-
 src/lib/elementary/efl_ui_popup.c | 54 +++
 src/lib/elementary/efl_ui_popup.eo|  8 ++---
 src/lib/elementary/efl_ui_popup_private.h |  4 +--
 5 files changed, 50 insertions(+), 50 deletions(-)

diff --git a/data/elementary/themes/edc/elm/popup.edc 
b/data/elementary/themes/edc/elm/popup.edc
index cb534a837a..e39b5cd5c3 100644
--- a/data/elementary/themes/edc/elm/popup.edc
+++ b/data/elementary/themes/edc/elm/popup.edc
@@ -626,7 +626,7 @@ group { "elm/popup/base/alert";
}
 }
 
-group { "elm/popup/base/event_bg";
+group { "elm/popup/base/backwall";
parts {
   rect { "base";
  desc { "default";
diff --git a/src/bin/elementary/test_ui_popup.c 
b/src/bin/elementary/test_ui_popup.c
index 2c7075de32..b39113f23d 100644
--- a/src/bin/elementary/test_ui_popup.c
+++ b/src/bin/elementary/test_ui_popup.c
@@ -16,7 +16,7 @@ typedef struct
 } efl_ui_popup_data;
 
 static void
-_bg_clicked(void *data EINA_UNUSED, const Efl_Event *ev EINA_UNUSED)
+_backwall_clicked(void *data EINA_UNUSED, const Efl_Event *ev EINA_UNUSED)
 {
printf("Popup's background is clicked.\n");
 }
@@ -55,7 +55,7 @@ _create_popup(efl_ui_popup_data *p_data)
 
Eo *efl_ui_popup = efl_add(EFL_UI_POPUP_CLASS, p_data->win);
 
-   efl_event_callback_add(efl_ui_popup, EFL_UI_POPUP_EVENT_BG_CLICKED, 
_bg_clicked, NULL);
+   efl_event_callback_add(efl_ui_popup, EFL_UI_POPUP_EVENT_BACKWALL_CLICKED, 
_backwall_clicked, NULL);
efl_event_callback_add(efl_ui_popup, EFL_UI_POPUP_EVENT_TIMEOUT, 
_timeout_cb, p_data);
efl_gfx_size_set(efl_ui_popup, EINA_SIZE2D(160, 160));
 
@@ -75,7 +75,7 @@ _create_cb(void *data, const Efl_Event *ev EINA_UNUSED)
 }
 
 static void
-_bg_cb(void *data EINA_UNUSED, const Efl_Event *ev)
+_backwall_cb(void *data EINA_UNUSED, const Efl_Event *ev)
 {
static int k = 0;
efl_ui_popup_data *p_data = data;
@@ -84,13 +84,13 @@ _bg_cb(void *data EINA_UNUSED, const Efl_Event *ev)
  {
 char buf[PATH_MAX];
 snprintf(buf, sizeof(buf), "%s/images/sky_01.jpg", 
elm_app_data_dir_get());
-efl_ui_popup_bg_set(p_data->efl_ui_popup, buf, NULL);
-efl_text_set(ev->object, "Bg UnSet");
+efl_ui_popup_backwall_set(p_data->efl_ui_popup, buf, NULL);
+efl_text_set(ev->object, "Backwall UnSet");
  }
else
  {
-efl_ui_popup_bg_set(p_data->efl_ui_popup, NULL, NULL);
-efl_text_set(ev->object, "Bg Set");
+efl_ui_popup_backwall_set(p_data->efl_ui_popup, NULL, NULL);
+efl_text_set(ev->object, "Backwall Set");
  }
k = !k;
 }
@@ -100,14 +100,14 @@ _repeat_event_cb(void *data EINA_UNUSED, const Efl_Event 
*ev)
 {
efl_ui_popup_data *p_data = data;
if (!p_data->efl_ui_popup) return;
-   if (!efl_ui_popup_bg_repeat_events_get(p_data->efl_ui_popup))
+   if (!efl_ui_popup_backwall_repeat_events_get(p_data->efl_ui_popup))
  {
-efl_ui_popup_bg_repeat_events_set(p_data->efl_ui_popup, EINA_TRUE);
+efl_ui_popup_backwall_repeat_events_set(p_data->efl_ui_popup, 
EINA_TRUE);
 efl_text_set(ev->object, "Repeat Event UnSet");
  }
else
  {
-efl_ui_popup_bg_repeat_events_set(p_data->efl_ui_popup, EINA_FALSE);
+efl_ui_popup_backwall_repeat_events_set(p_data->efl_ui_popup, 
EINA_FALSE);
 efl_text_set(ev->object, "Repeat Event Set");
  }
 }
@@ -265,11 +265,11 @@ test_ui_popup(void *data EINA_UNUSED, Evas_Object *obj 
EINA_UNUSED, void *event_
efl_gfx_size_set(dummy_btn, EINA_SIZE2D(150, 50));
efl_event_callback_add(dummy_btn, EFL_UI_EVENT_CLICKED, _dummy_cb, p_data);
 
-   Eo *bg_btn = efl_add(EFL_UI_BUTTON_CLASS, panel_win);
-   efl_gfx_position_set(bg_btn, EINA_POSITION2D(0, 100));
-   efl_gfx_size_set(bg_btn, EINA_SIZE2D(150, 50));
-   efl_text_set(bg_btn, "Bg Set");
-   efl_event_callback_add(bg_btn, EFL_UI_EVENT_CLICKED, _bg_cb, p_data);
+   Eo *backwall_btn = efl_add(EFL_UI_BUTTON_CLASS, panel_win);
+   efl_gfx_position_set(backwall_btn, EINA_POSITION2D(0, 100));
+   efl_gfx_size_set(backwall_btn, EINA_SIZE2D(150, 50));
+   efl_text_set(backwall_btn, "Backwall Set");
+   efl_event_callback_add(backwall_btn, EFL_UI_EVENT_CLICKED, _backwall_cb, 
p_data);
 
Eo *timeout_btn = efl_add(EFL_UI_BUTTON_CLASS, panel_win);
efl_text_set(timeout_btn, "Timeout Set");
@@ -453,7 +453,7 @@ test_ui_popup_anchor(void *data EINA_UNUSED, Evas_Object 
*obj EINA_UNUSED, void
 

[EGIT] [core/efl] master 10/29: efl_ui_popup: remove efl_ui_popup_position_set

2017-11-28 Thread JinYong Park
jaehyun pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=2e9042fae130ce9e6f7706b72c3d217cd506733a

commit 2e9042fae130ce9e6f7706b72c3d217cd506733a
Author: JinYong Park 
Date:   Wed Sep 6 11:09:08 2017 +0900

efl_ui_popup: remove efl_ui_popup_position_set

Summary:
Remove efl_ui_popup_position_set.
Its functionality is replaced with efl_gfx_position_set.

Test Plan:
  1. elementary_test -to efluipopup

Reviewers: Jaehyun_Cho, herb, thiepha, woohyun, jpeg, cedric

Reviewed By: Jaehyun_Cho

Differential Revision: https://phab.enlightenment.org/D5129
---
 src/bin/elementary/test_popup.c|  2 +-
 src/lib/elementary/efl_ui_popup.c  | 18 ++
 src/lib/elementary/efl_ui_popup.eo |  9 -
 3 files changed, 7 insertions(+), 22 deletions(-)

diff --git a/src/bin/elementary/test_popup.c b/src/bin/elementary/test_popup.c
index afc29a5858..2bb6edea45 100644
--- a/src/bin/elementary/test_popup.c
+++ b/src/bin/elementary/test_popup.c
@@ -1006,7 +1006,7 @@ static void
 _position_set_cb(void *data, Evas_Object *obj EINA_UNUSED,
 void *event_info EINA_UNUSED)
 {
-   efl_ui_popup_position_set(data, 0, 0);
+   evas_object_move(data, 0, 0);
 }
 
 void
diff --git a/src/lib/elementary/efl_ui_popup.c 
b/src/lib/elementary/efl_ui_popup.c
index a81ff67909..5db1415260 100644
--- a/src/lib/elementary/efl_ui_popup.c
+++ b/src/lib/elementary/efl_ui_popup.c
@@ -26,6 +26,7 @@ _bg_clicked_cb(void *data,
 EOLIAN static void
 _efl_ui_popup_efl_gfx_position_set(Eo *obj, Efl_Ui_Popup_Data *pd EINA_UNUSED, 
Eina_Position2D pos)
 {
+   pd->align = EFL_UI_POPUP_ALIGN_NONE;
efl_gfx_position_set(efl_super(obj, MY_CLASS), pos);
 }
 
@@ -52,19 +53,19 @@ _calc_align(Evas_Object *obj)
switch (align)
  {
 case EFL_UI_POPUP_ALIGN_CENTER:
-   evas_object_move(obj, x + ((w - pw ) / 2), y + ((h - ph) / 2));
+   efl_gfx_position_set(efl_super(obj, MY_CLASS), EINA_POSITION2D(x + 
((w - pw ) / 2), y + ((h - ph) / 2)));
 break;
 case EFL_UI_POPUP_ALIGN_LEFT:
-   evas_object_move(obj, x, y + ((h - ph) / 2));
+   efl_gfx_position_set(efl_super(obj, MY_CLASS), EINA_POSITION2D(x, y 
+ ((h - ph) / 2)));
 break;
 case EFL_UI_POPUP_ALIGN_RIGHT:
-   evas_object_move(obj, x + (w - pw), ((h - ph) / 2));
+   efl_gfx_position_set(efl_super(obj, MY_CLASS), EINA_POSITION2D(x + 
(w - pw), ((h - ph) / 2)));
 break;
 case EFL_UI_POPUP_ALIGN_TOP:
-   evas_object_move(obj, x + ((w - pw) / 2), y);
+   efl_gfx_position_set(efl_super(obj, MY_CLASS), EINA_POSITION2D(x + 
((w - pw) / 2), y));
 break;
 case EFL_UI_POPUP_ALIGN_BOTTOM:
-   evas_object_move(obj, x + ((w - pw) / 2), y + (h - ph));
+   efl_gfx_position_set(efl_super(obj, MY_CLASS), EINA_POSITION2D(x + 
((w - pw) / 2), y + (h - ph)));
 break;
 default:
 break;
@@ -120,13 +121,6 @@ _efl_ui_popup_parent_window_get(Eo *obj EINA_UNUSED, 
Efl_Ui_Popup_Data *pd)
return pd->win_parent;
 }
 
-EOLIAN void
-_efl_ui_popup_position_set(Eo *obj, Efl_Ui_Popup_Data *pd, int x, int y)
-{
-   evas_object_move(obj, x, y);
-   pd->align = EFL_UI_POPUP_ALIGN_NONE;
-}
-
 EOLIAN static void
 _efl_ui_popup_align_set(Eo *obj EINA_UNUSED, Efl_Ui_Popup_Data *pd, 
Efl_Ui_Popup_Align type)
 {
diff --git a/src/lib/elementary/efl_ui_popup.eo 
b/src/lib/elementary/efl_ui_popup.eo
index 14a30ca14e..a1a16644d3 100644
--- a/src/lib/elementary/efl_ui_popup.eo
+++ b/src/lib/elementary/efl_ui_popup.eo
@@ -39,15 +39,6 @@ class Efl.Ui.Popup(Efl.Ui.Layout)
 repeat: bool; [[If $true, events are passed to lower objects.]]
  }
   }
-  @property position {
-set {
-   [[Set the current popup position.]]
-}
-values {
-  x: int;
-  y: int;
-}
-  }
   @property align {
  set {
 [[ Set the popup alignment.]]

-- 




[EGIT] [core/efl] master 03/29: efl_ui_popup: add align and position properties

2017-11-28 Thread Taehyub Kim
jaehyun pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=0005b3105e31556bdf22d0f124c6522d5a567387

commit 0005b3105e31556bdf22d0f124c6522d5a567387
Author: Taehyub Kim 
Date:   Thu Aug 17 17:37:54 2017 +0900

efl_ui_popup: add align and position properties

Summary:
add align feature and position properties (center, left, right, top, bottom)
efl_ui_popup_position_set should be seperated from evas_object_move
since evas_object_move can be called internally.

Test Plan: 1. run elementary_test -to efluipopup

Reviewers: Jaehyun_Cho, jpeg, cedric, thiepha, Blackmole, woohyun

Reviewed By: Jaehyun_Cho

Differential Revision: https://phab.enlightenment.org/D5105
---
 src/bin/elementary/test_popup.c   | 93 ++-
 src/lib/elementary/efl_ui_popup.c | 79 ++
 src/lib/elementary/efl_ui_popup.eo| 30 +-
 src/lib/elementary/efl_ui_popup_private.h |  2 +
 4 files changed, 189 insertions(+), 15 deletions(-)

diff --git a/src/bin/elementary/test_popup.c b/src/bin/elementary/test_popup.c
index cc9de42f82..e42b7dc4a9 100644
--- a/src/bin/elementary/test_popup.c
+++ b/src/bin/elementary/test_popup.c
@@ -967,6 +967,48 @@ _image_change_btn_cb(void *data, Evas_Object *obj 
EINA_UNUSED,
k = !k;
 }
 
+static void
+_center_align_cb(void *data, Evas_Object *obj EINA_UNUSED,
+void *event_info EINA_UNUSED)
+{
+   efl_ui_popup_align_set(data, EFL_UI_POPUP_ALIGN_CENTER);
+}
+
+static void
+_left_align_cb(void *data, Evas_Object *obj EINA_UNUSED,
+void *event_info EINA_UNUSED)
+{
+   efl_ui_popup_align_set(data, EFL_UI_POPUP_ALIGN_LEFT);
+}
+
+static void
+_right_align_cb(void *data, Evas_Object *obj EINA_UNUSED,
+void *event_info EINA_UNUSED)
+{
+   efl_ui_popup_align_set(data, EFL_UI_POPUP_ALIGN_RIGHT);
+}
+
+static void
+_top_align_cb(void *data, Evas_Object *obj EINA_UNUSED,
+void *event_info EINA_UNUSED)
+{
+   efl_ui_popup_align_set(data, EFL_UI_POPUP_ALIGN_TOP);
+}
+
+static void
+_bottom_align_cb(void *data, Evas_Object *obj EINA_UNUSED,
+void *event_info EINA_UNUSED)
+{
+   efl_ui_popup_align_set(data, EFL_UI_POPUP_ALIGN_BOTTOM);
+}
+
+static void
+_position_set_cb(void *data, Evas_Object *obj EINA_UNUSED,
+void *event_info EINA_UNUSED)
+{
+   efl_ui_popup_position_set(data, 0, 0);
+}
+
 void
 test_efl_ui_popup(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void 
*event_info EINA_UNUSED)
 {
@@ -975,7 +1017,7 @@ test_efl_ui_popup(void *data EINA_UNUSED, Evas_Object *obj 
EINA_UNUSED, void *ev
win = elm_win_util_standard_add("Efl UI Popup", "Efl UI Popup");
elm_win_autodel_set(win, EINA_TRUE);
 
-   evas_object_resize(win, 320, 320);
+   evas_object_resize(win, 500, 500);
evas_object_show(win);
 
btn = elm_button_add(win);
@@ -988,7 +1030,6 @@ test_efl_ui_popup(void *data EINA_UNUSED, Evas_Object *obj 
EINA_UNUSED, void *ev
 
evas_object_smart_callback_add(efl_ui_popup, "bg,clicked", _bg_clicked, 
NULL);
 
-   evas_object_move(efl_ui_popup, 80, 80);
evas_object_resize(efl_ui_popup, 160, 160);
evas_object_show(efl_ui_popup);
 
@@ -1001,5 +1042,53 @@ test_efl_ui_popup(void *data EINA_UNUSED, Evas_Object 
*obj EINA_UNUSED, void *ev
evas_object_smart_callback_add(btn, "clicked", _image_change_btn_cb, 
efl_ui_popup);
evas_object_show(btn);
 
+   Evas_Object *center_btn;
+   center_btn = elm_button_add(win);
+   elm_object_text_set(center_btn, "Center Align");
+   evas_object_move(center_btn, 0, 300);
+   evas_object_resize(center_btn, 100, 50);
+   evas_object_show(center_btn);
+   evas_object_smart_callback_add(center_btn, "clicked", _center_align_cb, 
efl_ui_popup);
+
+   Evas_Object *left_btn;
+   left_btn = elm_button_add(win);
+   elm_object_text_set(left_btn, "Left Align");
+   evas_object_move(left_btn, 100, 300);
+   evas_object_resize(left_btn, 100, 50);
+   evas_object_show(left_btn);
+   evas_object_smart_callback_add(left_btn, "clicked", _left_align_cb, 
efl_ui_popup);
+
+   Evas_Object *right_btn;
+   right_btn = elm_button_add(win);
+   elm_object_text_set(right_btn, "Right Align");
+   evas_object_move(right_btn, 200, 300);
+   evas_object_resize(right_btn, 100, 50);
+   evas_object_show(right_btn);
+   evas_object_smart_callback_add(right_btn, "clicked", _right_align_cb, 
efl_ui_popup);
+
+   Evas_Object *top_btn;
+   top_btn = elm_button_add(win);
+   elm_object_text_set(top_btn, "Top Align");
+   evas_object_move(top_btn, 0, 350);
+   evas_object_resize(top_btn, 100, 50);
+   evas_object_show(top_btn);
+   evas_object_smart_callback_add(top_btn, "clicked", _top_align_cb, 
efl_ui_popup);
+
+   Evas_Object *bottom_btn;
+   bottom_btn = elm_button_add(win);
+   elm_object_text_set(bottom_btn, "Bottom Align");
+   evas_object_move(bottom_btn, 100, 350);
+   

[EGIT] [core/efl] master 23/29: test_popup: modify Efl.Ui.Popup Sample Code

2017-11-28 Thread Taehyub Kim
jaehyun pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=4a020223d89735dbfe99ef3c69a89c9aeb9717e6

commit 4a020223d89735dbfe99ef3c69a89c9aeb9717e6
Author: Taehyub Kim 
Date:   Fri Oct 27 18:11:58 2017 +0900

test_popup: modify Efl.Ui.Popup Sample Code

Summary: make Efl.Ui.Popup sample codes simpler

Test Plan:
1. run elementary_test -to efluipopup
2. test various options of efluipopup by clicking each button

Reviewers: Jaehyun_Cho, Blackmole, jpeg, cedric, woohyun

Reviewed By: Jaehyun_Cho

Differential Revision: https://phab.enlightenment.org/D5366
---
 src/bin/elementary/test_popup.c | 361 ++--
 1 file changed, 274 insertions(+), 87 deletions(-)

diff --git a/src/bin/elementary/test_popup.c b/src/bin/elementary/test_popup.c
index c5c8904da7..3a16718571 100644
--- a/src/bin/elementary/test_popup.c
+++ b/src/bin/elementary/test_popup.c
@@ -941,6 +941,14 @@ test_popup(void *data EINA_UNUSED, Evas_Object *obj 
EINA_UNUSED,
evas_object_show(win);
 }
 
+typedef struct
+{
+   Evas_Object *win;
+   Evas_Object *panel_win;
+   Evas_Object *efl_ui_popup;
+   Evas_Object *button;
+} efl_ui_popup_data;
+
 static void
 _bg_clicked(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED,
   void *event_info EINA_UNUSED)
@@ -949,165 +957,338 @@ _bg_clicked(void *data EINA_UNUSED, Evas_Object *obj 
EINA_UNUSED,
 }
 
 static void
-_image_change_btn_cb(void *data, Evas_Object *obj EINA_UNUSED,
-  void *event_info EINA_UNUSED)
+_timeout_cb(void *data EINA_UNUSED, const Efl_Event *ev EINA_UNUSED)
 {
-   static int k = 0;
+   efl_ui_popup_data *p_data = data;
+   p_data->efl_ui_popup = NULL;
+   printf("Popup times out and it is deleted.\n");
+}
+
+static void
+_delete_cb(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED,
+void *event_info EINA_UNUSED)
+{
+   efl_ui_popup_data *p_data = data;
+   if (p_data->efl_ui_popup)
+ {
+evas_object_del(p_data->efl_ui_popup);
+p_data->efl_ui_popup = NULL;
+return;
+ }
+   printf("Efl.Ui.Popup is not exist.\n");
+}
+
+static Evas_Object*
+_create_popup(efl_ui_popup_data *p_data)
+{
+   if (!p_data->win) return NULL;
+   if (p_data->efl_ui_popup)
+ {
+printf("Efl.Ui.Popup is already created.\n");
+evas_object_show(p_data->efl_ui_popup);
+return p_data->efl_ui_popup;
+ }
+
+   Evas_Object *efl_ui_popup = efl_add(EFL_UI_POPUP_CLASS, p_data->win);
+
+   evas_object_smart_callback_add(efl_ui_popup, "bg,clicked", _bg_clicked, 
NULL);
+   efl_event_callback_add(efl_ui_popup, EFL_UI_POPUP_EVENT_TIMEOUT, 
_timeout_cb, p_data);
+   evas_object_resize(efl_ui_popup, 160, 160);
+   evas_object_show(efl_ui_popup);
+
+   Evas_Object *btn = elm_button_add(efl_ui_popup);
+   elm_object_text_set(btn, "Efl.Ui.Popup");
+   evas_object_show(btn);
 
+   efl_content_set(efl_ui_popup, btn);
+
+   return efl_ui_popup;
+}
+
+static void
+_create_cb(void *data, Evas_Object *obj EINA_UNUSED,
+void *event_info EINA_UNUSED)
+{
+   efl_ui_popup_data *p_data = data;
+   p_data->efl_ui_popup = _create_popup(p_data);
+}
+
+static void
+_bg_cb(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED,
+void *event_info EINA_UNUSED)
+{
+   static int k = 0;
+   efl_ui_popup_data *p_data = data;
+   if (!p_data->efl_ui_popup) return;
if (k == 0)
  {
 char buf[PATH_MAX];
-snprintf(buf, sizeof(buf), "%s/images/logo.png", 
elm_app_data_dir_get());
-efl_ui_popup_bg_set(data, buf, NULL);
-efl_ui_popup_bg_repeat_events_set(data, EINA_TRUE);
+snprintf(buf, sizeof(buf), "%s/images/sky_01.jpg", 
elm_app_data_dir_get());
+efl_ui_popup_bg_set(p_data->efl_ui_popup, buf, NULL);
+elm_object_text_set(obj, "Bg UnSet");
  }
else
  {
-efl_ui_popup_bg_set(data, NULL, NULL);
-efl_ui_popup_bg_repeat_events_set(data, EINA_FALSE);
+efl_ui_popup_bg_set(p_data->efl_ui_popup, NULL, NULL);
+elm_object_text_set(obj, "Bg Set");
  }
k = !k;
 }
 
 static void
-_center_align_cb(void *data, Evas_Object *obj EINA_UNUSED,
+_repeat_event_cb(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED,
+void *event_info EINA_UNUSED)
+{
+   efl_ui_popup_data *p_data = data;
+   if (!p_data->efl_ui_popup) return;
+   if (!efl_ui_popup_bg_repeat_events_get(p_data->efl_ui_popup))
+ {
+efl_ui_popup_bg_repeat_events_set(p_data->efl_ui_popup, EINA_TRUE);
+elm_object_text_set(obj, "Repeat Event UnSet");
+ }
+   else
+ {
+efl_ui_popup_bg_repeat_events_set(p_data->efl_ui_popup, EINA_FALSE);
+elm_object_text_set(obj, "Repeat Event Set");
+ }
+}
+
+static void
+_repeat_test_cb(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED,
+void *event_info EINA_UNUSED)
+{
+   printf("Repeat Test 

[EGIT] [core/efl] master 24/29: test_ui_popup: Move code for Efl.Ui.Popup classes from test_popup

2017-11-28 Thread Jaehyun Cho
jaehyun pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=f82779efc220faf2c382489dede0e3910c37ea77

commit f82779efc220faf2c382489dede0e3910c37ea77
Author: Jaehyun Cho 
Date:   Mon Oct 30 20:03:01 2017 +0900

test_ui_popup: Move code for Efl.Ui.Popup classes from test_popup

Code refactoring to replace legacy APIs and move test code for
Efl.Ui.Popup and its sub classes from test_popup to test_ui_popup.
---
 src/Makefile_Elementary.am |   1 +
 src/bin/elementary/Makefile.am |   1 +
 src/bin/elementary/test.c  |  20 +-
 src/bin/elementary/test_popup.c| 585 -
 src/bin/elementary/test_ui_popup.c | 529 +
 5 files changed, 541 insertions(+), 595 deletions(-)

diff --git a/src/Makefile_Elementary.am b/src/Makefile_Elementary.am
index b6602554c2..2143085b6c 100644
--- a/src/Makefile_Elementary.am
+++ b/src/Makefile_Elementary.am
@@ -917,6 +917,7 @@ bin/elementary/test_transit_bezier.c \
 bin/elementary/test_ui_box.c \
 bin/elementary/test_ui_clock.c \
 bin/elementary/test_ui_grid.c \
+bin/elementary/test_ui_popup.c \
 bin/elementary/test_ui_textpath.c \
 bin/elementary/test_video.c \
 bin/elementary/test_weather.c \
diff --git a/src/bin/elementary/Makefile.am b/src/bin/elementary/Makefile.am
index 8f2a8106f4..dbc4437bdc 100644
--- a/src/bin/elementary/Makefile.am
+++ b/src/bin/elementary/Makefile.am
@@ -141,6 +141,7 @@ test_tooltip.c \
 test_transit.c \
 test_transit_bezier.c \
 test_ui_clock.c \
+test_ui_popup.c \
 test_video.c \
 test_weather.c \
 test_web.c \
diff --git a/src/bin/elementary/test.c b/src/bin/elementary/test.c
index ae576feec8..ecdd52170e 100644
--- a/src/bin/elementary/test.c
+++ b/src/bin/elementary/test.c
@@ -274,11 +274,11 @@ void test_naviframe_complex(void *data, Evas_Object *obj, 
void *event_info);
 void test_datetime(void *data, Evas_Object *obj, void *event_info);
 void test_ui_clock(void *data, Evas_Object *obj, void *event_info);
 void test_popup(void *data, Evas_Object *obj, void *event_info);
-void test_efl_ui_popup(void *data, Evas_Object *obj, void *event_info);
-void test_efl_ui_popup_alert(void *data, Evas_Object *obj, void *event_info);
-void test_efl_ui_popup_alert_scroll(void *data, Evas_Object *obj, void 
*event_info);
-void test_efl_ui_popup_alert_text(void *data, Evas_Object *obj, void 
*event_info);
-void test_efl_ui_popup_anchor(void *data, Evas_Object *obj, void *event_info);
+void test_ui_popup(void *data, Evas_Object *obj, void *event_info);
+void test_ui_popup_alert(void *data, Evas_Object *obj, void *event_info);
+void test_ui_popup_alert_scroll(void *data, Evas_Object *obj, void 
*event_info);
+void test_ui_popup_alert_text(void *data, Evas_Object *obj, void *event_info);
+void test_ui_popup_anchor(void *data, Evas_Object *obj, void *event_info);
 void test_dayselector(void *data, Evas_Object *obj, void *event_info);
 void test_image(void *data, Evas_Object *obj, void *event_info);
 void test_image_scale_type(void *data, Evas_Object *obj, void *event_info);
@@ -1047,11 +1047,11 @@ add_tests:
ADD_TEST(NULL, "Popups", "Tooltip 3", test_tooltip3);
ADD_TEST(NULL, "Popups", "Tooltip 4", test_tooltip4);
ADD_TEST(NULL, "Popups", "Popup", test_popup);
-   ADD_TEST(NULL, "Popups", "Efl UI Popup", test_efl_ui_popup);
-   ADD_TEST(NULL, "Popups", "Efl UI Popup Alert", test_efl_ui_popup_alert);
-   ADD_TEST(NULL, "Popups", "Efl UI Popup Alert Scroll", 
test_efl_ui_popup_alert_scroll);
-   ADD_TEST(NULL, "Popups", "Efl UI Popup Alert Text", 
test_efl_ui_popup_alert_text);
-   ADD_TEST(NULL, "Popups", "Efl UI Popup Anchor", test_efl_ui_popup_anchor);
+   ADD_TEST(NULL, "Popups", "UI.Popup", test_ui_popup);
+   ADD_TEST(NULL, "Popups", "UI.Popup.Alert", test_ui_popup_alert);
+   ADD_TEST(NULL, "Popups", "UI.Popup.Alert.Scroll", 
test_ui_popup_alert_scroll);
+   ADD_TEST(NULL, "Popups", "UI.Popup.Alert.Text", test_ui_popup_alert_text);
+   ADD_TEST(NULL, "Popups", "UI.Popup.Anchor", test_ui_popup_anchor);
 
//--//
ADD_TEST(NULL, "Times & Dates", "Calendar", test_calendar);
diff --git a/src/bin/elementary/test_popup.c b/src/bin/elementary/test_popup.c
index 3a16718571..da9bbca934 100644
--- a/src/bin/elementary/test_popup.c
+++ b/src/bin/elementary/test_popup.c
@@ -2,7 +2,6 @@
 # include "elementary_config.h"
 #endif
 
-#define EFL_UI_POPUP_ANCHOR_BETA
 #include 
 
 #define POPUP_POINT_MAX 8
@@ -940,587 +939,3 @@ test_popup(void *data EINA_UNUSED, Evas_Object *obj 
EINA_UNUSED,
evas_object_resize(win, 480, 400);
evas_object_show(win);
 }
-
-typedef struct
-{
-   Evas_Object *win;
-   Evas_Object *panel_win;
-   Evas_Object *efl_ui_popup;
-   Evas_Object *button;
-} efl_ui_popup_data;
-
-static void
-_bg_clicked(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED,
-  void *event_info EINA_UNUSED)
-{
-   printf("Popup's background is 

[EGIT] [core/efl] master 04/29: efl_ui_popup: make popup size expandable

2017-11-28 Thread Taehyub Kim
jaehyun pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=b38ad0971cb3bf8d84fcfcce51fdc1cca73c460f

commit b38ad0971cb3bf8d84fcfcce51fdc1cca73c460f
Author: Taehyub Kim 
Date:   Thu Aug 17 19:27:53 2017 +0900

efl_ui_popup: make popup size expandable

Summary: make popup size expandable

Reviewers: Jaehyun_Cho, jpeg, cedric, thiepha, Blackmole, woohyun

Differential Revision: https://phab.enlightenment.org/D5107
---
 src/lib/elementary/efl_ui_popup.c | 10 ++
 1 file changed, 10 insertions(+)

diff --git a/src/lib/elementary/efl_ui_popup.c 
b/src/lib/elementary/efl_ui_popup.c
index a8404cb89f..1f405769f5 100644
--- a/src/lib/elementary/efl_ui_popup.c
+++ b/src/lib/elementary/efl_ui_popup.c
@@ -183,6 +183,16 @@ _efl_ui_popup_elm_layout_sizing_eval(Eo *obj, 
Efl_Ui_Popup_Data *pd EINA_UNUSED)
edje_object_size_min_restricted_calc
  (wd->resize_obj, , , minw, minh);
evas_object_size_hint_min_set(obj, minw, minh);
+
+   Evas_Coord w, h;
+   evas_object_geometry_get(obj, NULL, NULL, , );
+
+   if ((minw > w) && (minh < h))
+ evas_object_resize(obj, minw, h);
+   else if ((minw < w) && (minh > h))
+ evas_object_resize(obj, w, minh);
+   else if ((minw > w) && (minh > h))
+ evas_object_resize(obj, minw, minh);
 }
 
 EOLIAN static void

-- 




[EGIT] [core/efl] master 22/29: efl_ui_popup: add _calc_align function in sizing eval function

2017-11-28 Thread Taehyub Kim
jaehyun pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=e65731b755709eba6ca869ce36e27a26564d337b

commit e65731b755709eba6ca869ce36e27a26564d337b
Author: Taehyub Kim 
Date:   Thu Oct 26 16:33:31 2017 +0900

efl_ui_popup: add _calc_align function in sizing eval function

Summary: add _calc_align function in sizing eval function to show popup 
correctly.

Reviewers: Jaehyun_Cho, jpeg, cedric, thiepha, Blackmole, woohyun

Reviewed By: Jaehyun_Cho

Differential Revision: https://phab.enlightenment.org/D5373
---
 src/lib/elementary/efl_ui_popup.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/src/lib/elementary/efl_ui_popup.c 
b/src/lib/elementary/efl_ui_popup.c
index c8f4b56092..79468817fe 100644
--- a/src/lib/elementary/efl_ui_popup.c
+++ b/src/lib/elementary/efl_ui_popup.c
@@ -245,6 +245,8 @@ _efl_ui_popup_elm_layout_sizing_eval(Eo *obj, 
Efl_Ui_Popup_Data *pd EINA_UNUSED)
new_size.w = (minw > size.w ? minw : size.w);
new_size.h = (minh > size.h ? minh : size.h);
efl_gfx_size_set(obj, new_size);
+
+   _calc_align(obj);
 }
 
 EOLIAN static void

-- 




[EGIT] [core/efl] master 13/29: efl_ui_popup_anchor: add Efl.Ui.Popup.Anchor class

2017-11-28 Thread JinYong Park
jaehyun pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=c8c7ac8aae0574ad0c6ad56f284c119dfd2709df

commit c8c7ac8aae0574ad0c6ad56f284c119dfd2709df
Author: JinYong Park 
Date:   Wed Sep 20 19:36:39 2017 +0900

efl_ui_popup_anchor: add Efl.Ui.Popup.Anchor class

Summary:
Add initial code for Efl.Ui.Popup.Anchor class.
It supports adding anchor object to popup.

Test Plan: 1. run elementary_test -to efluipopupanchor

Reviewers: Jaehyun_Cho, thiepha, herb, jpeg, cedric, woohyun

Reviewed By: Jaehyun_Cho

Differential Revision: https://phab.enlightenment.org/D5126
---
 data/elementary/objects/test.edc |  78 +
 src/Makefile_Elementary.am   |   3 +
 src/bin/elementary/test.c|   2 +
 src/bin/elementary/test_popup.c  | 116 
 src/lib/elementary/Elementary.h  |   1 +
 src/lib/elementary/efl_ui_popup_anchor.c | 357 +++
 src/lib/elementary/efl_ui_popup_anchor.eo|  40 +++
 src/lib/elementary/efl_ui_popup_anchor_private.h |  18 ++
 8 files changed, 615 insertions(+)

diff --git a/data/elementary/objects/test.edc b/data/elementary/objects/test.edc
index 834bea4e27..6574ab3adf 100644
--- a/data/elementary/objects/test.edc
+++ b/data/elementary/objects/test.edc
@@ -933,4 +933,82 @@ collections {
  }
   }
}
+   group { "efl_ui_popup_anchor_layout";
+  parts {
+ spacer { "base";
+desc { "default";
+}
+ }
+ swallow { "anchor1";
+scale;
+desc { "default";
+   rel.to: "base";
+   rel1.relative: 0.15 0.25;
+   rel2.relative: 0.15 0.25;
+   fixed: 1 1;
+   min: 50 50;
+}
+ }
+ swallow { "anchor2";
+scale;
+desc { "default";
+   rel.to: "base";
+   rel1.relative: 0.75 0.15;
+   rel2.relative: 0.75 0.15;
+   fixed: 1 1;
+   min: 50 50;
+}
+ }
+ swallow { "anchor3";
+scale;
+desc { "default";
+   rel.to: "base";
+   rel1.relative: 0.25 0.85;
+   rel2.relative: 0.25 0.85;
+   fixed: 1 1;
+   min: 50 50;
+}
+ }
+ swallow { "anchor4";
+scale;
+desc { "default";
+   rel.to: "base";
+   rel1.relative: 0.85 0.75;
+   rel2.relative: 0.85 0.75;
+   fixed: 1 1;
+   min: 50 50;
+}
+ }
+ swallow { "anchor5";
+scale;
+desc { "default";
+   rel.to: "base";
+   rel1.relative: 0.45 0.35;
+   rel2.relative: 0.45 0.35;
+   fixed: 1 1;
+   min: 50 50;
+}
+ }
+ swallow { "anchor6";
+scale;
+desc { "default";
+   rel.to: "base";
+   rel2.relative: 0.0 0.0;
+   rel1.offset: 150 300;
+   rel2.offset: 200 350;
+   fixed: 1 1;
+}
+ }
+ swallow { "anchor_none";
+scale;
+desc { "default";
+   rel.to: "base";
+   rel1.relative: 0.60 0.45;
+   rel2.relative: 0.60 0.45;
+   fixed: 1 1;
+   min: 70 50;
+}
+ }
+  }
+   }
 }
diff --git a/src/Makefile_Elementary.am b/src/Makefile_Elementary.am
index cbee49167e..f62e9f2d9d 100644
--- a/src/Makefile_Elementary.am
+++ b/src/Makefile_Elementary.am
@@ -39,6 +39,7 @@ elm_public_eolian_files = \
lib/elementary/efl_ui_popup_alert_scroll_part.eo \
lib/elementary/efl_ui_popup_alert_text.eo \
lib/elementary/efl_ui_popup_alert_text_part.eo \
+   lib/elementary/efl_ui_popup_anchor.eo \
lib/elementary/efl_ui_text_editable.eo \
lib/elementary/efl_ui_text_async.eo \
lib/elementary/efl_ui_textpath.eo \
@@ -295,6 +296,7 @@ includesunstable_HEADERS = \
lib/elementary/efl_ui_popup_alert_private.h \
lib/elementary/efl_ui_popup_alert_scroll_private.h \
lib/elementary/efl_ui_popup_alert_text_private.h \
+   lib/elementary/efl_ui_popup_anchor_private.h \
lib/elementary/elm_widget_index.h \
lib/elementary/elm_widget_inwin.h \
lib/elementary/elm_widget_label.h \
@@ -708,6 +710,7 @@ lib_elementary_libelementary_la_SOURCES = \
lib/elementary/efl_ui_popup_alert.c \
lib/elementary/efl_ui_popup_alert_scroll.c \
lib/elementary/efl_ui_popup_alert_text.c \
+   lib/elementary/efl_ui_popup_anchor.c \
lib/elementary/efl_ui_grid.c \
lib/elementary/efl_ui_grid_static.c \
lib/elementary/efl_ui_grid_private.h \
diff 

[EGIT] [core/efl] master 11/29: efl_ui_popup_alert_scroll: check sizing evaluation while scroller is changed

2017-11-28 Thread Taehyub Kim
jaehyun pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=f5010b7ba6d63cb665e8045b4e4ad1d8a85d7ad1

commit f5010b7ba6d63cb665e8045b4e4ad1d8a85d7ad1
Author: Taehyub Kim 
Date:   Tue Sep 19 09:36:26 2017 +0900

efl_ui_popup_alert_scroll: check sizing evaluation while scroller is changed

Summary: add a sizing check variable for safety of sizing evaluation when 
the min size of scroller is changed.

Test Plan:
1. run elementary_test
2. search the sample with "popup" keyword
3. click the Efl Ui Popup Alert Scroll sample

Reviewers: Jaehyun_Cho, jpeg, woohyun, thiepha, Blackmole, cedric

Reviewed By: Jaehyun_Cho

Differential Revision: https://phab.enlightenment.org/D5204
---
 src/lib/elementary/efl_ui_popup_alert_scroll.c | 6 ++
 src/lib/elementary/efl_ui_popup_alert_scroll_private.h | 1 +
 2 files changed, 7 insertions(+)

diff --git a/src/lib/elementary/efl_ui_popup_alert_scroll.c 
b/src/lib/elementary/efl_ui_popup_alert_scroll.c
index ca0fe7663c..290fc0fda2 100644
--- a/src/lib/elementary/efl_ui_popup_alert_scroll.c
+++ b/src/lib/elementary/efl_ui_popup_alert_scroll.c
@@ -18,6 +18,8 @@ _scroller_sizing_eval(Eo *obj, Efl_Ui_Popup_Alert_Scroll_Data 
*pd, Evas_Coord mi
Evas_Coord w, h;
evas_object_geometry_get(obj, NULL, NULL, , );
 
+   pd->is_sizing_eval = EINA_TRUE;
+
if (pd->is_expandable_w && !pd->is_expandable_h)
  {
 if ((pd->max_scroll_w > -1) && (minw > pd->max_scroll_w))
@@ -59,11 +61,15 @@ _scroller_sizing_eval(Eo *obj, 
Efl_Ui_Popup_Alert_Scroll_Data *pd, Evas_Coord mi
  evas_object_resize(obj, pd->max_scroll_w, pd->max_scroll_h);
}
  }
+
+   pd->is_sizing_eval = EINA_FALSE;
 }
 
 EOLIAN static void
 _efl_ui_popup_alert_scroll_elm_layout_sizing_eval(Eo *obj, 
Efl_Ui_Popup_Alert_Scroll_Data *pd)
 {
+   if (pd->is_sizing_eval) return;
+
elm_layout_sizing_eval(efl_super(obj, MY_CLASS));
 
ELM_WIDGET_DATA_GET_OR_RETURN(obj, wd);
diff --git a/src/lib/elementary/efl_ui_popup_alert_scroll_private.h 
b/src/lib/elementary/efl_ui_popup_alert_scroll_private.h
index d72e359572..3eb4005b97 100644
--- a/src/lib/elementary/efl_ui_popup_alert_scroll_private.h
+++ b/src/lib/elementary/efl_ui_popup_alert_scroll_private.h
@@ -12,6 +12,7 @@ struct _Efl_Ui_Popup_Alert_Scroll_Data
Evas_Coord max_scroll_h;
Eina_Bool is_expandable_w;
Eina_Bool is_expandable_h;
+   Eina_Bool is_sizing_eval;
 };
 
 #endif

-- 




[EGIT] [core/efl] master 01/29: efl_ui_popup: add Efl.Ui.Popup class

2017-11-28 Thread Taehyub Kim
jaehyun pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=996a975506edbbc695ecf6ec5e6c4c58a1ac1a50

commit 996a975506edbbc695ecf6ec5e6c4c58a1ac1a50
Author: Taehyub Kim 
Date:   Fri Jul 28 14:48:48 2017 +0900

efl_ui_popup: add Efl.Ui.Popup class

Summary: add initial code for Efl.Ui.Popup class

Test Plan: 1. run elementary_test -to efluipopup

Reviewers: Jaehyun_Cho, Blackmole, thiepha, woohyun, cedric

Reviewed By: Jaehyun_Cho

Subscribers: bu5hm4n, cedric, jpeg

Differential Revision: https://phab.enlightenment.org/D5037
---
 data/elementary/themes/edc/elm/popup.edc  |  36 
 src/Makefile_Elementary.am|   3 +
 src/bin/elementary/test.c |   2 +
 src/bin/elementary/test_popup.c   |  28 +++
 src/lib/elementary/Elementary.h   |   1 +
 src/lib/elementary/efl_ui_popup.c | 133 ++
 src/lib/elementary/efl_ui_popup.eo|  21 +
 src/lib/elementary/efl_ui_popup_private.h |  11 +++
 8 files changed, 235 insertions(+)

diff --git a/data/elementary/themes/edc/elm/popup.edc 
b/data/elementary/themes/edc/elm/popup.edc
index a551d4c602..ec79630716 100644
--- a/data/elementary/themes/edc/elm/popup.edc
+++ b/data/elementary/themes/edc/elm/popup.edc
@@ -507,3 +507,39 @@ group { name: "elm/popup/base/subpopup";
   }
}
 }
+
+//Efl.Ui.Popup Themes
+group { "elm/popup/base/view";
+   images.image: "rounded_square.png" COMP;
+   parts {
+  spacer { "base";
+ desc { "default";
+rel1.offset: 10 10;
+rel2.offset: -11 -11;
+ }
+  }
+  image { "bg";
+ desc { "default";
+min: 100 100;
+image.border: 15 15 15 15;
+image.normal: "rounded_square.png";
+ }
+  }
+  swallow { "elm.swallow.content";
+ desc { "default";
+rel.to: "base";
+ }
+  }
+   }
+}
+
+group { "elm/popup/base/event_bg";
+   parts {
+  rect { "base";
+ repeat;
+ desc { "default";
+color: 0 255 0 128;
+ }
+  }
+   }
+}
diff --git a/src/Makefile_Elementary.am b/src/Makefile_Elementary.am
index 3950d11e7d..d825df3d6c 100644
--- a/src/Makefile_Elementary.am
+++ b/src/Makefile_Elementary.am
@@ -33,6 +33,7 @@ elm_public_eolian_files = \
lib/elementary/efl_ui_grid_static.eo \
lib/elementary/efl_ui_text_interactive.eo \
lib/elementary/efl_ui_text.eo \
+   lib/elementary/efl_ui_popup.eo \
lib/elementary/efl_ui_text_editable.eo \
lib/elementary/efl_ui_text_async.eo \
lib/elementary/efl_ui_textpath.eo \
@@ -285,6 +286,7 @@ includesunstable_HEADERS = \
lib/elementary/elm_widget_hoversel.h \
lib/elementary/elm_widget_icon.h \
lib/elementary/efl_ui_widget_image.h \
+   lib/elementary/efl_ui_popup_private.h \
lib/elementary/elm_widget_index.h \
lib/elementary/elm_widget_inwin.h \
lib/elementary/elm_widget_label.h \
@@ -694,6 +696,7 @@ lib_elementary_libelementary_la_SOURCES = \
lib/elementary/efl_ui_box_stack.c \
lib/elementary/efl_ui_box_layout.c \
lib/elementary/efl_ui_box_private.h \
+   lib/elementary/efl_ui_popup.c \
lib/elementary/efl_ui_grid.c \
lib/elementary/efl_ui_grid_static.c \
lib/elementary/efl_ui_grid_private.h \
diff --git a/src/bin/elementary/test.c b/src/bin/elementary/test.c
index c643b8a4e1..63e902e902 100644
--- a/src/bin/elementary/test.c
+++ b/src/bin/elementary/test.c
@@ -274,6 +274,7 @@ void test_naviframe_complex(void *data, Evas_Object *obj, 
void *event_info);
 void test_datetime(void *data, Evas_Object *obj, void *event_info);
 void test_ui_clock(void *data, Evas_Object *obj, void *event_info);
 void test_popup(void *data, Evas_Object *obj, void *event_info);
+void test_efl_ui_popup(void *data, Evas_Object *obj, void *event_info);
 void test_dayselector(void *data, Evas_Object *obj, void *event_info);
 void test_image(void *data, Evas_Object *obj, void *event_info);
 void test_image_scale_type(void *data, Evas_Object *obj, void *event_info);
@@ -1042,6 +1043,7 @@ add_tests:
ADD_TEST(NULL, "Popups", "Tooltip 3", test_tooltip3);
ADD_TEST(NULL, "Popups", "Tooltip 4", test_tooltip4);
ADD_TEST(NULL, "Popups", "Popup", test_popup);
+   ADD_TEST(NULL, "Popups", "Efl UI Popup", test_efl_ui_popup);
 
//--//
ADD_TEST(NULL, "Times & Dates", "Calendar", test_calendar);
diff --git a/src/bin/elementary/test_popup.c b/src/bin/elementary/test_popup.c
index 173b1bf555..dbbb1a8891 100644
--- a/src/bin/elementary/test_popup.c
+++ b/src/bin/elementary/test_popup.c
@@ -938,3 +938,31 @@ test_popup(void *data EINA_UNUSED, Evas_Object *obj 
EINA_UNUSED,
evas_object_resize(win, 480, 400);
evas_object_show(win);
 }
+
+void
+test_efl_ui_popup(void *data EINA_UNUSED, 

[EGIT] [core/efl] master 20/29: efl_ui_popup_alert: Define Clicked_Event structure

2017-11-28 Thread Jaehyun Cho
jaehyun pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=27c0c90423bd399d463435a193ad6634da8941ab

commit 27c0c90423bd399d463435a193ad6634da8941ab
Author: Jaehyun Cho 
Date:   Tue Oct 24 22:30:49 2017 +0900

efl_ui_popup_alert: Define Clicked_Event structure
---
 src/bin/elementary/test_popup.c  | 15 ---
 src/lib/elementary/efl_ui_popup_alert.c  | 18 +++---
 src/lib/elementary/efl_ui_popup_alert.eo |  7 ++-
 3 files changed, 29 insertions(+), 11 deletions(-)

diff --git a/src/bin/elementary/test_popup.c b/src/bin/elementary/test_popup.c
index 4975a0f6f1..c5c8904da7 100644
--- a/src/bin/elementary/test_popup.c
+++ b/src/bin/elementary/test_popup.c
@@ -1113,13 +1113,14 @@ test_efl_ui_popup(void *data EINA_UNUSED, Evas_Object 
*obj EINA_UNUSED, void *ev
 static void
 efl_ui_popup_alert_clicked_cb(void *data EINA_UNUSED, const Efl_Event *ev)
 {
-Efl_Ui_Popup_Alert_Button type = (Efl_Ui_Popup_Alert_Button)ev->info;
-if (type == EFL_UI_POPUP_ALERT_BUTTON_POSITIVE)
-  printf("Positive Button is clicked\n");
-else if(type == EFL_UI_POPUP_ALERT_BUTTON_NEGATIVE)
-  printf("Negative Button is clicked\n");
-else if(type == EFL_UI_POPUP_ALERT_BUTTON_USER)
-  printf("User Button is clicked\n");
+   Efl_Ui_Popup_Alert_Clicked_Event *event = ev->info;
+
+   if (event->button_type == EFL_UI_POPUP_ALERT_BUTTON_POSITIVE)
+ printf("Positive Button is clicked\n");
+   else if(event->button_type == EFL_UI_POPUP_ALERT_BUTTON_NEGATIVE)
+ printf("Negative Button is clicked\n");
+   else if(event->button_type == EFL_UI_POPUP_ALERT_BUTTON_USER)
+ printf("User Button is clicked\n");
 }
 
 void
diff --git a/src/lib/elementary/efl_ui_popup_alert.c 
b/src/lib/elementary/efl_ui_popup_alert.c
index bfb2c3d4e2..13e708f50b 100644
--- a/src/lib/elementary/efl_ui_popup_alert.c
+++ b/src/lib/elementary/efl_ui_popup_alert.c
@@ -88,7 +88,11 @@ _positive_button_clicked_cb(void *data, Eo *obj EINA_UNUSED,
 void *event_info EINA_UNUSED)
 {
Eo *popup_obj = data;
-   efl_event_callback_call(popup_obj, EFL_UI_POPUP_ALERT_EVENT_CLICKED, (void 
*)(uintptr_t)EFL_UI_POPUP_ALERT_BUTTON_POSITIVE);
+
+   Efl_Ui_Popup_Alert_Clicked_Event event;
+   event.button_type = EFL_UI_POPUP_ALERT_BUTTON_POSITIVE;
+
+   efl_event_callback_call(popup_obj, EFL_UI_POPUP_ALERT_EVENT_CLICKED, 
);
 }
 
 static void
@@ -96,7 +100,11 @@ _negative_button_clicked_cb(void *data, Eo *obj EINA_UNUSED,
 void *event_info EINA_UNUSED)
 {
Eo *popup_obj = data;
-   efl_event_callback_call(popup_obj, EFL_UI_POPUP_ALERT_EVENT_CLICKED, (void 
*)(uintptr_t)EFL_UI_POPUP_ALERT_BUTTON_NEGATIVE);
+
+   Efl_Ui_Popup_Alert_Clicked_Event event;
+   event.button_type = EFL_UI_POPUP_ALERT_BUTTON_NEGATIVE;
+
+   efl_event_callback_call(popup_obj, EFL_UI_POPUP_ALERT_EVENT_CLICKED, 
);
 }
 
 static void
@@ -104,7 +112,11 @@ _user_button_clicked_cb(void *data, Eo *obj EINA_UNUSED,
 void *event_info EINA_UNUSED)
 {
Eo *popup_obj = data;
-   efl_event_callback_call(popup_obj, EFL_UI_POPUP_ALERT_EVENT_CLICKED, (void 
*)(uintptr_t)EFL_UI_POPUP_ALERT_BUTTON_USER);
+
+   Efl_Ui_Popup_Alert_Clicked_Event event;
+   event.button_type = EFL_UI_POPUP_ALERT_BUTTON_USER;
+
+   efl_event_callback_call(popup_obj, EFL_UI_POPUP_ALERT_EVENT_CLICKED, 
);
 }
 
 EOLIAN static void
diff --git a/src/lib/elementary/efl_ui_popup_alert.eo 
b/src/lib/elementary/efl_ui_popup_alert.eo
index 42c55a47f5..7d9fb1fbc1 100644
--- a/src/lib/elementary/efl_ui_popup_alert.eo
+++ b/src/lib/elementary/efl_ui_popup_alert.eo
@@ -5,6 +5,11 @@ enum Efl.Ui.Popup.Alert.Button {
user [[Button having user-defined meaning. e.g. "Cancel"]]
 }
 
+struct Efl.Ui.Popup.Alert.Clicked_Event {
+   [[Information of clicked event]]
+   button_type: Efl.Ui.Popup.Alert.Button; [[Clicked button type]]
+}
+
 class Efl.Ui.Popup.Alert(Efl.Ui.Popup)
 {
methods {
@@ -26,6 +31,6 @@ class Efl.Ui.Popup.Alert(Efl.Ui.Popup)
   Efl.Part.part;
}
events {
-  clicked;
+  clicked: Efl.Ui.Popup.Alert.Clicked_Event;
}
 }

-- 




[EGIT] [core/efl] master 02/29: efl_ui_popup: add bg_set and bg_repeat_events_set/get API

2017-11-28 Thread JinYong Park
jaehyun pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=bccd97bd62a0a2a9d95ba7d87949d92302ef50d2

commit bccd97bd62a0a2a9d95ba7d87949d92302ef50d2
Author: JinYong Park 
Date:   Thu Aug 10 15:48:36 2017 +0900

efl_ui_popup: add bg_set and bg_repeat_events_set/get API

Summary:
add bg_set and bg_repeat_events_set/get API
bg_set enables user change popup's outside bg
bg_repeat_events_set enables popup's outside bg repeat events

Test Plan:
 1. run elementary_test -to efluipopup
 2. click outside area of popup
 3. click button in popup

Reviewers: Jaehyun_Cho, herb, thiepha, woohyun, cedric, jpeg, singh.amitesh

Reviewed By: Jaehyun_Cho

Subscribers: jpeg

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D5054
---
 data/elementary/themes/edc/elm/popup.edc  | 42 +--
 src/bin/elementary/test_popup.c   | 41 --
 src/lib/elementary/efl_ui_popup.c | 48 +++
 src/lib/elementary/efl_ui_popup.eo| 38 +++-
 src/lib/elementary/efl_ui_popup_private.h |  1 +
 5 files changed, 159 insertions(+), 11 deletions(-)

diff --git a/data/elementary/themes/edc/elm/popup.edc 
b/data/elementary/themes/edc/elm/popup.edc
index ec79630716..7fb127b812 100644
--- a/data/elementary/themes/edc/elm/popup.edc
+++ b/data/elementary/themes/edc/elm/popup.edc
@@ -536,10 +536,48 @@ group { "elm/popup/base/view";
 group { "elm/popup/base/event_bg";
parts {
   rect { "base";
- repeat;
  desc { "default";
-color: 0 255 0 128;
+color: 0 0 0 64;
  }
+ desc { "show_image";
+inherit: "default";
+hid;
+ }
+  }
+  swallow { "elm.swallow.image";
+ desc { "default";
+rel.to: "base";
+hid;
+ }
+ desc { "show_image";
+inherit: "default";
+vis;
+ }
+  }
+  rect { "block";
+ desc { "default";
+rel.to: "base";
+color: 0 0 0 0;
+ }
+  }
+   }
+
+   programs {
+  program {
+ signal: "elm,state,image,visible"; source: "elm";
+ action: STATE_SET "show_image" 0.0;
+ target: "base";
+ target: "elm.swallow.image";
+  }
+  program {
+ signal: "elm,state,image,hidden"; source: "elm";
+ action: STATE_SET "default" 0.0;
+ target: "base";
+ target: "elm.swallow.image";
+  }
+  program {
+ signal: "mouse,clicked,1"; source: "block";
+ action: SIGNAL_EMIT "elm,action,clicked" "elm";
   }
}
 }
diff --git a/src/bin/elementary/test_popup.c b/src/bin/elementary/test_popup.c
index dbbb1a8891..cc9de42f82 100644
--- a/src/bin/elementary/test_popup.c
+++ b/src/bin/elementary/test_popup.c
@@ -939,10 +939,38 @@ test_popup(void *data EINA_UNUSED, Evas_Object *obj 
EINA_UNUSED,
evas_object_show(win);
 }
 
+static void
+_bg_clicked(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED,
+  void *event_info EINA_UNUSED)
+{
+   printf("Popup's background is clicked.\n");
+}
+
+static void
+_image_change_btn_cb(void *data, Evas_Object *obj EINA_UNUSED,
+  void *event_info EINA_UNUSED)
+{
+   static int k = 0;
+
+   if (k == 0)
+ {
+char buf[PATH_MAX];
+snprintf(buf, sizeof(buf), "%s/images/logo.png", 
elm_app_data_dir_get());
+efl_ui_popup_bg_set(data, buf, NULL);
+efl_ui_popup_bg_repeat_events_set(data, EINA_TRUE);
+ }
+   else
+ {
+efl_ui_popup_bg_set(data, NULL, NULL);
+efl_ui_popup_bg_repeat_events_set(data, EINA_FALSE);
+ }
+   k = !k;
+}
+
 void
 test_efl_ui_popup(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void 
*event_info EINA_UNUSED)
 {
-   Evas_Object *win;
+   Evas_Object *win, *btn;
 
win = elm_win_util_standard_add("Efl UI Popup", "Efl UI Popup");
elm_win_autodel_set(win, EINA_TRUE);
@@ -950,8 +978,16 @@ test_efl_ui_popup(void *data EINA_UNUSED, Evas_Object *obj 
EINA_UNUSED, void *ev
evas_object_resize(win, 320, 320);
evas_object_show(win);
 
+   btn = elm_button_add(win);
+   elm_object_text_set(btn, "bg repeat events test");
+   evas_object_move(btn, 0, 0);
+   evas_object_resize(btn, 150, 150);
+   evas_object_show(btn);
+
Evas_Object *efl_ui_popup= efl_add(EFL_UI_POPUP_CLASS, win);
 
+   evas_object_smart_callback_add(efl_ui_popup, "bg,clicked", _bg_clicked, 
NULL);
+
evas_object_move(efl_ui_popup, 80, 80);
evas_object_resize(efl_ui_popup, 160, 160);
evas_object_show(efl_ui_popup);
@@ -960,8 +996,9 @@ test_efl_ui_popup(void *data EINA_UNUSED, Evas_Object *obj 
EINA_UNUSED, void *ev
evas_object_geometry_get(efl_ui_popup, , , , );
printf("efl_ui_popup: %d %d %d %d\n", x, y, w, h);
 
-   Evas_Object *btn = 

[EGIT] [core/efl] master 27/29: examples: Add popup cxx example

2017-11-28 Thread Jaehyun Cho
jaehyun pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=59788cc9d072d3ff7c2f6ea42df18648c9c678d8

commit 59788cc9d072d3ff7c2f6ea42df18648c9c678d8
Author: Jaehyun Cho 
Date:   Wed Nov 15 21:16:22 2017 +0900

examples: Add popup cxx example
---
 src/examples/elementary/Makefile.am  |   3 +
 src/examples/elementary/popup_cxx_example.cc | 324 +++
 src/examples/elementary/sky_01.jpg   | Bin 0 -> 134813 bytes
 3 files changed, 327 insertions(+)

diff --git a/src/examples/elementary/Makefile.am 
b/src/examples/elementary/Makefile.am
index c4b5944c71..905683c4fd 100644
--- a/src/examples/elementary/Makefile.am
+++ b/src/examples/elementary/Makefile.am
@@ -193,6 +193,7 @@ calendar_cxx_example_05.cc \
 clock_cxx_example.cc \
 icon_cxx_example_01.cc \
 menu_cxx_example_01.cc \
+popup_cxx_example.cc \
 radio_cxx_example_01.cc \
 slider_cxx_example.cc \
 spinner_cxx_example.cc \
@@ -406,6 +407,7 @@ calendar_cxx_example_05 \
 clock_cxx_example \
 icon_cxx_example_01 \
 menu_cxx_example_01 \
+popup_cxx_example \
 radio_cxx_example_01 \
 slider_cxx_example \
 spinner_cxx_example \
@@ -435,6 +437,7 @@ clock_cxx_example_SOURCES = clock_cxx_example.cc
 icon_cxx_example_01_SOURCES = icon_cxx_example_01.cc
 menu_cxx_example_01_SOURCES = menu_cxx_example_01.cc
 radio_cxx_example_01_SOURCES = radio_cxx_example_01.cc
+popup_cxx_example_SOURCES = popup_cxx_example.cc
 slider_cxx_example_SOURCES = slider_cxx_example.cc
 spinner_cxx_example_SOURCES = spinner_cxx_example.cc
 table_cxx_example_01_SOURCES = table_cxx_example_01.cc
diff --git a/src/examples/elementary/popup_cxx_example.cc 
b/src/examples/elementary/popup_cxx_example.cc
new file mode 100644
index 00..8a06a81ac0
--- /dev/null
+++ b/src/examples/elementary/popup_cxx_example.cc
@@ -0,0 +1,324 @@
+// g++ -g `pkg-config --cflags --libs elementary-cxx efl-cxx eina-cxx eo-cxx 
ecore-cxx evas-cxx edje-cxx` popup_cxx_example.cc -o popup_cxx_example
+
+#define EFL_CXX_WREF_EASY
+#include 
+#include 
+#include 
+
+using efl::eo::instantiate;
+
+static efl::ui::Popup g_popup(nullptr);
+static efl::ui::Button g_repeat_events_test_btn(nullptr);
+
+static efl::ui::Popup
+create_popup(efl::ui::Win win)
+{
+   efl::ui::Popup popup(instantiate, win);
+
+   efl::ui::Button btn(instantiate, popup);
+   btn.text_set("Efl.Ui.Popup");
+   popup.content_set(btn);
+
+   popup.size_set({160, 160});
+
+   auto timeout_cb(std::bind([]() {
+g_popup = nullptr;
+std::cout << "Popup times out and it is deleted" << std::endl;
+ }));
+   efl::eolian::event_add(efl::ui::Popup::timeout_event, popup, timeout_cb);
+
+
+   return popup;
+}
+
+static void
+efl_main(void *data EINA_UNUSED, const Efl_Event *ev EINA_UNUSED)
+{
+   elm_policy_set(ELM_POLICY_QUIT, ELM_POLICY_QUIT_LAST_WINDOW_HIDDEN);
+
+
+   //Popup Window
+   efl::ui::Win win(instantiate);
+   win.text_set("Efl.Ui.Popup");
+   win.autohide_set(true);
+   win.size_set({500, 500});
+
+
+   //Popup Function Window
+   efl::ui::Win func_win(instantiate);
+   func_win.text_set("Efl.Ui.Popup Function");
+   func_win.autohide_set(true);
+   func_win.size_set({300, 500});
+
+
+   //Popup Window Delete callback
+   auto wfunc_win(func_win._get_wref());
+   auto win_del_cb(std::bind([wfunc_win]() {
+g_popup = nullptr;
+g_repeat_events_test_btn = nullptr;
+::efl_del(wfunc_win->_eo_ptr());
+std::cout << "Window is deleted" << std::endl;
+ }));
+   efl::eolian::event_add(win.delete_request_event, win, win_del_cb);
+
+
+   //Popup Function Window Delete callback
+   auto wwin(win._get_wref());
+   auto func_win_del_cb(std::bind([wwin]() {
+g_popup = nullptr;
+g_repeat_events_test_btn = nullptr;
+::efl_del(wwin->_eo_ptr());
+std::cout << "Window is deleted" << std::endl;
+ }));
+   efl::eolian::event_add(func_win.delete_request_event, func_win, 
func_win_del_cb);
+
+
+   //Dummy Button for Repeat Events Test
+   efl::ui::Button repeat_events_test_btn(instantiate, win);
+   repeat_events_test_btn.text_set("Repeat Event Test");
+   repeat_events_test_btn.position_set({0, 0});
+   repeat_events_test_btn.size_set({100, 100});
+   repeat_events_test_btn.visible_set(false);
+
+   auto repeat_events_test_cb(std::bind([]() {
+std::cout << "Repeat Test Button is clicked" << std::endl;
+ }));
+   efl::eolian::event_add(efl::ui::Clickable::clicked_event, 
repeat_events_test_btn, repeat_events_test_cb);
+   g_repeat_events_test_btn = repeat_events_test_btn;
+
+
+   //Popup
+   g_popup = create_popup(win);
+
+
+   //Create Button
+   efl::ui::Button create_btn(instantiate, func_win);
+   create_btn.text_set("Create Popup");
+   create_btn.position_set({0, 0});
+   create_btn.size_set({150, 50});
+
+   auto create_cb(std::bind([wwin]() {
+if (g_popup)
+  std::cout << "Efl.Ui.Popup is already created" << std::endl;
+else {
+  

[EGIT] [core/efl] master 26/29: efl_ui_popup: Make backwall efl part object of Efl.Ui.Popup

2017-11-28 Thread Jaehyun Cho
jaehyun pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=c752d8fe6beec321f66f566bf05731540f8d889e

commit c752d8fe6beec321f66f566bf05731540f8d889e
Author: Jaehyun Cho 
Date:   Fri Nov 10 17:56:34 2017 +0900

efl_ui_popup: Make backwall efl part object of Efl.Ui.Popup
---
 src/Makefile_Elementary.am|   1 +
 src/bin/elementary/test_ui_popup.c|  12 ++--
 src/lib/elementary/efl_ui_popup.c | 107 +++---
 src/lib/elementary/efl_ui_popup.eo|  25 ++-
 src/lib/elementary/efl_ui_popup_part.eo   |  11 +++
 src/lib/elementary/efl_ui_popup_private.h |   1 -
 6 files changed, 106 insertions(+), 51 deletions(-)

diff --git a/src/Makefile_Elementary.am b/src/Makefile_Elementary.am
index 2143085b6c..9fdc6b5120 100644
--- a/src/Makefile_Elementary.am
+++ b/src/Makefile_Elementary.am
@@ -34,6 +34,7 @@ elm_public_eolian_files = \
lib/elementary/efl_ui_text_interactive.eo \
lib/elementary/efl_ui_text.eo \
lib/elementary/efl_ui_popup.eo \
+   lib/elementary/efl_ui_popup_part.eo \
lib/elementary/efl_ui_popup_alert.eo \
lib/elementary/efl_ui_popup_alert_part.eo \
lib/elementary/efl_ui_popup_alert_scroll.eo \
diff --git a/src/bin/elementary/test_ui_popup.c 
b/src/bin/elementary/test_ui_popup.c
index b39113f23d..770ff93f7c 100644
--- a/src/bin/elementary/test_ui_popup.c
+++ b/src/bin/elementary/test_ui_popup.c
@@ -84,12 +84,12 @@ _backwall_cb(void *data EINA_UNUSED, const Efl_Event *ev)
  {
 char buf[PATH_MAX];
 snprintf(buf, sizeof(buf), "%s/images/sky_01.jpg", 
elm_app_data_dir_get());
-efl_ui_popup_backwall_set(p_data->efl_ui_popup, buf, NULL);
+efl_file_set(efl_part(p_data->efl_ui_popup, "backwall"), buf, NULL);
 efl_text_set(ev->object, "Backwall UnSet");
  }
else
  {
-efl_ui_popup_backwall_set(p_data->efl_ui_popup, NULL, NULL);
+efl_file_set(efl_part(p_data->efl_ui_popup, "backwall"), NULL, NULL);
 efl_text_set(ev->object, "Backwall Set");
  }
k = !k;
@@ -100,14 +100,14 @@ _repeat_event_cb(void *data EINA_UNUSED, const Efl_Event 
*ev)
 {
efl_ui_popup_data *p_data = data;
if (!p_data->efl_ui_popup) return;
-   if (!efl_ui_popup_backwall_repeat_events_get(p_data->efl_ui_popup))
+   if (!efl_canvas_object_repeat_events_get(efl_part(p_data->efl_ui_popup, 
"backwall")))
  {
-efl_ui_popup_backwall_repeat_events_set(p_data->efl_ui_popup, 
EINA_TRUE);
+efl_canvas_object_repeat_events_set(efl_part(p_data->efl_ui_popup, 
"backwall"), EINA_TRUE);
 efl_text_set(ev->object, "Repeat Event UnSet");
  }
else
  {
-efl_ui_popup_backwall_repeat_events_set(p_data->efl_ui_popup, 
EINA_FALSE);
+efl_canvas_object_repeat_events_set(efl_part(p_data->efl_ui_popup, 
"backwall"), EINA_FALSE);
 efl_text_set(ev->object, "Repeat Event Set");
  }
 }
@@ -453,7 +453,7 @@ test_ui_popup_anchor(void *data EINA_UNUSED, Evas_Object 
*obj EINA_UNUSED, void
 
Eo *efl_ui_popup = efl_add(EFL_UI_POPUP_ANCHOR_CLASS, win);
 
-   efl_ui_popup_backwall_repeat_events_set(efl_ui_popup, EINA_TRUE);
+   efl_canvas_object_repeat_events_set(efl_part(efl_ui_popup, "backwall"), 
EINA_TRUE);
 
//Default align priority order is top, left, right, bottom, center.
efl_ui_popup_anchor_align_priority_set(efl_ui_popup, EFL_UI_POPUP_ALIGN_TOP,
diff --git a/src/lib/elementary/efl_ui_popup.c 
b/src/lib/elementary/efl_ui_popup.c
index 92eed8df8b..114daa09c6 100644
--- a/src/lib/elementary/efl_ui_popup.c
+++ b/src/lib/elementary/efl_ui_popup.c
@@ -8,6 +8,8 @@
 
 #include "elm_priv.h"
 #include "efl_ui_popup_private.h"
+#include "efl_ui_popup_part.eo.h"
+#include "elm_part_helper.h"
 
 #define MY_CLASS EFL_UI_POPUP_CLASS
 #define MY_CLASS_NAME "Efl.Ui.Popup"
@@ -249,42 +251,101 @@ _efl_ui_popup_elm_layout_sizing_eval(Eo *obj, 
Efl_Ui_Popup_Data *pd EINA_UNUSED)
_calc_align(obj);
 }
 
-EOLIAN static void
-_efl_ui_popup_backwall_set(Eo *obj, Efl_Ui_Popup_Data *pd, const char* file, 
const char* group)
+static Eina_Bool
+_efl_ui_popup_content_set(Eo *obj, Efl_Ui_Popup_Data *pd EINA_UNUSED, const 
char *part, Eo *content)
 {
-   Eo *prev_obj = edje_object_part_swallow_get(pd->backwall, 
"elm.swallow.image");
-   if (prev_obj)
- {
-edje_object_part_unswallow(pd->backwall, prev_obj);
-efl_del(prev_obj);
- }
+   return efl_content_set(efl_part(efl_super(obj, MY_CLASS), part), content);
+}
 
-   Eo *image = elm_image_add(obj);
-   Eina_Bool ret = elm_image_file_set(image, file, group);
-   if (!ret)
- {
-edje_object_signal_emit(pd->backwall, "elm,state,image,hidden", "elm");
-efl_del(image);
-return;
- }
-   edje_object_part_swallow(pd->backwall, "elm.swallow.image", image);
-   edje_object_signal_emit(pd->backwall, "elm,state,image,visible", "elm");
+Eo *
+_efl_ui_popup_content_get(Eo 

[EGIT] [core/efl] master 07/29: efl_ui_popup_alert_scroll: add Efl.Ui.Popup.Alert.Scroll class

2017-11-28 Thread Taehyub Kim
jaehyun pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=f22d40b1e66d76dc5c1b38bcd3829d1ec5fe9948

commit f22d40b1e66d76dc5c1b38bcd3829d1ec5fe9948
Author: Taehyub Kim 
Date:   Thu Aug 31 13:18:45 2017 +0900

efl_ui_popup_alert_scroll: add Efl.Ui.Popup.Alert.Scroll class

Summary:
Add initial code for Efl.Ui.Popup.Alert.Scroll Class.
It supports scrolling content.

Test Plan: 1. run elementary_test -to efluipopupalertscroll

Reviewers: Jaehyun_Cho, jpeg, thiepha, cedric, Blackmole, woohyun

Reviewed By: Jaehyun_Cho

Differential Revision: https://phab.enlightenment.org/D5123
---
 src/Makefile_Elementary.am |   4 +
 src/bin/elementary/test.c  |   2 +
 src/bin/elementary/test_popup.c|  36 
 src/lib/elementary/Elementary.h|   1 +
 src/lib/elementary/efl_ui_popup_alert_scroll.c | 229 +
 src/lib/elementary/efl_ui_popup_alert_scroll.eo|  24 +++
 .../elementary/efl_ui_popup_alert_scroll_part.eo   |  10 +
 .../elementary/efl_ui_popup_alert_scroll_private.h |  17 ++
 8 files changed, 323 insertions(+)

diff --git a/src/Makefile_Elementary.am b/src/Makefile_Elementary.am
index 40c1611f3e..5c5c607501 100644
--- a/src/Makefile_Elementary.am
+++ b/src/Makefile_Elementary.am
@@ -35,6 +35,8 @@ elm_public_eolian_files = \
lib/elementary/efl_ui_text.eo \
lib/elementary/efl_ui_popup.eo \
lib/elementary/efl_ui_popup_alert.eo \
+   lib/elementary/efl_ui_popup_alert_scroll.eo \
+   lib/elementary/efl_ui_popup_alert_scroll_part.eo \
lib/elementary/efl_ui_text_editable.eo \
lib/elementary/efl_ui_text_async.eo \
lib/elementary/efl_ui_textpath.eo \
@@ -289,6 +291,7 @@ includesunstable_HEADERS = \
lib/elementary/efl_ui_widget_image.h \
lib/elementary/efl_ui_popup_private.h \
lib/elementary/efl_ui_popup_alert_private.h \
+   lib/elementary/efl_ui_popup_alert_scroll_private.h \
lib/elementary/elm_widget_index.h \
lib/elementary/elm_widget_inwin.h \
lib/elementary/elm_widget_label.h \
@@ -700,6 +703,7 @@ lib_elementary_libelementary_la_SOURCES = \
lib/elementary/efl_ui_box_private.h \
lib/elementary/efl_ui_popup.c \
lib/elementary/efl_ui_popup_alert.c \
+   lib/elementary/efl_ui_popup_alert_scroll.c \
lib/elementary/efl_ui_grid.c \
lib/elementary/efl_ui_grid_static.c \
lib/elementary/efl_ui_grid_private.h \
diff --git a/src/bin/elementary/test.c b/src/bin/elementary/test.c
index aebb39a24f..f5450f2a15 100644
--- a/src/bin/elementary/test.c
+++ b/src/bin/elementary/test.c
@@ -276,6 +276,7 @@ void test_ui_clock(void *data, Evas_Object *obj, void 
*event_info);
 void test_popup(void *data, Evas_Object *obj, void *event_info);
 void test_efl_ui_popup(void *data, Evas_Object *obj, void *event_info);
 void test_efl_ui_popup_alert(void *data, Evas_Object *obj, void *event_info);
+void test_efl_ui_popup_alert_scroll(void *data, Evas_Object *obj, void 
*event_info);
 void test_dayselector(void *data, Evas_Object *obj, void *event_info);
 void test_image(void *data, Evas_Object *obj, void *event_info);
 void test_image_scale_type(void *data, Evas_Object *obj, void *event_info);
@@ -1046,6 +1047,7 @@ add_tests:
ADD_TEST(NULL, "Popups", "Popup", test_popup);
ADD_TEST(NULL, "Popups", "Efl UI Popup", test_efl_ui_popup);
ADD_TEST(NULL, "Popups", "Efl UI Popup Alert", test_efl_ui_popup_alert);
+   ADD_TEST(NULL, "Popups", "Efl UI Popup Alert Scroll", 
test_efl_ui_popup_alert_scroll);
 
//--//
ADD_TEST(NULL, "Times & Dates", "Calendar", test_calendar);
diff --git a/src/bin/elementary/test_popup.c b/src/bin/elementary/test_popup.c
index 4074862175..299644f17d 100644
--- a/src/bin/elementary/test_popup.c
+++ b/src/bin/elementary/test_popup.c
@@ -1136,3 +1136,39 @@ test_efl_ui_popup_alert(void *data EINA_UNUSED, 
Evas_Object *obj EINA_UNUSED, vo
 
efl_event_callback_add(efl_ui_popup, EFL_UI_POPUP_ALERT_EVENT_CLICKED, 
efl_ui_popup_alert_clicked_cb, NULL);
 }
+
+void
+test_efl_ui_popup_alert_scroll(void *data EINA_UNUSED, Evas_Object *obj 
EINA_UNUSED, void *event_info EINA_UNUSED)
+{
+   Evas_Object *win;
+   char buf[PATH_MAX];
+
+   win = elm_win_util_standard_add("Efl UI Popup Alert Scroll", "Efl UI Popup 
Alert Scroll");
+   elm_win_autodel_set(win, EINA_TRUE);
+
+   evas_object_resize(win, 320, 320);
+   evas_object_show(win);
+
+   Evas_Object *efl_ui_popup= efl_add(EFL_UI_POPUP_ALERT_SCROLL_CLASS, win);
+
+   efl_ui_popup_alert_title_set(efl_ui_popup, "title");
+
+   evas_object_resize(efl_ui_popup, 160, 160);
+   evas_object_show(efl_ui_popup);
+
+   Evas_Object *layout = elm_layout_add(efl_ui_popup);
+   snprintf(buf, sizeof(buf), "%s/objects/test.edj", elm_app_data_dir_get());
+   

[EGIT] [core/efl] master 01/01: Efl.Ui.Format: do format check once only.

2017-11-28 Thread Amitesh Singh
ami pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=e8ae4178d846136e9993828c3523002c24cdf015

commit e8ae4178d846136e9993828c3523002c24cdf015
Author: Amitesh Singh 
Date:   Tue Nov 28 17:05:31 2017 +0900

Efl.Ui.Format: do format check once only.
---
 src/lib/efl/interfaces/efl_ui_format.c | 27 ++-
 1 file changed, 14 insertions(+), 13 deletions(-)

diff --git a/src/lib/efl/interfaces/efl_ui_format.c 
b/src/lib/efl/interfaces/efl_ui_format.c
index 7fdbc49249..15212f168f 100644
--- a/src/lib/efl/interfaces/efl_ui_format.c
+++ b/src/lib/efl/interfaces/efl_ui_format.c
@@ -3,11 +3,6 @@
 
 #define ERR(...) EINA_LOG_DOM_ERR(EINA_LOG_DOMAIN_DEFAULT, __VA_ARGS__)
 
-typedef struct
-{
-   const char *template;
-} Efl_Ui_Format_Data;
-
 typedef enum _Format_Type
 {
FORMAT_TYPE_INVALID,
@@ -15,6 +10,12 @@ typedef enum _Format_Type
FORMAT_TYPE_INT
 } Format_Type;
 
+typedef struct
+{
+   const char *template;
+   Format_Type format_type;
+} Efl_Ui_Format_Data;
+
 static Eina_Bool
 _is_valid_digit(char x)
 {
@@ -78,7 +79,6 @@ _default_format_cb(void *data, Eina_Strbuf *str, const 
Eina_Value value)
 {
const Eina_Value_Type *type = eina_value_type_get();
Efl_Ui_Format_Data *sd = data;
-   int format_check_result;
 
if (type == EINA_VALUE_TYPE_TM)
  {
@@ -89,29 +89,27 @@ _default_format_cb(void *data, Eina_Strbuf *str, const 
Eina_Value value)
 return;
  }
 
-   format_check_result = _format_string_check(sd->template);
-
-   if (format_check_result == FORMAT_TYPE_INVALID)
+   if (sd->format_type == FORMAT_TYPE_INVALID)
  {
 ERR("Wrong String Format: %s", sd->template);
 return;
  }
 
-   if ((format_check_result == FORMAT_TYPE_DOUBLE)
+   if ((sd->format_type == FORMAT_TYPE_DOUBLE)
&& (type == EINA_VALUE_TYPE_DOUBLE))
  {
 double v;
 eina_value_get(, );
 eina_strbuf_append_printf(str, sd->template, v);
  }
-   else if ((format_check_result == FORMAT_TYPE_INT)
+   else if ((sd->format_type == FORMAT_TYPE_INT)
 && (type == EINA_VALUE_TYPE_INT))
  {
 int v;
 eina_value_get(, );
 eina_strbuf_append_printf(str, sd->template, v);
  }
-   else if ((format_check_result == FORMAT_TYPE_DOUBLE)
+   else if ((sd->format_type == FORMAT_TYPE_DOUBLE)
 && (type == EINA_VALUE_TYPE_INT))
  {
 int v;
@@ -122,7 +120,7 @@ _default_format_cb(void *data, Eina_Strbuf *str, const 
Eina_Value value)
 d_v = v;
 eina_strbuf_append_printf(str, sd->template, d_v);
  }
-   else if ((format_check_result == FORMAT_TYPE_INT)
+   else if ((sd->format_type == FORMAT_TYPE_INT)
 && (type == EINA_VALUE_TYPE_DOUBLE))
  {
 double v;
@@ -157,7 +155,10 @@ EOLIAN static void
 _efl_ui_format_format_string_set(Eo *obj, Efl_Ui_Format_Data *sd, const char 
*template)
 {
if (!template) return;
+
eina_stringshare_replace(>template, template);
+   sd->format_type = _format_string_check(sd->template);
+
efl_ui_format_cb_set(obj, sd, _default_format_cb, _default_format_free_cb);
 }
 

--