Element.implement({

	visible: function(){
		return this.getStyle('display') == 'none' || this.getStyle('visibility') == 'hidden' ? false : true;
	},
	
	show: function(){
		return this.setStyle('display', '').set('opacity', 1);
	},
	
	hide: function(collapse){
		return collapse ? this.setStyle('display', 'none') : this.set('opacity', 0);
	},
	
	toggle: function(collapse){
		return this.visible() ? this.hide(collapse) : this.show();
	}
	
});

Fx.TweenMany = new Class({

	Extends: Fx.Tween,

	initialize: function(elements, options){
		this.parent(elements[0], options);
		this.elements = this.subject = $$(elements);
	},
	
	set: function(property, now){
		if (arguments.length == 1){
			now = property;
			property = this.property || this.options.property;
		}
		this.render(this.elements, property, now, this.options.unit);
		return this;
	}

});

