﻿//VER:2.0.0-A
//Copyright (c) 2009 TechPros, LLC (A Michigan Limited Liability Company)
//This website and the code contained within this website belong to its creator, 
//Thomas J. Thelen, owner of TechPros, LLC.
//This code may not be redistributed, copied, altered, or resold 
//without the explicit permission of its creator.
//If this website is not registered to you or your company then it may not be used 
//without obtaining a legal copy from TechPros, LLC.
//You may visit the TechPros, LLC website at "http://www.mitechpros.com" for more information on 
//how to obtain a legal copy of this website and/or the program(s) associated with it.

var strCurrent_Menu_Tab = "options_menu_tab_1-1";

function Change_Options_Menu_Focus(strWhat) {
    ShowOrHide(strCurrent_Menu_Tab, 'HIDE', 'DIS');
    
    document.getElementById(strCurrent_Menu_Tab.replace("-1", "")).style.backgroundColor = "#F0F0F0"
    document.getElementById(strCurrent_Menu_Tab.replace("-1", "")).style.borderBottomColor = "#B8B8B8"

    ShowOrHide(strWhat, 'SHOW', 'DIS');
    
    document.getElementById(strWhat.replace("-1", "")).style.backgroundColor = "#FFFFFF"
    document.getElementById(strWhat.replace("-1", "")).style.borderBottomColor = "#FFFFFF"
    
    strCurrent_Menu_Tab = strWhat;

}

function Initiate_Menu_tabs() {
    var intID = 0
    var strTabs = document.getElementsByTagName("td");

    for ( i = 0; i < strTabs.length; i++) {
        if (strTabs[i].className == "options_menu_tab") {
            intID = intID + 1            
            strTabs[i].id = "options_menu_tab_" + intID
            strTabs[i].onclick = function() {Change_Options_Menu_Focus(this.id + "-1")}
        }
    }
    
    Change_Options_Menu_Focus(strCurrent_Menu_Tab);
}