aboutsummaryrefslogtreecommitdiffstats
path: root/public/admin/view/javascript/openbay/js/openbay.js
blob: 359b3e675eb8c379263c1f76f61c17c591f9496d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
function showGreyScreen(boxDiv){
    $('#greyScreen').css({	"display": "block", opacity: 0.6, "width":$(document).width()+20,"height":$(document).height(), "z-index":99998}).show();
    $('#'+boxDiv).fadeIn().css({"display": "block", "z-index":99999});
    $('body').css({"overflow":"hidden"});
}

function hideGreyScreen(){
    $('#greyScreen').css("display", "none");
    $('.greyScreenBox').css("display", "none");
    $('body').css({"overflow":"scroll"});
}

$(window).resize(function(){
    $('#greyScreen').css("display") == 'block'?showGreyScreen():"";
});

$('.previewClose').bind('click', function(){
    hideGreyScreen();
});

$(document).ready(function(){
    hideGreyScreen();
});