elc_filselector: solve the mysterium of sometimes failing tests
authorMarcel Hollerbach <mail@marcel-hollerbach.de>
Wed, 27 Mar 2019 20:15:53 +0000 (21:15 +0100)
committerJunsuChoi <jsuya.choi@samsung.com>
Tue, 2 Apr 2019 04:14:38 +0000 (13:14 +0900)
commit7e9ba73f914df0e46cf7a984f88edafa11306f92
treedb5ddb6226a991d221bb641726bf8393354d25e1
parentb25de2df8e063c9f3a478b5fd815bb0b8ff1d41e
elc_filselector: solve the mysterium of sometimes failing tests

so after a phone call, two days of debugging, tears, crying etc. etc. we
finally came to a point of enlightenment! *Someone* (bu5hm4n) moved
gengrid and genlist events from eo back to smart events, so we can work
arround legacy borks and event-name collisions, at this point he did not
knew that some widgets (fileselector) already relied on those *lovely*
events. Hence this broke theoretically the testsuite, however, the
fileselector testsuite is ultimatily buggy, and the wait function does
not return false when it timeouts, (i don't know why not). So this break
was never discovered.

Additionally there is a second issue. it appears, that when we
immidiatly quit the mainloop after we have got the selected callback,
that then genlist decides to forget about the sd->selected pointer, and
NULLs that one out. Which then results in the fact that
elm_fileselector_selected_get ends up returning invalid paths.

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D8488
src/lib/elementary/elc_fileselector.c
src/tests/elementary/elm_test_fileselector.c