dojo.require("dijit.Dialog");
dojo.require("dojox.layout.ContentPane");
var VRModelBox=null;

function showVRModelBox(title,href,height,width) {
    if(VRModelBox!=null && VRModelBox.open)
        closeVRModelBox();

    if(VRModelBox==null) {
        VRModelBox = new dijit.Dialog({
            href: '/itbc/content.jsp',
            title: title,
            style: 'height:' + (height+10) + 'px;width:' + (width+10) + 'px;z-index:2000;',
            draggable: false,
            onCancel: function() {
                closeVRModelBox();
            },
            ioArgs: {
                content: {
                    href: href,
                    width: width,
                    height: height
                }
            }
        });
    }

    VRModelBox.show();
}

function closeVRModelBox() {
    if(VRModelBox!=null) {
        VRModelBox.destroyRecursive();
        VRModelBox=null;
    }
}