(function(){var b,c,a=function(d,e){return function(){return d.apply(e,arguments)}};b=(function(){function d(f,i,h,g,e){this.type=f;this.text=i;this.timeout=h;this.notificator=g;this.position=e;this.moveUp=a(this.moveUp,this);this.remove=a(this.remove,this);this.dom=$('<div class="notification '+this.type+'">\n    '+this.text+"\n</div>");this.active=true;this.position=0;this.dom.css({top:this.position+"px",left:"300px"});this.dom.animate({left:"0px"},500,"swing");setTimeout(this.remove,this.timeout)}d.prototype.remove=function(){var e=this;return this.dom.fadeTo(500,0,function(){e.notificator.notifications.pop(e);return e.dom.remove()})};d.prototype.moveUp=function(e){this.position-=e;return this.dom.animate({top:this.position+"px"},500,"swing")};return d})();c=(function(){function d(){this.notifications=[]}d.prototype.notify=function(j,m,k){var e,f,g,l,h,i=this;if(k==null){k=7000}h=this.notifications;f=function(n){return n.moveUp(-50)};for(g=0,l=h.length;g<l;g++){e=h[g];f(e)}e=new b(j,m,k,this,0);this.notifications.push(e);return $("#notifications").append(e.dom)};return d})();window.Notificator=new c()}).call(this);