Re: [E-devel] Elm Main Menu

2016-11-29 Thread Jean-Philippe André
On 30 November 2016 at 13:55, Jean-Philippe André  wrote:

> Hi Andy,
>
> On 30 November 2016 at 11:35, Andrew Williams 
> wrote:
>
>> Hi,
>>
>> The mainmenu seems to work fine.
>> But since updating my edi window seems to shrink vertically after certain
>> key presses - any chance it's related?
>>
>
> Omg indeed. For me it's every key press and even just giving focus to EDI.
>
>
>> Not pointing fingers as I've pushed plenty in today but I didn't see it
>> until I pulled from origin I don't think.
>>
>
> You know it's got to be the frenchie's fault. And probably related to the
> main menu, too.
> I'll have a look at what's going on.
>

And it's magically gone before I could dive deep into this issue.
Please let me know if you still experience it.


>
> :)
>
>
>>
>> Andy
>>
>> On Tue, 29 Nov 2016 at 02:05, Jean-Philippe André 
>> wrote:
>>
>>> Hey Andy,
>>>
>>> I've reverted my revert and tried to fix my original patch.
>>> Let me know if it works fine for you!
>>>
>>> Thanks,
>>>
>>>
>>> On 29 November 2016 at 02:02, Andrew Williams 
>>> wrote:
>>>
>>> Great thanks, I love having my tab bar back :)
>>>
>>> Have a great day!
>>> Andy
>>>
>>> On Mon, 28 Nov 2016 at 00:57, Jean-Philippe André 
>>> wrote:
>>>
>>> Hi,
>>>
>>> On 28 November 2016 at 11:44, Carsten Haitzler 
>>> wrote:
>>>
>>> On Sun, 27 Nov 2016 15:58:42 + Andrew Williams 
>>> said:
>>>
>>> > Yup - that's what I see - right in elementary_test.
>>> >
>>> > Not started bisecting as I've not been coding for a few days. Might
>>> get a
>>> > chance today.
>>> > But of course the efl build time is quite an issue for this :-p
>>>
>>> it's very likely to do with jpeg's changes tot he elm win/efl ui win and
>>> theme
>>> and csd etc. 
>>>
>>>
>>> Yes, of course it was related. After playing a bit with the menu, trying
>>> to place it inside the framespace, I encountered many sizing issues
>>> (elm_menu and efl_ui_win both use custom layout functions). So I reverted
>>> some of my changes and the menu bar is back inside win.edc. For now.
>>> Hopefully I can fix the sizing issues as all the conformant features also
>>> need to move inside the window.
>>>
>>>
>>>
>>> > Andrew
>>> > On Sun, 27 Nov 2016 at 02:57, Carsten Haitzler 
>>> wrote:
>>> >
>>> > > On Sun, 27 Nov 2016 07:44:25 +0200 Daniel Zaoui <
>>> daniel.za...@samsung.com>
>>> > > said:
>>> > >
>>> > > > Hi Andrew,
>>> > > >
>>> > > > Do you see any issues in elementary_test? Cause seems ok there.
>>> Did you
>>> > > try
>>> > > > to bisect?
>>> > > >
>>> > > > Exactness doesn't cover main_menu. It should but the scenario has
>>> never
>>> > > been
>>> > > > recorded.
>>> > > >
>>> > > > JackDanielZ
>>> > >
>>> > > elm test does show the b0rk. resize the main menu test vertically.
>>> notice
>>> > > the
>>> > > label will slide underneath the main menu. this is the b0rk. :)
>>> > >
>>> > > > On Sat, 26 Nov 2016 15:20:13 +
>>> > > > Andrew Williams  wrote:
>>> > > >
>>> > > > > Hi all,
>>> > > > >
>>> > > > > In the last week (or two) the elm main menu has stopped
>>> reserving its
>>> > > > > own space and has started overlapping content. Does anyone know
>>> why
>>> > > > > this might be?
>>> > > > > Have the UI tests stopped being run or did the exactness not
>>> cover
>>> > > > > mainmenu layout? (Again, not sure where to look)
>>> > > > >
>>> > > > > Thanks for any tips,
>>> > > > > Andy
>>> > > > >
>>> > > 
>>> --
>>> > > > > ___
>>> > > > > enlightenment-devel mailing list
>>> > > > > enlightenment-devel@lists.sourceforge.net
>>> > > > > https://lists.sourceforge.net/lists/listinfo/enlightenment-devel
>>> > > > >
>>> > > > >
>>> > > >
>>> > > >
>>> > > >
>>> > > 
>>> --
>>> > > > ___
>>> > > > enlightenment-devel mailing list
>>> > > > enlightenment-devel@lists.sourceforge.net
>>> > > > https://lists.sourceforge.net/lists/listinfo/enlightenment-devel
>>> > > >
>>> > >
>>> > >
>>> > > --
>>> > > - Codito, ergo sum - "I code, therefore I am"
>>> --
>>> > > The Rasterman (Carsten Haitzler)ras...@rasterman.com
>>> > >
>>> > >
>>>
>>>
>>> --
>>> - Codito, ergo sum - "I code, therefore I am" --
>>> The Rasterman (Carsten Haitzler)ras...@rasterman.com
>>>
>>>
>>> 
>>> --
>>> ___
>>> enlightenment-devel mailing list
>>> enlightenment-devel@lists.sourceforge.net
>>> https://lists.sourceforge.net/lists/listinfo/enlightenment-devel
>>>
>>>
>>>
>>>
>>> --
>>> Jean-Philippe André
>>>
>>>
>>>
>>>
>>> --
>>> Jean-Philippe André
>>>
>>
>
>
> --
> Jean-Philippe André
>



-- 
Jean-Philippe André
--
___

[EGIT] [tools/edi] master 01/01: editor: Fix crash when resizing without any code open

2016-11-29 Thread Jean-Philippe Andre
jpeg pushed a commit to branch master.

http://git.enlightenment.org/tools/edi.git/commit/?id=886b6356bd3678ec2768c9a7a6084d82e51137ef

commit 886b6356bd3678ec2768c9a7a6084d82e51137ef
Author: Jean-Philippe Andre 
Date:   Wed Nov 30 15:22:45 2016 +0900

editor: Fix crash when resizing without any code open
---
 src/bin/editor/edi_editor.c | 12 +++-
 1 file changed, 11 insertions(+), 1 deletion(-)

diff --git a/src/bin/editor/edi_editor.c b/src/bin/editor/edi_editor.c
index a8b3c71..317c01d 100644
--- a/src/bin/editor/edi_editor.c
+++ b/src/bin/editor/edi_editor.c
@@ -553,11 +553,20 @@ _edi_editor_config_changed(void *data, int type 
EINA_UNUSED, void *event EINA_UN
return ECORE_CALLBACK_RENEW;
 }
 
+static void
+_editor_del_cb(void *data, Evas *e EINA_UNUSED, Evas_Object *o EINA_UNUSED, 
void *event_info EINA_UNUSED)
+{
+   Ecore_Event_Handler *ev_handler = data;
+
+   ecore_event_handler_del(ev_handler);
+}
+
 Evas_Object *
 edi_editor_add(Evas_Object *parent, Edi_Mainview_Item *item)
 {
Evas_Object *vbox, *box, *searchbar, *statusbar;
Evas_Modifier_Mask ctrl, shift, alt;
+   Ecore_Event_Handler *ev_handler;
Evas *e;
 
Elm_Code *code;
@@ -627,7 +636,8 @@ edi_editor_add(Evas_Object *parent, Edi_Mainview_Item *item)
(void)!evas_object_key_grab(widget, "f", ctrl, shift | alt, 1);
 
evas_object_data_set(vbox, "editor", editor);
-   ecore_event_handler_add(EDI_EVENT_CONFIG_CHANGED, 
_edi_editor_config_changed, widget);
+   ev_handler = ecore_event_handler_add(EDI_EVENT_CONFIG_CHANGED, 
_edi_editor_config_changed, widget);
+   evas_object_event_callback_add(vbox, EVAS_CALLBACK_DEL, _editor_del_cb, 
ev_handler);
 
return vbox;
 }

-- 




[EGIT] [core/efl] master 02/04: win: Add a little hack to fix E's logout/shutdown dialogs

2016-11-29 Thread Jean-Philippe ANDRÉ
jpeg pushed a commit to branch master.

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

commit a3d29602705968c6dcacccaadb9bb6ab7319a856
Author: Jean-Philippe Andre 
Date:   Tue Nov 29 18:20:10 2016 +0900

win: Add a little hack to fix E's logout/shutdown dialogs

E creates an edje object, sets it as resize_object, calls
restricted_calc and sets the resulting min size to the window.
But the window min size isn't taken into account when sizing
it, as the window sizes itself. I have no idea how this could
work before my changes.

E never actually requested the edje object to update its size
hints, so the window is left with an object of min size 0x0.

This patch is clearly a hack, but I can't really figure out
what would be the best or proper solution. Other elementary
widgets and containers seem to force edje object's update_hints.

Reproduction case: In E, menu, system, logout.
---
 src/lib/elementary/efl_ui_win.c | 4 
 1 file changed, 4 insertions(+)

diff --git a/src/lib/elementary/efl_ui_win.c b/src/lib/elementary/efl_ui_win.c
index 724d3bba..d667bef 100644
--- a/src/lib/elementary/efl_ui_win.c
+++ b/src/lib/elementary/efl_ui_win.c
@@ -7656,6 +7656,10 @@ elm_win_resize_object_add(Eo *obj, Evas_Object *subobj)
ret  = elm_widget_sub_object_add(obj, subobj);
ret &= (evas_object_box_append(sd->legacy.box, subobj) != NULL);
 
+   // Little hack for E (edje object set as resize object... but never updated)
+   if (efl_isa(subobj, EDJE_OBJECT_CLASS))
+ edje_object_update_hints_set(subobj, 1);
+
if (!ret)
  ERR("could not add sub object %p to window %p", subobj, obj);
 }

-- 




[EGIT] [core/efl] master 03/04: win: Implement max size hint support

2016-11-29 Thread Jean-Philippe ANDRÉ
jpeg pushed a commit to branch master.

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

commit 8a40c063cebb68e53ca32a0470a17f180821afb2
Author: Jean-Philippe Andre 
Date:   Wed Nov 30 13:55:54 2016 +0900

win: Implement max size hint support

evas_object_size_hint_max() would not work on a window, unless
it somehow managed to not size itself (which would be another
issue). This patch allows apps to call size_hint_max_set() on
a window. A test case is provided in elm_test (Dialog).

@feature
---
 src/bin/elementary/test_win_dialog.c | 57 --
 src/lib/elementary/efl_ui_win.c  | 59 +++-
 src/lib/elementary/efl_ui_win.eo |  1 +
 3 files changed, 101 insertions(+), 16 deletions(-)

diff --git a/src/bin/elementary/test_win_dialog.c 
b/src/bin/elementary/test_win_dialog.c
index a0924fd..a7c3bf3 100644
--- a/src/bin/elementary/test_win_dialog.c
+++ b/src/bin/elementary/test_win_dialog.c
@@ -3,8 +3,6 @@
 #endif
 #include 
 
-
-
 static void
 _bt_clicked_cb(void *data, Evas_Object *obj EINA_UNUSED, void *event_info 
EINA_UNUSED)
 {
@@ -52,6 +50,55 @@ _bt2_clicked_cb(void *data, Evas_Object *obj EINA_UNUSED, 
void *event_info EINA_
efl_gfx_visible_set(dia, EINA_TRUE);
 }
 
+static void
+_size_update(void *data, const Efl_Event *ev)
+{
+   int w, h, W, H, wc, hc, ww, hh;
+   char buf[2048];
+   Eo *dia = ev->object;
+   Eo *lbl = data;
+
+   efl_gfx_size_hint_combined_min_get(dia, &wc, &hc);
+   efl_gfx_size_hint_min_get(dia, &w, &h);
+   efl_gfx_size_hint_max_get(dia, &W, &H);
+   efl_gfx_size_get(dia, &ww, &hh);
+
+   sprintf(buf, "This is a dialog with min/max size"
+   "Min size: %dx%d (requested) %dx%d (effective)"
+   "Max size: %dx%d"
+   "Current size: %dx%d", w, h, wc, hc, W, H, ww, hh);
+   //efl_text_set(lbl, buf);
+   elm_object_text_set(lbl, buf);
+}
+
+static void
+_bt3_clicked_cb(void *data, Evas_Object *obj EINA_UNUSED, void *event_info 
EINA_UNUSED)
+{
+   Efl_Canvas_Object *dia, *lb, *parent = data;
+
+   dia = efl_add(EFL_UI_WIN_STANDARD_CLASS, parent,
+ efl_ui_win_type_set(efl_added, EFL_UI_WIN_DIALOG_BASIC),
+ efl_ui_win_name_set(efl_added, "window-dia-3"),
+ efl_ui_win_autodel_set(efl_added, EINA_TRUE),
+ efl_text_set(efl_added, "Min/Max Size Dialog"));
+
+   //lb = efl_add(EFL_UI_TEXT_CLASS, dia);,
+   lb = elm_label_add(dia);
+   efl_event_callback_add(dia, EFL_GFX_EVENT_CHANGE_SIZE_HINTS, _size_update, 
lb);
+   efl_event_callback_add(dia, EFL_GFX_EVENT_RESIZE, _size_update, lb);
+   elm_object_text_set(lb, "This is a Dialog Window");
+   efl_gfx_size_hint_weight_set(lb, 1.0, 1.0);
+
+   // Swallow in the label as the default content, this will make it visible.
+   efl_content_set(dia, lb);
+
+   // Set min & max size (app-side)
+   efl_gfx_size_hint_min_set(dia, ELM_SCALE_SIZE(0), ELM_SCALE_SIZE(100));
+   efl_gfx_size_hint_max_set(dia, ELM_SCALE_SIZE(800), ELM_SCALE_SIZE(600));
+
+   efl_gfx_visible_set(dia, EINA_TRUE);
+}
+
 void
 test_win_dialog(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void 
*event_info EINA_UNUSED)
 {
@@ -77,6 +124,12 @@ test_win_dialog(void *data EINA_UNUSED, Evas_Object *obj 
EINA_UNUSED, void *even
elm_box_pack_end(box, bt);
evas_object_show(bt);
 
+   bt = elm_button_add(win);
+   elm_object_text_set(bt, "Create a new dialog with min/max sizes");
+   evas_object_smart_callback_add(bt, "clicked", _bt3_clicked_cb, win);
+   elm_box_pack_end(box, bt);
+   evas_object_show(bt);
+
evas_object_resize(win, 400, 400);
evas_object_show(win);
 }
diff --git a/src/lib/elementary/efl_ui_win.c b/src/lib/elementary/efl_ui_win.c
index d667bef..7b4799a 100644
--- a/src/lib/elementary/efl_ui_win.c
+++ b/src/lib/elementary/efl_ui_win.c
@@ -5,6 +5,7 @@
 #define ELM_INTERFACE_ATSPI_ACCESSIBLE_PROTECTED
 #define ELM_INTERFACE_ATSPI_WIDGET_ACTION_PROTECTED
 #define EFL_INPUT_EVENT_PROTECTED
+#define EFL_GFX_SIZE_HINT_PROTECTED
 
 #include 
 #include 
@@ -180,6 +181,7 @@ struct _Efl_Ui_Win_Data
int  aspect_w, aspect_h; /* used for the get API */
int  size_base_w, size_base_h;
int  size_step_w, size_step_h;
+   int  max_w, max_h;
int  norender;
int  modal_count;
int  response;
@@ -248,6 +250,7 @@ struct _Efl_Ui_Win_Data
Eina_Boolnoblank : 1;
Eina_Booltheme_alpha : 1; /**< alpha value fetched by a theme. this has 
higher priority than application_alpha */
Eina_Boolapplication_alpha : 1; /**< alpha value set by an 
elm_win_alpha_set() api. this has lower priority than theme_alpha */
+   Eina_Booltmp_updating_hints : 1;
 };
 
 struct _Input_Pointer_Iterator
@@ -1534,8 +1537,8 @@ _elm_win_state_change(Ecore_Evas *ee)
  }
