// SCRIPTS FOR DEFAULT.HTM

var pageInitialised = false;


function initialisePage(pageID)
{
InitialiseDHTML();
initialiseUtilMenu(pageID);
setupContactPanelAnims(); 
SetDHTMLElementVisibility(loadingMessage, false);
SetDHTMLElementVisibility(infoLinkTable, true);
SetDHTMLElementVisibility(consultationHeader, true);
SetDHTMLElementVisibility(guideHeader, true);
SetDHTMLElementVisibility(supportHeader, true);
SetDHTMLElementVisibility(emergeHeader, true);
SetDHTMLElementVisibility(faqHeader, true);
SetDHTMLElementVisibility(portfolioHeader, true);
SetDHTMLElementVisibility(kjHeader, true);
SetDHTMLElementVisibility(confidentialHeader, true);
SetDHTMLElementVisibility(conditionsHeader, true);
SetDHTMLElementVisibility(downloadsHeader, true);
SetDHTMLElementVisibility(contactHeader, true);
SetDHTMLElementVisibility(favoritesHeader, true);
pageInitialised = true; 
precacheNonCommonImages();
}


function refreshAnimation()
{
document.images['price_anim'].src = 'images/price_anim_blue_twist.gif';
}



function hideAllPopups(event)
{
HidePopup('consultationPopup', event);
HidePopup('guidePopup', event);
HidePopup('supportPopup', event);
HidePopup('emergePopup', event);
HidePopup('faqPopup', event);
HidePopup('portfolioPopup', event);
HidePopup('kjPopup', event);
HidePopup('confidentialPopup', event);
HidePopup('conditionsPopup', event);
HidePopup('downloadsPopup', event);
HidePopup('contactPopup', event);
HidePopup('favoritesPopup', event);
HidePopup('pricesPopup', event);
HidePopup('sorPopup', event);
HidePopup('ppPopup', event);
HidePopup('sepPopup', event);
HidePopup('bglPopup', event);
HidePopup('wcdPopup', event);
HidePopup('smPopup', event);
HidePopup('whdPopup', event);
HidePopup('atcPopup', event);
HidePopup('summaryPopup', event);
HidePopup('affordablePopup', event);
HidePopup('endorsementsPopup', event);
refreshAnimation();
}


function showNewUpperMenuPopup(popupID, inlineElemID, evt)
{
if (pageInitialised)
  {
  hideAllPopups(evt); 
  ShowPopup(popupID, 0, LeftXOfInlineElem(inlineElemID), TopYOfInlineElem(inlineElemID)+GetDHTMLElementHeight(inlineElemID), evt);
  }
}

function showNewLowerMenuPopup(popupID, inlineElemID, evt)
{
if (pageInitialised)
  {
  hideAllPopups(evt); 
  ShowPopup(popupID, 0, LeftXOfInlineElem(inlineElemID), TopYOfInlineElem(inlineElemID)-GetDHTMLElementHeight(popupID)-2, evt);
  }
}


function showNewFeaturePopup(popupID, inlineElemID, evt)
{
if (pageInitialised)
  {
  hideAllPopups(evt);
  ShowPopup(popupID, 2, 0, 0, evt);
  refreshAnimation();
  }
}



