/*========
 * flying-w.net/js/counter.js
 *
 * (c) Copyright 1998-2011 (v5.5s) Flying @ Flying's World
 * 吴颖晖 Freddie
 *
 *#req*/
if("object"!=typeof window["F"]){
	var err="Missing prerequisite: Fjl.js";
	alert(err);
	throw new Error(err);
}/*======*/

/*<<<	Catalog selector	>>>*/
F.Catalog=function(catalogs,root,speed){
	this.catalogs=$(catalogs);
	this.root=$(root);
	this.speed=speed||"slow";
};
F.Catalog.prototype.init=function(){
	var self=this;
	self.catalogs.each(function(_,c){
		var o=$(c),items=self.root.children('.'+o.val());
		o.click(function(){
			items[o.is(":checked")?"slideDown":"slideUp"](self.speed);
		});
	});
};
