⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 8yxqebj2wii.js

📁 Teach Yourself Programming in Ten Years
💻 JS
📖 第 1 页 / 共 5 页
字号:
function ig_fa(a){var b=_gel("ffloading");if(b)b.style.display="none";var c=_gel("ffresults");if(c)c.style.display="block";if(a.length>0&&a.charAt(0)=="<")c.innerHTML=a;else a.match(ig_D)!=ig_?eval(a):eval(a)}function _add_remote_module(a,b,c){_sendx("/ig/feeds"+ig_k()+"module=1&q="+_esc(a),function(d){b();ig_ga(d,c)},ig_a,ig_);return ig_a}function ig_ga(a,b){var c=/_add_m_confirm\((\"[^"]+\"),\s*(\"[^"]+\")(,\s*\"[^"]+\")?\)/,d=/^alert\(\"[^"]+\"\)$/;if(a.match(ig_D)!=ig_||a.match(d)!=ig_){if(b)a=a.replace(c,"_add_m($1$3)");eval(a)}}function _ListApp(a,b,c){this.items=a;this.deleted=[];this.item_constructor=b;this.module_id=c;this.app_name="m_"+c+"_App";this.display_area=_gel("m_"+c+"_disp");this.sort_on_refresh=ig_b;this.value_input_field=_gel("m_"+c+"_val");this.name_input_field=_gel("m_"+c+"_name");if(!this.name_input_field)this.name_input_field=this.value_input_field;if(this.name_input_field){this.default_name=this.name_input_field.value;this.default_value=this.value_input_field.value}this.prev_items=[].concat(this.items)}_ListApp.prototype.reset=function(){this.items=[].concat(this.prev_items);this.deleted=[];this.refresh()};_ListApp.prototype.sort=function(a,b){return a.u(b)};_ListApp.prototype.Ja=function(){var a="";if(_old_html)a="<table cellspacing=0 cellpadding=0 border=0>";var b="",c=this.items;for(var d=0;d<c.length;d++)if(c[d]){a+=_old_html?"<tr><td nowrap><font size=-1>"+c[d].C()+'</font></td><td><a href="#" onclick="'+this.app_name+"._del("+d+')"><img src="/ig/images/x.gif" width=16 height=13 border=0></a></td></tr>':'<a href="#" onclick="'+this.app_name+"._del("+d+')" class="delbox listdelbox"></a>'+c[d].C()+'<div class="c"></div>';if(parseInt(c[d]._uid,10)<0)b+=c[d].n(d)}else{this.items.splice(d,1);d--}var e=this.deleted,f="";for(var d=0;d<e.length;d++)if(parseInt(e[d]._uid,10)>=0)f+=","+e[d]._uid;a+=this.fa(b,f);return a};_ListApp.prototype.fa=function(a,b){var c="<input type=hidden name=m_"+this.module_id+'_del value="'+b+'"><input type=hidden name=m_'+this.module_id+'_add value="'+a+'">';if(_old_html)c="</table><input type=hidden name=m_"+this.module_id+'_del value="'+b+'"><input type=hidden name=m_'+this.module_id+'_add value="'+a+'">';return c};_ListApp.prototype.refresh=function(){this.sort_on_refresh&&this.items.sort(this.sort);this.display_area.innerHTML="<font size=-1>"+this.Ja()+"</font>"};_ListApp.prototype.add=function(a,b){a||(a=_trim(this.name_input_field.value));b||(b=_trim(this.value_input_field.value));var c=new this.item_constructor(a,b,-1);if(!c.z())return;this.items[this.items.length]=c;this.refresh();this.name_input_field.value=this.default_name;this.value_input_field.value=this.default_value};_ListApp.prototype._del=function(a){this.deleted[this.deleted.length]=this.items[a];this.items.splice(a,1);this.refresh()};function _PrefListApp(a,b,c,d,e){var f=typeof c=="string"?[]:c,g=new _ListApp(f,d,e);for(var h in g)this[h]=g[h];typeof c=="string"&&this.Ia(c);this.prefidx=a;this.prefname=b;this.app_name="m_"+e+"_"+a+"_App";this.display_area=_gel("m_"+e+"_"+a+"_disp");this.value_input_field=_gel("m_"+e+"_"+a+"_val");this.name_input_field=this.value_input_field;this.default_name="";this.default_value="";this.fa=_PrefListApp_get_tail}function _PrefListApp_get_tail(){var a="</table>";_gel("m_"+this.module_id+"_"+this.prefidx).value=this.Ma();return a}_PrefListApp.prototype.Ia=function(a){if(a.length==0)return;var b=_IG_Prefs._strToArray(a),c=[];for(var d=0;d<b.length;d++){var e=new this.item_constructor(b[d],b[d],-1);c[c.length]=e}this.items=c;this.prev_items=[].concat(c)};_PrefListApp.prototype.Ma=function(){var a=[];for(var b=0;b<this.items.length;b++)a[a.length]=this.items[b]._v;return _IG_Prefs._arrayToStr(a)};function _ListItem(a,b,c){this._n=a;this._v=b;this._uid=c}_ListItem.prototype.z=function(){return this._n!=""};_ListItem.prototype.u=function(){return 0};_ListItem.prototype.C=function(){return _hesc(this._n)};_ListItem.prototype.n=function(){return"&"+_esc(this._n)+"="+_esc(this._v)};function _BMListItem(a,b,c){_ListItem.call(this,a,b,c)}ig_c(_ListItem,_BMListItem);_BMListItem.prototype.z=function(){return _ListItem.prototype.z.call(this)&&this._n!="http://"};_BMListItem.prototype.H=function(){if(this._v)return this._v;else{var a=this._n;if(a.indexOf("http://")==0)a=a.substring(7);if(a.indexOf("www.")==0)a=a.substring(4);return a}};_BMListItem.prototype.C=function(){return'<a href="'+this._n+'" target=bmwindow>'+_hesc(this.H())+"</a>"};_BMListItem.prototype.n=function(a){return"&b"+a+"="+_esc(this._n)+"&t"+a+"="+_esc(this._v)};_BMListItem.prototype.u=function(a){var b=_uc(this.H()),c=_uc(a.H());if(b==c)return 0;return b<c?-1:1};function _WthrListItem(a,b,c){_ListItem.call(this,a,b,c)}ig_c(_ListItem,_WthrListItem);_WthrListItem.prototype.n=function(){var a="&"+_esc(this._n);if(this._v)a+="="+_esc(this._v);return a};function _FListItem(a,b,c,d){_ListItem.call(this,a,b,c);this._s=d||0}ig_c(_ListItem,_FListItem);_FListItem.prototype.n=function(){return"&"+_esc(this._n)};_FListItem.prototype.u=function(a){var b=this;if(b._s<a._s)return-1;if(b._s>a._s)return 1;var c=_uc(b._n),d=_uc(a._n);if(c<d)return-1;if(c>d)return 1;return 0};var ig_E={X:0,Oa:1800,na:ig_,ma:ig_,Aa:ig_b,L:ig_,use_url_param_refresh:ig_,N:function(){ig_E.X=(new Date).getTime()+ig_E.Oa*1000},ib:function(){(new Date).getTime()>ig_E.X&&_testConnection(function(){_reload(ig_E.X,ig_E.use_url_param_refresh)},ig_E.N)},pa:function(a){ig_E.N();ig_E.na&&ig_E.na(a)},oa:function(a){ig_E.N();ig_E.ma&&ig_E.ma(a)}};function _IG_disable_refresh_cycle(){ig_E.Aa=ig_a;if(ig_E.L!=ig_){clearInterval(ig_E.L);ig_E.L=ig_}}function _IG_start_refresh_cycle(a,b,c){if(ig_E.Aa){ig_E.na=document.onmousedown;ig_E.ma=document.onkeyup;ig_E.Oa=a;if(c)ig_E.use_url_param_refresh=c;if(document.addEventListener){document.addEventListener("keyup",ig_E.oa,ig_a);document.addEventListener("mousedown",ig_E.pa,ig_a)}else if(document.attachEvent){document.attachEvent("onkeyup",ig_E.oa);document.attachEvent("onmousedown",ig_E.pa)}else{document.onkeyup=ig_E.oa;document.onmousedown=ig_E.pa}ig_E.N();ig_E.L=setInterval(ig_E.ib,b*1000)}}function _testConnection(a,b,c){var d=ig_f(),e="/ig/nop?t="+(new Date).getTime();c||(c=3500);d.open("GET",e,ig_b);d.onreadystatechange=function(){if(d.readyState==4&&a)if(200<=d.status&&d.status<300||d.status==1223){b=ig_;a()}};try{d.send(ig_)}catch(f){}var g=function(){if(b){a=ig_;b()}};setTimeout(g,c)}function _mailWindow(a){window.open(a,"mailwindow","width=400,height=340,left=50,top=50,scrollbars=no")}function ig_F(a){if(!a)a=document.body;return a.scrollHeight>a.offsetHeight?a.scrollHeight:a.offsetHeight}function ig_ha(){return self.pageYOffset?self.pageYOffset:document.documentElement&&document.documentElement.scrollTop?document.documentElement.scrollTop:document.body.scrollTop}function _setHomepage(a,b){var c=_gel("hp_url").innerHTML;a.style.behavior="url(#default#homepage)";a.setHomePage(c);_sendx("/ig/ui?action=sethomepage&url="+_esc(c)+"&type="+b+"&confirmed="+(_IGoogleIsHomepage()?1:0),ig_,ig_a,ig_)}function _IGoogleIsHomepage(){var a=_gel("shp"),b=_gel("hp_url").innerHTML;return a.isHomePage(b)}function _maybeShowSetHPMsg(){if(!_IGoogleIsHomepage()){_gel("set_homepage_msg").style.display="inline";if(_gel("new_user_demo")!=ig_)_gel("new_user_demo").style.display="none"}}function _hideSetHPMsg(){if(_gel("set_homepage_msg")!=ig_)_gel("set_homepage_msg").style.display="none";if(_gel("new_user_demo")!=ig_)_gel("new_user_demo").style.display="block"}function _iGoogleRejectedAsHomepage(){if(_gel("set_homepage_msg")!=ig_)_gel("set_homepage_msg").style.display="none";if(_gel("new_user_demo")!=ig_)_gel("new_user_demo").style.display="block";if(_gel("set_homepage_footer")!=ig_)_gel("set_homepage_footer").style.display="inline"}function _maybeShowSetHPFooter(){if(!_IGoogleIsHomepage()&&_gel("set_homepage_msg")==ig_)_gel("set_homepage_footer").style.display="inline"}_exportSymbols("",["pageHeight",ig_F,"scrollTop",ig_ha]);function _IG_GetCachedUrl(a,b){var c;c=typeof b=="object"?b:{};var d=window.location.href,e="/ig/proxy?",f=/^http:\/\/[^\/]+\/ig\/ifr[?]/,g=f.exec(d);if(g||d.indexOf("http://www.google.cn/ig/china")==0){if(window.location.host!="p.gmodules.com"&&_et)e+="et="+_esc(_et)+"&"}else e="http://p.gmodules.com/ig/proxy?";if(!isNaN(c.refreshInterval)&&c.refreshInterval>=0)e=_appendMaxAgeParameter(e,c.refreshInterval);return e+"url="+_esc(a)+"&log=1"}function _IG_GetImageUrl(a,b){return _IG_GetCachedUrl(a,b)}function _IG_GetImage(a,b){var c=document.createElement("img");c.src=_IG_GetCachedUrl(a,b);return c};function _IG_Callback(a){var b=arguments;return function(){var c=[];for(var d=0;d<arguments.length;d++)c[c.length]=arguments[d];for(var d=1;d<b.length;d++)c[c.length]=b[d];a.apply(ig_,c)}};var _IG_time=(function(){function a(){return(new Date).getTime()}var b=window._IG_time_epoch||a(),c={},d={},e={set_epoch:function(f){b=f},start:function(f){c[f]=a();e.start_callback(f)},since:function(f){var g=c[f]||b;return a()-g},stop:function(f){d[f]=e.since(f);e.stop_callback(f)},get:function(f){return d[f]},print:function(f){document.write("<div style='color:#999999;font-size:75%'>"+f+" : "+e.get(f)+"ms</div>")},stop_and_print:function(f){e.stop(f);e.print(f)},start_callback:function(){},stop_callback:function(){}};return e})();var ig_ia={domload:1,xsetpdone:1,moduledragstart:1,moduledragend:1,moduletitleclick:1,moduleedit:1,modulecanceledit:1,moduledelete:1,moduleundelete:1,modulezip:1,moduleunzip:1,modulemaximize:1,moduleunmaximize:1,load:1,unload:1,resize:1},ig_ja={dragstart:1,dragend:1,titleclick:1,edit:1,canceledit:1,"delete":1,undelete:1,zip:1,unzip:1,maximize:1,unmaximize:1};function ig_ka(a){var b="ig_event_hashcode_";if(a.hasOwnProperty&&a.hasOwnProperty(b))return a[b];a[b]||(a[b]=++ig_G.gb);return a[b]}function ig_la(a){return"builtin_"+a}function ig_ma(a,b){if(a.indexOf&&a.indexOf("m_")==0)a=a.substring(2);return"builtin_m"+a+"_"+b}function ig_na(a,b){return"builtin_"+ig_G.cb(a)+"_"+b}function ig_oa(a){return"custom_"+a}function ig_pa(){for(var a in ig_G.b){for(var b=0;b<ig_G.b[a].length;b++)ig_G.b[a][b]=ig_;if(a in ig_G.G){var c=ig_G.G[a],d=c[0],e=c[1],f=c[2];if(d.removeEventListener)d.removeEventListener(e,f,ig_a);else d.detachEvent&&d.detachEvent("on"+e,f);ig_G.G[a]=ig_}}}function ig_qa(a,b,c){for(var d=c;d<b.length;d++)a[a.length]=b[d];return a}function ig_ra(a,b){if(a in ig_G.b)for(var c=0;c<ig_G.b[a].length;c++)if(ig_G.b[a][c]===b){ig_G.b[a][c]=ig_;return ig_b}return ig_a}function ig_sa(a){if(a in ig_G.b)for(var b=0;b<ig_G.b[a].length;b++)if(ig_G.b[a][b]){var c=[];for(var d=1;d<arguments.length;d++)c[c.length]=arguments[d];ig_G.b[a][b].apply(this,c)}}function ig_ta(a,b){if(!(a in ig_G.nb))throw Error("Unsupported event type: "+a);var c=ig_G.T(a);c in ig_G.b||(ig_G.b[c]=[]);ig_G.b[c][ig_G.b[c].length]=b}function ig_ua(a,b,c){if(!(b in ig_G.ob))throw Error("Unsupported module event type: "+b);var d=ig_G.U(a,b);d in ig_G.b||(ig_G.b[d]=[]);ig_G.b[d][ig_G.b[d].length]=c}function ig_va(a,b,c){var d=ig_G.Da(a,b);if(!(d in ig_G.b)){ig_G.b[d]=[];var e=function(g){if(!g)g=window.event;ig_G.P.apply(a,[d,g])};if(a.addEventListener)a.addEventListener(b,e,ig_a);else if(a.attachEvent)a.attachEvent("on"+b,e);else throw Error("Object {"+a+"} does not support DOM events.");ig_G.G[d]=[a,b,e]}var f=ig_G.b[d].length;if(a===window&&b=="unload"&&f>0){ig_G.b[d][f]=ig_G.b[d][f-1];ig_G.b[d][f-1]=c}else ig_G.b[d][f]=c}function ig_wa(a,b){var c=ig_G.S(a);c in ig_G.b||(ig_G.b[c]=[]);ig_G.b[c][ig_G.b[c].length]=b}function ig_xa(a,b){var c=ig_G.T(a);return ig_G.M(c,b)}function ig_ya(a,b,c){var d=ig_G.U(a,b);return ig_G.M(d,c)}function ig_za(a,b,c){var d=ig_G.Da(a,b);return ig_G.M(d,c)}function ig_Aa(a,b){var c=ig_G.S(a);return ig_G.M(c,b)}function ig_Ba(a){var b=a=="load"||a=="domload";b&&_IG_time.stop("pre_"+a);var c=ig_G.A([ig_G.T(a)],arguments,1);ig_G.P.apply(window,c);b&&_IG_time.stop("post_"+a)}function ig_Ca(){var a=ig_G.A([],arguments,0);setTimeout(function(){ig_G.triggerEvent.apply(window,a)},0)}function ig_Da(a,b){var c=ig_G.A([ig_G.U(a,b)],arguments,2);ig_G.P.apply(window,c)}function ig_Ea(){var a=ig_G.A([],arguments,0);setTimeout(function(){ig_G.triggerModuleEvent.apply(window,a)},0)}function ig_Fa(a){var b=ig_G.A([ig_G.S(a)],arguments,1);ig_G.P.apply(window,b)}function ig_Ga(){var a=ig_G.A([],arguments,0);setTimeout(function(){ig_G.triggerCustomEvent.apply(window,a)},0)}var ig_G={gb:0,b:{},G:{},nb:ig_ia,ob:ig_ja,cb:ig_ka,T:ig_la,U:ig_ma,Da:ig_na,S:ig_oa,Ya:ig_pa,A:ig_qa,M:ig_ra,P:ig_sa,addEventHandler:ig_ta,addModuleEventHandler:ig_ua,addDOMEventHandler:ig_va,addCustomEventHandler:ig_wa,removeEventHandler:ig_xa,removeModuleEventHandler:ig_ya,removeDOMEventHandler:ig_za,removeCustomEventHandler:ig_Aa,triggerEvent:ig_Ba,triggerModuleEvent:ig_Da,triggerCustomEvent:ig_Fa,triggerDelayedEvent:ig_Ca,triggerDelayedModuleEvent:ig_Ea,triggerDelayedCustomEvent:ig_Ga},_IG_AddEventHandler=ig_G.addEventHandler,_IG_AddModuleEventHandler=ig_G.addModuleEventHandler,_IG_AddGadgetEventHandler=ig_G.addModuleEventHandler,_IG_AddDOMEventHandler=ig_G.addDOMEventHandler,_IG_AddCustomEventHandler=ig_G.addCustomEventHandler,_IG_RemoveEventHandler=ig_G.removeEventHandler,_IG_RemoveModuleEventHandler=ig_G.removeModuleEventHandler,_IG_RemoveGadgetEventHandler=ig_G.removeModuleEventHandler,_IG_RemoveDOMEventHandler=ig_G.removeDOMEventHandler,_IG_RemoveCustomEventHandler=ig_G.removeCustomEventHandler,_IG_TriggerEvent=ig_G.triggerEvent,_IG_TriggerModuleEvent=ig_G.triggerModuleEvent,_IG_TriggerGadgetEvent=ig_G.triggerModuleEvent,_IG_TriggerCustomEvent=ig_G.triggerCustomEvent,_IG_TriggerDelayedEvent=ig_G.triggerDelayedEvent,_IG_TriggerDelayedModuleEvent=ig_G.triggerDelayedModuleEvent,_IG_TriggerDelayedGadgetEvent=ig_G.triggerDelayedModuleEvent,_IG_TriggerDelayedCustomEvent=ig_G.triggerDelayedCustomEvent;_IG_AddDOMEventHandler(window,"unload",ig_G.Ya);_IG_AddDOMEventHandler(window,"load",function(){_IG_TriggerEvent("load")});

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -