﻿window.onerror=function(){return true};SWFObject=function($){this.cfg=$;this.swfId=$.fid;this.asObjects={};this.onLoadInit=null;SWFObject.instances[this.swfId]=this};SWFObject.prototype.load=function(){Utils.f(this.cfg)};SWFObject.prototype.getASObject=function($){return this.asObjects[$.asoId]};SWFObject.prototype.registerASObject=function(A){var _=A.asoId,$=this.swfId;return this.asObjects[_]=new ASObject({asoId:_,swfId:$})};SWFObject.prototype.getASObjectProperty=function($){if(this.swf==null)this.swf=Utils.g(this.swfId);return this.swf.getASObjectProperty($)};SWFObject.prototype.setASObjectProperty=function($){if(this.swf==null)this.swf=Utils.g(this.swfId);this.swf.setASObjectProperty($)};SWFObject.prototype.callASObjectMethod=function($){if(this.swf==null)this.swf=Utils.g(this.swfId);return this.swf.callASObjectMethod($)};SWFObject.instances={};SWFObject.getSWFObject=function($){return SWFObject.instances[$.swfId]};SWFObject.dispatchASObjectEvent=function(B){var _=B.swfId,A=B.asoId,F=B.type,E=B.data,C=SWFObject.getSWFObject({swfId:_}),$=(A==undefined)?C:C.getASObject({asoId:A}),D="on"+F.substr(0,1).toUpperCase()+F.substr(1);if($[D]!=null)$[D](E)};SWFObject.registerASObject=function(A){var $=A.swfId,_=A.asoId,B=SWFObject.getSWFObject(A);B.registerASObject(A)};ASObject=function($){this.swfId=$.swfId;this.asoId=$.asoId;this.swfObject=SWFObject.getSWFObject($);if(ASObject.instances[this.swfId]==null)ASObject.instances[this.swfId]={};ASObject.instances[this.swfId][this.asoId]=this};ASObject.prototype.get=function($){return this.swfObject.getASObjectProperty({asoId:this.asoId,property:$})};ASObject.prototype.set=function(_,$){this.swfObject.setASObjectProperty({asoId:this.asoId,property:_,value:$})};ASObject.prototype.call=function($,_){return this.swfObject.callASObjectMethod({asoId:this.asoId,method:$,parameters:_})};ASObject.instances={};Utils={g:function($){return document.getElementById($)},f:function(_){var $='<embed id="#{fid}" name="#{fid}" src="#{movie}" flashVars="#{flashVars}" width="#{width}" height="#{height}" align="#{align}" type="application/x-shockwave-flash" pluginspage="http://www.adobe.com/go/getflashplayer" wmode="#{wmode}" scale="#{scale}" salign="#{salign}" allownetworking="#{allownetworking}" allowscriptaccess="#{allowscriptaccess}" />',A='<object id="#{fid}" classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" width="#{width}" height="#{height}" align="#{align}"><param name="movie" value="#{movie}" /><param name="flashVars" value="#{flashVars}" /><param name="wmode" value="#{wmode}" /><param name="scale" value="#{scale}" /><param name="salign" value="#{salign}" /><param name="allownetworking" value="#{allownetworking}" /><param name="allowscriptaccess" value="#{allowscriptaccess}" /></object>';this.g(_.cid).innerHTML=this.fm(this.b.isIE?A:$,_)},fm:function($,_){if(arguments.length)if(typeof(_)=="object")$=$.replace(/#\{([^\{\}]+)\}/g,function(A,B){var $=_[B];if(typeof $=="function")$=$(B);return typeof($)=="undefined"?"":$});else if(typeof(_)!="undefined")for(var A=arguments.length-2;A>-1;A--)$=$.replace(new RegExp("#\\{"+A+"\\}","g"),arguments[A+1]);return $},b:{isIE:/msie/i.test(navigator.userAgent),isFF:/firefox/i.test(navigator.userAgent),isMaxthon:(function(){var $=false;try{$=external.max_version}catch(_){}return $})()},mo:function(){var $={},B=arguments.length;for(var C=0;C<B;C++){var A=arguments[C];for(var _ in A){if($[_]!=null)continue;$[_]=arguments[C][_]}}return $}};HWR={loaded:false};HWR.load=function(E,C,D){HWR.tid=C;var $=D?("serviceUrl="+D):"",B={cid:E,fid:E+"_flash",width:410,height:290,movie:"http://123.baidu.com/swf/main.swf?v=1.1",align:"middle",salign:"lt",wmode:"window",scale:"noscale",allowscriptaccess:"always",allownetworking:"all",flashVars:$},A=new SWFObject(B);HWR.so=A;var _;A.onLoadInit=function($){HWR.ao=_=A.asObjects.handWrite;_.onCloseClick=function($){HWR._onCloseClick()};_.onCharSelect=function($){HWR._onCharSelect($["char"])}};A.load()};HWR._onCharSelect=function(A){var $=document.getElementById(HWR.tid);$.value+=A;var _=document.f.kw.value;document.f.kw.focus();document.f.kw.value=_};HWR._onCloseClick=function(){if(HWR.onCloseClick)HWR.onCloseClick()};HWR.onCloseClick=null;HWR.clear=function(){HWR.ao.call("clear",[])};function getFlashVersion(){var B=navigator;if(B.plugins&&B.mimeTypes.length){var A=B.plugins["Shockwave Flash"];if(A&&A.description)return A.description.replace(/([a-zA-Z]|\s)+/,"").replace(/(\s)+r/,".")+".0"}else if(window.ActiveXObject&&!window.opera)for(var C=10;C>=2;C--){try{var _=new ActiveXObject("ShockwaveFlash.ShockwaveFlash."+C);if(_){return C+".0.0";break}}catch($){}}return"0"}function addStyle(A,$){var _=document.styleSheets[0];if(_.addRule)_.addRule(A,$);else if(_.insertRule)_.insertRule(A+" { "+$+" }",_.cssRules.length)}function penControl(){var $=parseInt(getFlashVersion());if($<9)addStyle("#penControl","display:none")}function stopClosePen($){$=$||window.event;if($.stopPropagation)$.stopPropagation();else $.cancelBubble=true}var enablePen=false;function openPen($){if(!enablePen){var B=document.getElementById(HWR.so.cfg.cid);B.className="hwr_visible";enablePen=true;var _=window["__log__"+(new Date()).getTime()]=new Image();_.src="http://123.baidu.com/a.gif?t="+(new Date()).getTime()}$=$||event;var A=$.target||$.srcElement;A.blur();stopClosePen($)}HWR.onCloseClick=function(){HWR.clear();var _=document.getElementById(HWR.so.cfg.cid);_.className="hwr_hidden";var $=document.bdfm.q1.value;document.bdfm.q1.focus();document.bdfm.q1.value=$;enablePen=false};function closePen($){var B=document.getElementById(HWR.so.cfg.cid);$=$||event;var A=$.target||$.srcElement;if(enablePen){HWR.clear();B.className="hwr_hidden";if(A.nodeName!="INPUT"){var _=document.bdfm.q1.value;document.bdfm.q1.focus();document.bdfm.q1.value=_}enablePen=false}}
