?? infobox_collection.js
字號:
/* * Infobox.js * Part of ResourceSpace * Displays an information box when the user hovers over resource results. * *--------------------------------------------------------------------------*/var InfoBoxWaiting=false;var InfoBoxVisible=false;var InfoBoxRef=0;var InfoBoxTop=0;var InfoBoxLeft=0;function InfoBoxMM(event) { var i=$('InfoBoxCollection'); if (!i) {return false;} // no object? ignore for now var ii=$('InfoBoxCollectionInner'); var x=event.clientX; var y=event.clientY; var iebody=(document.compatMode && document.compatMode != "BackCompat")? document.documentElement : document.body var dsocleft=document.all? iebody.scrollLeft : pageXOffset var dsoctop=document.all? iebody.scrollTop : pageYOffset i.style.display='none'; InfoBoxTop=dsoctop + y - 25; if (InfoBoxTop<5) {InfoBoxTop=5;} InfoBoxLeft=dsocleft + x + 10; // Set up the box background / shadow // move the box higher up if the cursor is low enough to support this. if (x>400) { InfoBoxLeft-=396; i.style.backgroundImage="url('gfx/interface/infobox_left.png')"; ii.style.marginLeft="15px"; ii.style.marginRight="50px"; } else { i.style.backgroundImage="url('gfx/interface/infobox_right.png')"; ii.style.marginLeft="50px"; ii.style.marginRight="15px"; } // set a timer for the infobox to appear if ((InfoBoxRef!=0) && (InfoBoxWaiting==false)) { window.setTimeout('InfoBoxAppear()',1200); InfoBoxWaiting=true; } }function InfoBoxSetResource(ref) { InfoBoxRef=ref; } function InfoBoxAppear() { // Make sure we are still waiting for a box to appear and that the mouse has not yet moved. if ((InfoBoxWaiting) && (InfoBoxRef!=0)) { var i=$('InfoBoxCollection'); //Ajax loader here $('InfoBoxCollectionInner').innerHTML=''; new Ajax.Updater('InfoBoxCollectionInner','infobox_loader.php?ref=' + InfoBoxRef,{ method: 'get' }); i.style.display='block'; new Effect.Opacity('InfoBoxCollection', {duration:0.3, from:1, to:0.8}); i.style.top=InfoBoxTop + "px"; i.style.left=InfoBoxLeft + "px"; } InfoBoxWaiting=false; }
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -