// ------------------------------------------------------------- // Dave Holmes // // This javascript file contains all of the code used within the // system to display and manipulate the pop-up windows which can // be used to enter and analyse data....... // //--------------------------------------------------------------- // This function will display the modal dialog within the application it will also be ensured // the all of the HTML controls which may interfere with the popup are hidden and the shown afterwards // a DIV is used in the background to avoid the user access the back panel while the modal dialog is visible function vstall_dialog_show(url, width, height, mode) { if ( $( 'dialog' ) == null ) { body = $( document.body ); // If it's IE6 then we need to make some CSS changes to get around it's // poor support of position: fixed if ( window.ie6 ) { body.addClass( 'fixed' ); } mask = new Element( 'div', { 'styles' : { 'background-color' : '#000000', 'opacity' : 0 }, 'id' : 'mask' }); mask.injectInside( body ); dialog = new Element( 'div', { 'styles' : { 'width' : width + 'px', 'height' : height + 'px', 'margin-left' : '-' + ( width / 2 ) + 'px', 'margin-top' : '-' + ( height / 2 ) + 'px' }, 'id' : 'dialog' }); dialog.setHTML( '