1 line
15 KiB
JavaScript
1 line
15 KiB
JavaScript
|
(function(f){try{if(document.execCommand){document.execCommand("BackgroundImageCache",false,true)}}catch(i){}var d=/\d/;var b=/\s+/;var c=parseInt(f.browser.version.substring(0,5).replace(".",""));var g=f.browser.mozilla&&c>=180&&c<=191;var a=/d{1,4}|M{1,4}|yy(?:yy)?|([Hhmstf])\1*|"[^"]*"|'[^']*'/g;var j=f.telerik={create:function(e,k){var m=k.name;var l=f.extend({},f.fn[m].defaults,k.options);return e.each(function(){var n=f(this);l=f.meta?f.extend({},l,n.data()):l;if(!n.data(m)){var o=k.init(this,l);n.data(m,o);j.trigger(this,"load");if(k.success){k.success(o)}}})},toJson:function(e){var k=[];for(var m in e){var l=e[m];if(typeof l!="object"){k.push('"'+m+'":"'+l+'"')}else{k.push('"'+m+'":'+this.toJson(l))}}return"{"+k.join(",")+"}"},delegate:function(k,e){return function(l){e.apply(k,[l,this])}},stop:function(e,k){return function(l){l.stopPropagation();e.apply(k||this,arguments)}},stopAll:function(e,k){return function(l){l.preventDefault();l.stopPropagation();e.apply(k||this,arguments)}},bind:function(e,k){var l=f(e.element);f.each(k,function(m){if(f.isFunction(this)){l.bind(m,this)}})},preventDefault:function(k){k.preventDefault()},hover:function(){f(this).addClass("t-state-hover")},leave:function(){f(this).removeClass("t-state-hover")},buttonHover:function(){f(this).addClass("t-button-hover")},buttonLeave:function(){f(this).removeClass("t-button-hover")},stringBuilder:function(){this.buffer=[]},ajaxError:function(m,l,e,n){var k=this.trigger(m,l,{XMLHttpRequest:e,textStatus:n});if(!k){if(n=="error"&&e.status!="0"){alert("Error! The requested URL returned "+e.status+" - "+e.statusText)}if(n=="timeout"){alert("Error! Server timeout.")}}return k},trigger:function(l,k,m){m=f.extend(m||{},new f.Event(k));m.stopPropagation();f(l).trigger(m);return m.isDefaultPrevented()},getType:function(e){if(e instanceof Date){return"date"}if(!isNaN(e)){return"number"}return"object"},formatString:function(){var o=arguments[0];for(var e=0,k=arguments.length-1;e<k;e++){var n=new RegExp("\\{"+e+"(:([^\\}]+))?\\}","gm");var m=arguments[e+1];var p=this.formatters[this.getType(m)];if(p){var q=n.exec(o);if(q){m=p(m,q[2])}}o=o.replace(n,function(){return m})}return o},getElementZIndex:function(e){var k="auto";f(e).parents().andSelf().each(function(){k=f(this).css("zIndex");if(Number(k)){k=Number(k)+1;return false}});return k},lastIndexOf:function(e,k){var l=k.length;for(var m=e.length-1;m>-1;m--){if(e.substr(m,l)==k){return m}}return -1},caretPos:function(e){var k=-1;if(document.selection){k=Math.abs(e.document.selection.createRange().moveStart("character",-e.value.length))}else{if(e.selectionStart!==undefined){k=e.selectionStart}}return k},encode:function(e){return e.replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">").replace(/\u00a0/g," ")},formatters:{},fx:{},cultureInfo:{days:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],abbrDays:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],months:["January","February","March","April","May","June","July","August","September","October","November","December"],abbrMonths:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],longTime:"h:mm:ss tt",longDate:"dddd, MMMM dd, yyyy",shortDate:"M/d/yyyy",shortTime:"h:mm tt",fullDateTime:"dddd, MMMM dd, yyyy h:mm:ss tt",generalDateShortTime:"M/d/yyyy h:mm tt",generalDateTime:"M/d/yyyy h:mm:ss tt",sortableDateTime:"yyyy'-'MM'-'ddTHH':'mm':'ss",universalSortableDateTime:"yyyy'-'MM'-'dd HH':'mm':'ss'Z'",monthYear:"MMMM, yyyy",monthDay:"MMMM dd",today:"today",tomorrow:"tomorrow",yesterday:"yesterday",next:"next",last:"last",year:"year",month:"month",week:"week",day:"day",am:"AM",pm:"PM",dateSeparator:"/",timeSeparator:":",firstDayOfWeek:0}};j.dropDown=function(e){f.extend(this,e);this.$element=f(new j.stringBuilder().cat("<div ").catIf(e.attr,e.attr).cat('><ul class="t-reset"></ul></div>').string()).addClass("t-popup t-group").hide()};j.dropDown.prototype={_html:function(n){var l=new j.stringBuilder();if(n){for(var k=0,o=n.length;k<o;k++){var m=n[k];var p=m.Text;var q={html:p==undefined?m:p&&p.replace(b,"")?p:"&
|