changed behaviour for onShow triggering in 2.1?

I’ve only just noticed this, in 2.1 beta 4:

In earlier versions, if formA had an onShow method and formB was shown in a dialog on top of formA, the formA onShow method would trigger again when the formB dialog was closed. (If I didn’t want this to happen, I could set a global flag when the dialog was triggerred.)

Similarly, if formA had a tab panel (formC) which also had an onShow method, then that too would trigger again when the formB dialog was closed. i.e. when formB in dialog was closed, BOTH the formA and the formC onShow methods would trigger.

In 2.1b4 this behavious seems to have changed:

When the formB dialog is closed, the formA onShow method still triggers but any onShow method for formC shown in a tab panel on formA does not trigger again. :?

Can anyone confirm if this is a permanent change in behaviour or a bug in 2.1b4?

yes this is currently the way it works now because of a optimalisation in the parent form.

Do we need to have it back?
That the onShow is called on the main form is more or less a bit strange. Because the onHide will not be called for that form when displaying a dialog. The form is never really gone…

Are you saying that the main form onShow should NOT trigger again when a dialog on top of it is closed?

Personally I would prefer that it did not trigger again (either on the main form or any tab based form) as it should not need to run again unless action in the dialog has made changes to the displayed data that would require a re-run of the onShow method for some reason (in which case it would be easy to add conditions to the relevant close dialog method)

we really have no idea if there are changes to the data specific to that form when calling onshow again.

We just have to look what would be the best thing to do.. don’t know yet at this time.

IMHO the best solution is - if a dialog is shown on top of a form do not trigger onshow again when the dialog is closed.

just stumbled about this: I have an onShow method that pre-filters data. I searched for something else. I opened a dialog, closed it and my previous selection of data was gone and I had forgotten what I searched for.

I would prefer that onShow is not fired again. In RC3 it obviously is. I don’t want to build a work-around that is useless in two days. Is there any news on this?

Thanks
Patrick

you prefill on onshow?
so if you are really gone to a different form and then back the previous search would be gone anyway?
That looks a a bad design anyway to me.

If you want to prefill it once that do it on the onshow but test the boolean that you get in the arguments array (that says if it is the first time or not)

The onShow will be called in the final of 2.1
We can’t change that anymore and maybe it will never be changed. Because it is somehow still exactly the same as going to an other form in the main window. Because of the modal dialog (it is stacked just as it is in the main form but then is is shown in a dialog instead of the main window itself)