/*
 * jQuery Text Overflow v0.52
 *
 * Licensed under the new BSD License.
 * Copyright 2009, Bram Stein
 * All rights reserved.
 */
(function(a){a.extend(a.fn,{textOverflow:function(f,b){var c=f||"…",d=document.documentElement.style,e=("textOverflow" in d||"OTextOverflow" in d);if(!e){return this.each(function(){var j=a(this),n=j.clone(),l=j.text(),m=j.width(),g=0,i=0,k=l.length,h=function(){if(m!==j.width()){j.text(l);j.textOverflow(f,false);m=j.width()}};j.after(n.hide());if(n.width()>m){while(g<k){i=Math.floor(g+((k-g)/2));n.html(l.substr(0,i)+c);if(n.width()<m){g=i+1}else{k=i}}if(g<l.length){j.html(l.substr(0,g-1)+c)}}n.remove();if(b){setInterval(h,200)}})}else{return this}}})})(jQuery);