if (ch_wm_rotation)
  {
-evas_object_size_hint_min_set(obj, -1, -1);
-evas_ob

[EGIT] [core/efl] master 01/04: win: Fix opaque regions for Wayland

2016-11-29 Thread Jean-Philippe ANDRÉ
jpeg pushed a commit to branch master.

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

commit 2102ed9b7c7dbcda7f67379f42ed9dc97dfbff9f
Author: Jean-Philippe Andre 
Date:   Wed Nov 30 10:51:51 2016 +0900

win: Fix opaque regions for Wayland

In Wayland, an opaque window can still have shadow borders, and
only needs to set the opaque_region appropriately. In X on the
other hand, a window needs to be flagged as alpha in order to be
properly blended (otherwise you'd get black borders).

Thanks Derek for the report!

This fixes c91360fcbd3ca
---
 src/lib/elementary/efl_ui_win.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/lib/elementary/efl_ui_win.c b/src/lib/elementary/efl_ui_win.c
index 8571c81..724d3bba 100644
--- a/src/lib/elementary/efl_ui_win.c
+++ b/src/lib/elementary/efl_ui_win.c
@@ -414,10 +414,10 @@ _elm_win_apply_alpha(Eo *obj, Efl_Ui_Win_Data *sd)
  }
else
  {
-enabled |= (sd->csd.need && !sd->fullscreen);
 #ifdef HAVE_ELEMENTARY_X
 if (sd->x.xwin)
   {
+ enabled |= (sd->csd.need && !sd->fullscreen);
  if (enabled)
{
   if (!ecore_x_screen_is_composited(0))

-- 




[EGIT] [core/efl] master 04/04: theme: Add bevel around background (window)

2016-11-29 Thread Jean-Philippe ANDRÉ
jpeg pushed a commit to branch master.

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

commit 0dde22488a3f19c04998d461fb8cf2c40b4c90cf
Author: Jean-Philippe Andre 
Date:   Wed Nov 30 15:06:09 2016 +0900

theme: Add bevel around background (window)

This should fix (some) issues with exactness.
---
 data/elementary/themes/edc/elm/border.edc | 27 +++
 src/lib/elementary/efl_ui_win.c   |  8 +++-
 2 files changed, 34 insertions(+), 1 deletion(-)

diff --git a/data/elementary/themes/edc/elm/border.edc 
b/data/elementary/themes/edc/elm/border.edc
index 24a942f..3ff013b 100644
--- a/data/elementary/themes/edc/elm/border.edc
+++ b/data/elementary/themes/edc/elm/border.edc
@@ -91,6 +91,23 @@ group { name: "elm/border/base/default";
  required; // @since 1.19
  clip: "client_clip";
   }
+  image { "background_bevel";
+ desc { "default";
+image {
+   normal: "bevel_dark_out.png";
+   border: 1 1 1 1;
+   middle: 0;
+}
+fill.smooth: 0;
+rel.to: "elm.spacer.content";
+visible: 0;
+ }
+ desc { "visible";
+inherit: "default";
+visible: 1;
+ }
+  }
+
   /* main menu */
   rect { "menu_bg";
  desc { "default";
@@ -708,6 +725,16 @@ group { name: "elm/border/base/default";
  target: "elm.rect.background";
   }
   program {
+ signal: "elm,state,background,standard,on"; source: "elm";
+ action: STATE_SET "visible";
+ target: "background_bevel";
+  }
+  program {
+ signal: "elm,state,background,standard,off"; source: "elm";
+ action: STATE_SET "default";
+ target: "background_bevel";
+  }
+  program {
  signal: "elm,action,focus"; source: "elm";
  action: STATE_SET "focused";
  target: "top";
diff --git a/src/lib/elementary/efl_ui_win.c b/src/lib/elementary/efl_ui_win.c
index 7b4799a..0e971c7 100644
--- a/src/lib/elementary/efl_ui_win.c
+++ b/src/lib/elementary/efl_ui_win.c
@@ -214,6 +214,7 @@ struct _Efl_Ui_Win_Data
   Eina_Bool need_shadow : 1; /**< if true, application draws its csd and 
shadow */
   Eina_Bool need_borderless : 1;
   Eina_Bool need_bg_solid : 1;
+  Eina_Bool need_bg_standard : 1;
   Eina_Bool need_menu : 1;
   Eina_Bool need_unresizable : 1;
   Eina_Bool cur_borderless : 1;
@@ -221,6 +222,7 @@ struct _Efl_Ui_Win_Data
   Eina_Bool cur_focus : 1;
   Eina_Bool cur_maximized : 1;
   Eina_Bool cur_bg_solid : 1;
+  Eina_Bool cur_bg_standard : 1;
   Eina_Bool cur_menu : 1;
   Eina_Bool cur_unresizable : 1;
   Eina_Bool wayland : 1;
@@ -4156,7 +4158,7 @@ static void
 _elm_win_frame_style_update(Efl_Ui_Win_Data *sd, Eina_Bool force_emit, 
Eina_Bool calc)
 {
Eina_Bool borderless, maximized, shadow, focus, bg_solid, menu, unresizable,
- alpha;
+ alpha, bg_standard;
Eina_Bool changed = EINA_FALSE;
 
if (!sd->frame_obj)
@@ -4186,6 +4188,7 @@ _elm_win_frame_style_update(Efl_Ui_Win_Data *sd, 
Eina_Bool force_emit, Eina_Bool
if (alpha && borderless) shadow = 0;
focus = ecore_evas_focus_get(sd->ee);
bg_solid = sd->csd.need_bg_solid;
+   bg_standard = sd->csd.need_bg_standard;
unresizable = sd->csd.need_unresizable;
menu = sd->csd.need_menu;
 
@@ -4212,6 +4215,7 @@ _elm_win_frame_style_update(Efl_Ui_Win_Data *sd, 
Eina_Bool force_emit, Eina_Bool
STATE_SET(maximized, "elm,state,maximized", "elm,state,unmaximized");
STATE_SET(focus, "elm,action,focus", "elm,action,unfocus");
STATE_SET(bg_solid, "elm,state,background,solid,on", 
"elm,state,background,solid,off");
+   STATE_SET(bg_standard, "elm,state,background,standard,on", 
"elm,state,background,standard,off");
STATE_SET(unresizable, "elm,state,unresizable,on", 
"elm,state,unresizable,off");
STATE_SET(menu, "elm,action,show_menu", "elm,action,hide_menu");
 
@@ -6296,6 +6300,7 @@ _elm_win_standard_init(Eo *obj)
 
ELM_SAFE_DEL(sd->bg);
 
+   sd->csd.need_bg_standard = 1;
if (!_elm_win_bg_must_swallow(sd))
  {
 sd->csd.need_bg_solid = EINA_TRUE;
@@ -6332,6 +6337,7 @@ _efl_ui_win_content_set(Eo *obj, Efl_Ui_Win_Data *sd, 
const char *part, Eo *cont
  }
else if (eina_streq(part, "background"))
  {
+sd->csd.need_bg_standard = 0;
 if (sd->bg == content) return EINA_TRUE;
 if (!_elm_win_bg_set(sd, content))
   goto err;

-- 




[EGIT] [core/efl] master 01/01: edje_calc: round the scaled value when it is casted to int type.

2016-11-29 Thread Jaehwan Kim
jaehwan pushed a commit to branch master.

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

commit 7cce8ae40d7b9d607448135f0384605395537c32
Author: Jaehwan Kim 
Date:   Tue Nov 29 14:03:20 2016 +0900

edje_calc: round the scaled value when it is casted to int type.

It rounds the value for the more precious calculation when the scaled
value is casted to int type.
---
 src/lib/edje/edje_calc.c| 16 
 src/lib/edje/edje_private.h |  2 ++
 2 files changed, 10 insertions(+), 8 deletions(-)

diff --git a/src/lib/edje/edje_calc.c b/src/lib/edje/edje_calc.c
index 1d97be9..251dad5 100644
--- a/src/lib/edje/edje_calc.c
+++ b/src/lib/edje/edje_calc.c
@@ -2266,7 +2266,7 @@ _edje_part_recalc_single_min_max(FLOAT_T sc,
  }
 
*minw = mnw;
-   if (ep->part->scale) *minw = TO_INT(SCALE(sc, *minw));
+   if (ep->part->scale) *minw = TO_INT_ROUND(SCALE(sc, *minw));
if ((ep->type == EDJE_RP_TYPE_SWALLOW) &&
(ep->typedata.swallow))
  {
@@ -2293,7 +2293,7 @@ _edje_part_recalc_single_min_max(FLOAT_T sc,
  *maxw = mxw;
  if (*maxw > 0)
{
-  if (ep->part->scale) *maxw = TO_INT(SCALE(sc, *maxw));
+  if (ep->part->scale) *maxw = TO_INT_ROUND(SCALE(sc, *maxw));
   if (*maxw < 1) *maxw = 1;
}
   }
@@ -2306,7 +2306,7 @@ _edje_part_recalc_single_min_max(FLOAT_T sc,
   *maxw = mxw;
   if (*maxw > 0)
 {
-   if (ep->part->scale) *maxw = TO_INT(SCALE(sc, *maxw));
+   if (ep->part->scale) *maxw = TO_INT_ROUND(SCALE(sc, 
*maxw));
if (*maxw < 1) *maxw = 1;
 }
   if (ep->typedata.swallow->swallow_params.max.w < *maxw)
@@ -2319,7 +2319,7 @@ _edje_part_recalc_single_min_max(FLOAT_T sc,
 *maxw = mxw;
 if (*maxw > 0)
   {
- if (ep->part->scale) *maxw = TO_INT(SCALE(sc, *maxw));
+ if (ep->part->scale) *maxw = TO_INT_ROUND(SCALE(sc, *maxw));
  if (*maxw < 1) *maxw = 1;
   }
  }
@@ -2331,7 +2331,7 @@ _edje_part_recalc_single_min_max(FLOAT_T sc,
  }
 
*minh = mnh;
-   if (ep->part->scale) *minh = TO_INT(SCALE(sc, *minh));
+   if (ep->part->scale) *minh = TO_INT_ROUND(SCALE(sc, *minh));
if ((ep->type == EDJE_RP_TYPE_SWALLOW) &&
(ep->typedata.swallow))
  {
@@ -2358,7 +2358,7 @@ _edje_part_recalc_single_min_max(FLOAT_T sc,
  *maxh = mxh;
  if (*maxh > 0)
{
-  if (ep->part->scale) *maxh = TO_INT(SCALE(sc, *maxh));
+  if (ep->part->scale) *maxh = TO_INT_ROUND(SCALE(sc, *maxh));
   if (*maxh < 1) *maxh = 1;
}
   }
@@ -2371,7 +2371,7 @@ _edje_part_recalc_single_min_max(FLOAT_T sc,
   *maxh = mxh;
   if (*maxh > 0)
 {
-   if (ep->part->scale) *maxh = TO_INT(SCALE(sc, *maxh));
+   if (ep->part->scale) *maxh = TO_INT_ROUND(SCALE(sc, 
*maxh));
if (*maxh < 1) *maxh = 1;
 }
   if (ep->typedata.swallow->swallow_params.max.h < *maxh)
@@ -2384,7 +2384,7 @@ _edje_part_recalc_single_min_max(FLOAT_T sc,
 *maxh = mxh;
 if (*maxh > 0)
   {
- if (ep->part->scale) *maxh = TO_INT(SCALE(sc, *maxh));
+ if (ep->part->scale) *maxh = TO_INT_ROUND(SCALE(sc, *maxh));
  if (*maxh < 1) *maxh = 1;
   }
  }
diff --git a/src/lib/edje/edje_private.h b/src/lib/edje/edje_private.h
index 3e610d2..9a0fd21 100644
--- a/src/lib/edje/edje_private.h
+++ b/src/lib/edje/edje_private.h
@@ -148,6 +148,7 @@ EAPI extern int _edje_default_log_dom ;
 #define FROM_DOUBLE(a) eina_f32p32_double_from(a)
 #define FROM_INT(a) eina_f32p32_int_from(a)
 #define TO_INT(a) eina_f32p32_int_to(a)
+#define TO_INT_ROUND(a) eina_f32p32_int_to(ADD(a, FROM_DOUBLE(0.5)))
 #define ZERO 0
 #define COS(a) eina_f32p32_cos(a)
 #define SIN(a) eina_f32p32_sin(a)
@@ -168,6 +169,7 @@ EAPI extern int _edje_default_log_dom ;
 #define FROM_DOUBLE(a) (a)
 #define FROM_INT(a) (double)(a)
 #define TO_INT(a) (int)(a)
+#define TO_INT_ROUND(a) (int)(a + 0.5)
 #define ZERO 0.0
 #define COS(a) cos(a)
 #define SIN(a) sin(a)

-- 




Re: [E-devel] Elm Main Menu

2016-11-29 Thread Jean-Philippe André
Hi Andy,

On 30 November 2016 at 11:35, Andrew Williams  wrote:

> Hi,
>
> The mainmenu seems to work fine.
> But since updating my edi window seems to shrink vertically after certain
> key presses - any chance it's related?
>

Omg indeed. For me it's every key press and even just giving focus to EDI.


> Not pointing fingers as I've pushed plenty in today but I didn't see it
> until I pulled from origin I don't think.
>

You know it's got to be the frenchie's fault. And probably related to the
main menu, too.
I'll have a look at what's going on.

:)


>
> Andy
>
> On Tue, 29 Nov 2016 at 02:05, Jean-Philippe André 
> wrote:
>
>> Hey Andy,
>>
>> I've reverted my revert and tried to fix my original patch.
>> Let me know if it works fine for you!
>>
>> Thanks,
>>
>>
>> On 29 November 2016 at 02:02, Andrew Williams 
>> wrote:
>>
>> Great thanks, I love having my tab bar back :)
>>
>> Have a great day!
>> Andy
>>
>> On Mon, 28 Nov 2016 at 00:57, Jean-Philippe André 
>> wrote:
>>
>> Hi,
>>
>> On 28 November 2016 at 11:44, Carsten Haitzler 
>> wrote:
>>
>> On Sun, 27 Nov 2016 15:58:42 + Andrew Williams 
>> said:
>>
>> > Yup - that's what I see - right in elementary_test.
>> >
>> > Not started bisecting as I've not been coding for a few days. Might get
>> a
>> > chance today.
>> > But of course the efl build time is quite an issue for this :-p
>>
>> it's very likely to do with jpeg's changes tot he elm win/efl ui win and
>> theme
>> and csd etc. 
>>
>>
>> Yes, of course it was related. After playing a bit with the menu, trying
>> to place it inside the framespace, I encountered many sizing issues
>> (elm_menu and efl_ui_win both use custom layout functions). So I reverted
>> some of my changes and the menu bar is back inside win.edc. For now.
>> Hopefully I can fix the sizing issues as all the conformant features also
>> need to move inside the window.
>>
>>
>>
>> > Andrew
>> > On Sun, 27 Nov 2016 at 02:57, Carsten Haitzler 
>> wrote:
>> >
>> > > On Sun, 27 Nov 2016 07:44:25 +0200 Daniel Zaoui <
>> daniel.za...@samsung.com>
>> > > said:
>> > >
>> > > > Hi Andrew,
>> > > >
>> > > > Do you see any issues in elementary_test? Cause seems ok there. Did
>> you
>> > > try
>> > > > to bisect?
>> > > >
>> > > > Exactness doesn't cover main_menu. It should but the scenario has
>> never
>> > > been
>> > > > recorded.
>> > > >
>> > > > JackDanielZ
>> > >
>> > > elm test does show the b0rk. resize the main menu test vertically.
>> notice
>> > > the
>> > > label will slide underneath the main menu. this is the b0rk. :)
>> > >
>> > > > On Sat, 26 Nov 2016 15:20:13 +
>> > > > Andrew Williams  wrote:
>> > > >
>> > > > > Hi all,
>> > > > >
>> > > > > In the last week (or two) the elm main menu has stopped reserving
>> its
>> > > > > own space and has started overlapping content. Does anyone know
>> why
>> > > > > this might be?
>> > > > > Have the UI tests stopped being run or did the exactness not cover
>> > > > > mainmenu layout? (Again, not sure where to look)
>> > > > >
>> > > > > Thanks for any tips,
>> > > > > Andy
>> > > > >
>> > > 
>> --
>> > > > > ___
>> > > > > enlightenment-devel mailing list
>> > > > > enlightenment-devel@lists.sourceforge.net
>> > > > > https://lists.sourceforge.net/lists/listinfo/enlightenment-devel
>> > > > >
>> > > > >
>> > > >
>> > > >
>> > > >
>> > > 
>> --
>> > > > ___
>> > > > enlightenment-devel mailing list
>> > > > enlightenment-devel@lists.sourceforge.net
>> > > > https://lists.sourceforge.net/lists/listinfo/enlightenment-devel
>> > > >
>> > >
>> > >
>> > > --
>> > > - Codito, ergo sum - "I code, therefore I am"
>> --
>> > > The Rasterman (Carsten Haitzler)ras...@rasterman.com
>> > >
>> > >
>>
>>
>> --
>> - Codito, ergo sum - "I code, therefore I am" --
>> The Rasterman (Carsten Haitzler)ras...@rasterman.com
>>
>>
>> 
>> --
>> ___
>> enlightenment-devel mailing list
>> enlightenment-devel@lists.sourceforge.net
>> https://lists.sourceforge.net/lists/listinfo/enlightenment-devel
>>
>>
>>
>>
>> --
>> Jean-Philippe André
>>
>>
>>
>>
>> --
>> Jean-Philippe André
>>
>


-- 
Jean-Philippe André
--
___
enlightenment-devel mailing list
enlightenment-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel


[EGIT] [tools/enventor] master 01/01: edc_navigator: Add dragable bar for edc_navigator

2016-11-29 Thread YeongJong Lee
hermet pushed a commit to branch master.

http://git.enlightenment.org/tools/enventor.git/commit/?id=d9cbfba323c10c7e29defb2cad1daafb2faa4594

commit d9cbfba323c10c7e29defb2cad1daafb2faa4594
Author: YeongJong Lee 
Date:   Wed Nov 30 13:25:56 2016 +0900

edc_navigator: Add dragable bar for edc_navigator

Summary:
edc_navigator can be resized. in order to prevent collision
between edc_navigator and file_browser, limit the size to half each other.

Test Plan:
1. Run enventor
2-1. Drag the bar between text editor and edc_navigator
2-2. Toggle edc_navigator using key F10
3. Check edc_navigator size is saved after restart envertor

Reviewers: Jaehyun_Cho, Hermet

Differential Revision: https://phab.enlightenment.org/D4439
---
 data/themes/default/layout_common.edc | 172 +++---
 src/bin/base_gui.c|  16 
 src/bin/config_data.c |  22 +
 src/bin/edc_navigator.c   |  75 +++
 src/include/common.h  |   2 +-
 src/include/config_data.h |   2 +
 src/include/edc_navigator.h   |   4 +
 7 files changed, 281 insertions(+), 12 deletions(-)

diff --git a/data/themes/default/layout_common.edc 
b/data/themes/default/layout_common.edc
index 2c02872..061a38d 100644
--- a/data/themes/default/layout_common.edc
+++ b/data/themes/default/layout_common.edc
@@ -2422,28 +2422,26 @@ group { "main_layout";
to_y: "elm.swallow.file_tab";
 }
 align: 0 0;
-min: 200 0;
-max: 0 -1;
 fixed: 1 0;
 visible: 0;
  }
  desc { "visible";
 inherit: "default";
-align: 1 0;
 rel1 {
relative: 1.0 0.0;
-}
-rel2 {
-   relative: 1.0 0.0;
-   to_y: "elm.swallow.file_tab";
+   to: "elm.bar.right";
 }
 visible: 1;
  }
   }
   spacer { "whole_left";
  desc { "default";
-rel2.relative: 0.0 1.0;
-rel2.to: "elm.swallow.edc_navigator";
+rel2.relative: 0.5 1.0;
+ }
+  }
+  spacer { "whole_right";
+ desc { "default";
+rel1.relative: 0.5 0.0;
  }
   }
   spacer { "elm.bar.left";
@@ -2455,8 +2453,21 @@ group { "main_layout";
 max: 0 9;
 min: 0 14;
 fixed: 1 1;
-rel1.relative: 0.0 0.5;
-rel2.relative: 1.0 0.5;
+rel1.relative: 0.0 0.0;
+rel2.relative: 1.0 1.0;
+ }
+  }
+  spacer { "elm.bar.right";
+ dragable { confine: "whole_right";
+x: 1 1 1;
+y: 0 0 0;
+ }
+ desc { "default";
+max: 0 9;
+min: 0 14;
+fixed: 1 1;
+rel1.relative: 0.0 0.0;
+rel2.relative: 1.0 1.0;
  }
   }
   spacer { "elm.bar.event_left";
@@ -2467,6 +2478,14 @@ group { "main_layout";
 rel2.relative: 1.0 0.0;
  }
   }
+  spacer { "elm.bar.event_right";
+ desc { "default";
+rel1.to_x: "elm.bar.right";
+rel2.to_x: "elm.bar.right";
+rel2.to_y: "elm.swallow.file_tab";
+rel2.relative: 1.0 0.0;
+ }
+  }
   swallow { "bar_left";
  dragable.events: "elm.bar.left";
  desc { "default";
@@ -2480,6 +2499,19 @@ group { "main_layout";
 color: 0 0 0 0;
  }
   }
+  swallow { "bar_right";
+ dragable.events: "elm.bar.right";
+ desc { "default";
+min: 10 0;
+max: 9 9;
+fixed: 1 0;
+rel1.to_x: "elm.bar.event_right";
+rel1.relative: 0.0 0.25;
+rel2.to: "elm.bar.event_right";
+rel2.relative: 1.0 0.75;
+color: 0 0 0 0;
+ }
+  }
   rect { "bar_left1";
  repeat_events: 1;
  desc { "default";
@@ -2500,6 +2532,26 @@ group { "main_layout";
 color: 0 0 0 0;
  }
   }
+  rect { "bar_right1";
+ repeat_events: 1;
+ desc { "default";
+fixed: 1 1;
+rel1.to: "bar_right";
+rel2.to: "bar_right";
+rel2.relative: 0.5 1.0;
+color: 0 0 0 0;
+ }
+  }
+  rect { "bar_right2";
+ repeat_events: 1;
+ desc { "default";
+fixed: 1 1;
+rel1.to: "bar_right";
+rel1.relative: 0.5 0.0;
+rel2.to: "bar_right";
+color: 0 0 0 0;
+ }
+  }
   image { "glow1a_left";
  nomouse;
  desc { "default";
@@ -2566,6 +2618,72 @@ group { "main_layout";
 color: 255 255 255 255;
  }
   }
+  image { "glow1a_right";
+ nomouse;
+ desc { "default";
+image.n

[EGIT] [core/efl] master 01/01: elm_calendar: Use the flag already declared.

2016-11-29 Thread Woochan Lee
hermet pushed a commit to branch master.

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

commit 7b97d550048b469473e1641b6c1c8b893099cc41
Author: Woochan Lee 
Date:   Wed Nov 30 13:24:37 2016 +0900

elm_calendar: Use the flag already declared.

Summary: Oops, i missed use it in previous 
commit(6c04755a922d396356a561b85e010105e6ff61ae)

Reviewers: cedric, jpeg, woohyun, Hermet

Reviewed By: Hermet

Subscribers: cedric, jpeg

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

diff --git a/src/lib/elementary/elm_calendar.c 
b/src/lib/elementary/elm_calendar.c
index 14cc386..971f893 100644
--- a/src/lib/elementary/elm_calendar.c
+++ b/src/lib/elementary/elm_calendar.c
@@ -1550,7 +1550,7 @@ _key_action_move(Evas_Object *obj, const char *params)
//Otherwise, give focus to dec_btn_month.
if (sd->focused_it > (ELM_DAY_LAST / 2))
  //Double spinner case.
- if (edje_object_part_exists(wd->resize_obj, 
ELM_CALENDAR_BUTTON_YEAR_RIGHT))
+ if (double_spinner)
elm_object_focus_set(sd->inc_btn_year, EINA_TRUE);
  else
elm_object_focus_set(sd->inc_btn_month, EINA_TRUE);
@@ -1571,7 +1571,7 @@ _key_action_move(Evas_Object *obj, const char *params)
  {
 if (sd->focused_it > (ELM_DAY_LAST + (ELM_DAY_LAST 
/ 2)))
   //Double spinner case.
-  if (edje_object_part_exists(wd->resize_obj, 
ELM_CALENDAR_BUTTON_YEAR_RIGHT))
+  if (double_spinner)
 elm_object_focus_set(sd->inc_btn_year, 
EINA_TRUE);
   else
 elm_object_focus_set(sd->inc_btn_month, 
EINA_TRUE);

-- 




[EGIT] [core/efl] master 01/01: edje_external Multibuttonentry: Fix useless logic.

2016-11-29 Thread Woochan Lee
hermet pushed a commit to branch master.

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

commit 9eea2ddb9efaa26d70feeb080d96aefd903ed8d2
Author: Woochan Lee 
Date:   Wed Nov 30 13:22:29 2016 +0900

edje_external Multibuttonentry: Fix useless logic.

Summary:
Elm_Params_Multibuttonentry *mem = NULL;
if (!mem) return NULL;

Above code meaning that return null always... it's not intended i think.

Fix this weird code.

Reviewers: Hermet

Reviewed By: Hermet

Subscribers: cedric, jpeg

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

diff --git a/src/edje_external/elementary/elm_multibuttonentry.c 
b/src/edje_external/elementary/elm_multibuttonentry.c
index 5c62a85..cd6d0a7 100644
--- a/src/edje_external/elementary/elm_multibuttonentry.c
+++ b/src/edje_external/elementary/elm_multibuttonentry.c
@@ -88,7 +88,7 @@ external_multibuttonentry_params_parse(void *data EINA_UNUSED,
Edje_External_Param *param;
const Eina_List *l;
 
-   //mem = external_common_params_parse(Elm_Params_Multibuttonentry, data, 
obj, params);
+   mem = calloc(1, sizeof(Elm_Params_Multibuttonentry));
if (!mem)
  return NULL;
 

-- 




[EGIT] [tools/edi] master 01/01: fix extension lookup so we can see .eo files again

2016-11-29 Thread Andy Williams
ajwillia-ms pushed a commit to branch master.

http://git.enlightenment.org/tools/edi.git/commit/?id=65cda5ee4d363953b1e2fa3142336b54d477760f

commit 65cda5ee4d363953b1e2fa3142336b54d477760f
Author: Andy Williams 
Date:   Wed Nov 30 04:00:48 2016 +

fix extension lookup so we can see .eo files again
---
 src/lib/edi_build_provider_make.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/src/lib/edi_build_provider_make.c 
b/src/lib/edi_build_provider_make.c
index a0daa1e..bdcbc20 100644
--- a/src/lib/edi_build_provider_make.c
+++ b/src/lib/edi_build_provider_make.c
@@ -38,10 +38,10 @@ _make_file_hidden_is(const char *file)
if (!file || strlen(file) == 0)
  return EINA_FALSE;
 
-   if (eina_str_has_extension(file, "o") || eina_str_has_extension(file, "so") 
||
-   eina_str_has_extension(file, "lo"))
+   if (eina_str_has_extension(file, ".o") || eina_str_has_extension(file, 
".so") ||
+   eina_str_has_extension(file, ".lo"))
  return EINA_TRUE;
-   if (eina_str_has_extension(file, "a") || eina_str_has_extension(file, "la"))
+   if (eina_str_has_extension(file, ".a") || eina_str_has_extension(file, 
".la"))
  return EINA_TRUE;
 
return EINA_FALSE;

-- 




Re: [E-devel] Elm Main Menu

2016-11-29 Thread Andrew Williams
Hi,

The mainmenu seems to work fine.
But since updating my edi window seems to shrink vertically after certain
key presses - any chance it's related?

Not pointing fingers as I've pushed plenty in today but I didn't see it
until I pulled from origin I don't think.

Andy
On Tue, 29 Nov 2016 at 02:05, Jean-Philippe André  wrote:

> Hey Andy,
>
> I've reverted my revert and tried to fix my original patch.
> Let me know if it works fine for you!
>
> Thanks,
>
>
> On 29 November 2016 at 02:02, Andrew Williams 
> wrote:
>
> Great thanks, I love having my tab bar back :)
>
> Have a great day!
> Andy
>
> On Mon, 28 Nov 2016 at 00:57, Jean-Philippe André 
> wrote:
>
> Hi,
>
> On 28 November 2016 at 11:44, Carsten Haitzler 
> wrote:
>
> On Sun, 27 Nov 2016 15:58:42 + Andrew Williams 
> said:
>
> > Yup - that's what I see - right in elementary_test.
> >
> > Not started bisecting as I've not been coding for a few days. Might get a
> > chance today.
> > But of course the efl build time is quite an issue for this :-p
>
> it's very likely to do with jpeg's changes tot he elm win/efl ui win and
> theme
> and csd etc. 
>
>
> Yes, of course it was related. After playing a bit with the menu, trying
> to place it inside the framespace, I encountered many sizing issues
> (elm_menu and efl_ui_win both use custom layout functions). So I reverted
> some of my changes and the menu bar is back inside win.edc. For now.
> Hopefully I can fix the sizing issues as all the conformant features also
> need to move inside the window.
>
>
>
> > Andrew
> > On Sun, 27 Nov 2016 at 02:57, Carsten Haitzler 
> wrote:
> >
> > > On Sun, 27 Nov 2016 07:44:25 +0200 Daniel Zaoui <
> daniel.za...@samsung.com>
> > > said:
> > >
> > > > Hi Andrew,
> > > >
> > > > Do you see any issues in elementary_test? Cause seems ok there. Did
> you
> > > try
> > > > to bisect?
> > > >
> > > > Exactness doesn't cover main_menu. It should but the scenario has
> never
> > > been
> > > > recorded.
> > > >
> > > > JackDanielZ
> > >
> > > elm test does show the b0rk. resize the main menu test vertically.
> notice
> > > the
> > > label will slide underneath the main menu. this is the b0rk. :)
> > >
> > > > On Sat, 26 Nov 2016 15:20:13 +
> > > > Andrew Williams  wrote:
> > > >
> > > > > Hi all,
> > > > >
> > > > > In the last week (or two) the elm main menu has stopped reserving
> its
> > > > > own space and has started overlapping content. Does anyone know why
> > > > > this might be?
> > > > > Have the UI tests stopped being run or did the exactness not cover
> > > > > mainmenu layout? (Again, not sure where to look)
> > > > >
> > > > > Thanks for any tips,
> > > > > Andy
> > > > >
> > >
> --
> > > > > ___
> > > > > enlightenment-devel mailing list
> > > > > enlightenment-devel@lists.sourceforge.net
> > > > > https://lists.sourceforge.net/lists/listinfo/enlightenment-devel
> > > > >
> > > > >
> > > >
> > > >
> > > >
> > >
> --
> > > > ___
> > > > enlightenment-devel mailing list
> > > > enlightenment-devel@lists.sourceforge.net
> > > > https://lists.sourceforge.net/lists/listinfo/enlightenment-devel
> > > >
> > >
> > >
> > > --
> > > - Codito, ergo sum - "I code, therefore I am"
> --
> > > The Rasterman (Carsten Haitzler)ras...@rasterman.com
> > >
> > >
>
>
> --
> - Codito, ergo sum - "I code, therefore I am" --
> The Rasterman (Carsten Haitzler)ras...@rasterman.com
>
>
>
> --
> ___
> enlightenment-devel mailing list
> enlightenment-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/enlightenment-devel
>
>
>
>
> --
> Jean-Philippe André
>
>
>
>
> --
> Jean-Philippe André
>
--
___
enlightenment-devel mailing list
enlightenment-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel


[EGIT] [core/efl] master 01/01: evas: bug fix in bmp loader

2016-11-29 Thread Jaeun Choi
eunue pushed a commit to branch master.

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

commit b9965ffd8f36671a4ba839411b72d00f402749ba
Author: Jaeun Choi 
Date:   Tue Nov 29 23:27:18 2016 +0900

evas: bug fix in bmp loader

when the DIB header is BITMAPINFOHEADER (size 40),
a bitmap file has alpha channel only if the compression method is 
BI_ALPHABITFIELDS (= 6).
the original code enabled alpha channel when the compression method was 
BI_RGB (= 0),
which made an opaque bmp image loaded as a transparent one.

@fix
---
 src/modules/evas/image_loaders/bmp/evas_image_load_bmp.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/modules/evas/image_loaders/bmp/evas_image_load_bmp.c 
b/src/modules/evas/image_loaders/bmp/evas_image_load_bmp.c
index 93f4d59..fa3ba4b 100644
--- a/src/modules/evas/image_loaders/bmp/evas_image_load_bmp.c
+++ b/src/modules/evas/image_loaders/bmp/evas_image_load_bmp.c
@@ -205,7 +205,7 @@ _evas_image_load_file_header(void *map, size_t fsize, 
size_t *position, int *ima
if (!read_int(map, fsize, position, &tmp2)) return EINA_FALSE;
//important_colors = tmp2; // number of important colors - 0 if all
if (*image_size == 0) *image_size = fsize - header->offset;
-   if ((header->comp == 0) && (header->bit_count == 32)) header->hasa 
= 1; // GIMP seems to store it this way
+   if ((header->comp == 6) && (header->bit_count == 32)) header->hasa 
= 1;
break;
 }
   case 108: // Windows 95/NT4 + (v4)

-- 




[EGIT] [core/efl] master 01/02: Revert "naviframe: Fix to show hidden previous view when pop transition begins."

2016-11-29 Thread Jaehyun Cho
jaehyun pushed a commit to branch master.

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

commit 7b71f5dd6e7b4af6344b0a148b163178d606a9a5
Author: Jaehyun Cho 
Date:   Wed Nov 30 10:50:28 2016 +0900

Revert "naviframe: Fix to show hidden previous view when pop transition 
begins."

This reverts commit 29a7d08454bfee6c0c29b424b99ca20994a6ca28.
---
 src/lib/elementary/elc_naviframe.c | 6 ++
 1 file changed, 2 insertions(+), 4 deletions(-)

diff --git a/src/lib/elementary/elc_naviframe.c 
b/src/lib/elementary/elc_naviframe.c
index 5a96284..b455a75 100644
--- a/src/lib/elementary/elc_naviframe.c
+++ b/src/lib/elementary/elc_naviframe.c
@@ -1448,10 +1448,6 @@ _deferred(void *data, const Efl_Event *event EINA_UNUSED)
 _send_signal(cur, signals_cur[nfo->push]);
 _send_signal(other, nfo->push ? signals_new : signals_prev);
 
-//Show hidden previous view when pop transition begins.
-if (!nfo->push)
-  evas_object_show(VIEW(other));
-
 free(nfo);
  }
 
@@ -1811,7 +1807,9 @@ _elm_naviframe_item_pop(Eo *obj, Elm_Naviframe_Data *sd)
 
 /* these 2 signals MUST take place simultaneously */
 elm_object_signal_emit(VIEW(it), "elm,state,cur,popped", "elm");
+evas_object_show(VIEW(prev_it));
 elm_object_signal_emit(VIEW(prev_it), "elm,state,prev,popped", "elm");
+
 edje_object_message_signal_process(elm_layout_edje_get(VIEW(it)));
 edje_object_message_signal_process(elm_layout_edje_get(VIEW(prev_it)));
 

-- 




[EGIT] [core/efl] master 02/02: naviframe: Fix to show hidden previous view when pop transition begins.

2016-11-29 Thread Jaehyun Cho
jaehyun pushed a commit to branch master.

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

commit 3277ffa712fce9afa6a2fe70de9ac4099a643079
Author: Jaehyun Cho 
Date:   Wed Nov 30 10:53:11 2016 +0900

naviframe: Fix to show hidden previous view when pop transition begins.

Previously, previous view became visible before pop transition begins by
"elm,state,prev,popped" signal.
Now, previous view become visible when pop transition begins by
"elm,state,prev,popped" signal.
---
 src/lib/elementary/elc_naviframe.c | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/src/lib/elementary/elc_naviframe.c 
b/src/lib/elementary/elc_naviframe.c
index b455a75..de7f635 100644
--- a/src/lib/elementary/elc_naviframe.c
+++ b/src/lib/elementary/elc_naviframe.c
@@ -1807,12 +1807,13 @@ _elm_naviframe_item_pop(Eo *obj, Elm_Naviframe_Data *sd)
 
 /* these 2 signals MUST take place simultaneously */
 elm_object_signal_emit(VIEW(it), "elm,state,cur,popped", "elm");
-evas_object_show(VIEW(prev_it));
 elm_object_signal_emit(VIEW(prev_it), "elm,state,prev,popped", "elm");
-
 edje_object_message_signal_process(elm_layout_edje_get(VIEW(it)));
 edje_object_message_signal_process(elm_layout_edje_get(VIEW(prev_it)));
 
+//Show hidden previous view when pop transition begins.
+evas_object_show(VIEW(prev_it));
+
 if (!nfo) goto on_error;
 
 nfo->self = it;

-- 




[EGIT] [tools/edi] master 01/01: files: Avoid missing mime check

2016-11-29 Thread Andy Williams
ajwillia-ms pushed a commit to branch master.

http://git.enlightenment.org/tools/edi.git/commit/?id=48e954137fa7e636175fa5928efa73cab6883dd5

commit 48e954137fa7e636175fa5928efa73cab6883dd5
Author: Andy Williams 
Date:   Wed Nov 30 01:51:46 2016 +

files: Avoid missing mime check
---
 src/bin/edi_filepanel.c | 5 -
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/src/bin/edi_filepanel.c b/src/bin/edi_filepanel.c
index 6b8a5c1..0c6ff7f 100644
--- a/src/bin/edi_filepanel.c
+++ b/src/bin/edi_filepanel.c
@@ -179,8 +179,11 @@ _get_provider_from_hashset(const char *filename)
if ( !mime )
  {
mime = efreet_mime_type_get(filename);
-   eina_hash_add(mime_entries, filename, strdup(mime));
+
+   if (mime)
+ eina_hash_add(mime_entries, filename, strdup(mime));
  }
+
return edi_content_provider_for_mime_get(mime);
 }
 

-- 




[EGIT] [core/efl] master 01/01: elm_code: Add really simple indentation for braces handling

2016-11-29 Thread Andy Williams
ajwillia-ms pushed a commit to branch master.

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

commit 2935b0b4a36988b428f5be27482ae9264b8d746b
Author: Andy Williams 
Date:   Wed Nov 30 00:11:15 2016 +

elm_code: Add really simple indentation for braces handling

That's about as far as we can push it without proper scope handling
---
 src/lib/elementary/elm_code_indent.c| 17 -
 src/tests/elementary/elm_code_test_indent.c | 17 +
 2 files changed, 33 insertions(+), 1 deletion(-)

diff --git a/src/lib/elementary/elm_code_indent.c 
b/src/lib/elementary/elm_code_indent.c
index 0ff9fd0..7b3d8b1 100644
--- a/src/lib/elementary/elm_code_indent.c
+++ b/src/lib/elementary/elm_code_indent.c
@@ -11,7 +11,7 @@ elm_code_line_indent_get(const char *prevtext, unsigned int 
prevlength)
 {
unsigned int count = 0;
char *buf, *ptr = (char *)prevtext;
-   char next;
+   char next, last;
 
buf = malloc((prevlength + 3) * sizeof(char));
while (count < prevlength)
@@ -28,6 +28,9 @@ elm_code_line_indent_get(const char *prevtext, unsigned int 
prevlength)
if (count < prevlength)
  {
 next = *ptr;
+last = prevtext[prevlength - 1];
+
+// comment handling
 // TODO this should all be based on comment SCOPE not text matching
 if (next == '/')
   {
@@ -51,6 +54,18 @@ elm_code_line_indent_get(const char *prevtext, unsigned int 
prevlength)
  else
strcpy(buf + count, "*");
   }
+// VERY simple handling of braces
+else if (last == '{')
+  {
+ strcpy(buf + count, "   ");
+  }
+else if (last == '}')
+  {
+ if (count >= 2)
+   buf[count-2] = '\0';
+ else if (count >= 1)
+   buf[count-1] = '\0';
+  }
  }
return buf;
 }
diff --git a/src/tests/elementary/elm_code_test_indent.c 
b/src/tests/elementary/elm_code_test_indent.c
index beed282..38ee360 100644
--- a/src/tests/elementary/elm_code_test_indent.c
+++ b/src/tests/elementary/elm_code_test_indent.c
@@ -44,8 +44,25 @@ START_TEST (elm_code_indent_comments_test)
 }
 END_TEST
 
+START_TEST (elm_code_indent_simple_braces)
+{
+   const char *str;
+
+   str = elm_code_line_indent_get("if() {", 6);
+   ck_assert_str_eq("   ", str);
+   str = elm_code_line_indent_get("}", 1);
+   ck_assert_str_eq("", str);
+
+   str = elm_code_line_indent_get("  {", 3);
+   ck_assert_str_eq(" ", str);
+   str = elm_code_line_indent_get("  }", 3);
+   ck_assert_str_eq("", str);
+}
+END_TEST
+
 void elm_code_test_indent(TCase *tc)
 {
tcase_add_test(tc, elm_code_indent_whitespace_test);
tcase_add_test(tc, elm_code_indent_comments_test);
+   tcase_add_test(tc, elm_code_indent_simple_braces);
 }

-- 




[EGIT] [core/efl] master 02/02: evas: make sure that we initialize module correctly in all case.

2016-11-29 Thread Cedric BAIL
cedric pushed a commit to branch master.

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

commit ccc15523804eef39dd2baf1aab095564ca2064b4
Author: Cedric Bail 
Date:   Tue Nov 29 12:06:45 2016 -0800

evas: make sure that we initialize module correctly in all case.
---
 src/lib/evas/file/evas_module.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/lib/evas/file/evas_module.c b/src/lib/evas/file/evas_module.c
index 6752620..a7d46c2 100644
--- a/src/lib/evas/file/evas_module.c
+++ b/src/lib/evas/file/evas_module.c
@@ -526,7 +526,7 @@ evas_module_find_type(Evas_Module_Type type, const char 
*name)
 em = eina_hash_find(evas_modules[type], name);
 if (em)
   {
- return em;
+ if (evas_module_load(em)) return em;
   }
 
 eina_module_free(en);

-- 




[EGIT] [core/efl] master 01/02: evas: remove useless code.

2016-11-29 Thread Cedric BAIL
cedric pushed a commit to branch master.

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

commit b6eb284c68df888eb5b5f738a7a4aed88119efb4
Author: Cedric Bail 
Date:   Tue Nov 29 12:06:07 2016 -0800

evas: remove useless code.

Since we disable the possibility to shutdown evas module, this code
has been useless. Let's remove it.
---
 src/lib/evas/file/evas_module.c | 14 --
 1 file changed, 14 deletions(-)

diff --git a/src/lib/evas/file/evas_module.c b/src/lib/evas/file/evas_module.c
index 612507d..6752620 100644
--- a/src/lib/evas/file/evas_module.c
+++ b/src/lib/evas/file/evas_module.c
@@ -38,7 +38,6 @@ static Eina_Hash *evas_modules[6] = {
   NULL
 };
 
-static Eina_List *eina_evas_modules = NULL;
 static Eina_List *evas_module_paths = NULL;
 static Eina_Array *evas_engines = NULL;
 
@@ -527,7 +526,6 @@ evas_module_find_type(Evas_Module_Type type, const char 
*name)
 em = eina_hash_find(evas_modules[type], name);
 if (em)
   {
- eina_evas_modules = eina_list_append(eina_evas_modules, en);
  return em;
   }
 
@@ -670,24 +668,12 @@ _cb_mod_close(const Eina_Hash *hash EINA_UNUSED,
 void
 evas_module_shutdown(void)
 {
-   Eina_Module *en;
char *path;
int i;
 
for (i = 0; evas_static_module[i].shutdown; ++i)
  evas_static_module[i].shutdown();
 
-   EINA_LIST_FREE(eina_evas_modules, en)
- {
-// yes - looks zstupid. just to keep compilers from complaining with warnings
-if (!en) continue;
-// NEVER FREE MODULES - they MAY be needed after shutdown - eg indirect func
-// symbols from gl for example to shut down extensions. so yes - you may
-// think this is a leak. technically it is, but it's needed to keep things
-// running, so ignore this one
-//eina_module_free(en);
- }
-
eina_hash_foreach(evas_modules[EVAS_MODULE_TYPE_ENGINE], _cb_mod_close, 
NULL);
eina_hash_foreach(evas_modules[EVAS_MODULE_TYPE_IMAGE_LOADER], 
_cb_mod_close, NULL);
eina_hash_foreach(evas_modules[EVAS_MODULE_TYPE_IMAGE_SAVER], 
_cb_mod_close, NULL);

-- 




[EGIT] [website/www-content] master 01/01: Wiki page javascript_tutorial changed with summary [More updates] by Lauro Moura

2016-11-29 Thread Lauro Moura
WWW-www.enlightenment.org pushed a commit to branch master.

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

commit f05f2efa2e13c3fce7195df383a9ebcb1139a038
Author: Lauro Moura 
Date:   Tue Nov 29 11:38:58 2016 -0800

Wiki page javascript_tutorial changed with summary [More updates] by Lauro 
Moura
---
 pages/tutorial/javascript_tutorial.txt | 29 ++---
 1 file changed, 18 insertions(+), 11 deletions(-)

diff --git a/pages/tutorial/javascript_tutorial.txt 
b/pages/tutorial/javascript_tutorial.txt
index 9d6d58d..6cb3dec 100644
--- a/pages/tutorial/javascript_tutorial.txt
+++ b/pages/tutorial/javascript_tutorial.txt
@@ -1,7 +1,7 @@
 ~~Title: Javascript Tutorial~~
  Javascript Tutorial [DRAFT]
 
-This Javascript tutorial describes the basics to compiles and runs a 
Javascript example using EFL with Node.Js
+This Javascript tutorial describes the basic steps to compile and run a 
Javascript example using EFL with Node.Js
 
 
 The Javascript bindings are currently in BETA state.
@@ -9,7 +9,7 @@ The Javascript bindings are currently in BETA state.
 
 === Prerequisite ===
 
-Before you start you may want to read about how to compile an EFL library
+Before you start you may want to read about how to compile the EFL:
 
 * Installed from source: [[docs/efl/start|Get started with EFL]].
 
@@ -17,18 +17,18 @@ Before you start you may want to read about how to compile 
an EFL library
 
 You will need additional dependencies to Javascript Bindings:
 
-* [[https://nodejs.org|node]] (4.2 or better)
+* [[https://nodejs.org|node]] (4.2 or higher)
 
 === Compilation ===
 
 == Efl ==
-To configure efl sources with bindings to use in nodejs add 
''//––with-js=nodejs//'' to the configure flags to enable nodejs support.
+To configure efl sources with nodejs bindings add ''//––with-js=nodejs//'' to 
the configure flags:
 
 
 ./configure --with-js=nodejs #in efl source path
 
 
-After that, you can compile normally with
+After that, you can compile normally with:
 
 
 make
@@ -37,9 +37,7 @@ make install
 
 === Node.Js ===
 
-After everything is compiled and installed, it is time to use the modules in 
node.js. 
-
-EFL will install its nodejs modules under the ''/lib'' path. The 
default prefix, if not explicitly defined, is ''/usr/local''. In order to 
nodejs discover these modules, add the previously cited folder to the NODE_PATH 
environment variable:
+EFL will install its nodejs modules - named ''efl.node'' - under the 
''/lib'' path. The default prefix, if not explicitly defined, is 
''/usr/local''. In order to nodejs discover these modules, add the previously 
cited folder to the ''NODE_PATH'' environment variable:
 
 
 export NODE_PATH=/usr/local/lib:$NODE_PATH #if necessary replace with your 
prefix path
@@ -96,6 +94,8 @@ win.setSize(240, 60);
 win.setVisible(true);
 
 
+Once finished this setup, the ''efl.node'' module automatically integrates 
with the nodejs main loop without requiring you to call it explicitly.
+
 Twitter Example
 
 
@@ -165,7 +165,14 @@ Make a new file stream with ''fs.createWriteStream'', 
download the image to file
 }
 
 
-For each tweet we make a new Elm.Layout and set a theme using ''setfile'', 
''setText'' is used to define a new text to Edje elements in theme. To have a 
formatted text we use Elm.Entry to main tweet text and add this widget into 
theme using ''setContent'' layout method
+For each tweet, we make a new ''Elm.Layout'' and set various components, or, 
in efl jargon, "parts", using the ''set*'' family of methods.
+
+First, we set a base theme using ''setFile''. The layout will load the given 
file and setup the internal layout structure, etc. This will allow us to refer 
the individual tweet's parts by name on the following methods.
+
+Once we have the theme loaded, we can use ''setText'' to set a new text to the 
related Edje parts in the theme, referring them on each call by using the name 
of the part as the first argument.
+
+To have a formatted text, we use an ''Elm.Entry'' to show the main tweet text 
and add this widget into theme using the ''setContent'' layout method. This 
allows us to inject full widgets into the layout, besides the basic stuff. Like 
''setText'', ''setContent'' also receives the name of the target part as the 
first argument.
+
 
 for(i=0; i < tweets.length; i++){
 var layout = new elm.Elm.Layout(win);
@@ -179,7 +186,7 @@ For each tweet we make a new Elm.Layout and set a theme 
using ''setfile'', ''set
 layout.contentSet("tweet_text", entry);
 
 
-Add a layout widget to Elm.List and call ''list.go()'' to start displaying the 
list properly.
+Finally, we add the layout widget to the ''Elm.List'' and call ''list.go()'' 
to start displaying the list properly.
 
 item = list.itemAppend("", layout, null, null, null);
 }
@@ -188,7 +195,7 @@ Add a layout widget to Elm.List and call ''list.go()'' to 
start displaying 

[EGIT] [core/efl] master 02/02: eolian-js: Fix compilation of JavaScript binding

2016-11-29 Thread Felipe Magno de Almeida
felipealmeida pushed a commit to branch master.

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

commit b06d2510deab1884ea9c85cb7944102b3fb2078f
Author: Felipe Magno de Almeida 
Date:   Tue Nov 29 16:42:37 2016 -0200

eolian-js: Fix compilation of JavaScript binding
---
 src/Makefile_Cxx.am   |  2 +-
 src/Makefile_Efl_Js.am|  1 +
 src/Makefile_Eolian_Js.am |  3 ++
 src/bin/eolian_js/eolian/class.hh |  6 +--
 src/bin/eolian_js/main.cc | 90 +++
 src/bindings/js/eio_js/eio_js.cc  |  1 -
 6 files changed, 60 insertions(+), 43 deletions(-)

diff --git a/src/Makefile_Cxx.am b/src/Makefile_Cxx.am
index c87a559..febc123 100644
--- a/src/Makefile_Cxx.am
+++ b/src/Makefile_Cxx.am
@@ -129,7 +129,7 @@ bindings/cxx/ecore_cxx/Ecore_Manual.hh
 nodist_installed_ecorecxxheaders_DATA = $(ecore_eolian_cxx_hh) 
$(ecore_eolian_cxx_impl_hh) \
 lib/ecore/Ecore.eo.hh
 
-lib/ecore/Ecore.eo.hh: $(ecore_eolian_cxx_hh) $(eo_eolian_cxx_hh)
+lib/ecore/Ecore.eo.hh: $(ecore_eolian_cxx_hh) $(eo_eolian_cxx_hh) 
$(efl_eolian_cxx_hh)
@echo @ECHO_E@ "#ifndef EFL_CXX_ECORE_HH\n#define EFL_CXX_ECORE_HH\n" > 
$(top_builddir)/src/lib/ecore/Ecore.eo.hh
@echo @ECHO_E@ "#ifdef EFL_BETA_API_SUPPORT" >> 
$(top_builddir)/src/lib/ecore/Ecore.eo.hh
@for i in $(ecore_eolian_cxx_hh); do echo "#include <$$(basename $$i)>" 
>> $(top_builddir)/src/lib/ecore/Ecore.eo.hh; done
diff --git a/src/Makefile_Efl_Js.am b/src/Makefile_Efl_Js.am
index 64c643a..085f05f 100644
--- a/src/Makefile_Efl_Js.am
+++ b/src/Makefile_Efl_Js.am
@@ -204,6 +204,7 @@ SUITE_RUNNER_CPPFLAGS = -I$(top_builddir)/src/lib/efl \
 -DTESTS_BUILD_DIR=\"$(top_builddir)/src/tests/efl_js\" \
 @CHECK_CFLAGS@ \
 @EFL_JS_CFLAGS@ \
+@EFL_CFLAGS@ \
 @EINA_CXX_CFLAGS@ \
 @EO_CXX_CFLAGS@ \
 @EO_CFLAGS@ \
diff --git a/src/Makefile_Eolian_Js.am b/src/Makefile_Eolian_Js.am
index 9752027..b0e64de 100644
--- a/src/Makefile_Eolian_Js.am
+++ b/src/Makefile_Eolian_Js.am
@@ -13,6 +13,9 @@ bin_eolian_js_eolian_js_CPPFLAGS = 
-I$(top_builddir)/src/lib/efl \
 -I$(top_srcdir)/src/bindings/js/eo_js \
 @EOLIAN_JS_CFLAGS@ \
 @EINA_CXX_CFLAGS@ \
+@EO_CXX_CFLAGS@ \
+@EFL_CFLAGS@ \
+@ECORE_CXX_CFLAGS@ \
 @EOLIAN_CXX_CFLAGS@
 
 bin_eolian_js_eolian_js_LDADD = @USE_EO_LIBS@ @USE_EOLIAN_LIBS@
diff --git a/src/bin/eolian_js/eolian/class.hh 
b/src/bin/eolian_js/eolian/class.hh
index 2277987..633d6c4 100644
--- a/src/bin/eolian_js/eolian/class.hh
+++ b/src/bin/eolian_js/eolian/class.hh
@@ -1,6 +1,7 @@
 #ifndef EOLIAN_KLASS_HH
 #define EOLIAN_KLASS_HH
 
+#include 
 #include 
 
 #include 
@@ -38,11 +39,6 @@ inline std::string type_class_name(Eolian_Type const* tp)
if (tp)
  {
 Eolian_Type_Type tpt = ::eolian_type_type_get(tp);
-if (tpt == EOLIAN_TYPE_POINTER)
-  {
- return type_class_name(::eolian_type_base_type_get(tp));
-  }
-else
   {
  tp = ::eolian_type_aliased_base_get(tp);
  tpt = ::eolian_type_type_get(tp);
diff --git a/src/bin/eolian_js/main.cc b/src/bin/eolian_js/main.cc
index 9f95c74..db5fa16 100644
--- a/src/bin/eolian_js/main.cc
+++ b/src/bin/eolian_js/main.cc
@@ -83,18 +83,57 @@ _final_type_and_type_type_get(Eolian_Type const* tp_in, 
Eolian_Type const*& tp_o
 }
 
 std::string
-_eolian_type_cpp_type_named_get(const Eolian_Type *tp, std::string const& 
caller_class_prefix, std::set& need_name_getter)
+_eolian_type_cpp_type_named_get(const Eolian_Type *tp, std::string const& 
caller_class_prefix, std::set& need_name_getter, bool in_pointer = 
false)
 {
   const auto is_const = eolian_type_is_const(tp);
 
+  std::string result;
+
+   if(!in_pointer && (eolian_type_is_ptr(tp) || eolian_type_type_get(tp) == 
EOLIAN_TYPE_TERMINATED_ARRAY
+  || eolian_type_type_get(tp) == EOLIAN_TYPE_STATIC_ARRAY))
+   // else if (tpt == EOLIAN_TYPE_POINTER)
+ {
+// auto btp = eolian_type_base_type_get(tp);
+auto btp = eolian_type_type_get(tp) == EOLIAN_TYPE_TERMINATED_ARRAY
+  || eolian_type_type_get(tp) == EOLIAN_TYPE_STATIC_ARRAY
+  ? eolian_type_base_type_get(tp)
+  : tp;
+result += _eolian_type_cpp_type_named_get(btp, caller_class_prefix, 
need_name_getter
+  , eolian_type_is_ptr(tp));
+const auto base_is_const = eolian_type_is_const(btp);
+
+Eolian_Type_Type btpt = EOLIAN_TYPE_UNKNOWN_TYPE;
+_final_type_and_type_type_get(btp, btp, btpt);
+auto btpd = eolian_type_typedecl_get(btp);
+
+if (btpd && eolian_typedecl_type_get(btpd) == EOLIAN_TYPEDECL_STRUCT)
+  {
+ std::string f = "::make_struct_tag";
+ auto p = result.find(f);
+ if (p == std::string::npos)
+   throw std::runtime_error("missing struct type tag");
+ result.replace(p, f.size(), "::make_struct_ptr_tag");
+  

[EGIT] [core/efl] master 01/02: cxx: Ecore depends on generated eo headers

2016-11-29 Thread Lauro Moura
felipealmeida pushed a commit to branch master.

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

commit 90b6468bbd2d9c14e24d5bfe9f655b3f074c39ce
Author: Lauro Moura 
Date:   Tue Nov 29 14:22:07 2016 -0300

cxx: Ecore depends on generated eo headers
---
 src/Makefile_Cxx.am | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/Makefile_Cxx.am b/src/Makefile_Cxx.am
index 5140207..c87a559 100644
--- a/src/Makefile_Cxx.am
+++ b/src/Makefile_Cxx.am
@@ -129,7 +129,7 @@ bindings/cxx/ecore_cxx/Ecore_Manual.hh
 nodist_installed_ecorecxxheaders_DATA = $(ecore_eolian_cxx_hh) 
$(ecore_eolian_cxx_impl_hh) \
 lib/ecore/Ecore.eo.hh
 
-lib/ecore/Ecore.eo.hh: $(ecore_eolian_cxx_hh)
+lib/ecore/Ecore.eo.hh: $(ecore_eolian_cxx_hh) $(eo_eolian_cxx_hh)
@echo @ECHO_E@ "#ifndef EFL_CXX_ECORE_HH\n#define EFL_CXX_ECORE_HH\n" > 
$(top_builddir)/src/lib/ecore/Ecore.eo.hh
@echo @ECHO_E@ "#ifdef EFL_BETA_API_SUPPORT" >> 
$(top_builddir)/src/lib/ecore/Ecore.eo.hh
@for i in $(ecore_eolian_cxx_hh); do echo "#include <$$(basename $$i)>" 
>> $(top_builddir)/src/lib/ecore/Ecore.eo.hh; done

-- 




[EGIT] [tools/edi] master 01/01: filelist: Actually update on file add/rm

2016-11-29 Thread Andy Williams
ajwillia-ms pushed a commit to branch master.

http://git.enlightenment.org/tools/edi.git/commit/?id=5abd439e3e61c99b56f65dde6c300bb794480fbd

commit 5abd439e3e61c99b56f65dde6c300bb794480fbd
Author: Andy Williams 
Date:   Tue Nov 29 18:16:12 2016 +

filelist: Actually update on file add/rm

This is pretty much working except some genlist bugs :(
---
 src/bin/edi_filepanel.c | 82 +++--
 1 file changed, 66 insertions(+), 16 deletions(-)

diff --git a/src/bin/edi_filepanel.c b/src/bin/edi_filepanel.c
index 17d16a3..6b8a5c1 100644
--- a/src/bin/edi_filepanel.c
+++ b/src/bin/edi_filepanel.c
@@ -323,15 +323,63 @@ _on_list_contracted(void *data EINA_UNUSED,
_file_listing_empty(sd, it);
 }
 
+static Elm_Object_Item *_file_listing_item_find(const char *path, 
Elm_Object_Item *root)
+{
+   Elm_Object_Item *item;
+   Edi_Dir_Data *sd;
+   const Eina_List *itemlist, *l;
+
+   if (root)
+ itemlist = elm_genlist_item_subitems_get(root);
+   else
+ itemlist = elm_genlist_realized_items_get(list);
+   EINA_LIST_FOREACH(itemlist, l, item)
+ {
+sd = elm_object_item_data_get(item);
+
+if (!strcmp(path, sd->path))
+  return item;
+ }
+
+   return NULL;
+}
+
 static void
-_ls_main_cb(void *data,
-Eio_File *handler,
-const Eina_File_Direct_Info *info)
+_file_listing_item_insert(const char *path, Eina_Bool isdir, Elm_Object_Item 
*parent_it)
 {
-   Listing_Request *lreq = data;
Elm_Genlist_Item_Class *clas = &itc;
Edi_Dir_Data *sd;
 
+   sd = calloc(1, sizeof(Edi_Dir_Data));
+   if (isdir)
+ {
+clas = &itc2;
+sd->isdir = EINA_TRUE;
+ }
+
+   sd->path = eina_stringshare_add(path);
+   (void)!elm_genlist_item_sorted_insert(list, clas, sd, parent_it,
+ isdir ? ELM_GENLIST_ITEM_TREE : 
ELM_GENLIST_ITEM_NONE,
+ _file_list_cmp, _item_sel, sd);
+}
+
+static void
+_file_listing_item_delete(const char *path, Elm_Object_Item *parent_it)
+{
+   Elm_Object_Item *item;
+
+   item = _file_listing_item_find(path, parent_it);
+   if (!item)
+ return;
+
+   elm_object_item_del(item);
+}
+
+static void
+_ls_main_cb(void *data, Eio_File *handler, const Eina_File_Direct_Info *info)
+{
+   Listing_Request *lreq = data;
+
if (eio_file_check(handler)) return;
 
//if (!lreq->sd->files_view || lreq->sd->current != handler)
@@ -342,17 +390,7 @@ _ls_main_cb(void *data,
 
 //   _signal_first(lreq);
 
-   sd = calloc(1, sizeof(Edi_Dir_Data));
-   if (info->type == EINA_FILE_DIR)
- {
-clas = &itc2;
-sd->isdir = EINA_TRUE;
- }
-
-   sd->path = eina_stringshare_add(info->path);
-   (void)!elm_genlist_item_sorted_insert(list, clas, sd, lreq->parent_it,
- (clas == &itc2) ? 
ELM_GENLIST_ITEM_TREE : ELM_GENLIST_ITEM_NONE,
- _file_list_cmp, _item_sel, sd);
+   _file_listing_item_insert(info->path, info->type == EINA_FILE_DIR, 
lreq->parent_it);
 }
 
 static void
@@ -404,9 +442,21 @@ _file_listing_updated(void *data EINA_UNUSED, int type 
EINA_UNUSED,
 {
const char *dir;
Eio_Monitor_Event *ev = event;
+   Elm_Object_Item *parent_it;
 
dir = ecore_file_dir_get(ev->filename);
-
+   parent_it = _file_listing_item_find(dir, NULL);
+
+   if (type == EIO_MONITOR_FILE_CREATED)
+ _file_listing_item_insert(ev->filename, EINA_FALSE, parent_it);
+   else if (type == EIO_MONITOR_FILE_DELETED)
+ _file_listing_item_delete(ev->filename, parent_it);
+   if (type == EIO_MONITOR_DIRECTORY_CREATED)
+ _file_listing_item_insert(ev->filename, EINA_TRUE, parent_it);
+   else if (type == EIO_MONITOR_DIRECTORY_DELETED)
+ _file_listing_item_delete(ev->filename, parent_it);
+   else
+ DBG("Ignoring file update event for %s", ev->filename);
 }
 
 /* Panel filtering */

-- 




[EGIT] [core/efl] master 03/08: efl_net_dialer_http: special headers and date parse/serialize.

2016-11-29 Thread Gustavo Sverzut Barbieri
barbieri pushed a commit to branch master.

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

commit 3cf20ea8e8b9ddcca73578a59442da1c8bf546c5
Author: Gustavo Sverzut Barbieri 
Date:   Tue Nov 29 01:19:40 2016 -0200

efl_net_dialer_http: special headers and date parse/serialize.

CURL needs some special curl_easy_setopt() calls to enable automatic
gzip deflate (CURLOPT_ENCODING) and
If-Modified-Since/If-Unmodified-Since logic.

As If-Modified-Since/If-Unmodified-Since requires a timestamp string,
let's expose class methods to handle those.
---
 src/lib/ecore_con/ecore_con_url_curl.c   |   1 +
 src/lib/ecore_con/ecore_con_url_curl.h   |   5 ++
 src/lib/ecore_con/efl_net_dialer_http.c  | 103 +++
 src/lib/ecore_con/efl_net_dialer_http.eo |  23 +++
 4 files changed, 132 insertions(+)

diff --git a/src/lib/ecore_con/ecore_con_url_curl.c 
b/src/lib/ecore_con/ecore_con_url_curl.c
index c6ef501..507dd61 100644
--- a/src/lib/ecore_con/ecore_con_url_curl.c
+++ b/src/lib/ecore_con/ecore_con_url_curl.c
@@ -312,6 +312,7 @@ _c_init(void)
SYM(curl_slist_free_all);
SYM(curl_slist_append);
SYM(curl_version_info);
+   SYM(curl_getdate);
 
_c_init_errors();
 
diff --git a/src/lib/ecore_con/ecore_con_url_curl.h 
b/src/lib/ecore_con/ecore_con_url_curl.h
index 9f82230..094c286 100644
--- a/src/lib/ecore_con/ecore_con_url_curl.h
+++ b/src/lib/ecore_con/ecore_con_url_curl.h
@@ -446,6 +446,7 @@ struct _Ecore_Con_Curl
void(*curl_slist_free_all)(struct curl_slist *);
struct curl_slist  *(*curl_slist_append)(struct curl_slist *list,
 const char *string);
+   time_t  (*curl_getdate)(const char *p, const time_t 
*unused);
curl_version_info_data *(*curl_version_info)(CURLversion);
 };
 
@@ -460,4 +461,8 @@ void _c_shutdown(void);
 Eina_Error _curlcode_to_eina_error(const CURLcode code);
 Eina_Error _curlmcode_to_eina_error(const CURLMcode code);
 
+
+/* only for legacy support to implement behavior that we're not exposing 
anymore */
+CURL *efl_net_dialer_http_curl_get(const Eo *o);
+
 #endif
diff --git a/src/lib/ecore_con/efl_net_dialer_http.c 
b/src/lib/ecore_con/efl_net_dialer_http.c
index 97b6e5b..cf6c4a9 100644
--- a/src/lib/ecore_con/efl_net_dialer_http.c
+++ b/src/lib/ecore_con/efl_net_dialer_http.c
@@ -29,6 +29,7 @@
 #define curl_easy_init(...) _c->curl_easy_init(__VA_ARGS__)
 #define curl_easy_cleanup(...) _c->curl_easy_cleanup(__VA_ARGS__)
 #define curl_easy_pause(...) _c->curl_easy_pause(__VA_ARGS__)
+#define curl_getdate(s, unused) _c->curl_getdate(s, unused)
 
 #ifdef curl_easy_setopt
 #undef curl_easy_setopt
@@ -1260,6 +1261,7 @@ _efl_net_dialer_http_libproxy_cancel(void *data, 
Ecore_Thread *thread EINA_UNUSE
 EOLIAN static Eina_Error
 _efl_net_dialer_http_efl_net_dialer_dial(Eo *o, Efl_Net_Dialer_Http_Data *pd, 
const char *address)
 {
+   struct curl_slist *sl_it;
CURLcode r;
 
EINA_SAFETY_ON_NULL_RETURN_VAL(address, EINVAL);
@@ -1279,6 +1281,77 @@ _efl_net_dialer_http_efl_net_dialer_dial(Eo *o, 
Efl_Net_Dialer_Http_Data *pd, co
 o, curl_easy_strerror(r));
 return EINVAL;
  }
+   for (sl_it = pd->request.headers; sl_it != NULL; sl_it = sl_it->next)
+ {
+#define IS_HEADER(x) (strncasecmp(sl_it->data, x ":", strlen(x ":")) == 0)
+if (IS_HEADER("Accept-Encoding"))
+  {
+ const char *value = strchr(sl_it->data, ':') + 1;
+ while (*value && isspace(*value))
+   value++;
+ r = curl_easy_setopt(pd->easy, CURLOPT_ENCODING, value);
+ if (r != CURLE_OK)
+   {
+  ERR("dialer=%p could not set HTTP Accept-Encoding '%s': %s",
+  o, value, curl_easy_strerror(r));
+  return EINVAL;
+   }
+ DBG("Using Accept-Encoding: %s", value);
+  }
+else if (IS_HEADER("If-Modified-Since"))
+  {
+ const char *value = strchr(sl_it->data, ':') + 1;
+ long t;
+
+ r = curl_easy_setopt(pd->easy, CURLOPT_TIMECONDITION, 
CURL_TIMECOND_IFMODSINCE);
+ if (r != CURLE_OK)
+   {
+  ERR("dialer=%p could not set HTTP If-Modified-Since 
condition: %s",
+  o, curl_easy_strerror(r));
+  return EINVAL;
+   }
+
+ while (*value && isspace(*value))
+   value++;
+ t = curl_getdate(value, NULL);
+
+ r = curl_easy_setopt(pd->easy, CURLOPT_TIMEVALUE, t);
+ if (r != CURLE_OK)
+   {
+  ERR("dialer=%p could not set HTTP If-Modified-Since 
value=%ld: %s",
+  o, t, curl_easy_strerror(r));
+  return EINVAL;
+   }
+ DBG("Using If-Modified-Since: %s [t=%ld]", value, t);
+ 

[EGIT] [core/efl] master 05/08: efl_net_dialer_http: POST also allows resizing.

2016-11-29 Thread Gustavo Sverzut Barbieri
barbieri pushed a commit to branch master.

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

commit da143edd8c14822b457ea8884a743b7c188da73d
Author: Gustavo Sverzut Barbieri 
Date:   Tue Nov 29 02:56:18 2016 -0200

efl_net_dialer_http: POST also allows resizing.

resizing the dialer results in changing the request content length,
which is useful when uploading files AND posting data.
---
 src/lib/ecore_con/efl_net_dialer_http.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/src/lib/ecore_con/efl_net_dialer_http.c 
b/src/lib/ecore_con/efl_net_dialer_http.c
index 531b499..ffd1e46 100644
--- a/src/lib/ecore_con/efl_net_dialer_http.c
+++ b/src/lib/ecore_con/efl_net_dialer_http.c
@@ -1806,7 +1806,8 @@ _efl_net_dialer_http_efl_io_sizer_resize(Eo *o, 
Efl_Net_Dialer_Http_Data *pd, ui
EINA_SAFETY_ON_TRUE_RETURN_VAL(size > INT64_MAX, ERANGE);
 
pm = _efl_net_dialer_http_primary_mode_effective_get(pd);
-   if (pm == EFL_NET_DIALER_HTTP_PRIMARY_MODE_UPLOAD)
+   if ((pm == EFL_NET_DIALER_HTTP_PRIMARY_MODE_UPLOAD) ||
+   (strcmp(pd->method, "POST") == 0))
  {
 efl_net_dialer_http_request_content_length_set(o, size);
 return 0;

-- 




[EGIT] [core/efl] master 08/08: ecore_con_url: now on top of efl_net_dialer_http.

2016-11-29 Thread Gustavo Sverzut Barbieri
barbieri pushed a commit to branch master.

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

commit 2cb3466ddf8f52b5d012fcf02fbe4fa08e067559
Author: Gustavo Sverzut Barbieri 
Date:   Tue Nov 29 03:43:16 2016 -0200

ecore_con_url: now on top of efl_net_dialer_http.

Rewrite Ecore_Con_Url as a non-Eo (since it's just legacy) that is
built on top of Efl_Net_Dialer_Http.

Since there are some legacy behavior we do not want to expose in the
new classes, hack around and manipulate the curl_easy_setopt()
directly in those cases.

This includes the cookies: there is no reason why we should expose
independent files for read (COOKIEFILE) and write (COOKIEJAR), real
world applications can manipulate the files directly, like copying
from a template to a RDWR before using, etc.
---
 src/Makefile_Ecore_Con.am|5 +-
 src/lib/ecore_con/Ecore_Con.h|   80 +-
 src/lib/ecore_con/Ecore_Con_Eo.h |1 -
 src/lib/ecore_con/Ecore_Con_Legacy.h |   21 -
 src/lib/ecore_con/ecore_con_url.c| 2191 --
 src/lib/ecore_con/efl_network_url.eo |   29 -
 6 files changed, 1077 insertions(+), 1250 deletions(-)

diff --git a/src/Makefile_Ecore_Con.am b/src/Makefile_Ecore_Con.am
index 82221e7..c3e51ae 100644
--- a/src/Makefile_Ecore_Con.am
+++ b/src/Makefile_Ecore_Con.am
@@ -33,8 +33,7 @@ ecore_con_eolian_files = \
 lib/ecore_con/efl_net_session.eo \
lib/ecore_con/ecore_con_eet_base.eo \
lib/ecore_con/ecore_con_eet_server_obj.eo \
-   lib/ecore_con/ecore_con_eet_client_obj.eo \
-   lib/ecore_con/efl_network_url.eo
+   lib/ecore_con/ecore_con_eet_client_obj.eo
 
 if HAVE_WINDOWS
 else
@@ -134,8 +133,6 @@ lib/ecore_con/efl_net_control-none.c \
 lib/ecore_con/efl_net_session-none.c
 endif
 
-EXTRA_DIST2 += lib/ecore_con/ecore_con_legacy.c
-
 # these are included rather than compiled out
 # so the structures can be embedded into the
 # object Private Data and allows functions to
diff --git a/src/lib/ecore_con/Ecore_Con.h b/src/lib/ecore_con/Ecore_Con.h
index cc2dd2b..393b94c 100644
--- a/src/lib/ecore_con/Ecore_Con.h
+++ b/src/lib/ecore_con/Ecore_Con.h
@@ -272,6 +272,22 @@ typedef void (*Ecore_Con_Dns_Cb)(const char *canonname,
 #include "Ecore_Con_Eo.h"
 #endif
 
+
+/**
+ * @struct _Ecore_Con_Url
+ * Used to provide legacy ABI/ABI compatibility with non-Eo applications.
+ * @ingroup Ecore_Con_Url_Group
+ */
+struct _Ecore_Con_Url;
+
+/**
+ * @typedef Ecore_Con_Url
+ * Used to provide legacy API/ABI compatibility with non-Eo applications.
+ * @ingroup Ecore_Con_Url_Group
+ */
+typedef struct _Ecore_Con_Url Ecore_Con_Url;
+
+
 /**
  * @addtogroup Ecore_Con_Events_Group
  * @{
@@ -362,16 +378,6 @@ typedef struct _Ecore_Con_Event_Server_Write 
Ecore_Con_Event_Server_Write;
  */
 typedef struct _Ecore_Con_Event_Proxy_Bind Ecore_Con_Event_Proxy_Bind;
 
-#ifdef EFL_BETA_API_SUPPORT
-/**
- * @typedef Efl_Network_Event_Url_Data
- * Used as the @p data param for the corresponding event
- * EFL_NETWORK_EVENT_URL_DATA
- * @ingroup Ecore_Con_Url_Group
- */
-typedef struct _Efl_Network_Event_Url_Data Efl_Network_Event_Url_Data;
-#endif
-
 /**
  * @typedef Ecore_Con_Event_Url_Data
  * Used as the @p data param for the corresponding event
@@ -386,16 +392,6 @@ typedef struct _Ecore_Con_Event_Url_Data 
Ecore_Con_Event_Url_Data;
  */
 typedef struct _Ecore_Con_Event_Url_Complete Ecore_Con_Event_Url_Complete;
 
-#ifdef EFL_BETA_API_SUPPORT
-/**
- * @typedef Efl_Network_Event_Url_Complete
- * Used as the @p data param for the corresponding event
- * EFL_NETWORK_EVENT_URL_COMPLETE
- * @ingroup Ecore_Con_Url_Group
- */
-typedef struct _Ecore_Con_Event_Url_Complete Efl_Network_Event_Url_Complete;
-#endif
-
 /**
  * @typedef Ecore_Con_Event_Url_Progress
  * Used as the @p data param for the corresponding event
@@ -403,16 +399,6 @@ typedef struct _Ecore_Con_Event_Url_Complete 
Efl_Network_Event_Url_Complete;
  */
 typedef struct _Ecore_Con_Event_Url_Progress Ecore_Con_Event_Url_Progress;
 
-#ifdef EFL_BETA_API_SUPPORT
-/**
- * @typedef Efl_Network_Event_Url_Progress
- * Used as the @p data param for the corresponding event
- * EFL_NETWORK_EVENT_URL_PROGRESS
- * @ingroup Ecore_Con_Url_Group
- */
-typedef struct _Ecore_Con_Event_Url_Progress Efl_Network_Event_Url_Progress;
-#endif
-
 /**
  * @struct _Ecore_Con_Event_Client_Add
  * Used as the @p data param for the @ref ECORE_CON_EVENT_CLIENT_ADD event
@@ -544,20 +530,6 @@ struct _Ecore_Con_Event_Proxy_Bind
int port; /**< the proxy-bound port */
 };
 
-#ifdef EFL_BETA_API_SUPPORT
-/**
- * @struct _Efl_Network_Event_Url_Data
- * Used as the @p data param for the @ref EFL_NETWORK_EVENT_URL_DATA event
- * @ingroup Ecore_Con_Url_Group
- */
-struct _Efl_Network_Event_Url_Data
-{
-   Efl_Network_Url *url_con; /**< a pointer to the connection object */
-   int size; /**< the size of the current received data (in bytes) *

[EGIT] [core/efl] master 04/08: efl_net_dialer_http: export SSL controls.

2016-11-29 Thread Gustavo Sverzut Barbieri
barbieri pushed a commit to branch master.

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

commit 4aca800bde64f649a111a160ab4129a444762e7c
Author: Gustavo Sverzut Barbieri 
Date:   Tue Nov 29 02:16:47 2016 -0200

efl_net_dialer_http: export SSL controls.

verify peer, hostname and set CA/CRL files.
---
 src/lib/ecore_con/ecore_con_url_curl.h   |  3 ++
 src/lib/ecore_con/efl_net_dialer_http.c  | 81 
 src/lib/ecore_con/efl_net_dialer_http.eo | 28 +++
 3 files changed, 112 insertions(+)

diff --git a/src/lib/ecore_con/ecore_con_url_curl.h 
b/src/lib/ecore_con/ecore_con_url_curl.h
index 094c286..42eae54 100644
--- a/src/lib/ecore_con/ecore_con_url_curl.h
+++ b/src/lib/ecore_con/ecore_con_url_curl.h
@@ -251,12 +251,14 @@ typedef enum
CINIT(CONNECTTIMEOUT_MS, LONG, 156),
CINIT(HEADERFUNCTION, FUNCTIONPOINT, 79),
CINIT(HTTPGET, LONG, 80),
+   CINIT(SSL_VERIFYHOST, LONG, 81),
CINIT(COOKIEJAR, OBJECTPOINT, 82),
CINIT(HTTP_VERSION, LONG, 84),
CINIT(FTP_USE_EPSV, LONG, 85),
CINIT(DEBUGFUNCTION, FUNCTIONPOINT, 94),
CINIT(DEBUGDATA, OBJECTPOINT, 95),
CINIT(COOKIESESSION, LONG, 96),
+   CINIT(CAPATH, STRINGPOINT, 97),
CINIT(BUFFERSIZE, LONG, 98),
CINIT(NOSIGNAL, LONG, 99),
CINIT(PROXYTYPE, LONG, 101),
@@ -268,6 +270,7 @@ typedef enum
CINIT(COOKIELIST, OBJECTPOINT, 135),
CINIT(OPENSOCKETFUNCTION, FUNCTIONPOINT, 163),
CINIT(OPENSOCKETDATA, OBJECTPOINT, 164),
+   CINIT(CRLFILE, STRINGPOINT, 169),
CINIT(USERNAME, OBJECTPOINT, 173),
CINIT(PASSWORD, OBJECTPOINT, 174),
CINIT(CLOSESOCKETFUNCTION, FUNCTIONPOINT, 208),
diff --git a/src/lib/ecore_con/efl_net_dialer_http.c 
b/src/lib/ecore_con/efl_net_dialer_http.c
index cf6c4a9..531b499 100644
--- a/src/lib/ecore_con/efl_net_dialer_http.c
+++ b/src/lib/ecore_con/efl_net_dialer_http.c
@@ -201,6 +201,12 @@ typedef struct
   Efl_Net_Http_Authentication_Method method;
   Eina_Bool restricted;
} authentication;
+   struct {
+  Eina_Stringshare *ca;
+  Eina_Stringshare *crl;
+  Eina_Bool verify_peer;
+  Eina_Bool verify_hostname;
+   } ssl;
Efl_Future *pending_close;
unsigned int in_curl_callback;
SOCKET fd;
@@ -1084,6 +1090,7 @@ _efl_net_dialer_http_efl_object_constructor(Eo *o, 
Efl_Net_Dialer_Http_Data *pd)
efl_net_dialer_http_method_set(o, "GET");
efl_net_dialer_http_version_set(o, EFL_NET_HTTP_VERSION_V1_1);
efl_net_dialer_http_allow_redirects_set(o, EINA_TRUE);
+   efl_net_dialer_http_ssl_verify_set(o, EINA_TRUE, EINA_TRUE);
efl_net_dialer_timeout_dial_set(o, 30.0);
return o;
 }
@@ -1163,6 +1170,8 @@ _efl_net_dialer_http_efl_object_destructor(Eo *o, 
Efl_Net_Dialer_Http_Data *pd)
eina_stringshare_replace(&pd->response.content_type, NULL);
eina_stringshare_replace(&pd->authentication.username, NULL);
_secure_free(&pd->authentication.password);
+   eina_stringshare_replace(&pd->ssl.ca, NULL);
+   eina_stringshare_replace(&pd->ssl.crl, NULL);
 }
 
 static void
@@ -2265,6 +2274,78 @@ _efl_net_dialer_http_cookie_jar_get(Eo *o EINA_UNUSED, 
Efl_Net_Dialer_Http_Data
return pd->cookie_jar;
 }
 
+EOLIAN static void
+_efl_net_dialer_http_ssl_verify_set(Eo *o, Efl_Net_Dialer_Http_Data *pd, 
Eina_Bool peer, Eina_Bool hostname)
+{
+   CURLcode r;
+
+   r = curl_easy_setopt(pd->easy, CURLOPT_SSL_VERIFYPEER, (long)peer);
+   if (r != CURLE_OK)
+ ERR("dialer=%p could not set SSL verify peer %d: %s",
+ o, peer, curl_easy_strerror(r));
+
+   /* VERIFYHOST used to take 1 as debug,
+* it requires 2 to really enable it.
+*/
+   r = curl_easy_setopt(pd->easy, CURLOPT_SSL_VERIFYHOST, (long)hostname * 2);
+   if (r != CURLE_OK)
+ ERR("dialer=%p could not set SSL verify hostname %d: %s",
+ o, hostname, curl_easy_strerror(r));
+
+   pd->ssl.verify_peer = peer;
+   pd->ssl.verify_hostname = hostname;
+}
+
+EOLIAN static void
+_efl_net_dialer_http_ssl_verify_get(Eo *o EINA_UNUSED, 
Efl_Net_Dialer_Http_Data *pd, Eina_Bool *peer, Eina_Bool *hostname)
+{
+   if (peer) *peer = pd->ssl.verify_peer;
+   if (hostname) *hostname = pd->ssl.verify_hostname;
+}
+
+EOLIAN static void
+_efl_net_dialer_http_ssl_certificate_authority_set(Eo *o EINA_UNUSED, 
Efl_Net_Dialer_Http_Data *pd, const char *path)
+{
+   CURLcode r;
+   struct stat st;
+
+   if (path && (stat(path, &st) == 0) && (S_ISDIR(st.st_mode)))
+ r = curl_easy_setopt(pd->easy, CURLOPT_CAPATH, path);
+   else
+ r = curl_easy_setopt(pd->easy, CURLOPT_CAINFO, path);
+
+   if (r != CURLE_OK)
+ ERR("dialer=%p could not set SSL CA '%s': %s",
+ o, path, curl_easy_strerror(r));
+
+   eina_stringshare_replace(&pd->ssl.ca, path);
+}
+
+EOLIAN static const char *
+_efl_net_dialer_http_ssl_certificate_authority_get(Eo *o EINA_UNUSED, 
Efl_Net_Dialer_Http_Data *pd)
+{
+   return pd->ssl.ca;
+}
+
+EOLIAN static void
+_efl_net_dialer_http_ssl_certificate_revogation_list_set(Eo *o

[EGIT] [core/efl] master 01/08: efl_net_dialer_http: export read size.

2016-11-29 Thread Gustavo Sverzut Barbieri
barbieri pushed a commit to branch master.

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

commit b4ed72518d82c4e16485fb5bec5f382148839ea8
Author: Gustavo Sverzut Barbieri 
Date:   Mon Nov 28 19:06:30 2016 -0200

efl_net_dialer_http: export read size.

In the legacy wrapper I'll need that.
---
 src/lib/ecore_con/ecore_con_private.h   |  2 ++
 src/lib/ecore_con/efl_net_dialer_http.c | 10 --
 2 files changed, 10 insertions(+), 2 deletions(-)

diff --git a/src/lib/ecore_con/ecore_con_private.h 
b/src/lib/ecore_con/ecore_con_private.h
index 45864da..bf70f64 100644
--- a/src/lib/ecore_con/ecore_con_private.h
+++ b/src/lib/ecore_con/ecore_con_private.h
@@ -740,4 +740,6 @@ size_t efl_net_udp_datagram_size_query(SOCKET fd);
 /* SSL abstraction API */
 extern void *efl_net_ssl_context_connection_new(Efl_Net_Ssl_Context *context);
 
+#define EFL_NET_DIALER_HTTP_BUFFER_RECEIVE_SIZE (1U << 14) /* 16Kb to receive 
*/
+
 #endif
diff --git a/src/lib/ecore_con/efl_net_dialer_http.c 
b/src/lib/ecore_con/efl_net_dialer_http.c
index 83c85b0..ef2b6d2 100644
--- a/src/lib/ecore_con/efl_net_dialer_http.c
+++ b/src/lib/ecore_con/efl_net_dialer_http.c
@@ -10,8 +10,6 @@
 # include 
 #endif
 
-#define EFL_NET_DIALER_HTTP_BUFFER_RECEIVE_SIZE (1U << 14) /* 16Kb to receive 
*/
-
 #include "Ecore.h"
 #include "Ecore_Con.h"
 #include "ecore_con_private.h"
@@ -2193,4 +2191,12 @@ _efl_net_dialer_http_cookie_jar_get(Eo *o EINA_UNUSED, 
Efl_Net_Dialer_Http_Data
return pd->cookie_jar;
 }
 
+CURL *
+efl_net_dialer_http_curl_get(const Eo *o)
+{
+   Efl_Net_Dialer_Http_Data *pd = efl_data_scope_get(o, MY_CLASS);
+   EINA_SAFETY_ON_NULL_RETURN_VAL(pd, NULL);
+   return pd->easy;
+}
+
 #include "efl_net_dialer_http.eo.c"

-- 




[EGIT] [core/efl] master 06/08: ecore_con_url_headers_example: allow POST data.

2016-11-29 Thread Gustavo Sverzut Barbieri
barbieri pushed a commit to branch master.

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

commit a4931f4fb0ce1f992493e9d4b8963b11b6d524a6
Author: Gustavo Sverzut Barbieri 
Date:   Tue Nov 29 02:55:37 2016 -0200

ecore_con_url_headers_example: allow POST data.
---
 src/examples/ecore/ecore_con_url_headers_example.c | 8 +---
 1 file changed, 5 insertions(+), 3 deletions(-)

diff --git a/src/examples/ecore/ecore_con_url_headers_example.c 
b/src/examples/ecore/ecore_con_url_headers_example.c
index 656743f..6c9e162 100644
--- a/src/examples/ecore/ecore_con_url_headers_example.c
+++ b/src/examples/ecore/ecore_con_url_headers_example.c
@@ -42,12 +42,12 @@ int
 main(int argc, const char *argv[])
 {
Ecore_Con_Url *ec_url = NULL;
-   const char *type;
+   const char *type, *post_data = "";
Eina_Bool r;
 
if (argc < 3)
  {
-printf("need at least two parameters: < POST|GET >  \n");
+printf("need at least two parameters: < POST|GET >   
[post-data]\n");
 return -1;
  }
 
@@ -59,6 +59,8 @@ main(int argc, const char *argv[])
 return -1;
  }
 
+   if (argc > 3) post_data = argv[3];
+
ecore_init();
ecore_con_init();
ecore_con_url_init();
@@ -87,7 +89,7 @@ main(int argc, const char *argv[])
if (!strcmp(type, "GET"))
  r = ecore_con_url_get(ec_url);
else
- r = ecore_con_url_post(ec_url, NULL, 0, NULL);
+ r = ecore_con_url_post(ec_url, post_data, strlen(post_data), NULL);
 
if (!r)
  {

-- 




[EGIT] [core/efl] master 02/08: efl_net_dialer_http: only close if not closed yet.

2016-11-29 Thread Gustavo Sverzut Barbieri
barbieri pushed a commit to branch master.

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

commit 5c7b98474645b272e58d39011b2d1d83e8d957b1
Author: Gustavo Sverzut Barbieri 
Date:   Mon Nov 28 19:15:29 2016 -0200

efl_net_dialer_http: only close if not closed yet.

since eos_set() emits an event the user may have closed from there.
---
 src/lib/ecore_con/efl_net_dialer_http.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/src/lib/ecore_con/efl_net_dialer_http.c 
b/src/lib/ecore_con/efl_net_dialer_http.c
index ef2b6d2..97b6e5b 100644
--- a/src/lib/ecore_con/efl_net_dialer_http.c
+++ b/src/lib/ecore_con/efl_net_dialer_http.c
@@ -316,7 +316,8 @@ _efl_net_dialer_http_curlm_check(Efl_Net_Dialer_Http_Curlm 
*cm)
 else
   {
  efl_io_reader_eos_set(dialer, EINA_TRUE);
- efl_io_closer_close(dialer);
+ if (!efl_io_closer_closed_get(dialer))
+   efl_io_closer_close(dialer);
   }
 
 _efl_net_dialer_http_curlm_check_finished_object_remove(&finished, 
dialer);

-- 




[EGIT] [core/efl] master 07/08: examples/ecore: build ecore_con_url_ftp_example

2016-11-29 Thread Gustavo Sverzut Barbieri
barbieri pushed a commit to branch master.

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

commit d07e0c307249cf64dc5650b310c182772c091718
Author: Gustavo Sverzut Barbieri 
Date:   Tue Nov 29 03:16:53 2016 -0200

examples/ecore: build ecore_con_url_ftp_example
---
 src/examples/ecore/Makefile.am | 5 +
 1 file changed, 5 insertions(+)

diff --git a/src/examples/ecore/Makefile.am b/src/examples/ecore/Makefile.am
index 88f2384..5ac7a1d 100644
--- a/src/examples/ecore/Makefile.am
+++ b/src/examples/ecore/Makefile.am
@@ -53,6 +53,7 @@ ecore_con_server_simple_example \
 ecore_con_url_cookies_example \
 ecore_con_url_download_example \
 ecore_con_url_headers_example \
+ecore_con_url_ftp_example \
 ecore_evas_basics_example \
 ecore_evas_buffer_example_01 \
 ecore_evas_buffer_example_02 \
@@ -195,6 +196,9 @@ ecore_con_url_download_example_LDADD = 
$(ECORE_CON_COMMON_LDADD)
 ecore_con_url_headers_example_SOURCES = ecore_con_url_headers_example.c
 ecore_con_url_headers_example_LDADD = $(ECORE_CON_COMMON_LDADD)
 
+ecore_con_url_ftp_example_SOURCES = ecore_con_url_ftp_example.c
+ecore_con_url_ftp_example_LDADD = $(ECORE_CON_COMMON_LDADD)
+
 ecore_evas_basics_example_SOURCES = ecore_evas_basics_example.c
 ecore_evas_basics_example_LDADD = $(ECORE_EVAS_COMMON_LDADD)
 
@@ -384,6 +388,7 @@ ecore_con_server_simple_example.c \
 ecore_con_url_cookies_example.c \
 ecore_con_url_download_example.c \
 ecore_con_url_headers_example.c \
+ecore_con_url_ftp_example.c \
 ecore_evas_basics_example.c \
 ecore_evas_buffer_example_01.c \
 ecore_evas_buffer_example_02.c \

-- 




[EGIT] [core/enlightenment] master 01/01: teamwork: Use emile SHA1 functions

2016-11-29 Thread Derek Foreman
derekf pushed a commit to branch master.

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

commit d0b0f81fb761b85253b3617ce71dbb146fb88aa8
Author: Derek Foreman 
Date:   Wed Oct 12 05:36:31 2016 -0500

teamwork: Use emile SHA1 functions

Remove the SHA1 functions in the module in favour of the ones now present in
EFL
---
 src/modules/Makefile_teamwork.mk  |   4 +-
 src/modules/teamwork/e_mod_main.c |  17 +
 src/modules/teamwork/e_mod_main.h |   5 +-
 src/modules/teamwork/e_mod_tw.c   |   2 +-
 src/modules/teamwork/sha1.c   | 146 --
 src/modules/teamwork/sha1.h   |  54 --
 6 files changed, 8 insertions(+), 220 deletions(-)

diff --git a/src/modules/Makefile_teamwork.mk b/src/modules/Makefile_teamwork.mk
index 8abc04f..a157fc2 100644
--- a/src/modules/Makefile_teamwork.mk
+++ b/src/modules/Makefile_teamwork.mk
@@ -16,9 +16,7 @@ src_modules_teamwork_module_la_LDFLAGS = $(MOD_LDFLAGS)
 src_modules_teamwork_module_la_SOURCES = src/modules/teamwork/e_mod_main.c \
 src/modules/teamwork/e_mod_config.c \
 src/modules/teamwork/e_mod_main.h \
-src/modules/teamwork/e_mod_tw.c \
-src/modules/teamwork/sha1.c \
-src/modules/teamwork/sha1.h
+src/modules/teamwork/e_mod_tw.c
 
 if HAVE_WAYLAND
 src_modules_teamwork_module_la_SOURCES += \
diff --git a/src/modules/teamwork/e_mod_main.c 
b/src/modules/teamwork/e_mod_main.c
index ce24ef8..0be6ab4 100644
--- a/src/modules/teamwork/e_mod_main.c
+++ b/src/modules/teamwork/e_mod_main.c
@@ -1,5 +1,4 @@
 #include "e_mod_main.h"
-#include "sha1.h"
 
 EINTERN int _e_teamwork_log_dom = -1;
 EINTERN Mod *tw_mod = NULL;
@@ -30,23 +29,11 @@ _sha1_to_string(const unsigned char *hashout)
 }
 
 const char *
-sha1_encode(const unsigned char *data, size_t len)
+sha1_encode(const Eina_Binbuf *data)
 {
-   SHA_CTX2 ctx;
unsigned char hashout[20];
-   unsigned char *buf;
 
-   if (EINA_UNLIKELY(len > 65000))
- buf = malloc(len);
-   else
- buf = alloca(len);
-   EINA_SAFETY_ON_NULL_RETURN_VAL(buf, NULL);
-   memcpy(buf, data, len);
-
-   SHA1_Init2(&ctx);
-   SHA1_Update2(&ctx, buf, len);
-   SHA1_Final2(hashout, &ctx);
-   if (EINA_UNLIKELY(len > 65000)) free(buf);
+   emile_binbuf_sha1(data, hashout);
return _sha1_to_string(hashout);
 }
 
diff --git a/src/modules/teamwork/e_mod_main.h 
b/src/modules/teamwork/e_mod_main.h
index 9cb8695..e7f1d6a 100644
--- a/src/modules/teamwork/e_mod_main.h
+++ b/src/modules/teamwork/e_mod_main.h
@@ -1,6 +1,9 @@
 #ifndef E_MOD_MAIN_H
 #define E_MOD_MAIN_H
 
+/* We want emil_binbuf_sha1 which is beta API */
+#define EFL_BETA_API_SUPPORT
+
 #include "e.h"
 
 /**
@@ -45,7 +48,7 @@ extern Teamwork_Config *tw_config;
 extern Mod *tw_mod;
 extern int _e_teamwork_log_dom;
 
-EINTERN const char *sha1_encode(const unsigned char *data, size_t len);
+EINTERN const char *sha1_encode(const Eina_Binbuf *data);
 
 EINTERN int e_tw_init(void);
 EINTERN void e_tw_shutdown(void);
diff --git a/src/modules/teamwork/e_mod_tw.c b/src/modules/teamwork/e_mod_tw.c
index dae03d5..5c5ea3b 100644
--- a/src/modules/teamwork/e_mod_tw.c
+++ b/src/modules/teamwork/e_mod_tw.c
@@ -671,7 +671,7 @@ tw_media_add(const char *url, Eina_Binbuf *buf, unsigned 
long long timestamp, Ei
if (!media[video]) return -1;
if (!tw_config->allowed_media_age) return 0; //disk caching disabled
 
-   sha1 = sha1_encode(eina_binbuf_string_get(buf), 
eina_binbuf_length_get(buf));
+   sha1 = sha1_encode(buf);
DBG("Media: %s - %s", url, sha1);
 
list = eet_list(media[video], url, &lsize);
diff --git a/src/modules/teamwork/sha1.c b/src/modules/teamwork/sha1.c
deleted file mode 100644
index 7a53fa7..000
--- a/src/modules/teamwork/sha1.c
+++ /dev/null
@@ -1,146 +0,0 @@
-/*
- * The contents of this file are subject to the Mozilla Public
- * License Version 1.1 (the "License"); you may not use this file
- * except in compliance with the License. You may obtain a copy of
- * the License at http://www.mozilla.org/MPL/
- *
- * Software distributed under the License is distributed on an "AS
- * IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
- * implied. See the License for the specific language governing
- * rights and limitations under the License.
- *
- * The Original Code is SHA 180-1 Reference Implementation (Compact version)
- *
- * The Initial Developer of the Original Code is Paul Kocher of
- * Cryptography Research.  Portions created by Paul Kocher are
- * Copyright (C) 1995-9 by Cryptography Research, Inc.  All
- * Rights Reserved.
- *
- * Contributor(s):
- *
- * Paul Kocher
- *
- */
-
-#include "sha1.h"
-
-static void shaHashBlock(SHA_CTX2 *ctx);
-
-void
-SHA1_Init2(SHA_CTX2 *ctx) {
-   int i;
-
-   ctx->lenW = 0;
-   ctx->sizeHi = ctx->sizeLo = 0;
-
-   /* Initialize H with the magic constants (see FIPS180 for constants)
-*/
-   ctx->H[0] = 0x67452301;
-   ctx->H[1] = 0xefcdab89;
-   ctx->H[2] = 0x98badcfe;
-   ctx->H[3] = 0x10325476;

[EGIT] [core/enlightenment] master 01/01: Check for deleted client in e_pixmap_image_is_argb

2016-11-29 Thread Derek Foreman
derekf pushed a commit to branch master.

http://git.enlightenment.org/core/enlightenment.git/commit/?id=6ba85cf864f19b083f652c7c7222d2c93b3b034e

commit 6ba85cf864f19b083f652c7c7222d2c93b3b034e
Author: Derek Foreman 
Date:   Tue Nov 29 11:13:21 2016 -0600

Check for deleted client in e_pixmap_image_is_argb

Fixes a crash when closing Qt applications.
---
 src/bin/e_pixmap.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/src/bin/e_pixmap.c b/src/bin/e_pixmap.c
index 3f166d7..593f2b9 100644
--- a/src/bin/e_pixmap.c
+++ b/src/bin/e_pixmap.c
@@ -896,6 +896,7 @@ e_pixmap_image_is_argb(const E_Pixmap *cp)
 #endif
   case E_PIXMAP_TYPE_WL:
 #ifdef HAVE_WAYLAND
+if (e_object_is_del(E_OBJECT(cp->client))) return EINA_FALSE;
 if (cp->usable)
   return cp->image_argb;
 if (((E_Comp_Wl_Client_Data*)cp->client->comp_data)->cursor)

-- 




[EGIT] [tools/edi] master 02/03: ui: Don't how open context menu for directories

2016-11-29 Thread Andy Williams
ajwillia-ms pushed a commit to branch master.

http://git.enlightenment.org/tools/edi.git/commit/?id=fc89c66617418cf062ec9462d8bf716717257361

commit fc89c66617418cf062ec9462d8bf716717257361
Author: Andy Williams 
Date:   Tue Nov 29 17:08:58 2016 +

ui: Don't how open context menu for directories
---
 src/bin/edi_filepanel.c | 5 +
 1 file changed, 5 insertions(+)

diff --git a/src/bin/edi_filepanel.c b/src/bin/edi_filepanel.c
index 3f7247d..17d16a3 100644
--- a/src/bin/edi_filepanel.c
+++ b/src/bin/edi_filepanel.c
@@ -21,6 +21,7 @@ typedef struct _Edi_Dir_Data
 {
const char *path;
Eio_Monitor *monitor;
+   Eina_Bool isdir;
 } Edi_Dir_Data;
 
 static Elm_Genlist_Item_Class itc, itc2;
@@ -149,6 +150,9 @@ _item_clicked_cb(void *data EINA_UNUSED, Evas *e 
EINA_UNUSED, Evas_Object *obj,
it = elm_genlist_at_xy_item_get(obj, ev->output.x, ev->output.y, NULL);
sd = elm_object_item_data_get(it);
 
+   if (sd->isdir)
+ return;
+
if (!menu)
  _item_menu_create(_main_win);
 
@@ -342,6 +346,7 @@ _ls_main_cb(void *data,
if (info->type == EINA_FILE_DIR)
  {
 clas = &itc2;
+sd->isdir = EINA_TRUE;
  }
 
sd->path = eina_stringshare_add(info->path);

-- 




[EGIT] [tools/edi] master 03/03: Fix crash when opening a new window

2016-11-29 Thread Andy Williams
ajwillia-ms pushed a commit to branch master.

http://git.enlightenment.org/tools/edi.git/commit/?id=539953bc7260e8b47b6c12c9ddbbb06b72907692

commit 539953bc7260e8b47b6c12c9ddbbb06b72907692
Author: Andy Williams 
Date:   Tue Nov 29 17:09:25 2016 +

Fix crash when opening a new window

Since the refactoring this was duplicate freeing
@fix
---
 src/bin/mainview/edi_mainview.c | 3 ---
 1 file changed, 3 deletions(-)

diff --git a/src/bin/mainview/edi_mainview.c b/src/bin/mainview/edi_mainview.c
index 6d495a1..4964cce 100644
--- a/src/bin/mainview/edi_mainview.c
+++ b/src/bin/mainview/edi_mainview.c
@@ -491,9 +491,6 @@ edi_mainview_open_window(Edi_Path_Options *options)
 edi_mainview_item_select(it);
 _edi_mainview_item_close(it);
 _edi_mainview_items = eina_list_remove(_edi_mainview_items, it);
-
-eina_stringshare_del(it->path);
-free(it);
  }
 
if (options->type == NULL)

-- 




[EGIT] [tools/edi] master 01/03: ui: Fix file listing to stop duplicating entries

2016-11-29 Thread Andy Williams
ajwillia-ms pushed a commit to branch master.

http://git.enlightenment.org/tools/edi.git/commit/?id=bee632e5a1734a93fdc604f6fe20cc9849ca3b14

commit bee632e5a1734a93fdc604f6fe20cc9849ca3b14
Author: Andy Williams 
Date:   Tue Nov 29 17:03:45 2016 +

ui: Fix file listing to stop duplicating entries

Working towards a proper refresh of the UI on change...
@fix
---
 src/bin/edi_filepanel.c | 137 
 src/bin/edi_main.c  |   5 +-
 src/bin/edi_private.h   |   3 --
 3 files changed, 70 insertions(+), 75 deletions(-)

diff --git a/src/bin/edi_filepanel.c b/src/bin/edi_filepanel.c
index 23478a6..3f7247d 100644
--- a/src/bin/edi_filepanel.c
+++ b/src/bin/edi_filepanel.c
@@ -17,6 +17,12 @@
 
 #include "edi_private.h"
 
+typedef struct _Edi_Dir_Data
+{
+   const char *path;
+   Eio_Monitor *monitor;
+} Edi_Dir_Data;
+
 static Elm_Genlist_Item_Class itc, itc2;
 static Evas_Object *list;
 static edi_filepanel_item_clicked_cb _open_cb;
@@ -25,9 +31,12 @@ static Evas_Object *menu, *_main_win, *_filepanel_box, 
*_filter_box, *_filter;
 static const char *_menu_cb_path, *_root_path;
 static regex_t _filter_regex;
 static Eina_Bool _filter_set = EINA_FALSE;
+static Edi_Dir_Data *_root_dir;
 
 static void
-_populate(Evas_Object *obj, const char *path, Elm_Object_Item *parent_it, 
const char *selected);
+_file_listing_fill(Edi_Dir_Data *dir, Elm_Object_Item *parent_it);
+static void
+_file_listing_empty(Edi_Dir_Data *dir, Elm_Object_Item *parent_it);
 
 static void
 _item_menu_open_cb(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED,
@@ -132,18 +141,18 @@ _item_clicked_cb(void *data EINA_UNUSED, Evas *e 
EINA_UNUSED, Evas_Object *obj,
 {
Evas_Event_Mouse_Down *ev;
Elm_Object_Item *it;
-   const char *path;
+   Edi_Dir_Data *sd;
 
ev = event_info;
if (ev->button != 3) return;
 
it = elm_genlist_at_xy_item_get(obj, ev->output.x, ev->output.y, NULL);
-   path = elm_object_item_data_get(it);
+   sd = elm_object_item_data_get(it);
 
if (!menu)
  _item_menu_create(_main_win);
 
-   _menu_cb_path = eina_stringshare_add(path);
+   _menu_cb_path = eina_stringshare_add(sd->path);
elm_menu_move(menu, ev->canvas.x, ev->canvas.y);
evas_object_show(menu);
 }
@@ -151,7 +160,9 @@ _item_clicked_cb(void *data EINA_UNUSED, Evas *e 
EINA_UNUSED, Evas_Object *obj,
 static char *
 _text_get(void *data, Evas_Object *obj EINA_UNUSED, const char *source 
EINA_UNUSED)
 {
-   return strdup(basename(data));
+   Edi_Dir_Data *sd = data;
+
+   return strdup(basename((char *)sd->path));
 }
 
 static Eina_Hash *mime_entries = NULL;
@@ -172,13 +183,15 @@ _get_provider_from_hashset(const char *filename)
 static Evas_Object *
 _content_get(void *data, Evas_Object *obj, const char *source)
 {
+   Edi_Content_Provider *provider;
+   Edi_Dir_Data *sd = data;
+   Evas_Object *ic;
+
if (strcmp(source, "elm.swallow.icon"))
  return NULL;
 
-   Edi_Content_Provider *provider;
-   provider = _get_provider_from_hashset((const char *)data);
+   provider = _get_provider_from_hashset(sd->path);
 
-   Evas_Object *ic;
ic = elm_icon_add(obj);
if (provider)
  elm_icon_standard_set(ic, provider->icon);
@@ -194,16 +207,18 @@ _content_get(void *data, Evas_Object *obj, const char 
*source)
 static void
 _item_del(void *data, Evas_Object *obj EINA_UNUSED)
 {
-   eina_stringshare_del(data);
+   Edi_Dir_Data *sd = data;
+
+   eina_stringshare_del(sd->path);
 }
 
 static void
 _item_sel(void *data, Evas_Object *obj EINA_UNUSED, void *event_info 
EINA_UNUSED)
 {
-   const char *path = data;
+   Edi_Dir_Data *sd = data;
 
-   if (!ecore_file_is_dir(path))
- _open_cb(path, NULL, EINA_FALSE);
+   if (!ecore_file_is_dir(sd->path))
+ _open_cb(sd->path, NULL, EINA_FALSE);
 }
 
 static Evas_Object *
@@ -231,11 +246,14 @@ _ls_filter_cb(void *data EINA_UNUSED, Eio_File *handler 
EINA_UNUSED,
 static int
 _file_list_cmp(const void *data1, const void *data2)
 {
+   Edi_Dir_Data *sd1, *sd2;
+
const Elm_Object_Item *item1 = data1;
const Elm_Object_Item *item2 = data2;
const Elm_Genlist_Item_Class *ca = elm_genlist_item_item_class_get(item1);
const Elm_Genlist_Item_Class *cb = elm_genlist_item_item_class_get(item2);
 
+   // move dirs to the top
if (ca == &itc2)
  {
 if (cb != &itc2)
@@ -246,17 +264,16 @@ _file_list_cmp(const void *data1, const void *data2)
 return 1;
  }
 
-   const char *name1 = elm_object_item_data_get(item1);
-   const char *name2 = elm_object_item_data_get(item2);
+   sd1 = elm_object_item_data_get(item1);
+   sd2 = elm_object_item_data_get(item2);
 
-   return strcasecmp(name1, name2);
+   return strcasecmp(sd1->path, sd2->path);
 }
 
 static void
 _listing_request_cleanup(Listing_Request *lreq)
 {
eina_stringshare_del(lreq->path);
-   eina_stringshare_del(lreq->selected_path);
free(lreq);
 }
 
@@ -281,24 +298,25 @@ _on_list_contract_req(void *data   EINA_UNUSED,
 }
 
 static void
-_on

[EGIT] [core/enlightenment] master 05/06: always send valid size geom when configuring xdg6 popups

2016-11-29 Thread Mike Blumenkrantz
discomfitor pushed a commit to branch master.

http://git.enlightenment.org/core/enlightenment.git/commit/?id=632e4097b5bf1fdd6caef80a8d8d5fd461497b28

commit 632e4097b5bf1fdd6caef80a8d8d5fd461497b28
Author: Mike Blumenkrantz 
Date:   Tue Nov 29 11:44:29 2016 -0500

always send valid size geom when configuring xdg6 popups

sending 0x0 here when passed (which happens during initial commit)
breaks the universe
---
 src/modules/wl_desktop_shell/xdg6.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/modules/wl_desktop_shell/xdg6.c 
b/src/modules/wl_desktop_shell/xdg6.c
index 3debdf1..22b10ef 100644
--- a/src/modules/wl_desktop_shell/xdg6.c
+++ b/src/modules/wl_desktop_shell/xdg6.c
@@ -386,7 +386,7 @@ _e_xdg_shell_surface_configure_send(struct wl_resource 
*resource, uint32_t edges
 
 shd = ec->comp_data->shell.data;
 serial = wl_display_next_serial(e_comp_wl->wl.disp);
-zxdg_popup_v6_send_configure(resource, ec->x - ec->parent->x, ec->y - 
ec->parent->y, width, height);
+zxdg_popup_v6_send_configure(resource, ec->x - ec->parent->x, ec->y - 
ec->parent->y, width ?: ec->w, height ?: ec->h);
 zxdg_surface_v6_send_configure(shd->surface, serial);
 return;
  }

-- 




[EGIT] [core/enlightenment] master 06/06: check gravity variable for gravities when applying xdg6 positioners

2016-11-29 Thread Mike Blumenkrantz
discomfitor pushed a commit to branch master.

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

commit f5788293b5a374e1050870b86060a669050c324c
Author: Mike Blumenkrantz 
Date:   Tue Nov 29 11:45:09 2016 -0500

check gravity variable for gravities when applying xdg6 positioners

fixes positioning

--(typo--)
---
 src/modules/wl_desktop_shell/xdg6.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/src/modules/wl_desktop_shell/xdg6.c 
b/src/modules/wl_desktop_shell/xdg6.c
index 22b10ef..f39f928 100644
--- a/src/modules/wl_desktop_shell/xdg6.c
+++ b/src/modules/wl_desktop_shell/xdg6.c
@@ -659,7 +659,7 @@ _apply_positioner_x(int x, Positioner *p, Eina_Bool invert)
if (grav & ZXDG_POSITIONER_V6_GRAVITY_LEFT)
  x -= p->size.w;
/* center on anchor */
-   else if (!(an & ZXDG_POSITIONER_V6_GRAVITY_RIGHT))
+   else if (!(grav & ZXDG_POSITIONER_V6_GRAVITY_RIGHT))
  x -= p->size.w / 2;
return x;
 }
@@ -701,7 +701,7 @@ _apply_positioner_y(int y, Positioner *p, Eina_Bool invert)
if (grav & ZXDG_POSITIONER_V6_GRAVITY_TOP)
  y -= p->size.h;
/* center on anchor */
-   else if (!(an & ZXDG_POSITIONER_V6_GRAVITY_BOTTOM))
+   else if (!(grav & ZXDG_POSITIONER_V6_GRAVITY_BOTTOM))
  y -= p->size.h / 2;
return y;
 }

-- 




[EGIT] [core/enlightenment] master 01/06: correctly handle xdg surface deletion and pointer clearing

2016-11-29 Thread Mike Blumenkrantz
discomfitor pushed a commit to branch master.

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

commit 2a9d4e73c5fce24fda93d1ff18610ec0cf1a8583
Author: Mike Blumenkrantz 
Date:   Tue Nov 29 11:08:46 2016 -0500

correctly handle xdg surface deletion and pointer clearing

fixes crashing/leaking when deleting surfaces
---
 src/modules/wl_desktop_shell/e_mod_main.c | 14 +-
 1 file changed, 5 insertions(+), 9 deletions(-)

diff --git a/src/modules/wl_desktop_shell/e_mod_main.c 
b/src/modules/wl_desktop_shell/e_mod_main.c
index c818b9f..5f10da9 100644
--- a/src/modules/wl_desktop_shell/e_mod_main.c
+++ b/src/modules/wl_desktop_shell/e_mod_main.c
@@ -24,19 +24,15 @@ e_shell_surface_destroy(struct wl_resource *resource)
 ec->comp_data->grab = 0;
  }
 
-   shd = ec->comp_data->shell.data;
 
+   if (resource == ec->comp_data->shell.surface)
+ ec->comp_data->shell.surface = NULL;
+   shd = ec->comp_data->shell.data;
if (shd)
  {
 E_FREE_LIST(shd->pending, free);
-if ((resource == ec->comp_data->shell.surface) || (resource == 
shd->surface))
-  {
- if (ec->comp_data->shell.surface == resource)
-   ec->comp_data->shell.surface = NULL;
- else
-   shd->surface = NULL;
- E_FREE(ec->comp_data->shell.data);
-  }
+if (resource == shd->surface)
+  E_FREE(ec->comp_data->shell.data);
  }
 
if (ec->comp_data->mapped)

-- 




[EGIT] [core/enlightenment] master 03/06: handle illegal xdg-shell resource unbinds

2016-11-29 Thread Mike Blumenkrantz
discomfitor pushed a commit to branch master.

http://git.enlightenment.org/core/enlightenment.git/commit/?id=7851769eab9a0b50f1feb9b6c7ca1712c67ac860

commit 7851769eab9a0b50f1feb9b6c7ca1712c67ac860
Author: Mike Blumenkrantz 
Date:   Tue Nov 29 11:11:02 2016 -0500

handle illegal xdg-shell resource unbinds

this occurs when the shell resource dies before all the surfaces/positioners
are destroyed. usually this means the client has aborted, so there's no 
point in
sending an error or doing anything beyond performing a thorough cleanup
---
 src/modules/wl_desktop_shell/xdg6.c | 37 +
 1 file changed, 33 insertions(+), 4 deletions(-)

diff --git a/src/modules/wl_desktop_shell/xdg6.c 
b/src/modules/wl_desktop_shell/xdg6.c
index 45e4ab3..2e051bf 100644
--- a/src/modules/wl_desktop_shell/xdg6.c
+++ b/src/modules/wl_desktop_shell/xdg6.c
@@ -29,6 +29,7 @@ typedef struct v6_Shell_Data
 typedef struct Positioner
 {
v6_Shell_Data *v;
+   struct wl_resource *res;
Evas_Coord_Size size;
Eina_Rectangle anchor_rect;
enum zxdg_positioner_v6_anchor anchor;
@@ -147,6 +148,7 @@ _e_xdg_shell_positioner_destroy(struct wl_resource 
*resource)
Positioner *p;
 
p = wl_resource_get_user_data(resource);
+   if (!p) return;
if (p->v) p->v->positioners = eina_list_remove(p->v->positioners, p);
free(p);
 }
@@ -162,6 +164,8 @@ _e_xdg_shell_cb_positioner_create(struct wl_client *client, 
struct wl_resource *
res = wl_resource_create(client, &zxdg_positioner_v6_interface, 1, id);
p = E_NEW(Positioner, 1);
p->v = v;
+   p->res = res;
+   v->positioners = eina_list_append(v->positioners, p);
wl_resource_set_implementation(res, &_e_xdg_positioner_interface, p, 
_e_xdg_shell_positioner_destroy);
wl_resource_set_user_data(res, p);
 }
@@ -1291,10 +1295,16 @@ _e_xdg_shell_cb_surface_get(struct wl_client *client, 
struct wl_resource *resour
 static void
 _e_xdg_shell_cb_pong(struct wl_client *client EINA_UNUSED, struct wl_resource 
*resource, uint32_t serial EINA_UNUSED)
 {
-   E_Client *ec;
+   v6_Shell_Data *v;
+   Eina_List *l;
+   struct wl_resource *res;
 
-   if ((ec = wl_resource_get_user_data(resource)))
+   v = wl_resource_get_user_data(resource);
+   EINA_LIST_FOREACH(v->surfaces, l, res)
  {
+E_Client *ec = wl_resource_get_user_data(res);
+
+if (!ec) continue;
 ec->ping_ok = EINA_TRUE;
 ec->hung = EINA_FALSE;
  }
@@ -1312,12 +1322,31 @@ static void
 _e_xdg_shell_cb_unbind(struct wl_resource *resource)
 {
v6_Shell_Data *v;
+   Positioner *p;
+   struct wl_resource *res;
+   Eina_List *l, *ll;
struct wl_client *client = wl_resource_get_client(resource);
 
v = wl_resource_get_user_data(resource);
eina_hash_set(shell_resources, &client, NULL);
-   E_FREE_LIST(v->surfaces, e_shell_surface_cb_destroy);
-   v->positioners = eina_list_free(v->positioners);
+   EINA_LIST_REVERSE_FOREACH_SAFE(v->surfaces, l, ll, res)
+ {
+E_Client *ec = wl_resource_get_user_data(res);
+E_Shell_Data *shd;
+
+if (ec->comp_data->shell.surface)
+  e_shell_surface_cb_destroy(ec->comp_data->shell.surface);
+shd = ec->comp_data->shell.data;
+if (shd)
+  e_shell_surface_cb_destroy(shd->surface);
+v->surfaces = eina_list_remove_list(v->surfaces, l);
+ }
+
+   EINA_LIST_FREE(v->positioners, p)
+ {
+wl_resource_set_user_data(p->res, NULL);
+free(p);
+ }
free(v);
 }
 

-- 




[EGIT] [core/enlightenment] master 04/06: fix use of E_CONTAINS macro for xdg-shell positioners

2016-11-29 Thread Mike Blumenkrantz
discomfitor pushed a commit to branch master.

http://git.enlightenment.org/core/enlightenment.git/commit/?id=79d157f5d55cb1b67fa6aeae1fb7afac003db867

commit 79d157f5d55cb1b67fa6aeae1fb7afac003db867
Author: Mike Blumenkrantz 
Date:   Tue Nov 29 11:30:27 2016 -0500

fix use of E_CONTAINS macro for xdg-shell positioners

last week was backwards week
---
 src/modules/wl_desktop_shell/xdg6.c | 22 +++---
 1 file changed, 11 insertions(+), 11 deletions(-)

diff --git a/src/modules/wl_desktop_shell/xdg6.c 
b/src/modules/wl_desktop_shell/xdg6.c
index 2e051bf..3debdf1 100644
--- a/src/modules/wl_desktop_shell/xdg6.c
+++ b/src/modules/wl_desktop_shell/xdg6.c
@@ -734,7 +734,7 @@ _apply_positioner(E_Client *ec, Positioner *p)
e_zone_useful_geometry_get(ec->parent->zone, &zx, &zy, &zw, &zh);
 
 #define CONSTRAINED(EC, X, Y) \
-   !E_CONTAINS((X), (Y), (EC)->w, (EC)->h, zx, zy, zw, zh)
+   !E_CONTAINS(zx, zy, zw, zh, (X), (Y), (EC)->w, (EC)->h)
 
if (!CONSTRAINED(ec, ec->x, ec->y)) return;
 
@@ -744,28 +744,28 @@ _apply_positioner(E_Client *ec, Positioner *p)
 - resize
 */
if ((p->constrain & ZXDG_POSITIONER_V6_CONSTRAINT_ADJUSTMENT_FLIP_X) &&
-   (!E_CONTAINS(ec->x, zy, ec->w, 1, zx, zy, zw, zh)))
+   (!E_CONTAINS(zx, zy, zw, zh, ec->x, zy, ec->w, 1)))
  {
 int fx;
 
 fx = _apply_positioner_x(x, p, 1);
-if (E_CONTAINS(fx, zy, ec->w, 1, zx, zy, zw, zh))
+if (E_CONTAINS(zx, zy, zw, zh, fx, zy, ec->w, 1))
   ec->x = fx;
  }
if (!CONSTRAINED(ec, ec->x, ec->y)) return;
if ((p->constrain & ZXDG_POSITIONER_V6_CONSTRAINT_ADJUSTMENT_FLIP_Y) &&
-   (!E_CONTAINS(zx, ec->y, 1, ec->h, zx, zy, zw, zh)))
+   (!E_CONTAINS(zx, zy, zw, zh, zx, ec->y, 1, ec->h)))
  {
 int fy;
 
 fy = _apply_positioner_y(y, p, 1);
-if (E_CONTAINS(zx, fy, 1, ec->h, zx, zy, zw, zh))
+if (E_CONTAINS(zx, zy, zw, zh, zx, fy, 1, ec->h))
   ec->y = fy;
  }
if (!CONSTRAINED(ec, ec->x, ec->y)) return;
 
if ((p->constrain & ZXDG_POSITIONER_V6_CONSTRAINT_ADJUSTMENT_SLIDE_X) &&
-   (!E_CONTAINS(ec->x, zy, ec->w, 1, zx, zy, zw, zh)))
+   (!E_CONTAINS(zx, zy, zw, zh, ec->x, zy, ec->w, 1)))
  {
 int sx = ec->x;
 
@@ -783,12 +783,12 @@ _apply_positioner(E_Client *ec, Positioner *p)
  else if (ec->x + ec->w > zx + zw)
sx = MAX(zx + zw - ec->w, ec->parent->x);
   }
-if (E_CONTAINS(sx, zy, ec->w, 1, zx, zy, zw, zh))
+if (E_CONTAINS(zx, zy, zw, zh, sx, zy, ec->w, 1))
   ec->x = sx;
  }
if (!CONSTRAINED(ec, ec->x, ec->y)) return;
if ((p->constrain & ZXDG_POSITIONER_V6_CONSTRAINT_ADJUSTMENT_SLIDE_Y) &&
-   (!E_CONTAINS(zx, ec->y, 1, ec->h, zx, zy, zw, zh)))
+   (!E_CONTAINS(zx, zy, zw, zh, zx, ec->y, 1, ec->h)))
  {
 int sy = ec->y;
 
@@ -806,20 +806,20 @@ _apply_positioner(E_Client *ec, Positioner *p)
  else if (ec->y + ec->h > zy + zh)
sy = MAX(zy + zh - ec->h, ec->parent->y);
   }
-if (E_CONTAINS(zx, sy, 1, ec->h, zx, zy, zw, zh))
+if (E_CONTAINS(zx, zy, zw, zh, zx, sy, 1, ec->h))
   ec->y = sy;
  }
if (!CONSTRAINED(ec, ec->x, ec->y)) return;
 
if ((p->constrain & ZXDG_POSITIONER_V6_CONSTRAINT_ADJUSTMENT_RESIZE_X) &&
-   (!E_CONTAINS(ec->x, zy, ec->w, 1, zx, zy, zw, zh)))
+   (!E_CONTAINS(zx, zy, zw, zh, ec->x, zy, ec->w, 1)))
  {
 ec->w = zx + zw - ec->x;
 ec->changes.size = 1;
 if (!CONSTRAINED(ec, ec->x, ec->y)) return;
  }
if ((p->constrain & ZXDG_POSITIONER_V6_CONSTRAINT_ADJUSTMENT_RESIZE_Y) &&
-   (!E_CONTAINS(zx, ec->y, 1, ec->h, zx, zy, zw, zh)))
+   (!E_CONTAINS(zx, zy, zw, zh, zx, ec->y, 1, ec->h)))
  {
 ec->h = zy + zh - ec->y;
 ec->changes.size = 1;

-- 




[EGIT] [core/enlightenment] master 02/06: destroy xdg role surfaces if base surface is destroyed

2016-11-29 Thread Mike Blumenkrantz
discomfitor pushed a commit to branch master.

http://git.enlightenment.org/core/enlightenment.git/commit/?id=50b2712f61d16550eadf7ae9c80d629b0bf687ea

commit 50b2712f61d16550eadf7ae9c80d629b0bf687ea
Author: Mike Blumenkrantz 
Date:   Tue Nov 29 11:09:31 2016 -0500

destroy xdg role surfaces if base surface is destroyed

this is illegal, but at least we should not leak the client when it happens
---
 src/modules/wl_desktop_shell/xdg6.c | 6 ++
 1 file changed, 6 insertions(+)

diff --git a/src/modules/wl_desktop_shell/xdg6.c 
b/src/modules/wl_desktop_shell/xdg6.c
index 7e5d8e1..45e4ab3 100644
--- a/src/modules/wl_desktop_shell/xdg6.c
+++ b/src/modules/wl_desktop_shell/xdg6.c
@@ -1217,6 +1217,12 @@ _e_xdg_shell_surface_cb_destroy(struct wl_resource 
*resource)
 
if (e_object_is_del(E_OBJECT(ec))) return;
 
+   if (ec->comp_data->shell.surface)
+ {
+wl_resource_post_error(resource, ZXDG_SHELL_V6_ERROR_DEFUNCT_SURFACES, 
"shell surface destroyed before role surfaces");
+e_shell_surface_cb_destroy(ec->comp_data->shell.surface);
+ }
+
shd = ec->comp_data->shell.data;
if (shd)
  ((v6_Shell_Data*)shd->shell)->surfaces = 
eina_list_remove(((v6_Shell_Data*)shd->shell)->surfaces, resource);

-- 




[EGIT] [core/enlightenment] master 01/02: handle xdg-shell maximize/unmaximize calls correctly

2016-11-29 Thread Mike Blumenkrantz
discomfitor pushed a commit to branch master.

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

commit bf40d92ad83f64bc004695094f881c6cbb97ddb2
Author: Mike Blumenkrantz 
Date:   Tue Nov 29 10:05:21 2016 -0500

handle xdg-shell maximize/unmaximize calls correctly
---
 src/modules/wl_desktop_shell/xdg5.c | 8 
 src/modules/wl_desktop_shell/xdg6.c | 8 
 2 files changed, 8 insertions(+), 8 deletions(-)

diff --git a/src/modules/wl_desktop_shell/xdg5.c 
b/src/modules/wl_desktop_shell/xdg5.c
index 577393b..4fd0313 100644
--- a/src/modules/wl_desktop_shell/xdg5.c
+++ b/src/modules/wl_desktop_shell/xdg5.c
@@ -75,7 +75,7 @@ _xdg_shell_surface_send_configure(struct wl_resource 
*resource, Eina_Bool fullsc
  {
 if (fullscreen)
   pending |= STATE_FULLSCREEN;
-else
+else if (ec->fullscreen)
   pending |= STATE_UNFULLSCREEN;
  }
shd->fullscreen = fullscreen;
@@ -83,7 +83,7 @@ _xdg_shell_surface_send_configure(struct wl_resource 
*resource, Eina_Bool fullsc
  {
 if (maximized)
   pending |= STATE_MAXIMIZED;
-else
+else if (ec->maximized)
   pending |= STATE_UNMAXIMIZED;
  }
shd->maximized = maximized;
@@ -349,11 +349,13 @@ _e_xdg_shell_surface_cb_ack_configure(struct wl_client 
*client EINA_UNUSED, stru
   {
  ec->comp_data->shell.set.maximize = 1;
  ec->comp_data->shell.set.unmaximize = 0;
+ ec->comp_data->max = (e_config->maximize_policy & 
E_MAXIMIZE_TYPE) | E_MAXIMIZE_BOTH;
   }
 if (ps->state & STATE_UNMAXIMIZED)
   {
  ec->comp_data->shell.set.unmaximize = 1;
  ec->comp_data->shell.set.maximize = 0;
+ ec->comp_data->unmax = (e_config->maximize_policy & 
E_MAXIMIZE_TYPE) | E_MAXIMIZE_BOTH;
   }
 shd->pending = eina_list_remove_list(shd->pending, l);
 free(ps);
@@ -427,7 +429,6 @@ _e_xdg_shell_surface_cb_maximized_unset(struct wl_client 
*client EINA_UNUSED, st
if (e_object_is_del(E_OBJECT(ec))) return;
 
if (ec->lock_user_maximize) return;
-   ec->comp_data->unmax = (e_config->maximize_policy & E_MAXIMIZE_TYPE) | 
E_MAXIMIZE_BOTH;
if (e_config->window_maximize_animate && (!ec->maximize_anims_disabled))
  w = ec->w, h = ec->h;
else
@@ -489,7 +490,6 @@ _e_xdg_shell_surface_cb_minimized_set(struct wl_client 
*client EINA_UNUSED, stru
 
if (ec->lock_user_iconify) return;
ec->comp_data->shell.set.minimize = 1;
-   ec->comp_data->max = (e_config->maximize_policy & E_MAXIMIZE_TYPE) | 
E_MAXIMIZE_BOTH;
 }
 
 static const struct xdg_surface_interface _e_xdg_surface_interface =
diff --git a/src/modules/wl_desktop_shell/xdg6.c 
b/src/modules/wl_desktop_shell/xdg6.c
index 588ba11..7e5d8e1 100644
--- a/src/modules/wl_desktop_shell/xdg6.c
+++ b/src/modules/wl_desktop_shell/xdg6.c
@@ -322,7 +322,7 @@ _xdg_shell_surface_send_configure(struct wl_resource 
*resource, Eina_Bool fullsc
  {
 if (fullscreen)
   pending |= STATE_FULLSCREEN;
-else
+else if (ec->fullscreen)
   pending |= STATE_UNFULLSCREEN;
  }
shd->fullscreen = fullscreen;
@@ -330,7 +330,7 @@ _xdg_shell_surface_send_configure(struct wl_resource 
*resource, Eina_Bool fullsc
  {
 if (maximized)
   pending |= STATE_MAXIMIZED;
-else
+else if (ec->maximized)
   pending |= STATE_UNMAXIMIZED;
  }
shd->maximized = maximized;
@@ -475,11 +475,13 @@ _e_xdg_surface_cb_ack_configure(struct wl_client *client 
EINA_UNUSED, struct wl_
   {
  ec->comp_data->shell.set.maximize = 1;
  ec->comp_data->shell.set.unmaximize = 0;
+ ec->comp_data->max = (e_config->maximize_policy & 
E_MAXIMIZE_TYPE) | E_MAXIMIZE_BOTH;
   }
 if (ps->state & STATE_UNMAXIMIZED)
   {
  ec->comp_data->shell.set.unmaximize = 1;
  ec->comp_data->shell.set.maximize = 0;
+ ec->comp_data->unmax = (e_config->maximize_policy & 
E_MAXIMIZE_TYPE) | E_MAXIMIZE_BOTH;
   }
 shd->pending = eina_list_remove_list(shd->pending, l);
 free(ps);
@@ -553,7 +555,6 @@ _e_xdg_toplevel_cb_maximized_unset(struct wl_client *client 
EINA_UNUSED, struct
if (e_object_is_del(E_OBJECT(ec))) return;
 
if (ec->lock_user_maximize) return;
-   ec->comp_data->unmax = (e_config->maximize_policy & E_MAXIMIZE_TYPE) | 
E_MAXIMIZE_BOTH;
if (e_config->window_maximize_animate && (!ec->maximize_anims_disabled))
  w = ec->w, h = ec->h;
else
@@ -615,7 +616,6 @@ _e_xdg_toplevel_cb_minimized_set(struct wl_client *client 
EINA_UNUSED, struct wl
 
if (ec->lock_user_iconify) return;
ec->comp_data->shell.set.minimize = 1;
-   ec->comp_data->max = (e_config->maximize_policy & E_MAXIMIZE_TYPE) | 
E_MAXIMIZE_BOTH;
 }
 
 static int

-- 




[EGIT] [core/enlightenment] master 02/02: stack subsurfaces above their parents upon creation

2016-11-29 Thread Mike Blumenkrantz
discomfitor pushed a commit to branch master.

http://git.enlightenment.org/core/enlightenment.git/commit/?id=19a902ec094646c4a959a7c75c8691d65c7941fb

commit 19a902ec094646c4a959a7c75c8691d65c7941fb
Author: Mike Blumenkrantz 
Date:   Tue Nov 29 10:08:49 2016 -0500

stack subsurfaces above their parents upon creation

handles the case where no explicit stacking is set on the subsurface
---
 src/bin/e_comp_wl.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/src/bin/e_comp_wl.c b/src/bin/e_comp_wl.c
index 1f45171..1d0cba7 100644
--- a/src/bin/e_comp_wl.c
+++ b/src/bin/e_comp_wl.c
@@ -2351,6 +2351,8 @@ _e_comp_wl_subsurface_create(E_Client *ec, E_Client *epc, 
uint32_t id, struct wl
 
ec->comp_data->surface = surface_resource;
ec->comp_data->sub.data = sdata;
+   evas_object_layer_set(ec->frame, evas_object_layer_get(epc->frame));
+   evas_object_stack_above(ec->frame, epc->frame);
 
return EINA_TRUE;
 

-- 




[EGIT] [core/efl] master 02/02: ecore-drm2: Add API function to allow setting gamma of a given output

2016-11-29 Thread Christopher Michael
devilhorns pushed a commit to branch master.

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

commit 6b350fc696de250389fdabe5e901a96ac35b110d
Author: Chris Michael 
Date:   Tue Nov 29 09:15:07 2016 -0500

ecore-drm2: Add API function to allow setting gamma of a given output

Small patch to add an API function which will allow setting the gamma
level of a given output.

@feature

Signed-off-by: Chris Michael 
---
 src/lib/ecore_drm2/Ecore_Drm2.h | 16 
 src/lib/ecore_drm2/ecore_drm2_outputs.c | 15 ++-
 2 files changed, 30 insertions(+), 1 deletion(-)

diff --git a/src/lib/ecore_drm2/Ecore_Drm2.h b/src/lib/ecore_drm2/Ecore_Drm2.h
index 708e31a..863a9c6 100644
--- a/src/lib/ecore_drm2/Ecore_Drm2.h
+++ b/src/lib/ecore_drm2/Ecore_Drm2.h
@@ -705,6 +705,22 @@ EAPI void 
ecore_drm2_output_resolution_get(Ecore_Drm2_Output *output, int *w, in
 EAPI Eina_Bool ecore_drm2_output_possible_crtc_get(Ecore_Drm2_Output *output, 
unsigned int crtc);
 
 /**
+ * Set the gamma level of an Ecore_Drm_Output
+ *
+ * This function will set the gamma of an Ecore_Drm2_Output
+ *
+ * @param output The Ecore_Drm2_Output to set the gamma level on
+ * @param size The gamma table size to set
+ * @param red The amount to scale the red channel
+ * @param green The amount to scale the green channel
+ * @param blue The amount to scale the blue channel
+ *
+ * @ingroup Ecore_Drm2_Output_Group
+ * @since 1.19
+ */
+EAPI void ecore_drm2_output_gamma_set(Ecore_Drm2_Output *output, uint16_t 
size, uint16_t *red, uint16_t *green, uint16_t *blue);
+
+/**
  * @defgroup Ecore_Drm2_Fb_Group Drm framebuffer functions
  *
  * Functions that deal with setup of framebuffers
diff --git a/src/lib/ecore_drm2/ecore_drm2_outputs.c 
b/src/lib/ecore_drm2/ecore_drm2_outputs.c
index bd0703d..c9f7dde 100644
--- a/src/lib/ecore_drm2/ecore_drm2_outputs.c
+++ b/src/lib/ecore_drm2/ecore_drm2_outputs.c
@@ -754,7 +754,7 @@ _output_create(Ecore_Drm2_Device *dev, const drmModeRes 
*res, const drmModeConne
 
_output_backlight_init(output, conn->connector_type);
 
-   /* TODO: gamma */
+   output->gamma = output->ocrtc->gamma_size;
 
_output_modes_create(dev, output, conn);
 
@@ -1501,3 +1501,16 @@ ecore_drm2_output_release_handler_set(Ecore_Drm2_Output 
*o, Ecore_Drm2_Release_H
o->release_data = data;
o->release_cb = cb;
 }
+
+EAPI void
+ecore_drm2_output_gamma_set(Ecore_Drm2_Output *output, uint16_t size, uint16_t 
*red, uint16_t *green, uint16_t *blue)
+{
+   EINA_SAFETY_ON_NULL_RETURN(output);
+   EINA_SAFETY_ON_TRUE_RETURN(output->fd < 0);
+
+   if (output->gamma != size) return;
+
+   if (sym_drmModeCrtcSetGamma(output->fd, output->crtc_id, size,
+   red, green, blue) < 0)
+ ERR("Failed to set gamma for Output %s: %m", output->name);
+}

-- 




[EGIT] [core/efl] master 01/02: ecore-drm2: Add symlink to gamma setting function

2016-11-29 Thread Christopher Michael
devilhorns pushed a commit to branch master.

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

commit 4b4201584f663c2b9b04017689967cd4186be20e
Author: Chris Michael 
Date:   Tue Nov 29 09:14:31 2016 -0500

ecore-drm2: Add symlink to gamma setting function

Signed-off-by: Chris Michael 
---
 src/lib/ecore_drm2/ecore_drm2.c | 2 ++
 src/lib/ecore_drm2/ecore_drm2_private.h | 2 ++
 2 files changed, 4 insertions(+)

diff --git a/src/lib/ecore_drm2/ecore_drm2.c b/src/lib/ecore_drm2/ecore_drm2.c
index df0eb2d..491ed47 100644
--- a/src/lib/ecore_drm2/ecore_drm2.c
+++ b/src/lib/ecore_drm2/ecore_drm2.c
@@ -44,6 +44,7 @@ int (*sym_drmModeAddFB)(int fd, uint32_t width, uint32_t 
height, uint8_t depth,
 int (*sym_drmModeRmFB)(int fd, uint32_t bufferId) = NULL;
 int (*sym_drmModePageFlip)(int fd, uint32_t crtc_id, uint32_t fb_id, uint32_t 
flags, void *user_data) = NULL;
 int (*sym_drmModeDirtyFB)(int fd, uint32_t bufferId, drmModeClipPtr clips, 
uint32_t num_clips) = NULL;
+int (*sym_drmModeCrtcSetGamma)(int fd, uint32_t crtc_id, uint32_t size, 
uint16_t *red, uint16_t *green, uint16_t *blue) = NULL;
 
 EAPI int ECORE_DRM2_EVENT_OUTPUT_CHANGED = -1;
 EAPI int ECORE_DRM2_EVENT_ACTIVATE = -1;
@@ -119,6 +120,7 @@ _ecore_drm2_link(void)
 SYM(drm_lib, drmModeRmFB);
 SYM(drm_lib, drmModePageFlip);
 SYM(drm_lib, drmModeDirtyFB);
+SYM(drm_lib, drmModeCrtcSetGamma);
 
 if (fail)
   {
diff --git a/src/lib/ecore_drm2/ecore_drm2_private.h 
b/src/lib/ecore_drm2/ecore_drm2_private.h
index 0f1fe16..73b71b0 100644
--- a/src/lib/ecore_drm2/ecore_drm2_private.h
+++ b/src/lib/ecore_drm2/ecore_drm2_private.h
@@ -725,6 +725,7 @@ struct _Ecore_Drm2_Output
uint32_t subpixel;
uint32_t crtc_id, conn_id, conn_type;
uint32_t scale;
+   uint16_t gamma;
 
struct
  {
@@ -845,5 +846,6 @@ extern int (*sym_drmModeAddFB)(int fd, uint32_t width, 
uint32_t height, uint8_t
 extern int (*sym_drmModeRmFB)(int fd, uint32_t bufferId);
 extern int (*sym_drmModePageFlip)(int fd, uint32_t crtc_id, uint32_t fb_id, 
uint32_t flags, void *user_data);
 extern int (*sym_drmModeDirtyFB)(int fd, uint32_t bufferId, drmModeClipPtr 
clips, uint32_t num_clips);
+extern int (*sym_drmModeCrtcSetGamma)(int fd, uint32_t crtc_id, uint32_t size, 
uint16_t *red, uint16_t *green, uint16_t *blue);
 
 #endif

-- 




[EGIT] [core/enlightenment] master 01/01: remove unused variable in Luncher module

2016-11-29 Thread Christopher Michael
devilhorns pushed a commit to branch master.

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

commit d3b5b5a48dc8b314bbd983afb62d707928c72f3b
Author: Chris Michael 
Date:   Tue Nov 29 08:56:55 2016 -0500

remove unused variable in Luncher module

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

diff --git a/src/modules/luncher/grid.c b/src/modules/luncher/grid.c
index 225455c..8d9546c 100644
--- a/src/modules/luncher/grid.c
+++ b/src/modules/luncher/grid.c
@@ -246,7 +246,6 @@ _grid_icon_add(Instance *inst, Efreet_Desktop *desktop)
 {
const char *path = NULL, *k = NULL;
char buf[4096];
-   int len = 0;
Icon *ic;
 
ic = E_NEW(Icon, 1);

-- 




[EGIT] [core/efl] master 01/01: elementary: Fix coverity detected resource leak

2016-11-29 Thread Christopher Michael
devilhorns pushed a commit to branch master.

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

commit 2c7bedc622adc5aa872cb3d63d20c8a719203089
Author: Chris Michael 
Date:   Tue Nov 29 08:35:52 2016 -0500

elementary: Fix coverity detected resource leak

As elm_code_line_indent_get will malloc space for the returned string,
that space should be freed after usage. This fixes a resource leak
detected by Coverity.

CID1366468

Signed-off-by: Chris Michael 
---
 src/lib/elementary/elm_code_widget.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/src/lib/elementary/elm_code_widget.c 
b/src/lib/elementary/elm_code_widget.c
index d3551a4..cca8465 100644
--- a/src/lib/elementary/elm_code_widget.c
+++ b/src/lib/elementary/elm_code_widget.c
@@ -1319,6 +1319,7 @@ _elm_code_widget_newline(Elm_Code_Widget *widget)
  strlen(leading));
elm_obj_code_widget_cursor_position_set(widget, indent, row + 1);
efl_event_callback_legacy_call(widget, 
ELM_OBJ_CODE_WIDGET_EVENT_CHANGED_USER, NULL);
+   free(leading);
 
change = _elm_code_widget_change_create(width + 1, row, indent - 1, row + 
1, "\n", 1, EINA_TRUE);
_elm_code_widget_undo_change_add(widget, change);

-- 




[EGIT] [core/efl] master 01/01: ecore_con: fix work on Windows

2016-11-29 Thread Andrii Kroitor
lorddrew pushed a commit to branch master.

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

commit 03f20efaf045fd93e09cffac06790cf509ee6657
Author: Andrii Kroitor 
Date:   Tue Nov 29 15:11:55 2016 +0200

ecore_con: fix work on Windows

Per aspera ad astra.
One little missing star was breaking all EFL UI applications.
---
 src/lib/ecore_con/ecore_con_local_win32.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/lib/ecore_con/ecore_con_local_win32.c 
b/src/lib/ecore_con/ecore_con_local_win32.c
index b322d9a..4bd0ba4 100644
--- a/src/lib/ecore_con/ecore_con_local_win32.c
+++ b/src/lib/ecore_con/ecore_con_local_win32.c
@@ -552,7 +552,7 @@ ecore_con_local_connect(Ecore_Con_Server *obj,
 {
 #warning "I am pretty sure cb_done should be used."
Efl_Network_Server_Data *svr = efl_data_scope_get(obj, 
EFL_NETWORK_SERVER_CLASS);
-   char buf = NULL;
+   char *buf = NULL;
Ecore_Win32_Handler *handler_read;
Ecore_Win32_Handler *handler_peek;
 

-- 




[EGIT] [core/efl] master 01/01: elm_spinner: fix wrong focus logic when spinner is unfocused

2016-11-29 Thread WooHyun Jung
woohyun pushed a commit to branch master.

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

commit bf21eceb489b5971ce5d712b2788162fca198fc4
Author: WooHyun Jung 
Date:   Tue Nov 29 21:06:25 2016 +0900

elm_spinner: fix wrong focus logic when spinner is unfocused

When unfocusing spinner, entry's UNFOCUSED callback is called.
In the callback function, entry is hidden and spinner gets focus
from focus_revert logic.
This gave lots of meaningless focused/unfocused state changes.

@fix
---
 src/lib/elementary/elm_spinner.c | 19 +--
 1 file changed, 17 insertions(+), 2 deletions(-)

diff --git a/src/lib/elementary/elm_spinner.c b/src/lib/elementary/elm_spinner.c
index 6b8e4a2..ddea278 100644
--- a/src/lib/elementary/elm_spinner.c
+++ b/src/lib/elementary/elm_spinner.c
@@ -51,6 +51,8 @@ _inc_dec_button_mouse_move_cb(void *data, const Efl_Event 
*event);
 static void
 _text_button_focused_cb(void *data, const Efl_Event *event);
 static void
+_button_focused_cb(void *data, const Efl_Event *event);
+static void
 _entry_unfocused_cb(void *data, const Efl_Event *event);
 
 EFL_CALLBACKS_ARRAY_DEFINE(_inc_dec_button_cb,
@@ -606,8 +608,12 @@ _toggle_entry(Evas_Object *obj)
  elm_entry_markup_filter_append(sd->ent, 
_invalid_input_validity_filter, NULL);
  if (_elm_config->spinner_min_max_filter_enable)
elm_entry_markup_filter_append(sd->ent, 
_min_max_validity_filter, obj);
- efl_event_callback_add
-(sd->ent, ELM_WIDGET_EVENT_UNFOCUSED, _entry_unfocused_cb, 
obj);
+ if (sd->inc_button)
+   efl_event_callback_add
+  (sd->inc_button, ELM_WIDGET_EVENT_FOCUSED, 
_button_focused_cb, obj);
+ if (sd->dec_button)
+   efl_event_callback_add
+  (sd->dec_button, ELM_WIDGET_EVENT_FOCUSED, 
_button_focused_cb, obj);
  efl_event_callback_add
 (sd->ent, ELM_ENTRY_EVENT_ACTIVATED, _entry_unfocused_cb, obj);
   }
@@ -851,6 +857,15 @@ _text_button_focused_cb(void *data, const Efl_Event *event 
EINA_UNUSED)
 }
 
 static void
+_button_focused_cb(void *data, const Efl_Event *event EINA_UNUSED)
+{
+   ELM_SPINNER_DATA_GET(data, sd);
+
+   sd->entry_visible = EINA_TRUE;
+   _toggle_entry(data);
+}
+
+static void
 _entry_unfocused_cb(void *data, const Efl_Event *event EINA_UNUSED)
 {
ELM_SPINNER_DATA_GET(data, sd);

-- 




[EGIT] [core/efl] master 01/01: naviframe: Fix to show hidden previous view when pop transition begins.

2016-11-29 Thread Jaehyun Cho
jaehyun pushed a commit to branch master.

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

commit 29a7d08454bfee6c0c29b424b99ca20994a6ca28
Author: Jaehyun Cho 
Date:   Tue Nov 29 20:49:04 2016 +0900

naviframe: Fix to show hidden previous view when pop transition begins.

Previously, previous view became visible before pop transition begins by
"elm,state,prev,popped,deferred" signal.
Now, previous view become visible when pop transition begins by
"elm,state,prev,popped,deferred" signal.
---
 src/lib/elementary/elc_naviframe.c | 6 --
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/src/lib/elementary/elc_naviframe.c 
b/src/lib/elementary/elc_naviframe.c
index b455a75..5a96284 100644
--- a/src/lib/elementary/elc_naviframe.c
+++ b/src/lib/elementary/elc_naviframe.c
@@ -1448,6 +1448,10 @@ _deferred(void *data, const Efl_Event *event EINA_UNUSED)
 _send_signal(cur, signals_cur[nfo->push]);
 _send_signal(other, nfo->push ? signals_new : signals_prev);
 
+//Show hidden previous view when pop transition begins.
+if (!nfo->push)
+  evas_object_show(VIEW(other));
+
 free(nfo);
  }
 
@@ -1807,9 +1811,7 @@ _elm_naviframe_item_pop(Eo *obj, Elm_Naviframe_Data *sd)
 
 /* these 2 signals MUST take place simultaneously */
 elm_object_signal_emit(VIEW(it), "elm,state,cur,popped", "elm");
-evas_object_show(VIEW(prev_it));
 elm_object_signal_emit(VIEW(prev_it), "elm,state,prev,popped", "elm");
-
 edje_object_message_signal_process(elm_layout_edje_get(VIEW(it)));
 edje_object_message_signal_process(elm_layout_edje_get(VIEW(prev_it)));
 

-- 




[EGIT] [website/www-content] master 01/01: README: we now longer would consider this wiki a test

2016-11-29 Thread Stefan Schmidt
stefan pushed a commit to branch master.

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

commit c05d62b42bfb94abb2a86a29cc477a428b66c199
Author: Stefan Schmidt 
Date:   Tue Nov 29 11:04:47 2016 +0100

README: we now longer would consider this wiki a test
---
 README | 2 --
 1 file changed, 2 deletions(-)

diff --git a/README b/README
index b266746..79bb4bd 100644
--- a/README
+++ b/README
@@ -1,3 +1 @@
 This is the www content for enlightenment.org
-
-This is a test for now for dokuwiki

-- 




[EGIT] [website/www-content] master 01/01: Wiki page ubuntu-start changed with summary [] by Philippe Jean Guillaumie

2016-11-29 Thread Philippe Jean Guillaumie
WWW-www.enlightenment.org pushed a commit to branch master.

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

commit 2de9ae460ab6903fe1721878999ab7ffccfd905b
Author: Philippe Jean Guillaumie 
Date:   Tue Nov 29 01:10:01 2016 -0800

Wiki page ubuntu-start changed with summary [] by Philippe Jean Guillaumie
---
 pages/distros/ubuntu-start.txt | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/pages/distros/ubuntu-start.txt b/pages/distros/ubuntu-start.txt
index 00a8f85..3ac0f00 100644
--- a/pages/distros/ubuntu-start.txt
+++ b/pages/distros/ubuntu-start.txt
@@ -2,7 +2,7 @@
  Packages 
 
 The available packages in the official Ubuntu repositories are outdated.
-The PPA below provides the latest __stable version__ of E21.
+The [[https://help.ubuntu.com/community/PPA|PPA]] below provides the latest 
__stable version__ of E21.
 
 To add this PPA to your system,
 open a terminal and enter:
@@ -64,4 +64,4 @@ Then go to [[../docs-efl-start]] to learn how to install the 
whole thing ;-)
 
 See also https://www.enlightenment.org/distros/debian-start
 
-Alternatively, if you do not want to delve into the many subtleties 
of the compilation process, while retaining a fully functional Ubuntu system 
after the build has finished, check out 
[[http://build-enlightenment.monsite-orange.fr/|batden's script]]
\ No newline at end of file
+Alternatively, if you do not want to delve into the many subtleties 
of the compilation process — while retaining a fully functional Ubuntu system 
after the build has finished — check out 
[[http://build-enlightenment.monsite-orange.fr/|batden's script]]
\ No newline at end of file

-- 




[EGIT] [website/www-content] master 01/01: Wiki page ubuntu-start changed with summary [] by Philippe Jean Guillaumie

2016-11-29 Thread Philippe Jean Guillaumie
WWW-www.enlightenment.org pushed a commit to branch master.

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

commit 678ffc1b29aa2259eb13a824b8f0c44be17cf90d
Author: Philippe Jean Guillaumie 
Date:   Tue Nov 29 00:16:42 2016 -0800

Wiki page ubuntu-start changed with summary [] by Philippe Jean Guillaumie
---
 pages/distros/ubuntu-start.txt | 6 --
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/pages/distros/ubuntu-start.txt b/pages/distros/ubuntu-start.txt
index 25e7731..00a8f85 100644
--- a/pages/distros/ubuntu-start.txt
+++ b/pages/distros/ubuntu-start.txt
@@ -42,8 +42,8 @@ Required and recommended packages:
 
 
 
-automake autopoint build-essential ccache check doxygen \
-faenza-icon-theme git imagemagick libasound2-dev libblkid-dev \
+sudo apt-get install automake autopoint build-essential ccache check \
+doxygen faenza-icon-theme git imagemagick libasound2-dev libblkid-dev \
 libbluetooth-dev libbullet-dev libcogl-dev libfontconfig1-dev \
 libfreetype6-dev libfribidi-dev libgif-dev libgstreamer1.0-dev \
 libgstreamer-plugins-base1.0-dev libharfbuzz-dev libibus-1.0-dev \
@@ -63,3 +63,5 @@ valgrind xserver-xephyr
 Then go to [[../docs-efl-start]] to learn how to install the whole thing ;-)
 
 See also https://www.enlightenment.org/distros/debian-start
+
+Alternatively, if you do not want to delve into the many subtleties 
of the compilation process, while retaining a fully functional Ubuntu system 
after the build has finished, check out 
[[http://build-enlightenment.monsite-orange.fr/|batden's script]]
\ No newline at end of file

-- 




Re: [E-devel] Elm Main Menu

2016-11-29 Thread Jean-Philippe André
Hey Andy,

I've reverted my revert and tried to fix my original patch.
Let me know if it works fine for you!

Thanks,


On 29 November 2016 at 02:02, Andrew Williams  wrote:

> Great thanks, I love having my tab bar back :)
>
> Have a great day!
> Andy
>
> On Mon, 28 Nov 2016 at 00:57, Jean-Philippe André 
> wrote:
>
>> Hi,
>>
>> On 28 November 2016 at 11:44, Carsten Haitzler 
>> wrote:
>>
>> On Sun, 27 Nov 2016 15:58:42 + Andrew Williams 
>> said:
>>
>> > Yup - that's what I see - right in elementary_test.
>> >
>> > Not started bisecting as I've not been coding for a few days. Might get
>> a
>> > chance today.
>> > But of course the efl build time is quite an issue for this :-p
>>
>> it's very likely to do with jpeg's changes tot he elm win/efl ui win and
>> theme
>> and csd etc. 
>>
>>
>> Yes, of course it was related. After playing a bit with the menu, trying
>> to place it inside the framespace, I encountered many sizing issues
>> (elm_menu and efl_ui_win both use custom layout functions). So I reverted
>> some of my changes and the menu bar is back inside win.edc. For now.
>> Hopefully I can fix the sizing issues as all the conformant features also
>> need to move inside the window.
>>
>>
>>
>> > Andrew
>> > On Sun, 27 Nov 2016 at 02:57, Carsten Haitzler 
>> wrote:
>> >
>> > > On Sun, 27 Nov 2016 07:44:25 +0200 Daniel Zaoui <
>> daniel.za...@samsung.com>
>> > > said:
>> > >
>> > > > Hi Andrew,
>> > > >
>> > > > Do you see any issues in elementary_test? Cause seems ok there. Did
>> you
>> > > try
>> > > > to bisect?
>> > > >
>> > > > Exactness doesn't cover main_menu. It should but the scenario has
>> never
>> > > been
>> > > > recorded.
>> > > >
>> > > > JackDanielZ
>> > >
>> > > elm test does show the b0rk. resize the main menu test vertically.
>> notice
>> > > the
>> > > label will slide underneath the main menu. this is the b0rk. :)
>> > >
>> > > > On Sat, 26 Nov 2016 15:20:13 +
>> > > > Andrew Williams  wrote:
>> > > >
>> > > > > Hi all,
>> > > > >
>> > > > > In the last week (or two) the elm main menu has stopped reserving
>> its
>> > > > > own space and has started overlapping content. Does anyone know
>> why
>> > > > > this might be?
>> > > > > Have the UI tests stopped being run or did the exactness not cover
>> > > > > mainmenu layout? (Again, not sure where to look)
>> > > > >
>> > > > > Thanks for any tips,
>> > > > > Andy
>> > > > >
>> > > 
>> --
>> > > > > ___
>> > > > > enlightenment-devel mailing list
>> > > > > enlightenment-devel@lists.sourceforge.net
>> > > > > https://lists.sourceforge.net/lists/listinfo/enlightenment-devel
>> > > > >
>> > > > >
>> > > >
>> > > >
>> > > >
>> > > 
>> --
>> > > > ___
>> > > > enlightenment-devel mailing list
>> > > > enlightenment-devel@lists.sourceforge.net
>> > > > https://lists.sourceforge.net/lists/listinfo/enlightenment-devel
>> > > >
>> > >
>> > >
>> > > --
>> > > - Codito, ergo sum - "I code, therefore I am"
>> --
>> > > The Rasterman (Carsten Haitzler)ras...@rasterman.com
>> > >
>> > >
>>
>>
>> --
>> - Codito, ergo sum - "I code, therefore I am" --
>> The Rasterman (Carsten Haitzler)ras...@rasterman.com
>>
>>
>> 
>> --
>> ___
>> enlightenment-devel mailing list
>> enlightenment-devel@lists.sourceforge.net
>> https://lists.sourceforge.net/lists/listinfo/enlightenment-devel
>>
>>
>>
>>
>> --
>> Jean-Philippe André
>>
>


-- 
Jean-Philippe André
--
___
enlightenment-devel mailing list
enlightenment-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel


[EGIT] [core/efl] master 01/02: Revert "win: Move main menu back to win.edc (fix sizing)"

2016-11-29 Thread Jean-Philippe ANDRÉ
jpeg pushed a commit to branch master.

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

commit c7f2308e6c12181d06b5904d46a5d2b6c463f5c8
Author: Jean-Philippe Andre 
Date:   Mon Nov 28 17:24:18 2016 +0900

Revert "win: Move main menu back to win.edc (fix sizing)"

This reverts commit 8a213847596376305d282e1ba26080b548a207f9.
The following commit will reintroduce the menu slot inside the
border edc.
---
 data/elementary/themes/edc/elm/border.edc | 43 +++
 data/elementary/themes/edc/elm/win.edc| 40 
 src/lib/elementary/efl_ui_win.c   | 29 +
 3 files changed, 62 insertions(+), 50 deletions(-)

diff --git a/data/elementary/themes/edc/elm/border.edc 
b/data/elementary/themes/edc/elm/border.edc
index 72e84ab..1c5a25d 100644
--- a/data/elementary/themes/edc/elm/border.edc
+++ b/data/elementary/themes/edc/elm/border.edc
@@ -1,12 +1,10 @@
 /* Window client-side decorations and extra slots
  * Includes swallows for:
  *  - app content
+ *  - main menu
  *  - indicator
  *  - soft key
  *  - virtual keyboard
- *
- * Not included:
- *  - main menu (sizing issues - needs rework of the menu itself)
  */
 
 group { name: "elm/border/base/default";
@@ -93,11 +91,34 @@ group { name: "elm/border/base/default";
  required; // @since 1.19
  clip: "client_clip";
   }
+  /* main menu */
+  rect { "menu_bg";
+ desc { "default";
+color: 64 64 64 255; // FIXME: color_class
+align: 0.5 0.0;
+rel.to: "elm.swallow.menu";
+ }
+  }
+  swallow { "elm.swallow.menu";
+ required: 1; // since 1.19
+ desc { "default";
+rel.to: "top_clip";
+rel1.relative: 0.0 1.0;
+rel1.offset: 0 -1;
+visible: 0;
+align: 0.5 0.0;
+fixed: 1 1;
+ }
+ desc { "visible"; inherit: "default";
+visible: 1;
+fixed: 0 1;
+ }
+  }
 
-  /* application contents - spacer and clipper */
+  /* application contents - spacer and clipper (without main menu) */
   spacer { "client_spacer";
  desc { "default";
-rel1.to: "top_clip";
+rel1.to: "elm.swallow.menu";
 rel1.relative: 0.0 1.0;
 rel2.to: "bottom_clip";
 rel2.relative: 1.0 0.0;
@@ -784,6 +805,18 @@ group { name: "elm/border/base/default";
  UNSET_MODE(MAXIMIZED);
   }
 
+  /* application desktop menu */
+  program { name: "show_menu";
+ signal: "elm,action,show_menu"; source: "elm";
+ action: STATE_SET "visible";
+ target: "elm.swallow.menu";
+  }
+  program { name: "hide_menu";
+ signal: "elm,action,hide"; source: "elm";
+ action: STATE_SET "default";
+ target: "elm.swallow.menu";
+  }
+
   /* modal windows */
   program { name: "hide_blocker";
  signal: "elm,action,hide_blocker"; source: "elm";
diff --git a/data/elementary/themes/edc/elm/win.edc 
b/data/elementary/themes/edc/elm/win.edc
index 2c5e0dd..8c6a08d 100644
--- a/data/elementary/themes/edc/elm/win.edc
+++ b/data/elementary/themes/edc/elm/win.edc
@@ -1,28 +1,6 @@
 group { name: "elm/win/base/default";
data.item: "elm_win_version" "119";
parts {
-  /* main menu */
-  part { name: "menu_bg"; type: RECT;
- description { state: "default" 0.0;
-color: 64 64 64 255;
-align: 0.5 0;
-rel2.to: "elm.swallow.menu";
- }
-  }
-  part { name: "elm.swallow.menu"; type: SWALLOW;
- description { state: "default" 0.0;
-rel2.relative: 1.0 0.0;
-visible: 0;
-align: 0.5 0;
-fixed: 1 1;
- }
- description { state: "visible" 0.0;
-inherit: "default" 0.0;
-visible: 1;
-fixed: 0 1;
- }
-  }
-  /* application content */
   rect { "client_clip"; nomouse;
  desc { "default";
 rel.to: "elm.swallow.contents";
@@ -30,24 +8,6 @@ group { name: "elm/win/base/default";
   }
   swallow { "elm.swallow.contents";
  clip_to: "client_clip";
- desc { "default";
-rel1.to: "elm.swallow.menu";
-rel1.relative: 0.0 1.0;
- }
-  }
-   }
-   programs {
-  program { name: "show_menu";
- signal: "elm,action,show_menu";
- source: "elm";
- action: STATE_SET "visible" 0.0;
- target: "elm.swallow.menu";
-  }
-  program { name: "hide_menu";
- signal: "elm,action,hide";
- source: "elm";
- action: STATE_SET "default" 0.0;
- target: "elm.swallow.menu";
   }
}
 }
diff --git a/src/lib/elementary/efl_ui_win.c b/src/lib/elementary/efl_ui_win.c
index d552c04..309ff7f 100644
--- a/src/lib/elementary/efl_ui_win.c
+++ b/s

[EGIT] [core/efl] master 02/02: win: Move main menu to the framespace

2016-11-29 Thread Jean-Philippe ANDRÉ
jpeg pushed a commit to branch master.

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

commit 1f9dfe2ed374bd54dd84aaf70abb496b021269cb
Author: Jean-Philippe Andre 
Date:   Mon Nov 28 18:26:39 2016 +0900

win: Move main menu to the framespace

After reverting 8a213847596376305d282e1, I figured out how to move
the main menu back to the border group. This time the menu is in the
framespace and its layout algos have been adapted to allow non-zero
root coordinates.
---
 data/elementary/themes/edc/elm/border.edc |  5 ++--
 data/elementary/themes/edc/elm/menu.edc   |  1 +
 src/lib/elementary/efl_ui_win.c   | 34 ++
 src/lib/elementary/elm_hover.c| 12 --
 src/lib/elementary/elm_menu.c | 40 ---
 src/lib/elementary/elm_widget.c   | 15 
 src/lib/elementary/elm_widget.eo  |  1 +
 src/lib/elementary/elm_widget_menu.h  |  2 +-
 8 files changed, 80 insertions(+), 30 deletions(-)

diff --git a/data/elementary/themes/edc/elm/border.edc 
b/data/elementary/themes/edc/elm/border.edc
index 1c5a25d..24a942f 100644
--- a/data/elementary/themes/edc/elm/border.edc
+++ b/data/elementary/themes/edc/elm/border.edc
@@ -39,11 +39,11 @@ group { name: "elm/border/base/default";
  }
  desc { "max"; inherit: "default"; }
   }
-  /* covers the entire client contents, including the main menu */
+  /* covers the entire client contents, excluding the main menu */
   spacer { "elm.spacer.content";
  required; // since 1.19
  desc {
-rel1.to: "top_clip";
+rel1.to: "elm.swallow.menu";
 rel1.relative: 0.0 1.0;
 rel2.to: "bottom_clip";
 rel2.relative: 1.0 0.0;
@@ -104,7 +104,6 @@ group { name: "elm/border/base/default";
  desc { "default";
 rel.to: "top_clip";
 rel1.relative: 0.0 1.0;
-rel1.offset: 0 -1;
 visible: 0;
 align: 0.5 0.0;
 fixed: 1 1;
diff --git a/data/elementary/themes/edc/elm/menu.edc 
b/data/elementary/themes/edc/elm/menu.edc
index c4c510e..ec3d67b 100644
--- a/data/elementary/themes/edc/elm/menu.edc
+++ b/data/elementary/themes/edc/elm/menu.edc
@@ -761,6 +761,7 @@ group { name: "elm/hover/base/menu/default";
   part { name: "bottomclip"; type: RECT;
  description { state: "default" 0.0;
 color: 255 255 255 0;
+rel1.offset: 0 -7;
  }
  description { state: "visible" 0.0;
 inherit: "default" 0.0;
diff --git a/src/lib/elementary/efl_ui_win.c b/src/lib/elementary/efl_ui_win.c
index 309ff7f..8571c81 100644
--- a/src/lib/elementary/efl_ui_win.c
+++ b/src/lib/elementary/efl_ui_win.c
@@ -332,6 +332,7 @@ static Elm_Theme_Apply _elm_win_theme_internal(Eo *obj, 
Efl_Ui_Win_Data *sd);
 static void _elm_win_frame_add(Efl_Ui_Win_Data *sd, const char *style);
 static void _elm_win_frame_style_update(Efl_Ui_Win_Data *sd, Eina_Bool 
force_emit, Eina_Bool calc);
 static inline void _elm_win_need_frame_adjust(Efl_Ui_Win_Data *sd, const char 
*engine);
+static void _elm_win_resize_objects_eval(Evas_Object *obj);
 
 #ifdef HAVE_ELEMENTARY_X
 static void _elm_win_xwin_update(Efl_Ui_Win_Data *sd);
@@ -874,6 +875,15 @@ _elm_win_resize_job(void *data)
 evas_object_move(sd->frame_obj, -fx, -fy);
 evas_object_resize(sd->frame_obj, w + fw, h + fh);
  }
+
+   if (sd->main_menu)
+ {
+int mx, my;
+
+efl_gfx_position_get(sd->main_menu, &mx, &my);
+elm_menu_move(sd->main_menu, mx, my);
+ }
+
sd->response++;
evas_object_resize(sd->obj, w, h);
evas_object_resize(sd->legacy.edje, w, h);
@@ -1394,16 +1404,9 @@ _elm_win_frame_obj_update(Efl_Ui_Win_Data *sd)
int fx, fy, fw, fh;
int ox, oy, ow, oh;
 
+   if (!sd->frame_obj) return;
_elm_win_opaque_dirty(sd);
_elm_win_frame_geometry_adjust(sd);
-   if (sd->fullscreen || !sd->csd.need)
- {
-_elm_win_opaque_update(sd);
-evas_output_framespace_set(sd->evas, 0, 0, 0, 0);
-return;
- }
-
-   if (!sd->frame_obj) return;
evas_object_geometry_get(sd->frame_obj, &fx, &fy, &fw, &fh);
edje_object_part_geometry_get(sd->frame_obj, "elm.spacer.content", &ox, 
&oy, &ow, &oh);
evas_output_framespace_set(sd->evas, ox, oy, fw - ow, fh - oh);
@@ -5339,7 +5342,15 @@ _main_menu_swallow_get(Efl_Ui_Win_Data *sd)
 DBG("Detected legacy theme, using legacy swallows.");
 return sd->legacy.edje;
  }
-   return sd->legacy.edje;
+   return sd->frame_obj;
+}
+
+static void
+_main_menu_resize_cb(void *data EINA_UNUSED, const Efl_Event *ev)
+{
+   // After resize, the framespace size has changed, so update the win geometry
+   _elm_win_resize_objects_eval(ev->object);
+   efl_event_callback_del(ev->object, EFL_GFX_EVENT_RESIZE, 
_main_menu_resize_cb, NULL);
 }
 
 static void
@