

// ### Method ######################################################################

var divRootPageName;

function RelationViewInit()
{
  divRootPageName = document.getElementById("divRootPageName");
  tblRelationView = document.getElementById("tblRelationView");

  AddInlineEvent();
}

function AddInlineEvent()
{
  if (tblRelationView)
  {
    if (divRootPageName)
    {
      AddEvent(divRootPageName, "mouseover", RootPageNameOver)
      AddEvent(divRootPageName, "mouseout", RootPageNameOut)
    }

    AddEvent(tblRelationView, "mouseover", CancelResetRelationContent);
    AddEvent(tblRelationView, "mouseout", RootPageNameOut);

    divRootPageName.style.cursor = "pointer";
  }
  else
  {
    divRootPageName.style.cursor = "default";
  }
}


var tmrContent;
var tblRelationView;

function RootPageNameOver()
{
  if (tblRelationView)
  {
    divRootPageName.style.color = "#f8ac19";

    tblRelationView.style.left = (GetPosition(divRootPageName)[0] + 20).toString() + "px";
    tblRelationView.style.top = (GetPosition(divRootPageName)[1] + divRootPageName.offsetHeight).toString() + "px";

    tblRelationView.style.display = "block";
  }
}

function RootPageNameOut()
{
  tmrContent = window.setTimeout("ResetRelationContent()", 500);
}

function ResetRelationContent()
{
  if (tblRelationView)
  {
    divRootPageName.style.color = "#000000";
    tblRelationView.style.display = "none";
  }
}

function CancelResetRelationContent()
{
  if (tmrContent)
  {
    window.clearTimeout(tmrContent);
  }
}


