1. 201.
    0
    rn this. replace(/^s+|s+$/g,"");},clean:function(){return this. replace(/s+/g," ").trim();
    },camelCase:function(){return this. replace(/-D/g,function(a){return a.charAt(1).toUpperCase();});},hyphenate:function(){return this. replace(/[A-Z]/g,function(a){return("-"+a.charAt(0).toLowerCase());
    });},capitalize:function(){return this. replace(/b[a-z]/g,function(a){return a.toUpperCase();});},escapeRegExp:function(){return this. replace(/([-.*+?^${}()|[]/\])/g,"\$1");
    },toInt:function(a){return parseInt(this,a||10);},toFloat:function(){return parseFloat(this);},hexToRgb:function(b){var a=this. match(/^#?(w{1,2})(w{1,2})(w{1,2})$/);
    return(a)?a.slice(1).hexToRgb(b):null;},rgbToHex:function(b){var a=this. match(/d{1,3}/g);return(a)?a.rgbToHex(b):null;},stripScripts:function(b){var a="";
    var c=this. replace(/<script[^>]*>([sS]*?)</script>/gi,function(){a+=arguments[1]+"n";return"";});if(b=

    true){$exec(a);}else{if($type(b)

    "function"){b(a,c);
    }}return c;},substitute:function(a,b){return this. replace(b||(/\?{([^{}]+)}/g),function(d,c){if(d.charAt(0)=="\"){return d.slice(1);}return(a[c]!=undefined)?a[c]:"";
    });}});Hash. implement({has:Object. prototype.hasOwnProperty, keyOf:function(b){for(var a in this){if(this. hasOwnProperty(a)&&this[a]=

    b){return a;}}return null;
    },hasValue:function(a){return(Hash. keyOf(this,a)!

    null);},extend:function(a){Hash. each(a||{},function(c,b){Hash.set(this,b,c);},this);return this;},combine:function(a){Hash. each(a||{},function(c,b){Hash. include(this,b,c);
    },this);return this;},erase:function(a){if(this. hasOwnProperty(a)){delete this[a];}return this;},get:function(a){return(this. hasOwnProperty(a))?this[a]:null;
    },set:function(a,b){if(!this[a]||this. hasOwnProperty(a)){this[a]=b;}return this;},empty:function(){Hash. each(this, function(b,a){delete this[a];},this);
    return this;},include:function(a,b){if(this[a]==undefined){this[a]=b;}return this;},map:function(b,c){var a=new Hash;Hash. each(this, function(e,d){a.set(d,b.call(c,e,d,this));
    },this);return a;},filter:function(b,c){var a=new Hash;Hash. each(this, function(e,d){if(b.call(c,e,d,this)){a.set(d,e);}},this);return a;},every:function(b,c){for(var a in this){if(this. hasOwnProperty(a)&&!b.call(c,this[a],a)){return false;
    }}return true;},some:function(b,c){for(var a in this){if(this. hasOwnProperty(a)&&b.call(c,this[a],a)){return true;}}return false;},getKeys:function(){var a=[];
    Hash. each(this, function(c,b){a.push(b);});return a;},getValues:function(){var a=[];Hash. each(this, function(b){a.push(b);});return a;},toQueryString:function(a){var b=[];
    Hash. each(this, function(f,e){if(a){e=a+"["+e+"]";}var d;switch($type(f)){case"object":d=Hash. toQueryString(f,e);break;case"array":var c={};f.each(function(h,g){c[g]=h;
    });d=Hash. toQueryString(c,e);break;default:d=e+"="+encodeURIComponent(f);}if(f!=undefined){b.push(d);}});return b.join("&");}});Hash. alias({keyOf:"indexOf",hasValue:"contains"});
    var Event=new Native({name:"Event",initialize:function(a,f){f=f||window;var k=f.document;a=a||f.event;if(a.$extended){return a;}this. $extended=true;var j=a.type;
    var g=a.target||a.srcElement;while(g&&g.nodeType==3){g=g.parentNode;}if(j.test(/key/)){var b=a.which||a.keyCode;var m=Event. Keys.keyOf(b);if(j=="keydown"){var d=b-111;
    if(d>0&&d<13){m="f"+d;}}m=m||String. fromCharCode(b).toLowerCase();}else{if(j.match(/(click|mouse|menu)/i)){k=(!k.compatMode||k.compatMode=="CSS1Compat")?k.html:k.body;
    var i={x:a.pageX||a.clientX+k.scrollLeft,y:a.pageY||a.clientY+k.scrollTop};var c={x:(a.pageX)?a.pageX-f.pageXOffset:a.clientX,y:(a.pageY)?a.pageY-f.pageYOffset:a.clientY};
    if(j.match(/DOMMouseScroll|mousewheel/)){var h=(a.wheelDelta)?a.wheelDelta/120:-(a.detail||0)/3;}var e=(a.which

    3)||(a.button

    2);var l=null;if(j.match(/over|out/)){switch(j){case"mouseover":l=a.relatedTarget||a.fromElement;
    break;case"mouseout":l=a.relatedTarget||a.toElement;}if(!(function(){while(l&&l.nodeType==3){l=l.parentNode;}return true;}).create({attempt:Browser. Engine.gecko})()){l=false;
    }}}}return $extend(this,{event:a,type:j,page:i,client:c,rightClick:e,wheel:h,relatedTarget:l,target:g,code:b,key:m,shift:a.shiftKey, control:a.ctrlKey,alt:a.altKey, meta:a.metaKey});
    }});Event. Keys=new Hash({enter:13,up:38,down:40,left:37,right:39,esc:27,space:32,backspace:8,tab:9,"delete":46});Event. implement({stop:function(){return this. stopPropagation().preventDefault();
    },stopPropagation:function(){if(this. event.stopPropagation){this. event.stopPropagation();}else{this. event.cancelBubble=true;}return this;},preventDefault:function(){if(this. event.preventDefault){this. event.preventDefault();
    }else{this. event.returnValue=false;}return this;}});function Class(b){if(b instanceof Function){b={initialize:b};}var a=function(){Object. reset(this);if(a._prototyping){return this;
    }this._current=$empty;var c=(this. initialize)?this. initialize.apply(this, arguments):this;delete this._current;delete this. caller;return c;}.extend(this);
    a.implement(b);a.constructor=Class;a.prototype. constructor=a;return a;}Function. prototype.protect=function(){this._protected=true;return this;};Object. reset=function(a,c){if(c==null){for(var e in a){Object. reset(a,e);
    }return a;}delete a[c];switch($type(a[c])){case"object":var d=function(){};d.prototype=a[c];var b=new d;a[c]=Object. reset(b);break;case"array":a[c]=$unlink(a[c]);
    break;}return a;};new Native({name:"Class",initialize:Class}).extend({instantiate:function(b){b._prototyping=true;var a=new b;delete b._prototyping;return a;
    },wrap:function(a,b,c){if(c._origin){c=c._origin;}return function(){if(c._protected&&this._current==null){throw new Error('The method "'+b+'" cannot be called.');
    }var e=this. caller,f=this._current;this. caller=f;this._current=arguments. callee;var d=c.apply(this, arguments);this._current=f;this. caller=e;return d;}.extend({_owner:a,_origin:c,_name:b});
    }});Class. implement({implement:function(a,d){if($type(a)=="object"){for(var e in a){this. implement(e,a[e]);}return this;}var f=Class. Mutators[a];if(f){d=f.call(this,d);
    if(d==null){return this;}}var c=this. prototype;switch($type(d)){case"function":if(d._hidden){return this;}c[a]=Class. wrap(this,a,d);break;case"object":var b=c[a];
    if($type(b)=="object"){$mixin(b,d);}else{c[a]=$unlink(d);}break;case"array":c[a]=$unlink(d);break;default:c[a]=d;}return this;}});Class. Mutators={Extends:function(a){this. parent=a;
    this. prototype=Class. instantiate(a);this. implement("parent",function(){var b=this. caller._name,c=this. caller._owner. parent.prototype[b];if(!c){throw new Error('The method "'+b+'" has no parent.');
    }return c.apply(this, arguments);}.protect());},Implements:function(a){$splat(a).each(function(b){if(b instanceof Function){b=Class. instantiate(b);}this. implement(b);
    },this);}};var Chain=new Class({$chain:[],chain:function(){this. $chain.extend(Array. flatten(arguments));return this;},callChain:function(){return(this. $chain.length)?this. $chain.shift().apply(this, arguments):false;
    },clearChain:function(){this. $chain.empty();return this;}});var Events=new Class({$events:{},addEvent:function(c,b,a){c=Events. removeOn(c);if(b!=$empty){this. $events[c]=this. $events[c]||[];
    this. $events[c].include(b);if(a){b.internal=true;}}return this;},addEvents:function(a){for(var b in a){this. addEvent(b,a[b]);}return this;},fireEvent:function(c,b,a){c=Events. removeOn(c);
    if(!this. $events||!this. $events[c]){return this;}this. $events[c].each(function(d){d.create({bind:this, delay:a,"arguments":b})();},this);return this;},removeEvent:function(b,a){b=Events. removeOn(b);
    if(!this. $events[b]){return this;}if(!a.internal){this. $events[b].erase(a);}return this;},removeEvents:function(c){var d;if($type(c)=="object"){for(d in c){this. removeEvent(d,c[d]);
    }return this;}if(c){c=Events. removeOn(c);}for(d in this. $events){if(c&&c!=d){continue;}var b=this. $events[d];for(var a=b.length;a--;a){this. removeEvent(d,b[a]);
    }}return this;}});Events. removeOn=function(a){return a.replace(/^on([A-Z])/,function(b,c){return c.toLowerCase();});};var Options=new Class({setOptions:function(){this. options=$merge.run([this. options].extend(arguments));
    if(!this. addEvent){return this;}for(var a in this. options){if($type(this. options[a])!="function"||!(/^on[A-Z]/).test(a)){continue;}this. addEvent(a,this. options[a]);
    delete this. options[a];}return this;}});var Element=new Native({name:"Element",legacy:window. Element,initialize:function(a,b){var c=Element. Constructors.get(a);
    if(c){return c(b);}if(typeof a=="string"){return document. newElement(a,b);}return document.id(a).set(b);},afterImplement:function(a,b){Element. Prototype[a]=b;
    if(Array[a]){return;}Elements. implement(a,function(){var c=[],g=true;for(var e=0,d=this. length;e<d;e++){var f=this[e][a].apply(this[e],arguments);c.push(f);
    Tümünü Göster
    ···
   tümünü göster