/*
	Copyright (c) 2004-2007, The Dojo Foundation
	All Rights Reserved.

	Licensed under the Academic Free License version 2.1 or above OR the
	modified BSD license. For more information on Dojo licensing, see:

		http://dojotoolkit.org/community/licensing.shtml
*/


dojo._xdResourceLoaded({depends:[["provide","dijit._base.manager"]],defineResource:function(_1){if(!_1._hasResource["dijit._base.manager"]){_1._hasResource["dijit._base.manager"]=true;_1.provide("dijit._base.manager");_1.declare("dijit.WidgetSet",null,{constructor:function(){this._hash={};},add:function(_2){this._hash[_2.id]=_2;},remove:function(id){delete this._hash[id];},forEach:function(_4){for(var id in this._hash){_4(this._hash[id]);}},filter:function(_6){var _7=new dijit.WidgetSet();this.forEach(function(_8){if(_6(_8)){_7.add(_8);}});return _7;},byId:function(id){return this._hash[id];},byClass:function(_a){return this.filter(function(_b){return _b.declaredClass==_a;});}});dijit.registry=new dijit.WidgetSet();dijit._widgetTypeCtr={};dijit.getUniqueId=function(_c){var id;do{id=_c+"_"+(dijit._widgetTypeCtr[_c]!==undefined?++dijit._widgetTypeCtr[_c]:dijit._widgetTypeCtr[_c]=0);}while(dijit.byId(id));return id;};if(_1.isIE){_1.addOnUnload(function(){dijit.registry.forEach(function(_e){_e.destroy();});});}dijit.byId=function(id){return (_1.isString(id))?dijit.registry.byId(id):id;};dijit.byNode=function(_10){return dijit.registry.byId(_10.getAttribute("widgetId"));};}}});