
(function(win,J,undefined){if(win[J]===undefined)win[J]={};J=win[J];J.version="1.1.0";(function(){var initializing=false,fnTest=/xyz/.test(function(){xyz;})?/\b_super\b/:/.*/;function Class(){}
Class.extend=function(prop){var _super=this.prototype;initializing=true;var prototype=new this();initializing=false;for(var name in prop){prototype[name]=typeof prop[name]=="function"&&typeof _super[name]=="function"&&fnTest.test(prop[name])?(function(name,fn){return function(){var tmp=this._super;this._super=_super[name];var ret=fn.apply(this,arguments);this._super=tmp;return ret;};})(name,prop[name]):prop[name];}
function Klass(){if(!initializing&&this.init)
this.init.apply(this,arguments);}
Klass.prototype=prototype;Klass.constructor=Class;Klass.extend=arguments.callee;return Klass;};J.Class=Class;})();})(window,"J16");
J16.io=window.J16.io||{};J16.io.proxyUrl="http://api.1616.net/proxy.htm";J16.io.set=function(url,data,fn,callbackName){var CALLBACK={};window.addEventListener?window.addEventListener('message',callback,false):window.attachEvent('onmessage',callback);function callback(e){e=e.data||e;e=e.split('$$$');CALLBACK[e[1]](e[0]);destroyProxy(e[1]);};function destroyProxy(id){var div=document.getElementById(id),ifr=div.firstChild;div.innerHTML='';div.parentNode.removeChild(div);delete CALLBACK[id];};function createProxy(src,id){var div=document.createElement('DIV');div.style.display='none';div.id=id;div.innerHTML='<iframe src="'+src+'"></iframe>';document.body.appendChild(div);return div.firstChild;}
function post(func,params,fn){var RID='$'+(+new Date),ifr=createProxy(J16.io.proxyUrl,RID);CALLBACK[RID]=fn||new Function;params=params.concat(RID).concat(func).join('$$$');ifr.addEventListener?ifr.onload=loaded:ifr.attachEvent('onload',loaded);ifr.contentWindow.postMessage||(ifr.contentWindow.opener={data:params,callback:CALLBACK[RID]});function loaded(){ifr.contentWindow.postMessage&&ifr.contentWindow.postMessage(params,'*');}}
(data.replace(/[^\x00-\xff]/g,"xx").length>1350)?post('__send',[url,data],fn):J16.io.get(url+(/\?/.test(url)?'&':'?')+data,fn,callbackName,false);};J16.io.get=function(url,fnback,callbackName,isSimple){var
s,c,fn='jsonp'+(+new Date())+(this.jsonpid=++this.jsonpid||0),d=document,cbk=callbackName||'callback',src=(url.indexOf("?")==-1?url+(isSimple?"":"?"):url)+(isSimple?'':'&'+cbk+'='+fn),h=d.getElementsByTagName("head")[0];(s=d.createElement("script")).setAttribute("type","text/javascript");s.src=src;h.insertBefore(s,h.firstChild);window[fn]=function(){fnback&&fnback.apply(null,arguments);c=1};function done(){s.parentNode.removeChild(s);c||fnback&&fnback()}
s.onload=s.onreadystatechange=function(){s.readyState?s.readyState.toLowerCase()=='loaded'&&(s.onreadystatechange=null,done()):done()};};
J16.util=window.J16.util||{console:function(type,message){if(window.console)
window.console[type](message);},getType:function(o){var s=Object.prototype.toString,t={'undefined':'undefined','number':'number','boolean':'boolean','string':'string',"[object Function]":"function","[object RegExp]":"regexp","[object Array]":"array","[object Date]":"date","[object Error]":"error"};return t[typeof o]||t[s.call(o)]||(o?'object':'null');},getDomain:function(){return"."+location.host.split(".").slice(-2).join(".");},setHome:function(o,r){o.target="_self";var a="url(#default#homepage)",b="http://bbs.1616.net/thread-1913-1-4.html";try{if(document.all&&!external.max_version){o.style.behavior=a;o.setHomePage(r?r:"http://www"+this.getDomain());}else window.open(b);}catch(e){if(document.all){o.style.behavior=a;o.setHomePage(r?r:"http://www"+this.getDomain());}else window.open(b);}
return false;},getQueryString:function(name){var reg=new RegExp("[?&]"+name+"=([^&]*)");var r=location.search.match(reg);return r?r[1]:"";},hitTest:function(elem1,elem2){var pos1=elem1.getBoundingClientRect(),pos2=elem2.getBoundingClientRect(),x1=pos1.left,y1=pos1.top,x2=pos2.left,y2=pos2.top,w1=elem1.offsetWidth,h1=elem1.offsetHeight,w2=elem2.offsetWidth,h2=elem2.offsetHeight;return(x1<x2?x1+w1>x2:x1<x2+w2)&&(y1<y2?y1+h1>y2:y1<y2+h2);},mt:(function(){function parse(s){var a=[];var re_t=/\{\$((?:[^\\}]|\\[\s\S])+)\}/;var re_s=/\\([\s\S])/g;var esc=function(s){return s.replace(re_s,'$1');};var re_c=/(?:^|[^\\])(?:\\\\)*$/;var t,m,n;while(t=re_t.exec(s)){n=(m=t.index)+t[0].length;if(re_c.test(s.substr(0,m))){a.push(esc(s.substr(0,m)));a.push([esc(t[1])]);}
else a.push(esc(s.substr(0,n)));s=s.substr(n);}
return a;}
function show(s,o){var a=parse(s);for(var i=0;i<a.length;i++)
if(typeof a[i]=='object')
a[i]=o[a[i]]||'';return a.join('');}
function show2(s,o){return s.replace(/\{\$([^}]+)\}/g,function(a,b){return o[b]||'';});}
return function(template,data,adv){var f=adv?show:show2;if(!(data instanceof Array))
return f(template,data);var s='';for(var i=0;i<data.length;i++)
s+=f(templet,data[i]);return s;};})(),guid:(function(){if(typeof document.documentElement.uniqueID!=='undefined'){return function(element){return element.uniqueID;};}
var uid=0;return function(element){return element.__uniqueID||(element.__uniqueID='uniqueID__'+uid++);};})()};J16.util.cookie={set:function(n,v,e,p,d,s){if(!e)e=365;if(!p)p='/';e=e*1000*60*60*24;var e_date=new Date(new Date().getTime()+(e));document.cookie=n+'='+encodeURIComponent(v)+((e)?';expires='+e_date.toGMTString():'')+
((p)?';path='+p:'')+((d)?';domain='+d:'')+((s)?';secure':'');},get:function(n){var c=document.cookie.split("; ");for(var i=0;i<c.length;i++){var p=c[i].split("=");if(n==p[0])try{return decodeURIComponent(p[1])}catch(e){return null}}
return null;},del:function(name,path,domain){document.cookie=name+"=1"+((path)?";path="+path:"")+((domain)?";domain="+domain:"")+";expires=Thu, 01-Jan-1970 00:00:01 GMT";}};J16.util.json={obj2str:function(o){var r=[];if(typeof o=="string")return quote(o);if(typeof o=="undefined")return"undefined";if(typeof o=="object"){if(o===null)return"null";else if(!o.sort){for(var i in o)
r.push(this.obj2str(i)+":"+this.obj2str(o[i]));r="{"+r.join()+"}";}else{for(var i=0;i<o.length;i++)
r.push(this.obj2str(o[i]));r="["+r.join()+"]";}
return r;}
return o.toString();function quote(string){var escapable=/[\\\"\x00-\x1f\x7f-\x9f\u00ad\u0600-\u0604\u070f\u17b4\u17b5\u200c-\u200f\u2028-\u202f\u2060-\u206f\ufeff\ufff0-\uffff]/g;var meta={'\b':'\\b','\t':'\\t','\n':'\\n','\f':'\\f','\r':'\\r','"':'\\"','\\':'\\\\'};escapable.lastIndex=0;return escapable.test(string)?'"'+string.replace(escapable,function(a){var c=meta[a];return typeof c==='string'?c:'\\u'+('0000'+a.charCodeAt(0).toString(16)).slice(-4);})+'"':'"'+string+'"';}},str2obj:function(str){var undefined;try{if(str){return eval('('+str+')');}}catch(ex){}
return null;}};J16.util.string={cut:function(s,length,postfix){if(typeof(s)!="string")return s;postfix=postfix||"";if(!s||!length){return"";}
var len=0,temp="";for(var i=0;i<s.length;i++){if(s.charCodeAt(i)>255){len+=2;}else{len++;}
if(len>length){return temp+postfix;}
temp+=s.charAt(i);}
return s;}};J16.util.array={removeItem:function(array,dx){if(isNaN(dx)||dx>array.length||dx<0){return false;}
return array.splice(dx,1);}};
void function($){$.fn.tab=function(obj){var a=this.children().tab_blur();var c=$(obj.cnt).hide();var k=obj.cur||0,n=a.length;var f=obj.onChange;$(a[k]).tab_focus();$(c[k]).show();for(var i=0;i<n;i++)
$(a[i]).click(Go(i));return{go:go,cur:function(){return k;}};function go(i){if(k>-1){$(a[k]).tab_blur();$(c[k]).hide();}
$(a[i]).tab_focus();$(c[i]).show();k=i;if(f)f(i);}
function Go(i){return function(){if(k!=i)go(i);return false;};}};$.fn.tab_blur=function(){return this.attr('class','');};$.fn.tab_focus=function(){return this.attr('class','app_bt_sc');};}(jQuery);
