/* MyRAQA standard js functions */
function findPosX(obj){
    var curleft = 0;
    if(obj.offsetParent)
        while(1){
          curleft += obj.offsetLeft;
          if(!obj.offsetParent)
            break;
          obj = obj.offsetParent;
        }
    else if(obj.x)
        curleft += obj.x;
    return curleft;
}

function findPosY(obj){
    var curtop = 0;
    if(obj.offsetParent)
        while(1){
          curtop += obj.offsetTop;
          if(!obj.offsetParent)
            break;
          obj = obj.offsetParent;
        }
    else if(obj.y)
        curtop += obj.y;
    return curtop;
}


function display_callout(e, id){
        c = document.getElementById('callout_' + id);
        c.style.position = 'absolute';
        c.style.display = 'block';
        c.style.left = findPosX(e)-18;
        c.style.top = findPosY(e)+3;     
}

function hide_callout(id){
        c = document.getElementById('callout_' + id);
        c.style.display = 'none';
}
