[MGNLUI-3416] EditorCallback#onCancel not called upon closing a dialog with x button instead of the cancel action Created: 11/May/15 Updated: 21/Aug/15 Resolved: 19/Aug/15 |
|
| Status: | Closed |
| Project: | Magnolia UI |
| Component/s: | dialogs, forms |
| Affects Version/s: | 5.3.8 |
| Fix Version/s: | 5.3.11, 5.4.2 |
| Type: | Bug | Priority: | Major |
| Reporter: | Zdenek Skodik | Assignee: | Aleksandr Pchelintcev |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | support | ||
| Remaining Estimate: | 0d | ||
| Time Spent: | 2d | ||
| Original Estimate: | 0.5d | ||
| Issue Links: |
|
||||||||
| Template: |
|
||||||||
| Acceptance criteria: |
Empty
|
||||||||
| Task DoD: |
[ ]*
Doc/release notes changes? Comment present?
[ ]*
Downstream builds green?
[ ]*
Solution information and context easily available?
[ ]*
Tests
[ ]*
FixVersion filled and not yet released
[ ] 
Architecture Decision Record (ADR)
|
||||||||
| Bug DoR: |
[ ]*
Steps to reproduce, expected, and actual results filled
[ ]*
Affected version filled
|
||||||||
| Date of First Response: | |||||||||
| Sprint: | Sprint 3 (Vietnam), Sprint 6 (Basel) | ||||||||
| Story Points: | 8 | ||||||||
| Description |
|
Except of choose dialogs that are working fine since |
| Comments |
| Comment by Aleksandr Pchelintcev [ 28/May/15 ] |
|
| Comment by Evzen Fochr [ 28/May/15 ] |
|
I am afraid that i cannot handle it in base presenter. In FormDialogPresenterImpl is not called super.start and there are 3 different callback interfaces (MoveActionCallback, EditorCallback, ChooseDialogCallback) with different functions. (or do not have any idea how to do it) |
| Comment by Aleksandr Pchelintcev [ 28/May/15 ] |
|
| Comment by Aleksandr Pchelintcev [ 29/May/15 ] |
|
This is not exactly what I was trying to say in the previous comments:
also:
finally:
|
| Comment by Aleksandr Pchelintcev [ 02/Jun/15 ] |
|
Looks much better now!
|
| Comment by Aleksandr Pchelintcev [ 05/Jun/15 ] |
|
The solution causes stack overflow for the case of form dialogs. |
| Comment by Mikaël Geljić [ 05/Jun/15 ] |
|
FYI also mind a potential Internal Error e.g. when opening Change template light-dialog in pages app, and hitting ESC. |
| Comment by Evzen Fochr [ 15/Jun/15 ] |
|
In some callbacks is called closeDialog or close view functions, which is causing recursion. |
| Comment by Evzen Fochr [ 02/Jul/15 ] |
|
After removing closeDialog() from callbacks, dialogs aren close after commit or cancel action. |
| Comment by Trang Truong [ 30/Jul/15 ] |
|
It's fixed on branch |
| Comment by Aleksandr Pchelintcev [ 12/Aug/15 ] |
|
trang.truong the fix provided indeed breaks the infinite EditorCallback <-> DialogPresenter's close handler infinite loop by removing the close handlers before invoking them. However, if you consider the situation when there are several close handlers attached to a dialog, then a callback number i where i is > 0 will be called at least 2 times. |