You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@wicket.apache.org by "Mishelle Bonq (JIRA)" <ji...@apache.org> on 2011/06/17 11:57:47 UTC
[jira] [Created] (WICKET-3808) Data, passed from ModalPage to
ModalWindow, is not accessible in WindowClosedCallback
Data, passed from ModalPage to ModalWindow, is not accessible in WindowClosedCallback
-------------------------------------------------------------------------------------
Key: WICKET-3808
URL: https://issues.apache.org/jira/browse/WICKET-3808
Project: Wicket
Issue Type: Bug
Components: wicket-core, wicket-extensions
Affects Versions: 1.5-RC4
Environment: Win 7, FF
Reporter: Mishelle Bonq
Priority: Critical
Because of changes of pages processing an unacceptable behavior was detected. During such a processing in case if we try to pass some data from page on opened modal window to a modal window (which is an element of background page). The quickstart project was made to show this wrong behavior.
Steps to reproduce:
1. Run quickstart project. Open HomePage. You'll see a link "Show ModalWindow". Click it. As an action on this click a new PageCreator is set for ModalWindow, which creates a new instance of ModalPage & pass a callback to this instance. Inside the callback the visibility of hidden element from HomePage is changed (The text "Hello, World!" became visible).
2. So, a ModalWindow will be shown with a ModalPage as content. In ModalPage you'll see another link "Close ModalWindow and show hidden text on HomePage". Click this link.
This click must leads to setting the callback (which we've already passed in step 1 to ModalPage instance) to ModalWindow & close this ModalWindow.
Closing ModalWindow happens in a correct way. But we don't see the hidden text. The reason of this behavior is: when we set the callback from ModalPage to ModalWindow (element of HomePage) the numericId of HomePage is changed and this page is serialized with another id. During ModalWindow closing WindowClosedCallback is called. In this WindowClosedCallback we are trying to call our callback, which had to be set from ModalPage. But script, which handles WindowClosedCallback from browser, references to a HomePage with old numericId & of cource without set callback.
--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Commented] (WICKET-3808) Data, passed from ModalPage to
ModalWindow, is not accessible in WindowClosedCallback
Posted by "Mishelle Bonq (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/WICKET-3808?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13052540#comment-13052540 ]
Mishelle Bonq commented on WICKET-3808:
---------------------------------------
I tried the approach when we pass to a modalPage as parameters:
1 PageReference for access to a model of modalWindow
2 modalWindow instance for possibility to close the modalWindow
* As action, occurs on click link in modalPage it looks like:
void onLinkClick(PageReference homePageReference, ModalWindow modalWindow) {
HomePage homePage = (HomePage) homePageReference.getPage();
homePage.getModalWindow().setCallback(homePage.getCallback());
modalWindow.close(target);
}
If we follow this way, then everything works fine: when onclick event happens, we ask for the homePage (using an old id) and set the callback to the homePage instance with an old id. It marks as touched and serializes later. Then, when we call "modalWindow.close(target)" we refers to another instance of homePage, for that instance we set a new id and mark it as touched and serialize too.
But it seems a little bit strange to use such an approach. The fact that we must use only this approach may be confusing. If I look at this code it seems really strange to me that we set callback to the modalWindow in one way, and then close the same modalWindow in another way(of course, it's not the same modalWindow, but it's not obvious).
> Data, passed from ModalPage to ModalWindow, is not accessible in WindowClosedCallback
> -------------------------------------------------------------------------------------
>
> Key: WICKET-3808
> URL: https://issues.apache.org/jira/browse/WICKET-3808
> Project: Wicket
> Issue Type: Bug
> Components: wicket-core, wicket-extensions
> Affects Versions: 1.5-RC4
> Environment: Win 7, FF
> Reporter: Mishelle Bonq
> Attachments: project-2.rar, project.rar
>
>
> Because of changes of pages processing an unacceptable behavior was detected. During such a processing in case if we try to pass some data from page on opened modal window to a modal window (which is an element of background page). The quickstart project was made to show this wrong behavior.
> Steps to reproduce:
> 1. Run quickstart project. Open HomePage. You'll see a link "Show ModalWindow". Click it. As an action on this click a new PageCreator is set for ModalWindow, which creates a new instance of ModalPage & pass a callback to this instance. Inside the callback the visibility of hidden element from HomePage is changed (The text "Hello, World!" became visible).
>
> 2. So, a ModalWindow will be shown with a ModalPage as content. In ModalPage you'll see another link "Close ModalWindow and show hidden text on HomePage". Click this link.
> This click must leads to setting the callback (which we've already passed in step 1 to ModalPage instance) to ModalWindow & close this ModalWindow.
> Closing ModalWindow happens in a correct way. But we don't see the hidden text. The reason of this behavior is: when we set the callback from ModalPage to ModalWindow (element of HomePage) the numericId of HomePage is changed and this page is serialized with another id. During ModalWindow closing WindowClosedCallback is called. In this WindowClosedCallback we are trying to call our callback, which had to be set from ModalPage. But script, which handles WindowClosedCallback from browser, references to a HomePage with old numericId & of cource without set callback.
--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Updated] (WICKET-3808) Data, passed from ModalPage to
ModalWindow, is not accessible in WindowClosedCallback
Posted by "Martin Grigorov (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/WICKET-3808?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Martin Grigorov updated WICKET-3808:
------------------------------------
Priority: Major (was: Critical)
> Data, passed from ModalPage to ModalWindow, is not accessible in WindowClosedCallback
> -------------------------------------------------------------------------------------
>
> Key: WICKET-3808
> URL: https://issues.apache.org/jira/browse/WICKET-3808
> Project: Wicket
> Issue Type: Bug
> Components: wicket-core, wicket-extensions
> Affects Versions: 1.5-RC4
> Environment: Win 7, FF
> Reporter: Mishelle Bonq
> Attachments: project.rar
>
>
> Because of changes of pages processing an unacceptable behavior was detected. During such a processing in case if we try to pass some data from page on opened modal window to a modal window (which is an element of background page). The quickstart project was made to show this wrong behavior.
> Steps to reproduce:
> 1. Run quickstart project. Open HomePage. You'll see a link "Show ModalWindow". Click it. As an action on this click a new PageCreator is set for ModalWindow, which creates a new instance of ModalPage & pass a callback to this instance. Inside the callback the visibility of hidden element from HomePage is changed (The text "Hello, World!" became visible).
>
> 2. So, a ModalWindow will be shown with a ModalPage as content. In ModalPage you'll see another link "Close ModalWindow and show hidden text on HomePage". Click this link.
> This click must leads to setting the callback (which we've already passed in step 1 to ModalPage instance) to ModalWindow & close this ModalWindow.
> Closing ModalWindow happens in a correct way. But we don't see the hidden text. The reason of this behavior is: when we set the callback from ModalPage to ModalWindow (element of HomePage) the numericId of HomePage is changed and this page is serialized with another id. During ModalWindow closing WindowClosedCallback is called. In this WindowClosedCallback we are trying to call our callback, which had to be set from ModalPage. But script, which handles WindowClosedCallback from browser, references to a HomePage with old numericId & of cource without set callback.
--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Resolved] (WICKET-3808) Data, passed from ModalPage to
ModalWindow, is not accessible in WindowClosedCallback
Posted by "Martin Grigorov (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/WICKET-3808?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Martin Grigorov resolved WICKET-3808.
-------------------------------------
Resolution: Not A Problem
The example for ModalWindow with a Page at wicket-examples shows exactly this scenario and it works fine.
> Data, passed from ModalPage to ModalWindow, is not accessible in WindowClosedCallback
> -------------------------------------------------------------------------------------
>
> Key: WICKET-3808
> URL: https://issues.apache.org/jira/browse/WICKET-3808
> Project: Wicket
> Issue Type: Bug
> Components: wicket-core, wicket-extensions
> Affects Versions: 1.5-RC4
> Environment: Win 7, FF
> Reporter: Mishelle Bonq
> Attachments: project-2.rar, project.rar
>
>
> Because of changes of pages processing an unacceptable behavior was detected. During such a processing in case if we try to pass some data from page on opened modal window to a modal window (which is an element of background page). The quickstart project was made to show this wrong behavior.
> Steps to reproduce:
> 1. Run quickstart project. Open HomePage. You'll see a link "Show ModalWindow". Click it. As an action on this click a new PageCreator is set for ModalWindow, which creates a new instance of ModalPage & pass a callback to this instance. Inside the callback the visibility of hidden element from HomePage is changed (The text "Hello, World!" became visible).
>
> 2. So, a ModalWindow will be shown with a ModalPage as content. In ModalPage you'll see another link "Close ModalWindow and show hidden text on HomePage". Click this link.
> This click must leads to setting the callback (which we've already passed in step 1 to ModalPage instance) to ModalWindow & close this ModalWindow.
> Closing ModalWindow happens in a correct way. But we don't see the hidden text. The reason of this behavior is: when we set the callback from ModalPage to ModalWindow (element of HomePage) the numericId of HomePage is changed and this page is serialized with another id. During ModalWindow closing WindowClosedCallback is called. In this WindowClosedCallback we are trying to call our callback, which had to be set from ModalPage. But script, which handles WindowClosedCallback from browser, references to a HomePage with old numericId & of cource without set callback.
--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Updated] (WICKET-3808) Data, passed from ModalPage to
ModalWindow, is not accessible in WindowClosedCallback
Posted by "Mishelle Bonq (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/WICKET-3808?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Mishelle Bonq updated WICKET-3808:
----------------------------------
Attachment: project.rar
quickstart project added
> Data, passed from ModalPage to ModalWindow, is not accessible in WindowClosedCallback
> -------------------------------------------------------------------------------------
>
> Key: WICKET-3808
> URL: https://issues.apache.org/jira/browse/WICKET-3808
> Project: Wicket
> Issue Type: Bug
> Components: wicket-core, wicket-extensions
> Affects Versions: 1.5-RC4
> Environment: Win 7, FF
> Reporter: Mishelle Bonq
> Priority: Critical
> Attachments: project.rar
>
>
> Because of changes of pages processing an unacceptable behavior was detected. During such a processing in case if we try to pass some data from page on opened modal window to a modal window (which is an element of background page). The quickstart project was made to show this wrong behavior.
> Steps to reproduce:
> 1. Run quickstart project. Open HomePage. You'll see a link "Show ModalWindow". Click it. As an action on this click a new PageCreator is set for ModalWindow, which creates a new instance of ModalPage & pass a callback to this instance. Inside the callback the visibility of hidden element from HomePage is changed (The text "Hello, World!" became visible).
>
> 2. So, a ModalWindow will be shown with a ModalPage as content. In ModalPage you'll see another link "Close ModalWindow and show hidden text on HomePage". Click this link.
> This click must leads to setting the callback (which we've already passed in step 1 to ModalPage instance) to ModalWindow & close this ModalWindow.
> Closing ModalWindow happens in a correct way. But we don't see the hidden text. The reason of this behavior is: when we set the callback from ModalPage to ModalWindow (element of HomePage) the numericId of HomePage is changed and this page is serialized with another id. During ModalWindow closing WindowClosedCallback is called. In this WindowClosedCallback we are trying to call our callback, which had to be set from ModalPage. But script, which handles WindowClosedCallback from browser, references to a HomePage with old numericId & of cource without set callback.
--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Reopened] (WICKET-3808) Data, passed from ModalPage to
ModalWindow, is not accessible in WindowClosedCallback
Posted by "Martin Grigorov (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/WICKET-3808?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Martin Grigorov reopened WICKET-3808:
-------------------------------------
Reopen to review the new quickstart.
> Data, passed from ModalPage to ModalWindow, is not accessible in WindowClosedCallback
> -------------------------------------------------------------------------------------
>
> Key: WICKET-3808
> URL: https://issues.apache.org/jira/browse/WICKET-3808
> Project: Wicket
> Issue Type: Bug
> Components: wicket-core, wicket-extensions
> Affects Versions: 1.5-RC4
> Environment: Win 7, FF
> Reporter: Mishelle Bonq
> Attachments: project-2.rar, project.rar
>
>
> Because of changes of pages processing an unacceptable behavior was detected. During such a processing in case if we try to pass some data from page on opened modal window to a modal window (which is an element of background page). The quickstart project was made to show this wrong behavior.
> Steps to reproduce:
> 1. Run quickstart project. Open HomePage. You'll see a link "Show ModalWindow". Click it. As an action on this click a new PageCreator is set for ModalWindow, which creates a new instance of ModalPage & pass a callback to this instance. Inside the callback the visibility of hidden element from HomePage is changed (The text "Hello, World!" became visible).
>
> 2. So, a ModalWindow will be shown with a ModalPage as content. In ModalPage you'll see another link "Close ModalWindow and show hidden text on HomePage". Click this link.
> This click must leads to setting the callback (which we've already passed in step 1 to ModalPage instance) to ModalWindow & close this ModalWindow.
> Closing ModalWindow happens in a correct way. But we don't see the hidden text. The reason of this behavior is: when we set the callback from ModalPage to ModalWindow (element of HomePage) the numericId of HomePage is changed and this page is serialized with another id. During ModalWindow closing WindowClosedCallback is called. In this WindowClosedCallback we are trying to call our callback, which had to be set from ModalPage. But script, which handles WindowClosedCallback from browser, references to a HomePage with old numericId & of cource without set callback.
--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Updated] (WICKET-3808) Data, passed from ModalPage to
ModalWindow, is not accessible in WindowClosedCallback
Posted by "Mishelle Bonq (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/WICKET-3808?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Mishelle Bonq updated WICKET-3808:
----------------------------------
Attachment: project-2.rar
quickstart project-2 added
> Data, passed from ModalPage to ModalWindow, is not accessible in WindowClosedCallback
> -------------------------------------------------------------------------------------
>
> Key: WICKET-3808
> URL: https://issues.apache.org/jira/browse/WICKET-3808
> Project: Wicket
> Issue Type: Bug
> Components: wicket-core, wicket-extensions
> Affects Versions: 1.5-RC4
> Environment: Win 7, FF
> Reporter: Mishelle Bonq
> Attachments: project-2.rar, project.rar
>
>
> Because of changes of pages processing an unacceptable behavior was detected. During such a processing in case if we try to pass some data from page on opened modal window to a modal window (which is an element of background page). The quickstart project was made to show this wrong behavior.
> Steps to reproduce:
> 1. Run quickstart project. Open HomePage. You'll see a link "Show ModalWindow". Click it. As an action on this click a new PageCreator is set for ModalWindow, which creates a new instance of ModalPage & pass a callback to this instance. Inside the callback the visibility of hidden element from HomePage is changed (The text "Hello, World!" became visible).
>
> 2. So, a ModalWindow will be shown with a ModalPage as content. In ModalPage you'll see another link "Close ModalWindow and show hidden text on HomePage". Click this link.
> This click must leads to setting the callback (which we've already passed in step 1 to ModalPage instance) to ModalWindow & close this ModalWindow.
> Closing ModalWindow happens in a correct way. But we don't see the hidden text. The reason of this behavior is: when we set the callback from ModalPage to ModalWindow (element of HomePage) the numericId of HomePage is changed and this page is serialized with another id. During ModalWindow closing WindowClosedCallback is called. In this WindowClosedCallback we are trying to call our callback, which had to be set from ModalPage. But script, which handles WindowClosedCallback from browser, references to a HomePage with old numericId & of cource without set callback.
--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Commented] (WICKET-3808) Data, passed from ModalPage to
ModalWindow, is not accessible in WindowClosedCallback
Posted by "Mishelle Bonq (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/WICKET-3808?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13051070#comment-13051070 ]
Mishelle Bonq commented on WICKET-3808:
---------------------------------------
I'm not sure if i understand you in a correct way, but following your suggestions doesn't change the result. See attached quickstart project-2.
Your advice not to pass modalWindow to modalPage seems strange, because even in examples ( http://wicketstuff.org/wicket/ajax/modal-window ) modalWindow is passing, at least, we need the window object to have a possibility to close this modalWindow.
> Data, passed from ModalPage to ModalWindow, is not accessible in WindowClosedCallback
> -------------------------------------------------------------------------------------
>
> Key: WICKET-3808
> URL: https://issues.apache.org/jira/browse/WICKET-3808
> Project: Wicket
> Issue Type: Bug
> Components: wicket-core, wicket-extensions
> Affects Versions: 1.5-RC4
> Environment: Win 7, FF
> Reporter: Mishelle Bonq
> Attachments: project.rar
>
>
> Because of changes of pages processing an unacceptable behavior was detected. During such a processing in case if we try to pass some data from page on opened modal window to a modal window (which is an element of background page). The quickstart project was made to show this wrong behavior.
> Steps to reproduce:
> 1. Run quickstart project. Open HomePage. You'll see a link "Show ModalWindow". Click it. As an action on this click a new PageCreator is set for ModalWindow, which creates a new instance of ModalPage & pass a callback to this instance. Inside the callback the visibility of hidden element from HomePage is changed (The text "Hello, World!" became visible).
>
> 2. So, a ModalWindow will be shown with a ModalPage as content. In ModalPage you'll see another link "Close ModalWindow and show hidden text on HomePage". Click this link.
> This click must leads to setting the callback (which we've already passed in step 1 to ModalPage instance) to ModalWindow & close this ModalWindow.
> Closing ModalWindow happens in a correct way. But we don't see the hidden text. The reason of this behavior is: when we set the callback from ModalPage to ModalWindow (element of HomePage) the numericId of HomePage is changed and this page is serialized with another id. During ModalWindow closing WindowClosedCallback is called. In this WindowClosedCallback we are trying to call our callback, which had to be set from ModalPage. But script, which handles WindowClosedCallback from browser, references to a HomePage with old numericId & of cource without set callback.
--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Resolved] (WICKET-3808) Data, passed from ModalPage to
ModalWindow, is not accessible in WindowClosedCallback
Posted by "Martin Grigorov (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/WICKET-3808?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Martin Grigorov resolved WICKET-3808.
-------------------------------------
Resolution: Not A Problem
Your application is totally ugly.
HomePage creates the ModalWindow, then the PageCreator creates ModalPage and passes modalWindow, which implicitly passes a reference to HomePage instance ... You just beg for OutOfMemoryError with this.
Solution: Don't pass the modalWindow and the callback to ModalPage at all. Use PageReference as in wicket-examples.
> Data, passed from ModalPage to ModalWindow, is not accessible in WindowClosedCallback
> -------------------------------------------------------------------------------------
>
> Key: WICKET-3808
> URL: https://issues.apache.org/jira/browse/WICKET-3808
> Project: Wicket
> Issue Type: Bug
> Components: wicket-core, wicket-extensions
> Affects Versions: 1.5-RC4
> Environment: Win 7, FF
> Reporter: Mishelle Bonq
> Attachments: project.rar
>
>
> Because of changes of pages processing an unacceptable behavior was detected. During such a processing in case if we try to pass some data from page on opened modal window to a modal window (which is an element of background page). The quickstart project was made to show this wrong behavior.
> Steps to reproduce:
> 1. Run quickstart project. Open HomePage. You'll see a link "Show ModalWindow". Click it. As an action on this click a new PageCreator is set for ModalWindow, which creates a new instance of ModalPage & pass a callback to this instance. Inside the callback the visibility of hidden element from HomePage is changed (The text "Hello, World!" became visible).
>
> 2. So, a ModalWindow will be shown with a ModalPage as content. In ModalPage you'll see another link "Close ModalWindow and show hidden text on HomePage". Click this link.
> This click must leads to setting the callback (which we've already passed in step 1 to ModalPage instance) to ModalWindow & close this ModalWindow.
> Closing ModalWindow happens in a correct way. But we don't see the hidden text. The reason of this behavior is: when we set the callback from ModalPage to ModalWindow (element of HomePage) the numericId of HomePage is changed and this page is serialized with another id. During ModalWindow closing WindowClosedCallback is called. In this WindowClosedCallback we are trying to call our callback, which had to be set from ModalPage. But script, which handles WindowClosedCallback from browser, references to a HomePage with old numericId & of cource without set callback.
--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Commented] (WICKET-3808) Data, passed from ModalPage to
ModalWindow, is not accessible in WindowClosedCallback
Posted by "Mishelle Bonq (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/WICKET-3808?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13052027#comment-13052027 ]
Mishelle Bonq commented on WICKET-3808:
---------------------------------------
If we modify the modalWindow model via PageReference to homePage, during the "window.close()" operation the homePage (which we've got via PageRefence) changes its id, so the homePage with new data serializes with a new id. And then, when we execute WindowClosedCallback, it tries to get the homePage by the old id (this page was serialized without new data).
> Data, passed from ModalPage to ModalWindow, is not accessible in WindowClosedCallback
> -------------------------------------------------------------------------------------
>
> Key: WICKET-3808
> URL: https://issues.apache.org/jira/browse/WICKET-3808
> Project: Wicket
> Issue Type: Bug
> Components: wicket-core, wicket-extensions
> Affects Versions: 1.5-RC4
> Environment: Win 7, FF
> Reporter: Mishelle Bonq
> Attachments: project-2.rar, project.rar
>
>
> Because of changes of pages processing an unacceptable behavior was detected. During such a processing in case if we try to pass some data from page on opened modal window to a modal window (which is an element of background page). The quickstart project was made to show this wrong behavior.
> Steps to reproduce:
> 1. Run quickstart project. Open HomePage. You'll see a link "Show ModalWindow". Click it. As an action on this click a new PageCreator is set for ModalWindow, which creates a new instance of ModalPage & pass a callback to this instance. Inside the callback the visibility of hidden element from HomePage is changed (The text "Hello, World!" became visible).
>
> 2. So, a ModalWindow will be shown with a ModalPage as content. In ModalPage you'll see another link "Close ModalWindow and show hidden text on HomePage". Click this link.
> This click must leads to setting the callback (which we've already passed in step 1 to ModalPage instance) to ModalWindow & close this ModalWindow.
> Closing ModalWindow happens in a correct way. But we don't see the hidden text. The reason of this behavior is: when we set the callback from ModalPage to ModalWindow (element of HomePage) the numericId of HomePage is changed and this page is serialized with another id. During ModalWindow closing WindowClosedCallback is called. In this WindowClosedCallback we are trying to call our callback, which had to be set from ModalPage. But script, which handles WindowClosedCallback from browser, references to a HomePage with old numericId & of cource without set callback.
--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Commented] (WICKET-3808) Data, passed from ModalPage to
ModalWindow, is not accessible in WindowClosedCallback
Posted by "Martin Grigorov (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/WICKET-3808?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13052030#comment-13052030 ]
Martin Grigorov commented on WICKET-3808:
-----------------------------------------
The example at http://wicketstuff.org/wicket/ajax/modal-window shows how a ModalWindow with a Page is opened and then clicking on a link inside it closes it and updates the label in the first page. It looks just the same as you want to do in your quickstart.
> Data, passed from ModalPage to ModalWindow, is not accessible in WindowClosedCallback
> -------------------------------------------------------------------------------------
>
> Key: WICKET-3808
> URL: https://issues.apache.org/jira/browse/WICKET-3808
> Project: Wicket
> Issue Type: Bug
> Components: wicket-core, wicket-extensions
> Affects Versions: 1.5-RC4
> Environment: Win 7, FF
> Reporter: Mishelle Bonq
> Attachments: project-2.rar, project.rar
>
>
> Because of changes of pages processing an unacceptable behavior was detected. During such a processing in case if we try to pass some data from page on opened modal window to a modal window (which is an element of background page). The quickstart project was made to show this wrong behavior.
> Steps to reproduce:
> 1. Run quickstart project. Open HomePage. You'll see a link "Show ModalWindow". Click it. As an action on this click a new PageCreator is set for ModalWindow, which creates a new instance of ModalPage & pass a callback to this instance. Inside the callback the visibility of hidden element from HomePage is changed (The text "Hello, World!" became visible).
>
> 2. So, a ModalWindow will be shown with a ModalPage as content. In ModalPage you'll see another link "Close ModalWindow and show hidden text on HomePage". Click this link.
> This click must leads to setting the callback (which we've already passed in step 1 to ModalPage instance) to ModalWindow & close this ModalWindow.
> Closing ModalWindow happens in a correct way. But we don't see the hidden text. The reason of this behavior is: when we set the callback from ModalPage to ModalWindow (element of HomePage) the numericId of HomePage is changed and this page is serialized with another id. During ModalWindow closing WindowClosedCallback is called. In this WindowClosedCallback we are trying to call our callback, which had to be set from ModalPage. But script, which handles WindowClosedCallback from browser, references to a HomePage with old numericId & of cource without set callback.
--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Commented] (WICKET-3808) Data, passed from ModalPage to
ModalWindow, is not accessible in WindowClosedCallback
Posted by "Andera Del Bene (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/WICKET-3808?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13051993#comment-13051993 ]
Andera Del Bene commented on WICKET-3808:
-----------------------------------------
looks the same respect issue 3809...
Parent page should be modified through a PageReference
> Data, passed from ModalPage to ModalWindow, is not accessible in WindowClosedCallback
> -------------------------------------------------------------------------------------
>
> Key: WICKET-3808
> URL: https://issues.apache.org/jira/browse/WICKET-3808
> Project: Wicket
> Issue Type: Bug
> Components: wicket-core, wicket-extensions
> Affects Versions: 1.5-RC4
> Environment: Win 7, FF
> Reporter: Mishelle Bonq
> Attachments: project-2.rar, project.rar
>
>
> Because of changes of pages processing an unacceptable behavior was detected. During such a processing in case if we try to pass some data from page on opened modal window to a modal window (which is an element of background page). The quickstart project was made to show this wrong behavior.
> Steps to reproduce:
> 1. Run quickstart project. Open HomePage. You'll see a link "Show ModalWindow". Click it. As an action on this click a new PageCreator is set for ModalWindow, which creates a new instance of ModalPage & pass a callback to this instance. Inside the callback the visibility of hidden element from HomePage is changed (The text "Hello, World!" became visible).
>
> 2. So, a ModalWindow will be shown with a ModalPage as content. In ModalPage you'll see another link "Close ModalWindow and show hidden text on HomePage". Click this link.
> This click must leads to setting the callback (which we've already passed in step 1 to ModalPage instance) to ModalWindow & close this ModalWindow.
> Closing ModalWindow happens in a correct way. But we don't see the hidden text. The reason of this behavior is: when we set the callback from ModalPage to ModalWindow (element of HomePage) the numericId of HomePage is changed and this page is serialized with another id. During ModalWindow closing WindowClosedCallback is called. In this WindowClosedCallback we are trying to call our callback, which had to be set from ModalPage. But script, which handles WindowClosedCallback from browser, references to a HomePage with old numericId & of cource without set callback.
--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira