function hideAllBut(x) {

	for (i=0;i<selectors.length;i++){
		setObjDisplayed(selectors[i],0)
	}
	/*setObjDisplayed('byty',0);
      setObjDisplayed('rodinne-domy',0);	
	setObjDisplayed('pozemky',0);
	setObjDisplayed('zajimave-nemovitosti',0);*/
	if (selectors.inArray(x)) setObjDisplayed(x,1);
}

function OnOffObj(name) {
	if (name) {
		x = getObjDisplayed(name);
		y = (x == true ? 0 : 1);
		hideAllBut(name);
		setObjDisplayed(name,y);
	}
}
												  

Array.prototype.inArray = function (value)
// Returns true if the passed value is found in the
// array.  Returns false if it is not.
{
	var i;
	for (i=0; i < this.length; i++) {
		// Matches identical (===), not just similar (==).
		if (this[i] === value) {
			return true;
		}
	}
	return false;
};

