// JavaScript Document
function setSection(section){
	currentSection = section;
	checkSection();
}

function checkSection(){
	document.getElementById('dwbtn').style.backgroundPosition="top";
		
	if(currentSection == "dwbtn"){
		document.getElementById('dwbtn').style.backgroundPosition="bottom";
	}
	else {
		document.getElementById('dwbtn').style.backgroundPosition="top";
	}
}

function changeButtons(n){
	switch(n){
		case 1:
		document.getElementById('dwbtn').style.backgroundPosition="bottom";
		break;
	}
}

function changeButtonsBack(n){
	switch(n){
		case 1:
		if(currentSection == "dwbtn"){
			document.getElementById('dwbtn').style.backgroundPosition="bottom";
		}
		else {
			document.getElementById('dwbtn').style.backgroundPosition="top";
		}
		break;
	}
}



function setSection1(section1){
	currentSection1 = section1;
	checkSection1();
}

function checkSection1(){
	document.getElementById('dwbtn1').style.backgroundPosition="top";
		
	if(currentSection1 == "dwbtn1"){
		document.getElementById('dwbtn1').style.backgroundPosition="bottom";
	}
	else {
		document.getElementById('dwbtn1').style.backgroundPosition="top";
	}
}

function changeButtons1(n){
	switch(n){
		case 1:
		document.getElementById('dwbtn1').style.backgroundPosition="bottom";
		break;
	}
}

function changeButtonsBack1(n){
	switch(n){
		case 1:
		if(currentSection1 == "dwbtn1"){
			document.getElementById('dwbtn1').style.backgroundPosition="bottom";
		}
		else {
			document.getElementById('dwbtn1').style.backgroundPosition="top";
		}
		break;
	}
}





function setSection2(section2){
	currentSection2 = section2;
	checkSection2();
}

function checkSection2(){
	document.getElementById('home').style.backgroundPosition="top";
	document.getElementById('product').style.backgroundPosition="top";
	document.getElementById('pricelist').style.backgroundPosition="top";
	document.getElementById('download').style.backgroundPosition="top";
	document.getElementById('aboutus').style.backgroundPosition="top";
	document.getElementById('contactus').style.backgroundPosition="top";
		
	if(currentSection2 == "home"){
		document.getElementById('home').style.backgroundPosition="bottom";
	}
	else if(currentSection2 == "product"){
		document.getElementById('product').style.backgroundPosition="bottom";
	}
	else if(currentSection2 == "pricelist"){
		document.getElementById('pricelist').style.backgroundPosition="bottom";
	}
	else if(currentSection2 == "download"){
		document.getElementById('download').style.backgroundPosition="bottom";
	}
	else if(currentSection2 == "aboutus"){
		document.getElementById('aboutus').style.backgroundPosition="bottom";
	}
	else if(currentSection2 == "contactus"){
		document.getElementById('contactus').style.backgroundPosition="bottom";
	}
	else {
		document.getElementById('home').style.backgroundPosition="top";
		document.getElementById('product').style.backgroundPosition="top";
		document.getElementById('pricelist').style.backgroundPosition="top";
		document.getElementById('download').style.backgroundPosition="top";
		document.getElementById('aboutus').style.backgroundPosition="top";
		document.getElementById('contactus').style.backgroundPosition="top";
	}
}

function changeButtons2(n){
	switch(n){
		case 1:
		document.getElementById('home').style.backgroundPosition="bottom";
		break;
		
		case 2:
		document.getElementById('product').style.backgroundPosition="bottom";
		break;
		
		case 3:
		document.getElementById('pricelist').style.backgroundPosition="bottom";
		break;
		
		case 4:
		document.getElementById('download').style.backgroundPosition="bottom";
		break;
		
		case 5:
		document.getElementById('aboutus').style.backgroundPosition="bottom";
		break;
		
		case 6:
		document.getElementById('contactus').style.backgroundPosition="bottom";
		break;
	}
}

function changeButtonsBack2(n){
	switch(n){
		case 1:
		if(currentSection2 == "home"){
			document.getElementById('home').style.backgroundPosition="bottom";
		}
		else {
			document.getElementById('home').style.backgroundPosition="top";
		}
		break;
		
		case 2:
		if(currentSection2 == "product"){
			document.getElementById('product').style.backgroundPosition="bottom";
		}
		else {
			document.getElementById('product').style.backgroundPosition="top";
		}
		break;
		
		case 3:
		if(currentSection2 == "pricelist"){
			document.getElementById('pricelist').style.backgroundPosition="bottom";
		}
		else {
			document.getElementById('pricelist').style.backgroundPosition="top";
		}
		break;
		
		case 4:
		if(currentSection2 == "download"){
			document.getElementById('download').style.backgroundPosition="bottom";
		}
		else {
			document.getElementById('download').style.backgroundPosition="top";
		}
		break;
		
		case 5:
		if(currentSection2 == "aboutus"){
			document.getElementById('aboutus').style.backgroundPosition="bottom";
		}
		else {
			document.getElementById('aboutus').style.backgroundPosition="top";
		}
		break;
		
		case 6:
		if(currentSection2 == "contactus"){
			document.getElementById('contactus').style.backgroundPosition="bottom";
		}
		else {
			document.getElementById('contactus').style.backgroundPosition="top";
		}
		break;
	}
}