Fix to issue with dangling events after ajax refresh of main panel in MySpaces portlet

git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@5748 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
Kevin Roast
2007-05-22 09:55:49 +00:00
parent 6dcd786e7f
commit 77b1de82da

View File

@@ -265,6 +265,9 @@ var MySpaces = {
anim.start({'opacity': 1});
},
/**
* OK button click handler for the Upload File pop-up panel
*/
uploadOK: function(actionEl, path)
{
// call the upload help to perform the upload
@@ -278,18 +281,27 @@ var MySpaces = {
this.uploadClose(actionEl);
},
/**
* Cancel button click handler for the Upload File pop-up panel
*/
uploadClose: function(actionEl)
{
var panel = $(actionEl).getParent();
panel.setStyle("display", "none");
},
/**
* Callback function executed after the upload of a new file is complete
*/
uploadCompleteHandler: function(id, path, fileName, error)
{
if (error == null)
{
// empty the main panel div and restart by reloading the panel contents
$('spacePanel').empty();
var spacePanel = $('spacePanel');
spacePanel.setStyle('visibility', 'hidden');
spacePanel.empty();
spacePanel.removeEvents('mouseleave');
MySpaces.start();
}
else