﻿function showPopupMask()
{
    var mask = document.getElementById('popupMask');
    
    if (mask != null)
    {   
        mask.style.height = Math.max(document.body.clientHeight, getViewportHeight()) + "px";
        mask.style.width = Math.min(document.body.clientWidth, getViewportWidth()) + "px";
        mask.style.display = 'block';
    }
}

function hidePopupMask()
{
    var mask = document.getElementById('popupMask');
    
    if (mask != null)
    {
        mask.style.display = 'none';
    }
}