(function(){var e=function(e){var t=this,n=function(){var t=e(),n=0,r=e(window),i=0,s=0,o;e(function(){i=r.width(),s=r.height()}),e.event.special.resize={setup:function(n){return this!==window&&(t.push(this),e.unique(t)),this!==window},teardown:function(){return t=t.not(this),this!==window},add:function(u){var a=u.handler;u.origHandler=a,u.handler=function(a,f){var l=this===window;if(l&&a.originalEvent){var c=r.width(),h=r.height();if(c!=i||h!=s)i=c,s=h,clearTimeout(o),o=setTimeout(function(){r.trigger("resize")},1);return}if(n===0){n++;var p=f===!1?a.target:this;e.event.handle.call(p,a);if(a.isPropagationStopped()){n--;return}var d=t.index(this),v=t.length,m,g;while(++d<v&&(m=t[d])&&(l||e.contains(p,m))){e.event.handle.call(m,a);if(a.isPropagationStopped())while(++d<v&&(g=t[d]))if(!e.contains(m,g)){d--;break}}a.stopImmediatePropagation(),n--}else u.origHandler.call(this,a,f)}}},e([document,window]).bind("resize",function(){})};n(),t.resolveWith(n)};dispatch("mvc/event.resize").containing(e).to("Foundry/2.1 Modules")})();