Page MenuHomePhabricator

Show, Hide and Show Efl.Ui.Win
Closed, ResolvedPublic


After the following commit, the frame_object of Efl.Ui.Win does not shows, if Efl.Ui.Win shows, hides, and shows.
Please test with following step.

(1) evas_object_show(win)
(2) evase_object_hide(win)
(3) evas_object_show(win)

commit fa02f16a3fcf24ac32ea0d1e07fbcb145b0da565
Author: Mike Blumenkrantz <>
Date:   Tue Apr 17 14:52:19 2018 -0400

    efl_ui_win: remove show intercept function
    this should just be handled in the pre-render callback where the rest
    of the calc for the window is done
    also removes an unnecessary smart calc
    Differential Revision:
kimcinoo created this task.Jul 20 2018, 5:30 AM

For your convenience, please refer to following sample.

#include <Elementary.h>

_test_timer_cb(void *data)
   Evas_Object *win = data;
   Eina_Bool vis = evas_object_visible_get(win);
   if (vis)

elm_main(int argc EINA_UNUSED, char **argv EINA_UNUSED)
   Evas_Object *win;

   win = elm_win_util_standard_add("window", "window");
   elm_win_autodel_set(win, EINA_TRUE);

   evas_object_resize(win, 400, 400);

   ecore_timer_add(5.0, _test_timer_cb, win);

   return 0;
zmike added a comment.Jul 20 2018, 7:27 AM

Hm this seems like something that I'd want to add a unit test for, but tracking internal object attributes is not easy...

Is the _efl_ui_win_efl_gfx_entity_size_set called before _efl_ui_win_show?

zmike added a comment.Jul 23 2018, 5:01 AM

I don't understand?

At first the _efl_ui_win_efl_gfx_entity_size_set is called before _efl_ui_win_show.
But the second evas_object_show(win) does not make _efl_ui_win_efl_gfx_entity_size_set be called.
So first_draw is not changed. As a result, the frame_object is not visible at the second show.

zmike added a comment.Jul 23 2018, 7:23 AM

This is to handle the case where:

  1. Window is visible
  2. Window is hidden
  3. Window is resized
  4. Window is shown

Without this check, the objects here would be unconditionally shown immediately instead of waiting for the pre-render callback which correctly sizes them at the same time that they are made visible.

This is similar enough to T5181 that I'm not sure if it's a dupe or not.

It's helpful to see where this broke, as I wasn't sure it was a regression, but I suspect the named patch isn't really "at fault" so much as the behaviour has always been just barely functional and is now broken. :(

I'll review and test the related patches today, maybe we can close T5181 and T7172 :)

Testing seems to show that these patches resolve T5181 as well