Page MenuHomePhabricator

elm_fileselector: support expandable items

Authored by bu5hm4n on Apr 29 2020, 6:36 AM.



the fileselector can store exactly 1 model and monitor that for changes,
which works normally just well. However, when we expand a items, another
model comes into play, which is not monitored, and no additional
reference is taken. Which means, _process_last will simply delete it,
and elements that did not come into play at the _populate call are never

With this commit, we check that we do not have a parent item, and
explictly wait for the model to publish all its items, before we call

Additionally, that showed that the tracking of the list/grid item is
ultimatly buggy, as there is no assertion that the parent model is
really the parent directoy. Hence we need to hand pass the parent item
here, as a fallback option to set the correct parent item.

fixes T8689

Diff Detail

rEFL core/efl
Automatic diff as part of commit; lint not applicable.
Automatic diff as part of commit; unit tests not applicable.
bu5hm4n created this revision.Apr 29 2020, 6:36 AM

It seems that this patch has no reviewers specified. If you are unsure who can review your patch, please check this wiki page and see if anyone can be added:

bu5hm4n requested review of this revision.Apr 29 2020, 6:36 AM
zmike added a subscriber: zmike.Apr 29 2020, 6:46 AM

I recall seeing a TODO comment about monitoring for subitems which is probably addressed by this patch. Can you remove that to avoid future confusion?

No - monitoring is not addressed by that patch, this just ensures that we publish the items that are "known" after the first cycle of children,count updates.

zmike added a comment.Apr 29 2020, 7:11 AM

Sure, but by successfully changing the model now it seems like that covers the case that the comment was mentioning, doesn't it?

As long as you mean the comment in line 191: No - the monitoring of subitems is not changed by this patch at all. The problem that only one model can be monitored is still present, and not changed...

zmike accepted this revision.Apr 29 2020, 8:22 AM

I guess my interpretation of that comment was that it acknowledged the problem that was happening without this patch where the model monitoring/processing was screwed up, but maybe I was just reading too much into it.

This revision is now accepted and ready to land.Apr 29 2020, 8:22 AM
Closed by commit rEFLf21df93595f1: elm_fileselector: support expandable items (authored by Marcel Hollerbach <>, committed by zmike). · Explain WhyApr 29 2020, 8:47 AM
This revision was automatically updated to reflect the committed changes.