add method to close the modal dialog

This commit is contained in:
Doug Bell 2010-07-30 14:41:05 -05:00
parent 8e4dce0dbb
commit e03a441ded

View file

@ -454,6 +454,20 @@ WebGUI.Admin.prototype.openModalDialog
this.modalDialog = dialog;
};
/**
* closeModalDialog( )
* Close the current modal dialog
*/
WebGUI.Admin.prototype.closeModalDialog
= function ( ) {
if ( !this.modalDialog ) {
return; // Can't close what isn't open
}
this.modalDialog.destroy();
this.modalDialog = null;
};
/****************************************************************************
* WebGUI.Admin.LocationBar
*/