<!--
// Copyright Organic, Inc. 2000.  All rights reserved.  This
// source code file contains proprietary and confidential information
// and trade secrets of Organic, Inc.

var menus = new Array();
var options = new Array();
var problemMenu = null;
var problemForm = null;

function getMenus(){return};
function buildSearch(){return};
function buildDescript(){return};
function buildTools(){return};
function buildExplanations() {return};
function getPositions(){return};

function swapOn(imgName) {
    if (ie4 || ns5) hideOtherMenus("null")
    document [imgName].src= "/global/images/" + imgName + "-on.gif";
}

function swapOff(imgName) {
    document [imgName].src= "/global/images/" + imgName + ".gif";
}

function init() {
    preloadImgs();
    if(is4) buildOptions();
}

function surfto(formname) {
    myindex=eval("document." + formname + ".elements[0].selectedIndex");
    location=eval("document." + formname + ".elements[0].options[myindex].value");
}

function clearForm(formname) {
    var elementCount = eval('document.' + formname + '.elements.length');
    var elementType;
    var i;
    for (i = 0; i < elementCount; i++) {
        elementType = (eval("document." + formname + ".elements[i].type"));
        if (elementType == "text" || elementType == "textarea") {
            eval('document.' + formname + '.elements[i].value = ""');
        }
    }
}

function preloadImgs() {
    var preloadIms = new Array('/global/images/btn_home-on.gif','/global/images/btn_largebusiness-on.gif','/global/images/btn_myQwest-on.gif','/global/images/btn_partners-on.gif','/global/images/btn_residential-on.gif','/global/images/btn_smallbusiness-on.gif','/global/images/btn_top_customer_service-on.gif','/global/images/btn_top_dsl-on.gif','/global/images/btn_top_internet-on.gif','/global/images/btn_top_search-on.gif','/global/images/btn_top_wireless-on.gif','/global/images/btn_wholesale-on.gif','/global/images/footer_about_qwest-on.gif','/global/images/footer_careers-on.gif') ;
    for (each in preloadIms) {
        var a_image = new Image();
        a_image.src = preloadIms[each] ;
    }
}

function itemOver(whichItem, type) {
    if(is4 && (type != null)) {
        if (type == 'menu' && menus[whichItem + 'Menu'] && menus[whichItem + 'Menu'].visShow) {
            mask.setVis(true);
            showMenu(whichItem + 'Menu');
        }
        else {
            if(window[whichItem + 'Obj']) thisObj = window[whichItem + 'Obj'];
            else return;

            if(type == 'home') {
                thisImg = '';
                if (document.images[(whichItem + 'Img')]) thisImg = document.images[(whichItem + 'Img')];
                thisImg.src = "/global/images/" + whichItem + "On.gif";
                hMask.setVis(true);
                thisObj.setVis(true);
            }

            if(type == 'home2') {
                thisImg = '';
                if (document.images[(whichItem + 'Img')]) thisImg = document.images[(whichItem + 'Img')];
                thisImg.src="/global/images/" + whichItem + "On.gif";
                thisObj.setVis(true);
            }

            if((type == 'object') && thisObj && thisObj.setVisibility) {
                thisObj.setVisibility(true);
                if(whichItem == 'search') {
                    mask.setVis(true);
                    thisObj.imgMask.setVis(true);
                    searchFormElm.focus();
                }
                else {
                    thisObj[whichItem + 'ImgMask'].setVis(true);
                }
            }
        }
    }
    else {
        if(whichItem == 'search') return;
        if (ie4 || ns5) hideOtherMenus(whichItem);
        thisImg = '';
        if (document.images[(whichItem + 'Img')]) thisImg = document.images[(whichItem + 'Img')];
        else return;
        thisImg.src="/global/images/" + whichItem + "On.gif";
    }
}

function itemOut(whichItem, type, event) {
    if(is4 && (type == 'home')) {
        if(window[whichItem + 'Obj']) thisObj = window[whichItem + 'Obj'];
        else return;

        hMask.setVis(false);
        thisObj.setVis(false);
    }

    if(is4 && (type == 'home2')) {
        if(window[whichItem + 'Obj']) thisObj = window[whichItem + 'Obj'];
        else return;

        thisObj.setVis(false);
    }

    if(is4 && (type == 'menu')) {
        //if (ie4 || ns5) menus[whichItem + 'Menu'].visHide();
        if (ie4 || ns5) {
            var m = menus[whichItem + 'Menu'];
            var x = event.layerX;
            var y = event.layerY;
            //alert("menu: " + m.border.id + "\nx: " + x + "\ny: " + y);
        }
        return;
    }

    thisImg = document.images[(whichItem + 'Img')];
    thisImg.src="/global/images/" + whichItem + "Off.gif";
    return;
}

function goTo(url) {
    window.location = url;
}

function hideOtherMenus(whichMenu) {
    // hide all other menus.
    for (n in menus) {
        if (n != whichMenu && (menus[n].isVisible())) menus[n].visHide();
    }
}
// -->