﻿/*
 * core.js JavaScript Library ver0.8
 * http://www.geometry.ne.jp/
 * Copyright 2011, GEOMETRY graphics
 *
*/
function browserCheck(window){this.bv=0;this.bn='';var agt=navigator.userAgent.toLowerCase();this.uag=agt;this.gecko=(agt.indexOf('gecko')!==-1);this.mv=parseInt(navigator.appVersion);this.op=(agt.indexOf('opera')!==-1);this.sf=(agt.indexOf('safari')!==-1);this.fx=(agt.indexOf('firefox')!==-1);this.ie=(agt.indexOf('msie')!==-1&&!this.op);this.ns=((agt.indexOf('netscape')!==-1)||(agt.indexOf('navigator')!==-1));this.cr=(agt.indexOf('chrome')!==-1);if(this.ns){this.bn='ns';if(agt.indexOf('netscape/7')!==-1){this.bv=7}else if(agt.indexOf('netscape/8')!==-1){this.bv=8}else if(agt.indexOf('navigator/9')!==-1){this.bv=9}}else if(this.op){this.bn='op';if(agt.indexOf('opera/11')!==-1||agt.indexOf('opera 11')!==-1){this.bv=11}else if(agt.indexOf('opera/10')!==-1||agt.indexOf('opera 10')!==-1){this.bv=10}else if(agt.indexOf('opera/9')!==-1||agt.indexOf('opera 9')!==-1){this.bv=9}else if(agt.indexOf('opera/8')!==-1||agt.indexOf('opera 8')!==-1){this.bv=8}else if(agt.indexOf('opera/7')!==-1||agt.indexOf('opera 7')!==-1){this.bv=7}}else if(this.sf){this.bn='sf';if(agt.indexOf('version/5')!==-1){this.bv=5}else if(agt.indexOf('version/4')!==-1){this.bv=4}else if(agt.indexOf('version/3')!==-1){this.bv=3}else if(agt.indexOf('applewebkit/4')!==-1){this.bv=2}}else if(this.fx){this.bn='fx';if(agt.indexOf('firefox/3')>0){this.bv=3}else if(agt.indexOf('firefox/2')!==-1){this.bv=2}else if(agt.indexOf('firefox/1')!==-1){this.bv=1}}else if(this.ie){this.bn='ie';this.ie6=(agt.indexOf('msie 6')!==-1);this.ie7=(agt.indexOf('msie 7')!==-1);this.ie8=(agt.indexOf('msie 8')!==-1);this.ie9=(agt.indexOf('msie 9')!==-1);this.ie10=(agt.indexOf('msie 10')!==-1);this.ie11=(agt.indexOf('msie 11')!==-1);if(this.ie6)this.bv=6;if(this.ie7)this.bv=7;if(this.ie8)this.bv=8;if(this.ie9)this.bv=9;if(this.ie10)this.bv=10;if(this.ie11)this.bv=11;this.ie6under=(this.bv<7);this.ie7under=(this.bv<8);this.ie8under=(this.bv<9);this.ie9under=(this.bv<10);this.ie10under=(this.bv<11);this.ie7up=(this.ie7||this.ie8||this.ie9);this.ie8up=(this.ie8||this.ie9||this.ie10);this.ie9up=(this.ie9||this.ie10||this.ie11);this.ie10up=(this.ie10||this.ie11)}else this.bn='ot';if(agt.indexOf('windows')!==-1)this.p='win';else if(agt.indexOf('macintosh')!==-1)this.p='mac';else if(agt.indexOf('iphone')!==-1)this.p='ipn';else if(agt.indexOf('ipad')!==-1)this.p='ipd';else if(agt.indexOf('ipod')!==-1)this.p='ipt';else if(agt.indexOf('android')!==-1)this.p='ard';else if(agt.indexOf('linux')!==-1)this.p='linux';else this.p='other';this.ios=(this.p==='ipn'||this.p==='ipd'||this.p==='ipt');this.smf=(this.ios||this.p==='ard');this.osv=0;if(this.ios){this.osv=(agt.indexOf('os 6_')!==-1)?6:(agt.indexOf('os 5_')!==-1)?5:(agt.indexOf('os 4_')!==-1)?4:(agt.indexOf('os 3_')!==-1)?3:2;this.ios2=(this.osv===2);this.ios3=(this.osv===3);this.ios4=(this.osv===4);this.ios5=(this.osv===5);this.ios6=(this.osv===6);this.ios2under=(this.osv<3);this.ios3under=(this.osv<4);this.ios4under=(this.osv<5);this.ios5under=(this.osv<6);this.ios2up=(this.osv>1);this.ios3up=(this.osv>2);this.ios4up=(this.osv>3);this.ios5up=(this.osv>4);this.ios6up=(this.osv>5)}}var is=new browserCheck();var $=new Object;var gg=(function(){var _globalLock=0;var _size=new Object;var _oldsize=new Object;var _minareaWd=0;var _minareaHi=0;var timeID=null;function createHttpRequest(){if(window.ActiveXObject){try{return new ActiveXObject("Msxml2.XMLHTTP")}catch(e){try{return new ActiveXObject("Microsoft.XMLHTTP")}catch(e2){return null}}}else if(window.XMLHttpRequest){return new XMLHttpRequest()}else{return null}}function sendRequest(arg){var callback=(typeof arg.callback==='function')?arg.callback:'';var data=(arg.data||'');var method=(arg.method||'get').toUpperCase();var url=(arg.url||'');var async=(arg.async||true);if(callback===''||url==='')return null;var obj=createHttpRequest();if(obj===null){return null}var sload=(arg.sload||false);sload=(typeof sload==='boolean')?sload:false;if(sload){url+="?t="+(new Date()).getTime()}if(is.op||is.sf||is.fx){obj.onload=function(){callback(obj)}}else{obj.onreadystatechange=function(){if(obj.readyState===4){callback(obj)}}}if(method==='GET'){if(data!==''){var encdata='';var datas=data.split('&');for(i=0;i<datas.length;i++){var dataq=datas[i].split('=');encdata+='&'+encodeURIComponent(dataq[0])+'='+encodeURIComponent(dataq[1])}url=url+encdata}}obj.open(method,url,async);if(method==='POST'){if(is.op){if((typeof obj.setRequestHeader)==='function'){obj.setRequestHeader('Content-Type','application/x-www-form-urlencoded; charset=UTF-8')}}else{obj.setRequestHeader('Content-Type','application/x-www-form-urlencoded; charset=UTF-8')}}obj.send(data||null);return obj}function getElementsByClassName(cname){var elmc;var objtbl=document.getElementsByTagName('*');var objbuf=new Array();for(var i=0;i<objtbl.length;i++){elmc=objtbl[i].className.split(/\s+/);for(var j=0;j<elmc.length;j++){if(elmc[j]===cname){objbuf.push(objtbl[i]);break}}}return objbuf}function getStyleValue(selector,property,p){property=(property.match(/-/))?property.camelize():property;var stylesheets=document.styleSheets[p].rules||document.styleSheets[p].cssRules;var len=stylesheets.length;for(var i=0;i<len;i++){var css=stylesheets.item(i);var str=(new String(css.selectorText)).toLowerCase();if(str===selector.toLowerCase()){if(css.style[property]){return css.style[property]}}}return null}function getStyle(id){var e=document.getElementById(id);return e.currentStyle||document.defaultView.getComputedStyle(e,'')}function getInnerSize(){var _quirks=(document.compatMode||'')!=='CSS1Compat';var _ieroot=_quirks?'body':'documentElement';var root=document.uniqueID?document[_ieroot]:window;return{w:root.innerWidth||root.clientWidth,h:root.innerHeight||root.clientHeight,r:window.orientation||0}}function getClientSize(){var sz=new Object;var size=getInnerSize();var w=(size.w<_minareaWd)?_minareaWd:size.w;var h=(size.h<_minareaHi)?_minareaHi:size.h;sz=size;return sz}function getPageSize(){var x,y,w,h;if(window.innerHeight&&window.scrollMaxY){x=document.body.scrollWidth;y=window.innerHeight+window.scrollMaxY}else if(document.body.scrollHeight>document.body.offsetHeight){x=document.body.scrollWidth;y=document.body.scrollHeight}else{x=document.body.offsetWidth;y=document.body.offsetHeight}if(window.innerHeight){w=window.innerWidth;h=window.innerHeight}else if(document.documentElement&&document.documentElement.clientHeight){w=document.documentElement.clientWidth;h=document.documentElement.clientHeight}else if(document.body){w=document.body.clientWidth;h=document.body.clientHeight}var ph=(y<h)?h:y;var pw=(x<w)?w:x;return{w:pw,h:ph}}function chekcResizeEvent(func){function loop(){if(!_globalLock++){var newsize=getInnerSize();if(is.ios){var ws=Math.abs(_size.w-newsize.w);var hs=Math.abs(_size.h-newsize.h);var sz1=60;var sz2=110;if(_size.r!==newsize.r||ws===sz1||ws===sz2||hs===sz1||hs===sz2){if(_size.r===undefined)_size.r=newsize.r;if(_size.w===undefined)_size.w=ws;if(_size.h===undefined)_size.h=hs;_oldsize=_size;_size=newsize;func(_size,_oldsize)}}else{if(_size.w!==newsize.w||_size.h!==newsize.h){_oldsize=_size;var w=(newsize.w<_minareaWd)?_minareaWd:newsize.w;var h=(newsize.h<_minareaHi)?_minareaHi:newsize.h;if(!_oldsize.w)_oldsize.w=w;if(!_oldsize.h)_oldsize.h=h;_size=newsize;func(_size,_oldsize)}}setTimeout(function(){_globalLock=0},0)}setTimeout(loop,500)}timeID=setTimeout(loop,500)}function setIE6PNG(){var p=0;var c=0;var buffer=[];while(document.getElementsByTagName('img').item(p)!==null){var obj=document.getElementsByTagName('img').item(p);var classname=obj.getAttribute((is.ie7under)?'className':'class');var ary=obj.getAttribute('src').split('.');if(ary[ary.length-1]==='png'){var tmp=document.createElement('span');tmp.className=obj.className;tmp.style.display='inline-block';tmp.style.width=obj.width;tmp.style.height=obj.height;tmp.style.styleFloat=obj.align;tmp.style.cursor='pointer';tmp.style.filter='progid:DXImageTransform.Microsoft.AlphaImageLoader(src='+obj.src+',sizingMethod="scale")';buffer[c]=[];buffer[c][0]=obj;buffer[c][1]=tmp;c++}p++}for(c=0;c<buffer.length;c++){obj=buffer[c][0];tmp=buffer[c][1];obj.parentNode.replaceChild(tmp,obj)}}function capitalize(arg){return arg.replace(/-([a-z])/g,function(m,m1){return m1.toUpperCase()})}function getStyleType(id,csstype){if(!csstype||typeof id==='object'){return'0'}var obj=document.getElementById(id);var mt;if(obj.currentStyle){if(csstype.indexOf("-")!=-1)csstype=capitalize(csstype);mt=obj.currentStyle[csstype]}else if(getComputedStyle){mt=document.defaultView.getComputedStyle(obj,'').getPropertyValue(csstype)}if(mt.indexOf('px')!=-1)mt=mt.substr(0,mt.length-2);return mt}function geoCore(id){if(id===''){return}this.elm=(typeof id==='object')?id:document.getElementById(id);this.css=this.elm.style;this.x=this.elm.offsetLeft;this.y=this.elm.offsetTop;this.mgx=getStyleType(id,'margin-left');this.mgy=getStyleType(id,'margin-top');this.pdx=getStyleType(id,'padding-left');this.pdy=getStyleType(id,'padding-top');this.w=this.sw=this.elm.offsetWidth;this.h=this.sh=this.elm.offsetHeight;this.opacity=100;this.scroll=0;this.rad=0;this.r=0;if(document.body){this.scx=document.body.scrollLeft;this.scy=document.body.scrollTop}else{this.scx=document.documentElement.scrollLeft;this.scy=document.documentElement.scrollTop}this.id=(typeof id==='object')?'':id;this.pausefg=false;this.timerID=null;this.timers=[]}function geoGetScrollPosition(){return{xp:(document.documentElement.scrollLeft||document.body.scrollLeft),yp:(document.documentElement.scrollTop||document.body.scrollTop)}}function geoResizeEvent(func){var obj=this;this.resizeTimerID=setInterval(function(){if(obj.elm.offsetHeight!==obj.h||obj.elm.offsetWidth!==obj.w){obj.h=obj.elm.offsetHeight;obj.w=obj.elm.offsetWidth;if(typeof func==='function')func()}},100)}function geoMoveEvent(func){var obj=this;this.resizeTimerID=setInterval(function(){if(obj.elm.offsetLeft!==obj.x||obj.elm.offsetTop!==obj.y){obj.x=obj.elm.offsetLeft;obj.y=obj.elm.offsetTop;if(typeof func==='function')func()}},100)}function geoCoreCtrlIME(){var mode='';switch(sw){case 1:mode='active';case 2:mode='inactive';case 3:mode='disabled';default:mode='auto'}this.css.imeMode=mode}function geoCoreGetDimensions(){var display=getStyleValue('#'+this.id,'display',0);if(display!=='none'&&display!==null){return{width:this.elm.offsetWidth,height:this.elm.offsetHeight}}var orgVisibility=this.css.visibility;var orgPosition=this.css.position;var orgDisplay=this.css.display;this.css.visibility='hidden';this.css.position='absolute';this.css.display='block';var orgWidth=this.elm.clientWidth;var orgHeight=this.elm.clientHeight;this.css.display=orgDisplay;this.css.position=orgPosition;this.css.visibility=orgVisibility;return{width:orgWidth,height:orgHeight}}function geoMouseDownEvent(func){var obj=this.elm;if(document.addEventListener){if(is.smf){obj.addEventListener('touchstart',function(ev){mevent(ev,1,func)},false)}else{obj.addEventListener('mousedown',function(ev){mevent(ev,1,func)},false)}}else{obj.attachEvent('onmousedown',function(){mevent(event,1,func)})}}function geoMouseMoveEvent(func){var obj=this.elm;if(document.addEventListener){if(is.smf){obj.addEventListener('touchmove',function(ev){mevent(ev,2,func)},false)}else{obj.addEventListener('mousemove',function(ev){mevent(ev,2,func)},false)}}else{obj.attachEvent('onmousemove',function(){mevent(event,2,func)})}}function geoMouseUpEvent(func){var obj=this.elm;if(document.addEventListener){if(is.smf){obj.addEventListener('touchend',function(ev){mevent(ev,3,func)},false)}else{obj.addEventListener('mouseup',function(ev){mevent(ev,3,func)},false)}}else{obj.attachEvent('onmouseup',function(){mevent(event,3,func)})}}function geoMouseClickEvent(func){var obj=this.elm;if(document.addEventListener){if(!is.smf){obj.addEventListener('click',function(ev){mevent(ev,4,func)},false)}}else{obj.attachEvent('onclick',function(){mevent(event,4,func)})}}function geoMouseOverEvent(func){var obj=this.elm;if(document.addEventListener){if(!is.smf){obj.addEventListener('mouseover',function(ev){mevent(ev,5,func)},false)}}else{obj.attachEvent('onmouseover',function(){mevent(event,5,func)})}}function geoMouseOutEvent(func){var obj=this.elm;if(document.addEventListener){if(!is.smf){obj.addEventListener('mouseout',function(ev){mevent(ev,6,func)},false)}}else{obj.attachEvent('onmouseout',function(){mevent(event,6,func)})}}function geoMouseWheelEvent(func){var obj=this.elm;if(document.addEventListener){if(!is.smf){if(is.sf||is.op)obj.onmousewheel=function(ev){mevent(ev,9,func)};else obj.addEventListener('DOMMouseScroll',function(ev){mevent(ev,9,func)},false)}}else{obj.attachEvent('onmousewheel',function(){mevent(event,9,func)})}}function geoMouseDoubleClick(func){var obj=this.elm;if(document.addEventListener){if(!is.smf){obj.addEventListener('dblclick',function(ev){mevent(ev,10,func)},false)}}else{obj.attachEvent("ondblclick",function(){mevent(event,10,func)})}}function mevent(ev,mode,func){var mx,my;if(is.ie){ev=event;if(mode<9){ev.mx=ev.clientX-2;ev.my=ev.clientY-2;ev.omx=ev.offsetX;ev.omy=ev.offsetY;ev.tg=ev.srcElement;ev.btn=ev.button}else if(mode===9){ev.delta=ev.wheelDelta/120}ev.mode=mode;if(func(ev)&&mode!==3){ev.cancelBubble=true;ev.returnValue=false}}else if(is.smf){ev.touche=ev.changedTouches;var evt=ev.touche[0];ev.btn=1;ev.mx=evt.pageX;ev.my=evt.pageY;ev.tg=evt.target;ev.mode=mode;if(func(ev)&&mode===1){ev.stopPropagation();ev.preventDefault()}}else{if(mode<9){ev.mx=ev.pageX;ev.my=ev.pageY;ev.tg=ev.target;ev.btn=ev.which;if(ev.offsetX!==undefined){ev.omx=ev.offsetX;ev.omy=ev.offsetY}else{ev.omx=ev.layerX;ev.omy=ev.layerY}}else if(mode===9){if(ev.wheelDelta){var j=0;if(is.p==='mac'&&is.cr)j=3;else if(is.sf)j=120;else j=40;ev.delta=ev.wheelDelta/j}else if(ev.detail){ev.delta=-ev.detail}}ev.mode=mode;if(func(ev)&&(mode===1||mode===9)){ev.stopPropagation();ev.preventDefault()}}}function geoCoreDisplay(fg){this.css.display=(fg)?'block':'none'}function geoCoreGetDisplay(){return(this.css.display!=='none')}function geoCoreShow(){this.css.visibility='visible'}function geoCoreHide(){this.css.visibility='hidden'}function geoCoreGetVisibility(){return(this.css.visibility==='visible')}function geoNodeOffset(){var e=this.elm;var tp=0,lt=0;do{var obj=$[e.id];if(obj){lt+=obj.x;tp+=obj.y}else{lt+=e.offsetLeft||0;tp+=e.offsetTop||0}e=e.offsetParent}while(e);lt=Math.round(lt);tp=Math.round(tp);return{x:lt,y:tp}}function geoCoreTransTo(x,y){if(x!==null&&!isNaN(x)){this.x=x;if(is.sf){if(is.ios){this.css.webkitTransform='translate3d('+x+'px,'+this.y+'px, 0)'}else this.css.webkitTransform='translate('+x+'px,'+this.y+'px)'}else if(is.fx){this.css.MozTransform='translate('+x+'px,'+this.y+'px)'}else if(is.op){this.css.OTransform='translate('+x+'px,'+this.y+'px)'}else(is.ie)?this.css.pixelLeft=x:this.css.left=x+'px'}if(y!==null&&!isNaN(y)){this.y=y;if(is.sf){if(is.ios)this.css.webkitTransform='translate3d('+this.x+'px, '+y+'px, 0)';else this.css.webkitTransform='translate('+this.x+'px, '+y+'px)'}else if(is.fx){this.css.MozTransform='translate('+this.x+'px, '+y+'px)'}else if(is.op){this.css.OTransform='translate('+this.x+'px, '+y+'px)'}else(is.ie)?this.css.pixelTop=y:this.css.top=y+'px'}}function geoCoreMoveTo(x,y){if(x!==null&&!isNaN(x)){this.x=x;(is.ie)?this.css.pixelLeft=x:this.css.left=x+'px'}if(y!==null&&!isNaN(y)){this.y=y;(is.ie)?this.css.pixelTop=y:this.css.top=y+'px'}}function geoCoreMoveToAlign(x,y){if(x!==null&&!isNaN(x)){this.mgx=x;this.css.marginLeft=x+'px'}if(y!==null&&!isNaN(y)){this.mgy=y;this.css.marginTop=y+'px'}}function geoCoreMoveToPadding(x,y){if(x!==null&&!isNaN(x)){this.pdx=x;this.css.paddingLeft=x+'px'}if(y!==null&&!isNaN(y)){this.pdy=y;this.css.paddingTop=y+'px'}}function geoCorePositionReset(x,y){this.x=this.elm.offsetLeft;this.y=this.elm.offsetTop}function geoCoreSizeReset(w,h){this.w=this.elm.clientWidth;this.h=this.elm.clientHeight}function geoCoreMoveBy(x,y){var dx=this.x;var dy=this.y;if(x!==null&&!isNaN(x))dx+=x;if(y!==null&&!isNaN(y))dy+=y;this.moveTo(dx,dy)}function geoCoreResizeTo(w,h){if(w!==null&&w!==undefined){w=(w<0)?0:w;this.css.width=w+'px';this.w=w}if(h!==null&&h!==undefined){h=(h<0)?0:h;this.css.height=h+'px';this.h=h}}function geoCoreScrollCts(x,y){if(x!==null&&x!==undefined){x=(x<0)?0:x;this.elm.scrollTo(x,this.scy);this.scx=(document.documentElement.scrollLeft||document.body.scrollLeft)}if(y!==null&&y!==undefined){y=(y<0)?0:y;this.elm.scrollTo(this.scx,y);this.scy=(document.documentElement.scrollTop||document.body.scrollTop)}}function geoCoreClipInit(tp,rt,bt,lt){this.clipTo(tp,rt,bt,lt)}function geoCoreClipTo(tp,rt,bt,lt){if(tp===null)tp=this.clipValues('tp');if(rt===null)rt=this.clipValues('rt');if(bt===null)bt=this.clipValues('bt');if(lt===null)lt=this.clipValues('lt');this.css.clip='rect('+tp+'px '+rt+'px '+bt+'px '+lt+'px)'}function geoCoreClipValues(which){var clipv=this.css.clip.split('rect(')[1].split(')')[0];if(is.ie){clipv=clipv.split('px')}else{clipv=clipv.split(',');clipv[0]=clipv[0].split('px')[0];clipv[1]=clipv[1].split('px')[0];clipv[2]=clipv[2].split('px')[0];clipv[3]=clipv[3].split('px')[0]}if(which==='tp')return parseInt(clipv[0]);if(which==='rt')return parseInt(clipv[1]);if(which==='bt')return parseInt(clipv[2]);if(which==='lt')return parseInt(clipv[3])}function geoCoreBackgroundImage(imgpath,pos,rep){if(imgpath==='none'){this.css.backgroundImage='none'}else{this.css.backgroundImage='url("'+imgpath+'")';this.css.backgroundRepeat=pos;this.css.backgroundPosition=rep}}function geoCoreAlphaSet(a){if(is.ie){this.css.filter="progid:DXImageTransform.Microsoft.Alpha(Style=0,Opacity="+a+",FinishOpacity=100)";this.opacity=a}else{a*=0.01;if(is.sf){this.css.opacity=a}else if(is.ns||is.fx){this.css.MozOpacity=a}else if(is.op){this.css.opacity=a}}this.opacity=this.getAlpha()}function geoCoreGetAlpha(){var a=null;if(is.ie){a=this.opacity}else if(is.sf){a=this.css.opacity*100}else if(is.ns||is.fx){a=this.css.MozOpacity*100}else if(is.op){a=this.css.opacity*100}return a}function geoColreSetInterval(rules,easing,duration,func){var fg=(arguments.length>4)?arguments[4]:false;if(this.timerID!==null){clearInterval(this.timerID);this.timerID=null;this.timers.length=0}var self=this;this.startTime=(new Date).getTime();this.duration=duration;this.pauseTime=0;this.pousefg=false;this.funcs=func;this.easing=easing;this.timers=[];var p=0;for(prop in rules){self.timers[p++]={mode:prop,start:this[prop],end:rules[prop],func:function(self,mode,val){if(mode==='x'){(fg)?self.transTo(val,null):self.moveTo(val,null)}else if(mode==='y'){(fg)?self.transTo(null,val):self.moveTo(null,val)}else if(mode==='w'){self.resizeTo(val,null)}else if(mode==='h'){self.resizeTo(null,val)}else if(mode==='r'){self.drawTransform(val)}else if(mode==='opacity'){self.setAlpha(val)}else if(mode==='mgx'){self.moveToAg(val,null)}else if(mode==='mgy'){self.moveToAg(null,val)}else if(mode==='pdx'){self.moveToPd(val,null)}else if(mode==='pdy'){self.moveToPd(null,val)}else if(mode==='scx'){self.scrollCts(val,null)}else if(mode==='scy'){self.scrollCts(null,val)}}}}var easfunc={linear:function(state,n,b,c,duration){return b+c*state},swing:function(state,n,b,c,duration){return((-Math.cos(state*Math.PI)/2)+0.5)*c+b},easeInQuad:function(state,n,b,c,duration){return c*(n/=duration)*n+b},easeOutQuad:function(state,n,b,c,duration){return-c*(n/=duration)*(n-2)+b},easeInOutQuad:function(state,n,b,c,duration){if((n/=duration/2)<1)return c/2*n*n+b;return-c/2*((--n)*(n-2)-1)+b},easeInCubic:function(state,n,b,c,duration){return c*(n/=duration)*n*n+b},easeOutCubic:function(state,n,b,c,duration){return c*((n=n/duration-1)*n*n+1)+b},easeInOutCubic:function(state,n,b,c,duration){if((n/=duration/2)<1)return c/2*n*n*n+b;return c/2*((n-=2)*n*n+2)+b},easeInQuart:function(state,n,b,c,duration){return c*(n/=duration)*n*n*n+b},easeOutQuart:function(state,n,b,c,duration){return-c*((n=n/duration-1)*n*n*n-1)+b},easeInOutQuart:function(state,n,b,c,duration){if((n/=duration/2)<1)return c/2*n*n*n*n+b;return-c/2*((n-=2)*n*n*n-2)+b},easeInBack:function(state,n,b,c,duration){var s=1.70158;return c*(n/=duration)*n*((s+1)*n-s)+b},easeOutBack:function(state,n,b,c,duration){var s=1.70158;return c*((n=n/duration-1)*n*((s+1)*n+s)+1)+b},easeInOutBack:function(state,n,b,c,duration){var s=1.70158;if((n/=duration/2)<1){var pos=c/2*(n*n*(((s*=(1.525))+1)*n-s))+b}else{var pos=c/2*((n-=2)*n*(((s*=(1.525))+1)*n+s)+2)+b}return pos},easeInBounce:function(state,n,b,c,duration){return c-easfunc.easeOutBounce(state,duration-n,0,c,duration)+b},easeOutBounce:function(state,n,b,c,duration){var pos=0;var s=7.5625;if((n/=duration)<(1/2.75)){pos=1*(s*n*n)+0}else if(n<(2/2.75)){pos=c*(s*(n-=(1.5/2.75))*n+.75)+b}else if(n<(2.5/2.75)){pos=c*(s*(n-=(2.25/2.75))*n+.9375)+b}else{pos=c*(s*(n-=(2.625/2.75))*n+.984375)+b}return pos},easeInOutBounce:function(state,n,b,c,duration){if(n<duration/2){return easfunc.easeInBounce(state,n*2,0,c,duration)*.5+b}else{return easfunc.easeOutBounce(state,n*2-duration,0,c,duration)*.5+c*.5+b}},easeInSine:function(state,n,b,c,duration){return-c*Math.cos(n/duration*(Math.PI/2))+c+b},easeOutSine:function(state,n,b,c,duration){return c*Math.sin(n/duration*(Math.PI/2))+b},easeInOutSine:function(state,n,b,c,duration){return-c/2*(Math.cos(Math.PI*t/duration)-1)+b},easeInExpo:function(state,n,b,c,duration){return(n==0)?b:c*Math.pow(2,10*(n/duration-1))+b},easeOutExpo:function(state,n,b,c,duration){return(n==duration)?b+c:c*(-Math.pow(2,-10*n/duration)+1)+b},easeInOutExpo:function(state,n,b,c,duration){if(n==0)return b;if(n==duration)return b+c;if((n/=duration/2)<1)return c/2*Math.pow(2,10*(n-1))+b;return c/2*(-Math.pow(2,-10*--n)+2)+b},easeInCirc:function(state,n,b,c,duration){return-c*(Math.sqrt(1-(n/=duration)*n)-1)+b},easeOutCirc:function(state,n,b,c,duration){return c*Math.sqrt(1-(n=n/duration-1)*n)+b},easeInOutCirc:function(state,n,b,c,duration){if((n/=duration/2)<1)return-c/2*(Math.sqrt(1-n*n)-1)+b;return c/2*(Math.sqrt(1-(n-=2)*n)+1)+b},easeInElastic:function(state,n,b,c,duration){var s=1.70158,p=0,a=c;if(n===0)return b;if((n/=duration)===1)return b+c;if(!p)p=duration*.3;if(a<Math.abs(c)){a=c;s=p/4}else{s=p/(2*Math.PI)*Math.asin(c/a)}return-(a*Math.pow(2,10*(n-=1))*Math.sin((n*duration-s)*(2*Math.PI)/p))+b},easeOutElastic:function(state,n,b,c,duration){var s=1.70158,p=0,a=c;if(n===0)return b;if((n/=duration)===1)return b+c;if(!p)p=duration*.3;if(a<Math.abs(c)){a=c;s=p/4}else{s=p/(2*Math.PI)*Math.asin(c/a)}return a*Math.pow(2,-10*n)*Math.sin((n*duration-s)*(2*Math.PI)/p)+c+b},easeInOutElastic:function(state,n,b,c,duration){var s=1.70158,p=0,a=c;if(n===0)return b;if((n/=duration/2)===2)return b+c;if(!p)p=duration*(.3*1.5);if(a<Math.abs(c)){a=c;s=p/4}else{s=p/(2*Math.PI)*Math.asin(c/a)}if(n<1)return-.5*(a*Math.pow(2,10*(n-=1))*Math.sin((n*duration-s)*(2*Math.PI)/p))+b;return a*Math.pow(2,-10*(n-=1))*Math.sin((n*duration-s)*(2*Math.PI)/p)*.5+c+b},easeInQuint:function(state,n,b,c,duration){return c*(n/=duration)*n*n*n*n+b},easeOutQuint:function(state,n,b,c,duration){return c*((n=n/duration-1)*n*n*n*n+1)+b},easeInOutQuint:function(state,n,b,c,duration){if((n/=duration/2)<1)return c/2*n*n*n*n*n+b;return c/2*((n-=2)*n*n*n*n+2)+b}};this.timerID=setInterval(function(){if(self.pausefg)return;var now,err=0;for(var i=0;i<self.timers.length;i++){var t=(new Date).getTime()-self.pauseTime;var tm=self.timers[i];if(t>=self.duration+self.startTime){now=tm.end;err=tm.func(self,tm.mode,now);if(self.timers.length-1===i)self.timers.length=0}else{var n=t-self.startTime;var state=n/self.duration;var pos=easfunc[self.easing](state,n,0,1,self.duration);now=tm.start+((tm.end-tm.start)*pos);err=tm.func(self,tm.mode,now);if(err<0){self.timers.length=0;break}}if(!err)self.funcs(tm.mode,now)}if(!self.timers.length){clearInterval(self.timerID);self.timerID=null;self.funcs()}},13)}function geoStopEasing(){if(this.timers.length)this.timers.length=0}function geoPauseEasing(){if(this.timers.length){if(arguments.length&&typeof arguments[0]==='boolean'){var fg=arguments[0];if(fg&&!this.pausefg){this.start=(new Date).getTime()}else if(!fg&&this.pausefg){this.pauseTime+=(new Date).getTime()-this.start}}else{if(this.pausefg){this.pauseTime+=(new Date).getTime()-this.start;this.pausefg=false}else{this.start=(new Date).getTime();this.pausefg=true}}}}function geoCoreMoveCenter(x,y){this.cx=x;this.cy=y;x-=this.w/2;y-=this.h/2;this.moveTo(x,y);return{'x':x,'y':y}}function geoCoreMoveCenterPos(x,y){x-=this.w/2;y-=this.h/2;return{'x':x,'y':y}}function geoVML(tag){document.createStyleSheet().addRule(".rvml","behavior:url(#default#VML)");try{!document.namespaces.rvml&&document.namespaces.add("rvml","urn:schemas-microsoft-com:vml");return function(tag){return document.createElement('<rvml:'+tag+' class="rvml">')}}catch(e){return function(tag){return document.createElement('<'+tag+' xmlns="urn:schemas-microsoft.com:vml" class="rvml">')}}}function geoDrawTransform(rad){var r=rad%360;if(is.ie){this.css.filter="progid:DXImageTransform.Microsoft.Matrix(sizingMethod='auto expand')";var deg=(r>=0)?r:360-Math.abs(r);var rd=deg*Math.PI/180;var sin=Math.sin(rd);var cos=Math.cos(rd);var w=this.w;var h=this.h;var matrices=this.elm.filters.item(0);var dr=90;var sr=(r>=0)?r:360-Math.abs(r);if(sr<dr)dr=deg%dr;else if(sr<180)dr=dr-(deg%dr);else if(sr<270)dr=deg%dr;else if(sr<360)dr=dr-(deg%dr);rd=dr*Math.PI/180;var dsin=Math.sin(rd);var dcos=Math.cos(rd);var lt=(w-(dsin*h)-(dcos*w))/2;var tp=(h-(dsin*w)-(dcos*h))/2;this.css.marginLeft=lt+"px";this.css.marginTop=tp+"px";matrices.M11=cos;matrices.M12=-sin;matrices.M21=sin;matrices.M22=cos}else if(is.fx){this.css.MozTransform='rotate('+r+'deg)'}else if(is.sf){this.css.webkitTransform='rotate('+r+'deg)'}else if(is.op){this.css.OTransform='rotate('+r+'deg)'}this.rad=r;this.r=rad}function geoEasingState(){return(this.timerID!==null)}function geoScrollSet(ev,callfunc){var p={xp:0,yp:0};if(is.ie){p=this.scrollPosition()}else{p.xp=this.elm.scrollX;p.yp=this.elm.scrollY}this.scx=p.xp;this.scy=p.yp;callfunc(ev,this)}function geoScrollEvent(callfunc){var self=this;if(document.addEventListener)this.elm.addEventListener('scroll',function(ev){self.scrollSet(ev,callfunc)},false);else this.elm.attachEvent('onscroll',function(){self.scrollSet(event,callfunc)})}geoCore.prototype.getSize=geoCoreGetDimensions;geoCore.prototype.ctrlIME=geoCoreCtrlIME;geoCore.prototype.transTo=geoCoreTransTo;geoCore.prototype.moveTo=geoCoreMoveTo;geoCore.prototype.moveBy=geoCoreMoveBy;geoCore.prototype.getOff=geoNodeOffset;geoCore.prototype.moveToAg=geoCoreMoveToAlign;geoCore.prototype.moveToPd=geoCoreMoveToPadding;geoCore.prototype.Display=geoCoreDisplay;geoCore.prototype.getDisplay=geoCoreGetDisplay;geoCore.prototype.Show=geoCoreShow;geoCore.prototype.Hide=geoCoreHide;geoCore.prototype.getVisibility=geoCoreGetVisibility;geoCore.prototype.resizeTo=geoCoreResizeTo;geoCore.prototype.clipInit=geoCoreClipInit;geoCore.prototype.clipTo=geoCoreClipTo;geoCore.prototype.clipValues=geoCoreClipValues;geoCore.prototype.backImg=geoCoreBackgroundImage;geoCore.prototype.setAlpha=geoCoreAlphaSet;geoCore.prototype.getAlpha=geoCoreGetAlpha;geoCore.prototype.timerTo=geoColreSetInterval;geoCore.prototype.stopEasing=geoStopEasing;geoCore.prototype.pauseEasing=geoPauseEasing;geoCore.prototype.easingState=geoEasingState;geoCore.prototype.positionReset=geoCorePositionReset;geoCore.prototype.sizeReset=geoCoreSizeReset;geoCore.prototype.resizeEvent=geoResizeEvent;geoCore.prototype.moveEvent=geoMoveEvent;geoCore.prototype.drawTransform=geoDrawTransform;geoCore.prototype.moveToCenter=geoCoreMoveCenter;geoCore.prototype.getCorner=geoCoreMoveCenterPos;geoCore.prototype.createVMLNode=geoVML;geoCore.prototype.scrollCts=geoCoreScrollCts;geoCore.prototype.scrollEvent=geoScrollEvent;geoCore.prototype.mouseDown=geoMouseDownEvent;geoCore.prototype.mouseMove=geoMouseMoveEvent;geoCore.prototype.mouseUp=geoMouseUpEvent;geoCore.prototype.mouseClick=geoMouseClickEvent;geoCore.prototype.mouseOver=geoMouseOverEvent;geoCore.prototype.mouseOut=geoMouseOutEvent;geoCore.prototype.mouseWheel=geoMouseWheelEvent;geoCore.prototype.mouseDoubleClick=geoMouseDoubleClick;geoCore.prototype.scrollPosition=geoGetScrollPosition;geoCore.prototype.scrollSet=geoScrollSet;var funcBuffer=[];return{resize:function(func){funcBuffer.push(func);if(timeID===null){chekcResizeEvent(function(sz,sz2){for(var i=0;i<funcBuffer.length;i++)funcBuffer[i](sz,sz2)})}},getBeforeSize:function(){return _oldsize},getInner:function(){return getInnerSize()},clientSize:function(){return getClientSize()},getPage:function(){return getPageSize()},ajax:function(arg){return sendRequest(arg)},firstNode:function(e){while(e.nodeType===3){e=e.nextSibling}return e},$:function(selector){var objstr=(typeof selector).toLowerCase();if(!selector){return $['window']=new geoCore(window)}if(objstr==='string'){if(selector==='document')obj=document;else if(selector==='window')obj=window;else if(selector==='body')obj=document.body;else{if(document.getElementById(selector))obj=selector;else return undefined}return $[selector]=new geoCore(obj)}else if(objstr==='object'){return selector}},setMinimamClientSize:function(w,h){_minareaWd=w;_minareaHi=h},ready:function(func){var dc=(arguments.length>1&&arguments[1]==='object')?arguments[1]:document;if(document.addEventListener){dc.addEventListener('DOMContentLoaded',function(){func()},false)}else{var done=false;var init=function(){if(!done){done=true;func()}};(function(){try{dc.documentElement.doScroll('left')}catch(error){setTimeout(arguments.callee,10);return}init()})();dc.onready=function(){if(dc.readyState=='complete'){dc.onready=null;init()}}}},compt:function(func){if(window.addEventListener){window.addEventListener('load',function(ev){func(ev)},false)}else{if(typeof(window.attachEvent)==='object'){window.attachEvent('onload',function(){func()})}else{var oldfunc=dc.onload;if(typeof(dc.onload)!=='function'){dc.onload=function(){func()}}else{dc.onload=function(){oldfunc();(new Function(func))()}}}}}}})(window);
