﻿// JScript File

// create a dimmer div
function buildDimmerDiv()
{
    document.write('<div id="dimmer" class="dimmer" style="width:'+
    window.screen.width + 'px; height:' + window.screen.height +'px"></div>');
}


function notifyNoAvailableGallery()
{
    /*
    Ext.Msg.show({
       title:'No Available Sets',
       msg: 'Sorry there are no available sets as of the moment. Please try again some other time.',
       buttons: Ext.Msg.OK,
       fn: gotoMain
    });
    */
    
    Event.observe(window, 'load', function() {   
    
        alert("Sorry there are no available sets as of the moment.");
        gotoMain();
    
    }); 
    
}

function gotoMain()
{
    window.location = ResolveClientUrl("/default.aspx");
}

function ResolveClientUrl(relativePath){
    // assuming all executing scripts is not located in a child directory
    return window.location.href.substring(0,window.location.href.lastIndexOf("/")) + relativePath;
}