• R/O
  • HTTP
  • SSH
  • HTTPS

Commit

Tags
No Tags

Frequently used words (click to add to your profile)

javac++androidlinuxc#windowsobjective-ccocoa誰得qtpythonphprubygameguibathyscaphec計画中(planning stage)翻訳omegatframeworktwitterdomtestvb.netdirectxゲームエンジンbtronarduinopreviewer

ギコナビ


Commit MetaInfo

Revisione197e76508834997bc131530d8125b6fa9b2d30c (tree)
Time2006-05-27 23:09:19
Authorgenyakun <genyakun>
Commitergenyakun

Log Message

最新版(Ver3.6.1231)に差し替え

Change Summary

Incremental Difference

--- a/res/skin/skin30-2G/Header.html
+++ b/res/skin/skin30-2G/Header.html
@@ -16,7 +16,7 @@
1616 var start_time = new Date();
1717 //==========ƒOƒ[ƒoƒ‹•Ï”
1818 var anchorHead="";
19-var skinName="skin30-2 v3.5.0704";
19+var skinName="skin30-2 v3.6.1231";
2020 var browser="ƒMƒRƒiƒr";
2121 //==========ƒMƒRƒiƒr—pƒAƒ“ƒJ[‚Ì”»’èi0:ˆ—–³‚µ,1:ƒ|ƒbƒvƒAƒbƒv,2:ƒ{ƒ^ƒ“‘}“üj
2222 // ƒMƒRƒiƒr‚ł́AƒŒƒXƒAƒ“ƒJ[‚Í‘Š‘΃AƒhƒŒƒX‚Å‹Lq‚³‚ê‚é
@@ -48,6 +48,16 @@ function threadurl(){
4848 t_bbs=RegExp.$1;
4949 t_key=RegExp.$2;
5050 }
51+//==========”ñ•\Ž¦ƒŒƒX‚Ì•\Ž¦-ƒMƒRƒiƒr‚Ì‚Ý
52+function hiddenRes(e){
53+ var number=tohan(event.srcElement.innerText.replace(/>|„/g,""));
54+ var i=0;while(document.anchors[i].name.match(/\D/)){i++}
55+ var startRes=parseInt(document.anchors[i+1].name.replace(/\D/g,""));
56+ if(number.match(/(\d*)\D+(\d*)/)){var start=parseInt(RegExp.$1);}
57+ else {var start=parseInt(number);}
58+ //alert(startRes+">"+start+" && "+start+"!="+1);
59+ if(startRes>start && start!=1){return true}else{return false}
60+}
5161 </script>
5262 </head>
5363 <body>
--- a/res/skin/skin30-2G/chie_base.css
+++ b/res/skin/skin30-2G/chie_base.css
@@ -7,8 +7,11 @@ dt a{text-decoration:none;}
77 dd a{text-decoration:underline;line-height:1.1}
88
99 /* ŒŸõŒ‹‰Ê */
10-#foundResult a {color:LightSlateGray;}
11-#foundResult a:hover{color:#000;}
10+#foundPanel{color:LightSlateGray;}
11+#foundPanel div {font-family:"‚l‚r ƒSƒVƒbƒN";}
12+#foundPanel div span{font-family:Times;cursor:hand;}
13+#foundPanel a {color:LightSlateGray;}
14+#foundPanel a:hover{color:#000;}
1215
1316 /* dt */
1417 dt{
--- a/res/skin/skin30-2G/chie_event.js
+++ b/res/skin/skin30-2G/chie_event.js
@@ -1,18 +1,22 @@
1+//========V’…ƒWƒƒƒ“ƒvÝ’è
2+var buffer=1; // ’ᑬ‰ñü‚â’ᑬƒ}ƒVƒ“‚̏ꍇ‚É‚Íbuffer‚̐”’l‚𑝂₷‚Æ‚æ‚萳Šm‚ɃWƒƒƒ“ƒvi1‘‚â‚·‚Æ0.1•b’x‚ê‚éj
3+var newResJump=1; // V’…ƒŒƒXƒWƒƒƒ“ƒvi0:ƒuƒ‰ƒEƒU”C‚¹A1:“Ç—¹Žž‚̂݁A2:íŽžj–‚©‚¿‚ãAOpenJaneAtwintail‚݂̂̐ݒè
4+//==========ˆÈ‰º‚̓XƒNƒŠƒvƒg–{•¶‚Å‚·‚æB
15 //ƒCƒxƒ“ƒgƒnƒ“ƒhƒ‰’è‹`
26 //ŠO•”ŠÖ”Ftohan
37 //ŠO•”•Ï”FanchorHead,lightmode,getID,skinName,browser,dts
4-//ƒOƒ[ƒoƒ‹•Ï”
5-var buffer=1; // ’ᑬ‰ñü‚â’ᑬƒ}ƒVƒ“‚̏ꍇ‚É‚Íbuffer‚̐”’l‚𑝂₷‚Æ‚æ‚萳Šm‚ɃWƒƒƒ“ƒvi1‘‚â‚·‚Æ0.1•b’x‚ê‚éj
6-var newResJump=1; // V’…ƒŒƒXƒWƒƒƒ“ƒvi0:ƒuƒ‰ƒEƒU”C‚¹A1:“Ç—¹Žž‚̂݁A2:íŽžj–‚©‚¿‚ãAOpenJaneAtwintail‚݂̂̐ݒè
8+//=========ŠO•”ƒtƒ@ƒCƒ‹‹¤—p‚̃Oƒ[ƒoƒ‹•Ï”
9+var waited=false;//command•\Ž¦Œãtrue‚É‚µA‘I‘ðŒã‚Éfalse‚É‚·‚éB
10+var viewed=false;//thumb“Ǎž‚ÝŒãtrue‚É‚µAthumbPanel‚ɏæ~Œãfalse‚É‚·‚éB
11+var searched=false; //ŒŸõŒã‚ɁAtrue‚É‚µAfoundPanel‚ɏæ~Œãfalse‚É‚·‚éB
12+var cp,tp,vp,fp;
713 //========Clickˆ—¨search,‘¼
814 document.onclick = clickEvent;
915 function clickEvent(){
1016 if(clickCancel){return false}else{clearTimeout(clickTimer);if(document.getElementById("context")){document.getElementById("context").removeNode(true);}}
1117 var obj=window.event.srcElement;
1218 var tag=obj.tagName;
13- if (tag=="B") {search(obj.parentElement)} //–¼‘O
14- else if(tag=="U") {search(obj)} //ƒgƒŠƒbƒv
15- else if(tag=="SPAN"){if(getID(obj)){searchID(obj)}} //ID
19+ if(tag=="B"||tag=="U"||tag=="SPAN"){searchPerson(obj)} //–¼‘O,ƒgƒŠƒbƒv,ID
1620 else if(tag=="DT") {searchRef(obj)}
1721 else if(tag=="DD") {defaultPopup()}
1822 else if(tag=="A"){
@@ -23,7 +27,7 @@ function clickEvent(){
2327 if(obj.href.match(/^http:.*#/)){window.open(obj.href,"_parent");return false}
2428 }
2529 //A Bone•â³i”ñ•\Ž¦ƒŒƒX‚Ì•\Ž¦j
26- if(browser=="A Bone" && hidedRes(obj)){showModelessDialog(document.getElementsByName("ThreadURL")[0].content+tohan(obj.innerText.replace(/[>„]/g,"")),window,"dialogWidth:"+document.body.clientWidth+"px;help:no;resizable:yes;status:no;unadorned:yes;");window.focus();}
30+ if((browser=="A Bone"||browser=="ƒMƒRƒiƒr") && hiddenRes(obj)){showModelessDialog(document.getElementsByName("ThreadURL")[0].content.replace(/\/l50$/,"/")+tohan(obj.innerText.replace(/[>„]/g,"")),window,"dialogWidth:"+document.body.clientWidth+"px;help:no;resizable:yes;status:no;unadorned:yes;");window.focus();}
2731 //Jane,Live,ƒMƒRƒiƒr•â³iskin30-2Normal‹y‚уMƒRƒiƒrj–ƒŒƒXƒWƒƒƒ“ƒv‚ªscrollIntoView‚Å‚È‚¢‚à‚Ì‚ÉŒW‚é•â³
2832 if(browser=="A Bone" || browser=="OpenJane" || browser=="Live2ch" || browser=="ƒMƒRƒiƒr"){if(obj.href.match(/^about|jumpres/)){
2933 var h=tohan(obj.innerText.replace(/[>„]/g,""));
@@ -32,17 +36,17 @@ function clickEvent(){
3236 }}
3337 return true;
3438 }
35- else{return}
39+ else{panelOver();return}
3640 }
3741
3842 //=========MouseOverˆ—¨image,popup
3943 document.onmouseover = mouseOverEvent;
4044 function mouseOverEvent() {
4145 var e = window.event.srcElement;
42- if(e.tagName=='B'){
46+ if(e.tagName=='B'){if(browser!="twintail2"){
4347 if(e.innerText.match(/^([^\d‚O-‚X]*)([\d‚O-‚X]+)([^\d‚O-‚X]*.*)/)){namePopup(e,RegExp.$1,RegExp.$2,RegExp.$3);}
4448 else if(e.innerText.match(/^‚ ‚ځ`‚ñ$/)) {abonePopup(e);}
45- }
49+ }}
4650 if(e.tagName=='A'){
4751 if(!e.innerText.match(/%/)){ // URLƒGƒ“ƒR[ƒh‚Å‚ ‚肪‚¿‚È%‚ª‚È‚¯‚ê‚Î
4852 //e.href=e.href.replace(/>/g,"");
@@ -55,9 +59,8 @@ function mouseOverEvent() {
5559 }
5660 }
5761 if (checkAnchor(e.href)==2){insButton(e);return;}
58- else if(checkAnchor(e.href)==1){
62+ else if(checkAnchor(e.href)==1){ // ‘½’iƒ|ƒbƒvƒAƒbƒv
5963 if(event.shiftKey){if(e.rel){e.href=e.rel}return}
60- // ‘½’iƒ|ƒbƒvƒAƒbƒv
6164 var parent=e.parentElement;
6265 var aNum= (parent.tagName!="DD") ? parent.firstChild.sourceIndex : parent.previousSibling.firstChild.innerText;
6366 if(!document.getElementById("p"+aNum)){
@@ -66,49 +69,48 @@ function mouseOverEvent() {
6669 if(!onPopup){removePopup()}
6770 makePopContent(e);return;
6871 }
72+ }else if(checkAnchor(e.href)==0){ // ‹tŽQÆƒ|ƒbƒvƒAƒbƒv
73+ if(e.href.match(/menu:/) && event.shiftKey){searchPopup(e)}
6974 }
75+ }else if(e.tagName=="SPAN"||e.tagName=="TT"){
76+ var obj=e;var onPopup;
77+ while(obj.tagName!="BODY"){if(obj.id.match(/p\d+/)){onPopup=true;break}else{obj=obj.parentElement}}
78+ if(e.tagName=="SPAN"){
79+ if(!onPopup && event.shiftKey){searchPopup(e)}
80+ }else{searchPopup(e)}
7081 }else{ // ‘½’iƒ|ƒbƒvƒAƒbƒvÁ‹Ž
7182 var obj=e;var onPopup;
7283 if(obj.sourceIndex<0){obj=document.body;if(document.getElementById("popupBase")){onPopup=true;}} // namePopup‚Æ‚Ì‹£‡‚Ńm[ƒh‚ªŠO‚ê‚éuŠÔ‚̉ñ”ð
73- while(obj.tagName!="BODY"){if(obj.id.match(/p\d+/)){onPopup=true;break}else{obj=obj.parentElement;}}
84+ while(obj.tagName!="BODY"){if(obj.id.match(/(p\d+)/)){onPopup=true;break}else{obj=obj.parentElement;}}
7485 if(onPopup){while(obj.id!=obj.parentElement.lastChild.id){obj.parentElement.lastChild.removeNode(true)}}
7586 else {removePopup()}
7687 }
77- if(e.tagName=="DT"){setHash();}
78- if(e.tagName=="SPAN"){
79- var obj=e;var onPopup;
80- while(obj.tagName!="BODY"){if(obj.id.match(/p\d+/)){onPopup=true;break}else{obj=obj.parentElement}}
81- if(!onPopup && event.shiftKey){searchPopup(event.toElement);} return;
82- }
8388 }
84-//=========MouseMoveˆ—¨menuOver(),tpOver()
89+//=========MouseMoveˆ—¨panelOver()
8590 document.onmousemove=mouseMoveEvent;
86-var waited=false;//command•\Ž¦Œãtrue‚É‚µA‘I‘ðŒã‚Éfalse‚É‚·‚éB
87-var viewed=false;//thumb“Ǎž‚ÝŒãtrue‚É‚µAthumbPanel‚ɏæ~Œãfalse‚É‚·‚éB
88-var cp,tp,vp;
8991 function mouseMoveEvent() {
9092 if(!cp){
91- var nHTML ="<div id='controlPanel'><input type='button' value='TOP' onclick='scroll_Top();blur()'><input type='button' value='END' onclick='scroll_End();blur()'><input type='button' value='IMG' onmouseup='imgCommand();blur()'><input type='button' value='FND' onclick='findIt(document.selection.createRange().text);blur()'></div>";
92- if(skinName.match(/30-2/)){nHTML+="<div id='thumbPanel' onmouseout='viewed=false'></div><div id='viewPanel'></div>";}
93- document.body.insertAdjacentHTML('afterBegin',nHTML);
94- cp=document.getElementById("controlPanel");
95- if(skinName.match(/30-2/)){tp=document.getElementById("thumbPanel");vp=document.getElementById("viewPanel");}
93+ var nHTML ='<div id="controlPanel"><input type="button" value="TOP" onclick="scroll_Top();blur()"><input type="button" value="END" onclick="scroll_End();blur()"><input type="button" value="IMG" onmouseup="imgCommand();blur()"><input type="button" value="FND" onclick="fndCommand();blur();"></div><div id="foundPanel" onmouseout="searched=false"></div>';
94+ if(skinName.match(/30-2/)){nHTML+='<div id="thumbPanel" onmouseout="viewed=false"></div><div id="viewPanel"></div>';}
95+ document.body.insertAdjacentHTML("afterBegin",nHTML);
96+ cp=document.getElementById("controlPanel");fp=document.getElementById("foundPanel");
97+ if(skinName.match(/30-2/)){tp=document.getElementById("thumbPanel");vp=document.getElementById("viewPanel");}else{tp=vp=new Object()}
98+ cp.condition="waited";tp.condition="vp.firstChild || viewed || !lightmode";fp.condition=resultView ? "fp.hasChildNodes()" : "searched";
99+ cp.territory="<25"; tp.territory=">20"; fp.territory="<(30+fp.clientHeight) && fp.hasChildNodes()";
96100 }
97- cpOver();
98- tpOver();
101+ if(event){panelOver();}
102+ if(!idHash.length){setHash();searchColoring();}
99103 }
100-// ƒRƒ“ƒgƒ[ƒ‹ƒpƒlƒ‹
101-function cpOver(){
104+// Šeƒpƒlƒ‹
105+function panelOver(){
102106 var territoryW=document.body.clientWidth-120;var territoryH=25;
103- if(waited){cp.style.visibility="visible";return}
104- if(event.y<territoryH && event.x>territoryW){cp.style.visibility="visible";}else{cp.style.visibility="hidden";}
105-}
106-// ƒTƒ€ƒlƒCƒ‹ƒpƒlƒ‹
107-function tpOver(){
108- if(skinName.match(/30-3/) || !lightmode){return}
109- var territoryW=document.body.clientWidth-120;var territoryH=20;
110- if(document.getElementById("viewPanel").firstChild || viewed){tp.style.visibility="visible";return}
111- if(event.y>territoryH && event.x>territoryW){tp.style.visibility="visible";}else{tp.style.visibility="hidden";}
107+ var panels=new Array("cp","tp","fp");
108+ for(var i in panels){
109+ if(skinName.match(/30-3/)&&panels[i]=="tp"){continue}
110+ var panel=eval(panels[i]); var territoryY=eval("event.y"+panel.territory); var territoryX=eval(event.x>document.body.clientWidth-panel.offsetWidth-15);
111+ if(eval(panel.condition)){panel.style.visibility="visible";return}
112+ if(territoryY && territoryX){panel.style.visibility="visible";}else{panel.style.visibility="hidden";}
113+ }
112114 }
113115 // TOP,END
114116 function scroll_Top(){document.getElementsByTagName("DL")[0].firstChild.scrollIntoView(true);}
@@ -127,6 +129,14 @@ function imgCommand(mode,s){
127129 clearCommand();
128130 }
129131 }
132+function fndCommand(mode,s){
133+ if(!waited){
134+ findIt(document.selection.createRange().text);
135+ event.cancelBubble=true;
136+ }else{
137+ clearCommand();
138+ }
139+}
130140 function clearCommand(){
131141 waited=false;
132142 document.getElementById("command").removeNode(true);
@@ -174,7 +184,7 @@ function key(){
174184 else if(code=="36"){scroll_Top()}
175185 else if(code=="35"){scroll_End()}
176186 else if(code=="73" && event.shiftKey){changePanel();return false;} // shift+I
177- else if(code=="70" && event.shiftKey){cp.childNodes[3].click();return false;} // shift+F
187+ else if(code=="70" && event.shiftKey){findIt(document.selection.createRange().text);return false;} // shift+F
178188 else if(code=="78" && event.shiftKey && firstNew){firstNew.scrollIntoView(true)} // shift+N
179189 else if(code=="82" && event.shiftKey && event.ctrlKey){ // ctrl+shift+R
180190 //‚©‚¿‚ã`‚µ‚á•â³i”XV‚̃Vƒ‡[ƒgƒJƒbƒgƒL[j
@@ -190,7 +200,7 @@ function key(){
190200 //=========‚©‚¿‚ãAABoneAƒ]ƒk‚Q
191201 var newResNum=parseInt(document.getElementsByName("GetRescount")[0].content)+1;
192202 var k=0;
193-function loadEvent(num){ //setTimeout("setHash();",100);
203+function loadEvent(num){
194204 //====V’…ƒŒƒXƒWƒƒƒ“ƒv
195205 if(newResJump==0){clearInterval(timerID);return} //uƒuƒ‰ƒEƒU”C‚¹v‚È‚çI—¹
196206 //V’…ƒŒƒX‚ÌŠJŽn”ԍ†‚ðŽæ“¾
@@ -209,7 +219,7 @@ function loadEvent(num){ //setTimeout("setHash();",100);
209219 //=========V’…ƒŒƒXŽæ“¾Œãˆ—i•W€ƒXƒLƒ“‘Ήžƒuƒ‰ƒEƒU—pj©NewMark‚©‚çŒÄ‚яo‚µ
210220 //=========OpenJAtwin
211221 var scr,viewPos,endPos=0;
212-function reloadEvent(){ //setTimeout("setHash();",100);
222+function reloadEvent(){
213223 //====Šù“lj»
214224 var lastDt=dts[dts.length-2];if(!lastDt){return}// ‘S•”V’…‚È‚çI—¹
215225 while(lastDt && lastDt.className=="new"){lastDt.className="";lastDt=lastDt.previousSibling.previousSibling;}
@@ -242,10 +252,10 @@ function defaultPopup(){
242252 obj.innerText=num;
243253 obj.href="#"+hnum;
244254 makePopContent(obj);
245- }else if(num.match(/\w/) && num.length==8){ //\w{8}‚Å‚Í‚¾‚߂ہH
246- var obj=document.createElement("span");
247- obj.innerText="date time ID:"+num;
248- setHash();searchID(obj);
255+ }else if(num.match(/\w{8,9}/)){ //\w{8}‚Å‚Í‚¾‚߂ہH
256+ var obj=document.createElement("DT");
257+ obj.innerHTML="<span>date time ID:"+num+"</span>";
258+ searchPerson(obj.firstChild);
249259 }
250260 }
251261
@@ -260,5 +270,14 @@ function copyEvent(){
260270 copyText.execCommand("Copy");
261271 return false;
262272 }
263-//=========onLoadˆ—iDAT2HTML‚̂݁j
264-window.onload=function(){setHash()}
273+//=========onScrollˆ—
274+//window.onscroll=function(){clearInterval(beforeScrollTimer);onLoadEvent()}
275+window.onscroll=function(){onLoadEvent()}
276+if(document.getElementById("dl")){
277+ document.getElementById("dl").onscroll=function(){onLoadEvent()}
278+}
279+//=========onLoadˆ—
280+window.onload=onLoadEvent;
281+function onLoadEvent(){mouseMoveEvent();setHash();searchColoring();}
282+setTimeout("onLoadEvent()",1000); // ˆê‰ñ‚¾‚¯’…F
283+
--- a/res/skin/skin30-2G/chie_image.css
+++ b/res/skin/skin30-2G/chie_image.css
@@ -18,7 +18,7 @@ input,button{
1818 }
1919 #thumbPanel div{
2020 width:100px;
21- margin-bottom:2px;
21+ margin-bottom:0px;
2222 border:solid 1px #D6DCE1;
2323 background-color:#FFF;
2424 text-align:right;
--- a/res/skin/skin30-2G/chie_image.js
+++ b/res/skin/skin30-2G/chie_image.js
@@ -1,9 +1,11 @@
1-// ƒCƒxƒ“ƒgƒnƒ“ƒhƒ‰FonMouseover
2-// ŠO•”ŠÖ”FaddAnchor
3-// ŠO•”•Ï”Fcp,tp,vp,dds
41 //======‰æ‘œ“Ǎž‚̐ݒè
2+var onOpenLoad =1; // ƒXƒŒ“ǍžŽž‚̉摜“Ǎž@0:“ǂݍž‚Ü‚È‚¢A1:V’…ƒŒƒX‚̂݁A2:‘S•”
53 var onMouseLoad=true; // true:ƒJ[ƒ\ƒ‹‚ð‡‚í‚¹‚½‚¾‚¯Afalse:LOADƒ{ƒ^ƒ“‚ðƒNƒŠƒbƒN‚µ‚Ä‚©‚ç
64 var takeArisk=false; // true:‰æ‘œ“ǂݍž‚ÝŽž‚Ƀ‚[ƒhØ‘ցAfalse:Žè“®‚Ń‚[ƒhØ‘Ö
5+//==========ˆÈ‰º‚̓XƒNƒŠƒvƒg–{•¶‚Å‚·‚æB
6+// ƒCƒxƒ“ƒgƒnƒ“ƒhƒ‰FonMouseover
7+// ŠO•”ŠÖ”FaddAnchor
8+// ŠO•”•Ï”Fcp,tp,vp,dds
79 //==========ƒOƒ[ƒoƒ‹•Ï”
810 //==========‰æ‘œˆ—“™
911 var lightmode = true;
@@ -56,14 +58,22 @@ function insButton(a,hRH) {
5658 var nHTML='<input type="button" value="LOAD" onClick=\'loadImage(this,"'+a.href+'");blur()\'>'
5759 +'<input type="button" value="VIEW" onClick=\'changeView("swf","'+a.href+'");blur()\'>';
5860 }else{
59- if(hRH){var ahref=hRH}else{var ahref=a.href}
61+ var ahref=(hRH)?hRH:a.href;
6062 if(ahref.match(/^javascript:.*'(.*)'.*/)){ahref=RegExp.$1+document.getElementsByName("ThreadURL")[0].content;a.href=ahref}
6163 var nHTML='<input type="button" value="VIEW" onClick=\'changeView("html","'+ahref+'");blur()\'>'
62- ;//+'<input type="button" value="CHECK" onClick=\'changeView("html","http://www.tekijuku.com/URL/?url='+ahref+'");blur()\'>';
64+ +'<input type="button" value="CHECK" onClick=\'changeView("html","http://so.7walker.net/?site='+ahref+'");blur()\'>';
6365 }
6466 a.insertAdjacentHTML('AfterEnd',nHTML);
6567 a.className = 'replaced';
66- if(onMouseLoad && imageExt2(a.href)){loadImage(a.nextSibling,a.href)}
68+ if(imageExt2(a.href)){
69+ if(!event||event.type=="mousemove"||event.type=="scroll"){ // autoImageLoad‚ł̓Ǎž
70+ if(onOpenLoad){loadImage(a.nextSibling,a.href)}
71+ }else if(event.type=="mouseover"){ // mouseover‚ł̓Ǎž
72+ if(onMouseLoad){loadImage(a.nextSibling,a.href)}
73+ }else if(event.type=="click"){ // allImageload‚ł̓Ǎž
74+ loadImage(a.nextSibling,a.href);
75+ }
76+ }
6777 return;
6878 }
6979 }
@@ -71,19 +81,19 @@ function insButton(a,hRH) {
7181 function loadImage(btn,href){
7282 if(!panel){changePanel()}
7383 if(takeArisk && lightmode){changeMode()}
74- if(btn.tagName!="A"){
75- var thumbs = document.images;
76- var l=thumbs.length;
77- for(var i=l;i--;){if(thumbs[i].src==href){
78- if(lightmode){tp.style.visibility="visible";viewed=true;}
79- //thumbs[i].scrollIntoView(true);
80- imgOver(thumbs[i],100);
81- return true;
82- }}
83- }
84+ // “¯ˆê‰æ‘œŠm”F
85+ var thumbs = document.images;
86+ var l=thumbs.length;
87+ for(var i=l;i--;){if(thumbs[i].src==href){
88+ if(lightmode){tp.style.visibility="visible";viewed=true;}
89+ //thumbs[i].scrollIntoView(true);
90+ imgOver(thumbs[i],100);
91+ return true;
92+ }}
8493 if(btn.parentElement.tagName=="DD"){var dt = btn.parentElement.previousSibling;}
8594 else {var dt = btn.parentElement;}
8695 var num = dt.firstChild.innerText;
96+ if(href.match(/www.securityfocus.com/)){if(!confirm(num+"‚̃ŒƒX‚É‚ ‚éhttp://www.securityfocus.com/‚̉摜‚̓uƒ‰ƒNƒ‰‚̉”\«‚ª‚‚¢‚Å‚·‚ªAŠJ‚«‚Ü‚·‚©H")){return}}
8797 if(href.search(/\.swf/i)==-1){
8898 var nHTML = '<div><img src="'+href+'" onLoad="imgResult(this)" onError="imgResult(this)" onClick="changeView(\'img\')" onmouseover="imgOver(this,100)" onmouseout="imgOver(this,30)">'
8999 +addAnchor(num,num)+' '
@@ -106,7 +116,14 @@ function loadImage(btn,href){
106116 function imgResult(img){
107117 var btn=img.parentElement.children.item(2);
108118 if(event.type=="load"){btn.value='___'; img.style.display='block';}
109- else {btn.value='NONE';btn.style.color='#C00';setTimeout("viewed=false",3000)}
119+ else {btn.value='NONE';btn.style.color='#C00';}
120+ if(event.type=="error"){
121+ var dt=getDTfromAnc(img.parentElement.children.item(1).innerText);
122+ var ddAnc=dt.nextSibling.getElementsByTagName("A");
123+ var a;var i=0;do{a=ddAnc[i];i++;}while(a.href!=img.href);
124+ var btn=a.nextSibling;
125+ btn.value='NONE';btn.style.color='#C00';
126+ }
110127 }
111128 // ƒTƒCƒY‚̐ؑÖ
112129 function changeSize(btn){
@@ -187,12 +204,10 @@ function allImageLoad(mode){
187204 var ddl=dds.length;var exist;
188205 for(var i=0;i<ddl;i++){
189206 if(mode=="new"){if(dds[i].previousSibling.className!="new"){continue}}
190- cl=dds[i].childNodes.length;
191- for(j=0;j<cl;j++){
192- cn=dds[i].childNodes[j];
193- if(cn.tagName == "A"){
194- if(imageExt2(cn.href)){loadImage(cn,cn.href);exist=true}
195- }
207+ var ddAnc=dds[i].getElementsByTagName("A");
208+ for(j=0;j<ddAnc.length;j++){
209+ cn=ddAnc[j];
210+ if(imageExt2(cn.href)){insButton(cn,cn.href);exist=true}
196211 }
197212 }
198213 if(!exist){
--- a/res/skin/skin30-2G/chie_popup.js
+++ b/res/skin/skin30-2G/chie_popup.js
@@ -1,4 +1,6 @@
1+//==========ˆÈ‰º‚̓XƒNƒŠƒvƒg–{•¶‚Å‚·‚æB
12 // ƒCƒxƒ“ƒgƒnƒ“ƒhƒ‰FonMouseover
3+// ŠO•”•Ï”FidHash,refHash,foudRes,highlight
24 // ŠO•”ŠÖ”FaddAnchor,getDTfromAnc
35 // “Á’¥FDIV#popupBase‰º‚Ɂuƒtƒ‰ƒbƒg‚ŃŠƒjƒAv‚ÉDL#p\d‚ðì¬‚·‚éB
46 //==========CSS‚̏o—Í
@@ -9,65 +11,65 @@ nCSS+='#popupBase dl{position:absolute; background-color:window; border:outset 1
911 nCSS+='#popupBase dt span{float:none; margin-left:1em;}';
1012 nCSS+='#popupBase dd{margin:auto 1em}';
1113 document.write('<style type="text/css">'+nCSS+'</style>\n');
12-//=========ƒOƒ[ƒoƒ‹•Ï”
13-var pb;
14+//=========ŠO•”ƒtƒ@ƒCƒ‹‹¤—p‚̃Oƒ[ƒoƒ‹•Ï”
1415 //=========ƒiƒ“ƒo[‚È–¼‘O‚̃|ƒbƒvƒAƒbƒv
1516 function namePopup(e,before,num,after){
1617 var hnum=tohan(num);
17- //‚RŽü”NA‚SŽü”NASocket774A774KBA21‹ÖA[1-30]A‚È‚Ç‚Í–³Ž‹
18- if(before){if(hnum==5 || hnum==774 || hnum==4 || hnum==21 || hnum==1 || hnum==30){return}}
18+ if(hnum==774 || hnum==21 || hnum==1 || hnum==30){return} // Socket774A774KBA21‹ÖA[1-30]A‚È‚Ç‚Í–³Ž‹
19+ if(before && before.match(/–¼–³/)){return} //–¼–³‚µ‚Á‚Û‚¢‚Ì‚Í–³Ž‹
20+ if(after) {if(after=="Žü”N"){return}} // ƒfƒtƒHƒ‹ƒg‚È"‚ŽŽü”N"‚Í–³Ž‹
1921 var nB = before ? "<b>"+before+"</b><b>":"<b>"; nB+=addAnchor(hnum,num); nB+=after ? "</b><b>"+after+"</b>":"</b>";
2022 e.outerHTML=nB;
2123 }
2224 //=========Žã‚ ‚ځ`‚ñ‚̃|ƒbƒvƒAƒbƒv
23-function abonePopup(e){
24- var hnum=e.parentElement.previousSibling.innerText;
25- e.outerHTML = "<b>"+addAnchor(hnum,'‚ ‚ځ`‚ñ')+"</b>";
25+function abonePopup(e){e.outerHTML = "<b>"+addAnchor(e.parentElement.previousSibling.innerText,'‚ ‚ځ`‚ñ')+"</b>";}
26+//=========ŒŸõ‚µ‚½ƒŒƒX‚̃|ƒbƒvƒAƒbƒv
27+function searchPopup(obj){
28+ var reg,cArray;var tag=obj.tagName;
29+ /*ref Popup*/if (tag=="A") {if(refHash[obj.innerText]){cArray=refHash[obj.innerText].split(" ")}else{return}}
30+ /*ID Popup*/ else if(tag=="SPAN"){reg=getID(obj);if(reg&&reg.length>3){cArray=idHash[reg].split(" ");}else{return} if(cArray.length==1){return}}
31+ /*ŒŸõPopup*/else if(tag=="TT") {var cHash=(obj.parentElement.rel=="res")?foundRes:highlight;cArray=cHash[obj.parentElement.firstChild.style.backgroundColor];if(!cArray){return}}
32+ var targetString=""; for(var i=0;i<cArray.length;i++){targetString+=returnString(cArray[i]);} //’†g‚̐؂èo‚µ
33+ if(targetString){popup(targetString);} //‘Ώۂª‘¶Ý‚µ‚½‚çƒ|ƒbƒvƒAƒbƒv
2634 }
2735 //=========‘½’iƒ|ƒbƒvƒAƒbƒv
2836 //Eƒ|ƒbƒvƒAƒbƒv‚̍쐬
29-var startRes;
3037 function makePopContent(obj){
3138 //Ž–‘O€”õ
32- var num=obj.innerText.replace(/[>„]/g,"");
33- var number=tohan(num);
34- if(!obj.rel){obj.rel=obj.href;}
35- obj.href="decoy:";
36- //’²¸
37- if(document.anchors.length==1){return} //ƒŒƒX”‚ª1‚È‚çI—¹
38- if(!startRes){startRes=parseInt(document.anchors[1].name.replace(/\D/g,""))}
39+ var num=obj.innerText.replace(/[>„]/g,""); var number=tohan(num);
40+ if(!obj.rel){obj.rel=obj.href;} obj.href="decoy:"; // ƒuƒ‰ƒEƒU–{‘̂̃|ƒbƒvƒAƒbƒv‰ñ”ð
41+ //”ԍ†’²¸
3942 if(number.match(/(\d*)\D+(\d*)/)){var start=parseInt(RegExp.$1); var end=parseInt(RegExp.$2);}
4043 else {var start=end=parseInt(number);}
41-// alert(startRes+">"+end+" && "+end+"!=1")
42- if(startRes>end && end!=1){obj.href=obj.rel;return}//‘¶Ý‚µ‚Ä‚¢‚È‚¯‚ê‚ΏI—¹
44+ if(end-start>100){end=start+100} // 100ˆÈã•\Ž¦‚µ‚È‚¢
4345 //’†g‚̐؂èo‚µ
44- var targetString=""; if(end-start>100){end=start+100}
45- if(start==end){targetString=returnString(start)}
46- else {for(var i=0;i<=end-start;i++){targetString+=returnString(start+i)}}
46+ var targetString=""; for(var i=0;i<=end-start;i++){targetString+=returnString(start+i)}
4747 //‘Ώۂª‘¶Ý‚µ‚½‚çrel‚É‘Þ”ð‚µ‚Äƒ|ƒbƒvƒAƒbƒv
4848 if(targetString){popup(targetString);}else{obj.href=obj.rel;}
4949 }
5050 //E’†g‚̐؂èo‚µ
5151 function returnString(num){
5252 var obj=getDTfromAnc(num);
53+ setSearchColor(obj);//ƒ|ƒbƒvƒAƒbƒvæ‚Ì’…F
5354 if(!obj){return("")} //‘Ώۂª“§–¾‚ ‚ځ`‚ñ‚È‚çI—¹
54- var dt,dd,dtOuter,ddOuter;
55- dt=obj.cloneNode(true);
56- dtOuter=dt.outerHTML.replace(/name=.*?>/,">"); // LABELNUMBER‘Ήž‚Ì‚à‚Ì‚ÉŒW‚郊ƒ“ƒNƒAƒ“ƒJ[‚̏œ‹Ž
57- dd=obj.nextSibling.cloneNode(true);
55+ var dt=obj.cloneNode(true);
56+ var dtOuter=dt.outerHTML.replace(/name=.*?>/,">"); // LABELNUMBER‘Ήž‚Ì‚à‚Ì‚ÉŒW‚郊ƒ“ƒNƒAƒ“ƒJ[‚̏œ‹Ž
57+ var dd=obj.nextSibling.cloneNode(true);
5858 if(dd.hasChildNodes()){
5959 while(dd.lastChild.name){dd.lastChild.removeNode(true)} // LABELNUMBER”ñ‘Ήž‚Ì‚à‚Ì‚ÉŒW‚郊ƒ“ƒNƒAƒ“ƒJ[‚̏œ‹Ž
6060 if(dd.lastChild.tagName=="DL"){dd.lastChild.removeNode(true)} // ‹tŽQÆ‚̏œ‹Ž
6161 }
62- ddOuter=dd.outerHTML;
62+ var ddOuter=dd.outerHTML;
6363 return(dtOuter+ddOuter);
6464 }
6565 //Eƒ|ƒbƒvƒAƒbƒv
66+var pb;
6667 function popup(inner){
6768 if(!pb){document.body.insertAdjacentHTML('afterBegin','<div id="popupBase"></div>');pb=document.getElementById("popupBase")}
6869 //—v‘f‚̍쐬
6970 var parent=event.srcElement.parentElement;
70- var aNum= (parent.tagName!="DD") ? parent.firstChild.sourceIndex : parent.previousSibling.firstChild.innerText; // DDˆÈŠO–¼‘O—“A‰æ‘œAIDŒŸõ
71+ //var aNum= (parent.tagName!="DD") ? parent.firstChild.sourceIndex : parent.previousSibling.firstChild.innerText; // DDˆÈŠO–¼‘O—“A‰æ‘œAIDŒŸõ
72+ var aNum=event.srcElement.sourceIndex;if(!aNum){alert("aNumŽæ“¾ƒGƒ‰[")}
7173 if(document.getElementById('p'+aNum)){return} // ƒ|ƒbƒvƒAƒbƒv‚µ‚Ä‚½‚çI—¹
7274 pb.insertAdjacentHTML("beforeEnd",'<dl id="p'+aNum+'">'+inner+'</dl>');
7375 //—v‘f‚Ì”z’u
@@ -75,16 +77,16 @@ function popup(inner){
7577 // yŽ²’²®
7678 var pos=Math.min(event.y,document.body.clientHeight-event.y);
7779 var scTop=document.body.scrollTop+event.y;
78- if(pos==event.y){var y=scTop-30;} // ‰º
79- else {var y=scTop+10-p.clientHeight;} // ã
80+ if(pos==event.y){var y=scTop-30;} // ƒJ[ƒ\ƒ‹‚̉º‚Ö•\Ž¦
81+ else {var y=scTop+10-p.clientHeight;} // ƒJ[ƒ\ƒ‹‚̏ã‚Ö•\Ž¦
8082 if(y<0){y=0}
81- if(event.srcElement.parentElement.id=="foundResult"){y+=30}
83+ if(event.srcElement.parentElement.tagName=="TT"){y+=35;}
8284 p.style.pixelTop=y;
8385 // xŽ²’²®
8486 var pos=Math.min(event.x,document.body.clientWidth-event.x);
8587 var scLeft=document.body.scrollLeft+event.x;
86- if(pos==event.x){var x=scLeft-2} // ‰E
87- else {var x=scLeft-4-p.clientWidth;} // ¶
88+ if(pos==event.x){var x=scLeft-2} // ƒJ[ƒ\ƒ‹‚̉E‚Ö•\Ž¦
89+ else {var x=scLeft-4-p.clientWidth;} // ƒJ[ƒ\ƒ‹‚̍¶‚Ö•\Ž¦
8890 if(x<0){x=0}
8991 p.style.pixelLeft=x;
9092 // ‚‚³’²®iscrollBar‚ð—v‚·ê‡‚Æ—v‚µ‚È‚¢ê‡‚ª‚ ‚éj¨yŽ²’²®
--- a/res/skin/skin30-2G/chie_search.js
+++ b/res/skin/skin30-2G/chie_search.js
@@ -1,243 +1,398 @@
1-// “ú•t•¶Žš—ñ‚Ì’…FÝ’è@’…F‚·‚é:1@’…F‚µ‚È‚¢:0
2-coloring=1;
3-threshold1=[2,"#0000FF"]; // ‘‚«ž‚Ý‚ª•¡”‚ ‚éID ‚Ì‚µ‚«‚¢’l‚ƐF
4-threshold2=[5,"#FF0000"]; // ‘‚«ž‚Ý‚ª‘½”‚ ‚éID ‚Ì‚µ‚«‚¢’l‚ƐF
5-threshold3=[1,"#0000FF"]; // ‘‚«ž‚Ý‚ª‚ ‚é ƒŒƒX ‚Ì‚µ‚«‚¢’l‚ƃŒƒX”ԍ†‚̐F
6-threshold4=[4,"#FF0000"]; // ‘‚«ž‚Ý‚ª‘½”‚ ‚郌ƒX ‚Ì‚µ‚«‚¢’l‚ƃŒƒX”ԍ†‚̐F
7-// ƒCƒxƒ“ƒgƒnƒ“ƒhƒ‰FonClick
8-// ŠO•”ŠÖ”FaddAnchor,checkAnchor,tohan
9-// ŠO•”•Ï”FanchorHead,browser
10-// “Á’¥FƒCƒxƒ“ƒg”­¶DT‚ɑΉž‚·‚éDD‰º‚ɁADL-DT-DD\‘¢‚ðì¬‚·‚éB
1+beID=false; // be‚ɃƒOƒCƒ“o—ˆ‚éê‡‚́Atrue
2+//==========ŒŸõÝ’è
3+var expression="multiAND"; // ŒŸõ•û–@@@default:•W€AregExp:³‹K•\Œ»AmultiAnd:ANDŒŸõAmultiOR:ORŒŸõ
4+var searchView="resList"; // ŒŸõŒ‹‰Ê•\Ž¦@@resList:ŠY“–ƒŒƒX”ԍ†•\Ž¦AresPopup:ŠY“–ƒŒƒXƒ|ƒbƒvƒAƒbƒvA
5+var resultView=false; // ŒŸõŒ‹‰Ê‚̏펞•\Ž¦@@true:íŽž•\Ž¦Afalse:ƒ}ƒEƒX‚ŋ߂¯‚½‚Æ‚«‚Ì‚Ý•\Ž¦
6+var listLimit =10; // searchView‚ªresPopup‚Å‚È‚¢ê‡‚́AƒŒƒX”ԍ†‚Ì•\Ž¦§ŒÀ
7+//==========ƒŒƒX”ԍ†A“ú•t•¶Žš—ñ‚Ì’…FÝ’è
8+coloring=1; // ’…F‚·‚é:1@’…F‚µ‚È‚¢:0
9+threshold1=[2,"#0000ff"]; // ‘‚«ž‚Ý‚ª•¡”‚ ‚éID ‚Ì‚µ‚«‚¢’l‚ƐF
10+threshold2=[5,"#aaaa00"]; // ‘‚«ž‚Ý‚ª‘½”‚ ‚éID ‚Ì‚µ‚«‚¢’l‚ƐF
11+threshold3=[8,"#ff0000"]; // ‘‚«ž‚Ý‚ª‘½”‚ ‚éID ‚Ì‚µ‚«‚¢’l‚ƐF
12+threshold4=[1,"#0000FF"]; // ‘‚«ž‚Ý‚ª‚ ‚é ƒŒƒX ‚Ì‚µ‚«‚¢’l‚ƃŒƒX”ԍ†‚̐F
13+threshold5=[4,"#aaaa00"]; // ‘‚«ž‚Ý‚ª‘½”‚ ‚郌ƒX ‚Ì‚µ‚«‚¢’l‚ƃŒƒX”ԍ†‚̐F
14+threshold6=[7,"#ff0000"]; // ‘‚«ž‚Ý‚ª‘½”‚ ‚郌ƒX ‚Ì‚µ‚«‚¢’l‚ƃŒƒX”ԍ†‚̐F
15+//==========–¼‘OEIDŒŸõ‚É‚æ‚郌ƒX‚̑т̐FŽw’èi16i”–”‚ÍWebŒ`Ž®‚̐F–¼‚ÅŽw’èB‚¢‚­‚‚łà‰ÂBƒAƒ‹ƒtƒ@ƒxƒbƒg‚͏¬•¶Žš‚Å‚¨Šè‚¢j
16+var foundResColor =new Array("#ffdfee","#eeffdf","#ffeedf","#dfffee","#eedfff","#ffffe1");
17+//==========’PŒêŒŸõ‚É‚æ‚éƒnƒCƒ‰ƒCƒgFŽw’èi“¯ãj
18+var highlightColor=new Array("#ffff66","#a0ffff","#99ff99","#ff9999","#ff66ff","#880000","#00aa00","#886800","#004699","#990099");
19+//==========ˆÈ‰º‚̓XƒNƒŠƒvƒg–{•¶‚Å‚·‚æB
20+// ƒCƒxƒ“ƒgƒnƒ“ƒhƒ‰FonClick,onScroll,onMousemove
21+// ŠO•”ŠÖ”FaddAnchor,checkAnchor,tohan,searchPopup
22+// ŠO•”•Ï”FanchorHead,browser,fp
23+// ‹tŽQÆ‚Ì“Á’¥FƒCƒxƒ“ƒg”­¶DT‚ɑΉž‚·‚éDD‰º‚ɁADL-DT-DD\‘¢‚ðì¬‚·‚éB
1124 //==========CSS‚̏o—Í
1225 var nCSS='';
13-nCSS+='#foundResult{position:absolute;top:expression(body.scrollTop+25);right:18px;padding:2px 5px;z-index:6;background-color:white;border:1px solid #999}';
26+nCSS+='#foundPanel {position:absolute;top:expression(body.scrollTop+25);right:18px;padding:2px 5px;z-index:6;background-color:white;border:1px solid #999;visibility:hidden}';
27+nCSS+='#foundPanel div{padding-left:5px;text-align:right;font-size:100%;}';
1428 nCSS+='.refResult{margin:0.5em 0.3em; border:1px solid #666;padding-right:0px}';
1529 nCSS+='.refResult{border-top:none}';
1630 nCSS+='.refResult dt{margin-right:0px;}';
1731 nCSS+='.refResult dd{margin-left:0.8em;}';
1832 document.write('<style type="text/css">'+nCSS+'</style>\n');
19-//==========ŒŸõ‚É‚æ‚éFŽw’èi16i”–”‚ÍWebŒ`Ž®‚̐F–¼‚ÅŽw’èB‚¢‚­‚‚łà‰Âj
20-var foundColor = new Array("#ffdfee","#eeffdf","#ffeedf","#dfffee","#eedfff","#ffffe1");
2133 var nCSS='';
22-for(var css=0;css<foundColor.length;css++){
23- nCSS+='#COLOR'+css+" a{border-color:"+foundColor[css]+"}";
24- nCSS+='#COLOR'+css+" a:hover{border-color:red}";
34+for(var css in foundResColor){
35+ var c=foundResColor[css].replace(/#/,"");
36+ nCSS+='#COLOR'+c+" a{border-color:"+foundResColor[css]+"}\n";
37+ nCSS+='#COLOR'+c+" a:hover{border-color:red}\n";
2538 }
2639 document.write('<style type="text/css">'+nCSS+'</style>\n');
27-//==========ƒOƒ[ƒoƒ‹•Ï”
40+//=========ŠO•”ƒtƒ@ƒCƒ‹‹¤—p‚̃Oƒ[ƒoƒ‹•Ï”
2841 var dts=document.getElementsByTagName('DT');
2942 var dds=document.getElementsByTagName('DD');
30-var fR;
43+var idHash=new Array(); var refHash=new Array();
44+var foundRes,highlight;
3145 //==========ID‚ÆŽQÆ‚ðƒnƒbƒVƒ…‚ÉŠi”[
32-var idHash=new Array(); var refHash=new Array(); var searchEnd=0;
46+// ”z—ñ‚̃nƒbƒVƒ…‚æ‚èŒy‚¢‚Á‚Û‚¢‚̂ŁA‹ó”’‹æØ‚è‚Ì’l‚É‚æ‚é’Pƒ‚ȃnƒbƒVƒ…‚É‚µ‚Ä‚Ý‚éƒeƒXƒgB
47+// setEndIdx:–{•¶‚Ì“¯ƒŒƒX‚ðd•¡ˆ—‚µ‚È‚¢‚悤‚ɁAHash‰»ˆÊ’u‚Æ‚µ‚Ä‚Ìdts‚̍ŏIindex‚ð‹L‰¯
48+// setEndNum:–{•¶ˆÈŠOƒŒƒX‚ðd•¡ˆ—‚µ‚È‚¢‚悤‚ɁAÅIƒŒƒX”ԍ†‚ð‹L‰¯
49+var setEndIdx=setEndNum=0;
3350 function setHash(){
34- var l=dts.length;
35- if(dts[l-1].rel=="setEnd"){return} // ÅŒã‚Ü‚Å’²¸Ï‚Ý‚È‚ç‰ñ”ð
36- for(var i=searchEnd;i<l;i++){
51+ //var t0=new Date();
52+ var l=Math.min(dts.length,dds.length);
53+ var lastNum=l ? parseInt(dts[l-1].firstChild.innerText) : 0;
54+ if(isNaN(lastNum)&&l>1){lastNum=parseInt(dts[l-2].firstChild.innerText)} //Footer‚ ‚è‚È‚çˆê‚‘O
55+ if(l==0 || lastNum<=setEndNum){return} // ÅŒã‚Ü‚Å’²¸Ï‚Ý‚È‚ç‰ñ”ð
56+ for(var i=setEndIdx;i<l;i++){
3757 if(dds[i].parentElement.className=="refResult"){continue} // ‹tŽQÆ“à‚ÌDD‚È‚ç‰ñ”ð
3858 var num=dts[i].firstChild.innerText; var span=dts[i].lastChild;
3959 // ID
40- var t=getID(span); idHash[t] = idHash[t] ? idHash[t]+" "+num : num;
41- // ref
60+ var t=getID(span); if(t&&t.length>3){idHash[t] = idHash[t] ? idHash[t]+" "+num : num;} // ???‚âID:0,ID:#(@ƒ]ƒk)‚̓Xƒ‹[B
61+ // ‰æ‘œ”Â
62+ var imgURL=getIMG(span);
63+ if(imgURL){
64+ var dd=dts[i].nextSibling;
65+ if(tp && imgURL && !dd.getElementsByTagName("IMG").length){
66+ var aObj=(dd.innerText)?'<br><a href="'+imgURL+'">'+imgURL+'</a>':'<a href="'+imgURL+'">'+imgURL+'</a>';
67+ if(!beID && imgURL.match(/kako/)){/*dd.insertAdjacentHTML("beforeEnd","<br>Be‚ɃƒOƒCƒ“‚µ‚Ä‚È‚¢‚Ǝ擾‚Å‚«‚Ü‚¹‚ñ");*/}else{dd.insertAdjacentHTML("beforeEnd",aObj)}
68+ }
69+ }
70+ // ref,IMG
4271 var ddAnc=dds[i].getElementsByTagName("A");
43- for(var j=ddAnc.length;j--;){
44- if(checkAnchor(ddAnc[j].href)!=1){continue}
45- var anc=tohan(ddAnc[j].innerText.replace(/[>„]/g,""));
46- if(anc.match(/(\d*)\D+(\d*)/)){
47- var start=parseInt(RegExp.$1); var end=parseInt(RegExp.$2);
48- if(end-start>100){continue} // >>1-1000‚Æ‚©‚͉ؗí‚ɃXƒ‹[
49- else if(num-end<3 && start==1){continue} // >>1-n(’¼‘OƒŒƒX)‚ÍŽ‚Ë,‚Æ‚©‚àƒXƒ‹[
50- for(var k=start;k<=end;k++){
51- if(refHash[k] && refHash[k].indexOf(num)!=-1){continue} // d•¡‚̓Xƒ‹[
52- if(num>=k){refHash[k]=refHash[k] ? refHash[k]+" "+num : num;} // –¢—ˆ‚ւ̃Aƒ“ƒJ[‚̓Xƒ‹[
72+ for(var j=0;j<ddAnc.length;j++){
73+ if (checkAnchor(ddAnc[j].href)==0){
74+ continue;
75+ }else if(checkAnchor(ddAnc[j].href)==1){
76+ var anc=tohan(ddAnc[j].innerText.replace(/[>„]/g,""));var start,end;
77+ if(anc.match(/(\d*)\D+(\d*)/)){
78+ start=parseInt(RegExp.$1); end=parseInt(RegExp.$2);
79+ if( (end-start>100) || (num-end<4 && start==1) ){continue} // >>1-1000‚Æ‚©>>1-n(’¼‘OƒŒƒX)‚Æ‚©‚͉ؗí‚ɃXƒ‹[
80+ }else{
81+ start=end=parseInt(anc);
5382 }
54- }else{anc=parseInt(anc);
55- if(refHash[anc] && refHash[anc].indexOf(num)!=-1){continue} // d•¡‚̓Xƒ‹[
56- if(num>=anc){refHash[anc]=refHash[anc] ? refHash[anc]+" "+num : num;} // –¢—ˆ‚ւ̃Aƒ“ƒJ[‚̓Xƒ‹[
83+ var k=start-1;do{k++;
84+ if((!refHash[k] || refHash[k].indexOf(num)==-1) && num>k){refHash[k]=refHash[k] ? refHash[k]+" "+num : num;} // d•¡‚â–¢—ˆ‚ւ̃Aƒ“ƒJ[‚̓Xƒ‹[
85+ }while(k<end);
86+ }else if(imageExt2(ddAnc[j].href) && onOpenLoad!=0){
87+ if(onOpenLoad==1){if(dds[i].previousSibling.className!="new"){continue}}
88+ insButton(ddAnc[j],ddAnc[j].href);
5789 }
5890 }
5991 }
60- dts[l-1].rel="setEnd"; searchEnd=l;
92+ setEndIdx=l;setEndNum=lastNum;
93+ //var t1=new Date(); var t=(t1-t0)/1000; if(t){alert(t+"•b");}
94+}
95+// ƒXƒŒƒbƒhƒEƒBƒ“ƒhƒE’†S‚É‘OŒã5ƒŒƒX‚𒅐F
96+var resUnit=new Array();
97+function searchColoring(){
6198 if(!coloring){return;} // ’…F•s—v‚È‚çI—¹
62- for(var i=l;i--;){
63- if(!dts[i].innerText){continue}
64- //if(dts[i].innerText.match(/id:/i)){ // ID‚ª‚È‚¢”‚ŁA‚‘¬‰»‚·‚é‚©‚àH
65- var span=dts[i].lastChild; var t=getID(span); if(browser=="ƒzƒbƒgƒ]ƒk‚Q"){span=span.lastChild}
66- if(t && idHash[t] && span){
67- var idResult=idHash[t].split(/\s/); if(t.match(/\?\?\?/)){idResult="";idHash[t]="";}
68- if (idResult.length>=threshold2[0]){span.style.color=threshold2[1];span.title="“¯ˆêID ("+idResult.length+"‰ñ)\n"+idHash[t]}
69- else if(idResult.length>=threshold1[0]){span.style.color=threshold1[1];span.title="“¯ˆêID ("+idResult.length+"‰ñ)\n"+idHash[t]}
70- else if(idResult.length==1){span.title="“¯ˆêID‚Í\n‚ ‚è‚Ü‚¹‚ñ"}
71- }
72- //}
73- var imgURL=getIMG(span);
74- if(imgURL){dds[i].insertAdjacentHTML("afterBegin",'<img src="'+imgURL+'"><br>')}
75- //
76- var numA=dts[i].firstChild; var num=numA.innerText;
77- if(refHash[num]){
78- var refResult=refHash[num].split(/\s/);
79- if (refResult.length>=threshold4[0]){numA.style.color=threshold4[1];dts[i].title="‚±‚ê‚ւ̃ŒƒX ("+refResult.length+"ŒÂ)\n"+refHash[num];}
80- else if(refResult.length>=threshold3[0]){numA.style.color=threshold3[1];dts[i].title="‚±‚ê‚ւ̃ŒƒX ("+refResult.length+"ŒÂ)\n"+refHash[num];}
81- else{numA.title="‚±‚ê‚ւ̃ŒƒX‚Í‚È‚¢–Í—l"}
99+ if(!scr){scr=lightmode ? document.body : document.getElementById("dl");}
100+ var nowScrollPos=scr.scrollTop+document.body.clientHeight/2;
101+ var l=Math.min(dts.length,dds.length);var st,ed;
102+ // dt‚ÌoffsetTop‚ðŠi”[i25ƒŒƒX’PˆÊj
103+ if(resUnit.length<=Math.floor(dts.length/25)){resUnit[0]=0;
104+ for(var i=25;i<l;i+=25){resUnit[i/25]=dts[i].offsetTop;}
105+ }
106+ // Œ»Ý‚Ç‚Ì‚ ‚½‚è‚܂ŃXƒNƒ[ƒ‹‚µ‚Ä‚é‚©’²¸
107+ var rul=resUnit.length-1;
108+ if (rul==0) {st=0;ed=l-1;} //25–¢–ž
109+ else if(resUnit[0]>nowScrollPos) {st=0;ed=24;} //0-24
110+ else if(resUnit[rul]<nowScrollPos){st=l-26;ed=l-1;} // ÅI25ƒŒƒX
111+ else{
112+ for(var i=rul;i--;){
113+ if(resUnit[i+1]>nowScrollPos&&resUnit[i]<=nowScrollPos){st=i*25;ed=st+25;break}
82114 }
83115 }
84-}
85-var regIMG=new RegExp(".*?\\s.*?\\s.*:.*?\\sIMG:(.*?)(\\s|$)"); // ‰æ‘œ‚à‰Â”\‚É‚µ‚Ä‚Ý‚é
86-function getIMG(obj){
87- if(regIMG.test(obj.innerText)){
88- var filename=RegExp.$1;
89- var tmp=filename.match(/(\d\d\d\d)(\d\d\d\d)(\d\d)/);
90- var fileurl="http://up01.2ch.io/_img/"+RegExp.$1+"/"+RegExp.$1+RegExp.$2+"/"+RegExp.$3+"/"+filename;
91- return(fileurl)
92- }else{return(false)}
93-}
94-//==========–¼‘OEIDŒŸõ“™
95-// ID‚ÌŒŸõEíœ
96-function searchID(obj){
97- var singleColor=event.altKey;
98- var decoy=obj.parentElement ? obj.parentElement : obj;
99- var reg=getID(obj);
100- if(!decoy.id.match(/^COLOR/)){
101- if(!idHash[reg]){return}
102- var target=new Array();target=idHash[reg].split(" ");
103- // ƒJƒ‰[‘I‘ð
104- var c = singleColor ? 0 : selectColor();
105- if (c=="restart"){c=0;singleColor=true}
106- else if(c=="exit"){return;}
107- // ŒŸõ
108- for(i in target){var dt=getDTfromAnc(target[i]);activate(dt,c);}
109- foundReturn(target);
110- }else{
111- clearResult(obj);return;
116+ // Œ»Ý‚Ì”ÍˆÍ“à‚©‚çƒEƒBƒ“ƒhƒE‚̐^‚ñ’†‚ ‚½‚è‚É•\Ž¦‚µ‚Ă郌ƒX‚ðŽæ“¾i‚±‚±‚Å’…F‚·‚é‚ƁA25ƒŒƒX’PˆÊ‚̐ؑ֎ž‚ɐ”ƒŒƒX‚ª’…F‚³‚ê‚È‚¢j
117+ var dtIdx=0; //if(cp){cp.childNodes[1].value=(st+1)+"-"+(ed+1);cp.style.visibility="visible";}
118+ for(var i=st;i<=ed;i++){if(!dts[i+1]){dtIdx=ed;break;}
119+ if(dts[i+1].offsetTop>nowScrollPos && dts[i].offsetTop<=nowScrollPos){dtIdx=i;break;}
120+ }
121+ // dtIdx‚©‚ç‚»‚ÌŽü•Ó‚ð“Á’è
122+ var start=dtIdx-5;var end=dtIdx+5;//
123+ for(var i=start;i<=end;i++){
124+ if(dts[i]){setSearchColor(dts[i])}
112125 }
113126 }
114-// IDƒ|ƒbƒvƒAƒbƒv
115-function searchPopup(obj){
116- var objs=document.getElementsByTagName(obj.tagName);
117- var reg=getID(obj);if(!reg){return}
118- var target=idHash[reg].split(" ");
119- if(target.length==1){return}
120- if(!obj.rel){obj.rel=obj.href;} obj.href="decoy:";
121- var targetString=""; for(i in target){targetString+=returnString(target[i])} //’†g‚̐؂èo‚µ
122- if(targetString){popup(targetString);}else{obj.href=obj.rel;} //‘Ώۂª‘¶Ý‚µ‚½‚çrel‚É‘Þ”ð‚µ‚Äƒ|ƒbƒvƒAƒbƒv
127+// IDHashArefHash‚ðŒ³‚É’…F
128+function setSearchColor(dt){
129+ if(!dt.innerText){return}
130+ // ID
131+ var span=dt.lastChild; var t=getID(span);//alert(t +"&&"+ idHash[t] +"&&"+ span);
132+ if (browser=="ƒzƒbƒgƒ]ƒk‚Q"){span=span.lastChild}
133+ else if(browser=="A Bone") {span=span.childNodes[1]}
134+ if(t && idHash[t] && span){
135+ var idResult=idHash[t].split(" "); if(t.match(/\?\?\?/)){idResult="";idHash[t]="";}
136+ if (idResult.length>=threshold3[0]){span.style.color=threshold3[1];span.title="“¯ˆêID ("+idResult.length+"‰ñ)\n"+idHash[t]}
137+ else if(idResult.length>=threshold2[0]){span.style.color=threshold2[1];span.title="“¯ˆêID ("+idResult.length+"‰ñ)\n"+idHash[t]}
138+ else if(idResult.length>=threshold1[0]){span.style.color=threshold1[1];span.title="“¯ˆêID ("+idResult.length+"‰ñ)\n"+idHash[t]}
139+ else if(idResult.length==1){span.title="“¯ˆêID‚Í\n‚ ‚è‚Ü‚¹‚ñ"}
140+ }
141+ // ref
142+ var numA=dt.firstChild; var num=numA.innerText;
143+ if(refHash[num]){
144+ var refResult=refHash[num].split(" ");
145+ if (refResult.length>=threshold6[0]){numA.style.color=threshold6[1];dt.title="‚±‚ê‚ւ̃ŒƒX ("+refResult.length+"ŒÂ)\n"+refHash[num];}
146+ else if(refResult.length>=threshold5[0]){numA.style.color=threshold5[1];dt.title="‚±‚ê‚ւ̃ŒƒX ("+refResult.length+"ŒÂ)\n"+refHash[num];}
147+ else if(refResult.length>=threshold4[0]){numA.style.color=threshold4[1];dt.title="‚±‚ê‚ւ̃ŒƒX ("+refResult.length+"ŒÂ)\n"+refHash[num];}
148+ else{numA.title="‚±‚ê‚ւ̃ŒƒX‚Í‚È‚¢–Í—l"}
149+ }
123150 }
124-// –¼‘O‚ÌŒŸõEíœ
125-function search(obj){
126- var singleColor=event.altKey;
127- var objs=document.getElementsByTagName(obj.tagName);
128- var reg=obj.innerText; var target="objs[i].innerText"; //–¼‘OEƒgƒŠƒbƒv
129- var decoy=obj.parentElement ? obj.parentElement : obj;
130- if(!decoy.id.match(/^COLOR/)){
131- // ƒJƒ‰[‘I‘ð
132- var c = singleColor ? 0 : selectColor();
133- if (c=="restart"){c=0;singleColor=true}
134- else if(c=="exit"){return;}
135- // ŒŸõ
136- var found=new Array; var l=objs.length;
137- for(var i=l;i--;){
138- var dt=objs[i].parentElement; if(dt.parentElement.className=="refResult"){continue} // ‹tŽQÆ“à‚ÌDT‚È‚ç‰ñ”ð
139- if(eval(target)==reg){activate(dt,c);found.unshift(dt.firstChild.innerText);}
140- else if(singleColor) {deactivate(dt)}
151+//==========–¼‘OEIDŒŸõ“™
152+function searchPerson(obj){
153+ var by,thisDT,reg;
154+ if (obj.tagName=="DT") {by="ID"; thisDT=obj; reg=getID(obj)}
155+ else if(obj.tagName=="SPAN"){by="ID"; thisDT=obj.parentElement;reg=getID(obj)}
156+ else if(obj.tagName=="U") {by="NAME";thisDT=obj.parentElement; reg=obj.innerHTML.replace(/<B>(.*?)<\/B>/ig,"");if(!reg){reg=RegExp.$1.replace(/<.*?A.*?>/ig,"")}/*–¼‘O‚ª”Žš*/}
157+ else if(obj.tagName=="B") {by="NAME";thisDT=obj.parentElement.parentElement;reg=obj.innerText}
158+ else{return}
159+ if(!thisDT.rel){
160+ var c=selectColor("res"); if(!c){return} var color=new Array(c); // ƒJƒ‰[‘I‘ð
161+ if(by=="ID"){
162+ if(!reg || !idHash[reg]){return} // ID‚È‚µAID:???A–{•¶’†‚Ì‘¼ƒXƒŒ‚̃RƒsƒyID
163+ // ŒŸõƒnƒbƒVƒ…‚É’l‚ðÝ’肵‚āA‚»‚ê‚ÉŠî‚«ƒŒƒX’…F
164+ foundRes[c]=idHash[reg].split(" "); foundRes[c].word="ID:"+reg;
165+ for(i in foundRes[c]){var dt=getDTfromAnc(foundRes[c][i]);toggleResColor(dt,c);}
166+ }else{
167+ var us=document.getElementsByTagName("U"); var l=us.length;
168+ var regName=new RegExp();regName.compile(reg);
169+ // ƒ‹[ƒv’†‚ɃŒƒX’…FE’l‚̐ݒè‚𓯎žŽÀs
170+ for(var i=l;i--;){var dt=us[i].parentElement;
171+ if(dt.parentElement.className=="refResult"){continue} // ‹tŽQÆ“à‚ÌDT‚È‚ç‰ñ”ð
172+ if(regName.test(us[i].innerText)){toggleResColor(dt,c);foundRes[c].unshift(dt.firstChild.innerText);}
173+ }
174+ foundRes[c].word=reg;
141175 }
142- foundReturn(found);
176+ returnFound("res",color);
143177 }else{
144- clearResult(obj);return;
178+ clearColor("res",thisDT.style.backgroundColor);
145179 }
146180 }
147-
148181 // ID•¶Žš—ñ‚Ì’Šo
149-//var regID=new RegExp("ID:(.*)$");
150-var regID=new RegExp(".*?\\s.*?\\s.*:(.*?)(\\s|$)"); // HOST‚â‚炵‚½‚ç‚΂à‰Â”\‚É‚µ‚Ä‚Ý‚é
151-function getID(obj){
152- if(regID.test(obj.innerText)){return(RegExp.$1)}else{return(false)}
182+var regID=new RegExp(); // HOST‚à‰Â”\‚É‚µ‚Ä‚Ý‚é
183+regID.compile(".*?\\s.*?\\s.*:(.*?)(\\s|$)"); // 1000res‚Å0.02•b‚قǍ‚‘¬
184+function getID(span){
185+ if(regID.test(span.innerText)){return(RegExp.$1)}else{return(false)}
153186 }
154-// FÝ’è
155-function activate(obj,c){
156- var color=foundColor[c];
157- obj.rev=obj.style.backgroundColor;
158- obj.style.backgroundColor=color;
159- obj.id="COLOR"+c; // “¯ˆêid‚ª•¡”¶‚¶‚邪ByName‚Å‚Ídt‚Ìname‚©‚çŽæ“¾‚Å‚«‚È‚¢‚½‚ß‚â‚Þ‚È‚µ
187+//==========FÝ’è‰ðœ
188+// ƒIƒuƒWƒFƒNƒg‚̏‰Šú‰»
189+function createHash(name,key,arr,word){
190+ name[key]=arr?arr:new Array();
191+ name[key].word=word?word:"";
192+ name[key].justMovedRes=undefined;
160193 }
161-// F•œ‹A
162-function deactivate(obj){if(!obj){return}
163- obj.style.backgroundColor=obj.rev;
164- if(obj.id!="sizeinfo"){obj.removeAttribute("id");}
165- obj.removeAttribute("rev");
166- obj.removeAttribute("title");
194+// F‘I‘ð(ŠY“–ƒŒƒX”ԍ†”z—ñ‚ðŽ‚½‚È‚¢ƒL[‚ð•Ô‚·)
195+function selectColor(type){
196+ if(!foundRes) {foundRes =new Array();for(var i in foundResColor) {createHash(foundRes,foundResColor[i]);}} // Hash foundRes ={F:ŠY“–ƒŒƒX”ԍ†”z—ñ}
197+ if(!highlight){highlight=new Array();for(var i in highlightColor){createHash(highlight,highlightColor[i]);}} // Hash hightLight={F:ŠY“–ƒŒƒX”ԍ†”z—ñ}
198+ var cHash,cArray,cMess;
199+ if(type=="res"){cHash=foundRes; cArray=foundResColor; cMess="¡‚܂ł̃ŒƒX’…F‚ð‰ðœ‚µ‚Ü‚·‚©H";}
200+ else {cHash=highlight;cArray=highlightColor;cMess="¡‚܂ł̃nƒCƒ‰ƒCƒg‚ð‰ðœ‚µ‚Ü‚·‚©H";}
201+ var i=0; while(cHash[cArray[i]].word){
202+ i++; if(i==cArray.length){if(confirm(cMess)){clearColor(type);i=0;break}else{i=null;break}}
203+ }
204+ return(cArray[i]);
167205 }
168-// ƒJƒ‰[‘I‘ð
169-function selectColor(){
170- var c=0;
171- while(document.getElementById("COLOR"+c)){
172- c++;
173- if(!foundColor[c]){if(confirm("F‚ð‰Šú‰»‚µ‚Ü‚·‚©H")){return("restart")}else{return("exit")}}
206+// F‰ðœiƒnƒbƒVƒ…A‘ΏہAfoundPanelj
207+function clearColor(type,color){
208+ var cHash=(type=="res")?foundRes:highlight;
209+ if(event && event.altKey){color=""}
210+ for(var i in cHash){
211+ if(type=="res"){
212+ if(color && i!=color){continue} // Žw’èF‚Å‚È‚¯‚ê‚΃Xƒ‹[
213+ for(var j in cHash[i]){
214+ if(event.srcElement.value=="DEL"){removeRes(getDTfromAnc(cHash[i][j]))}else{toggleResColor(getDTfromAnc(cHash[i][j]))}
215+ }
216+ cHash[i]=new Array();
217+ document.getElementById("c"+i).removeNode(true);
218+ }else{
219+ var strongs=document.getElementsByTagName("STRONG");
220+ var reg=new RegExp(i);
221+ if(!color.match(i)){continue} // Žw’èF‚Å‚È‚¯‚ê‚΃Xƒ‹[
222+ for(var j=0;j<strongs.length;j++){
223+ if(strongs[j].style.backgroundColor==i){
224+ if(event.srcElement.value=="DEL"){removeRes(strongs[j].parentElement.previousSibling);j--}else{strongs[j].removeNode(false);j--}
225+ }
226+ }
227+ cHash[i]=new Array();
228+ if(document.getElementById("c"+i)){document.getElementById("c"+i).removeNode(true);} // and,orŒŸõ‚Å‚PF–Ú‚Ì‚Ý
229+ }
174230 }
175- return(c);
231+ if(!fp.hasChildNodes()){fp.style.visibility="hidden";searched=false;}
176232 }
177-// Œ‹‰Ê•\Ž¦
178-function foundReturn(found){
179- if(!fR){document.body.insertAdjacentHTML('afterBegin','<div id="foundResult"></div>');fR=document.getElementById("foundResult");}
180- //dt‚Ìtitle‚É
181- for(var i=found.length;i--;){dt=getDTfromAnc(found[i]);dt.title=found.join(" ");}
182- //foundResult‚É
183- var buttons='<input type="button" value="CLR" onclick="clearResult(this)" title="Alt‰Ÿ‰ºŽž\n’…FƒŒƒX‘S‚Ä"><input type="button" value="DEL" onclick="clearResult(this)" title="Alt‰Ÿ‰ºŽž\n’…FƒŒƒX‘S‚Ä">';
184- if(found.length>=20 && confirm("20ˆÈã‚ ‚邯‚Ç•\Ž¦‚·‚éH")==false){
185- fR.innerHTML=buttons; fR.title=found.join(" ");
233+// ƒŒƒXFƒgƒOƒ‹
234+function toggleResColor(dt,c){
235+ if(!dt){return} // for-in‚Å‘—‚ç‚ê‚é”ԍ†ˆÈŠO‚Ìobj‚È‚çI—¹
236+ if(c){
237+ dt.rev=dt.style.backgroundColor;
238+ dt.rel="colored";
239+ dt.id ="COLOR"+c.replace(/#/,"");
240+ dt.style.backgroundColor=c;
186241 }else{
187- for(var i=0;i<found.length;i++){found[i] = addAnchor(found[i],found[i])}
188- fR.innerHTML=found.join(" ")+buttons;
242+ dt.style.backgroundColor=dt.rev;
243+ if(dt.id.match(/COLOR/)){dt.removeAttribute("id")}//else{alert("dt‚ÉCOLOR***ˆÈŠO‚Ìidi"+dt.id+"j‚ªÝ’肳‚ê‚Ä‚¢‚Ü‚·")}
244+ dt.removeAttribute("rev");
245+ dt.removeAttribute("rel");
189246 }
190- fR.style.visibility="visible";
191247 }
192-// Œ‹‰ÊÁ‹ŽAŒ‹‰Êíœ
193-function clearResult(obj){
194- var fromObj=obj.parentElement;
195- var singleColor=event.altKey;
196- var result=new Array();var arrayElement; var numbers=fromObj.title ? fromObj.title : fromObj.innerText;
197- if(singleColor){result=dts; arrayElement="result[i]";}
198- else {result=numbers.split(" ");arrayElement="getDTfromAnc(result[i])";}
199- var l=result.length;
200- if(!result[0]){
201- /* ŒŸõŒ‹‰Êƒ[ƒ‚Å‚àresult‚ªnull‚É‚È‚ç‚È‚¢‘΍ô */
202- }else if(event.srcElement.value!="DEL"){
203- for(var i=l;i--;){
204- var dt=eval(arrayElement);
205- deactivate(dt);
206- }
248+// ŒŸõŒ‹‰Ê‚ÉŠî‚«Á‹Ž
249+function removeRes(dt){if(!dt){return} // cHash[i][j]=ID:xxxxxxxx‚Ì‚Æ‚«
250+ if(browser=="Live2ch"){location.href='func:ABONECLEAR?'+dt.firstChild.innerText;} // Live‚Ì‚Ý-“§–¾‚ ‚ځ`‚ñ
251+ dt.nextSibling.removeNode(true);dt.removeNode(true);
252+}
253+//==========Œ‹‰Ê•\Ž¦
254+// ƒŒƒX”ԍ†ƒŠƒXƒgiƒ|ƒbƒvƒAƒbƒvƒAƒ“ƒJ[‚ðŠÜ‚ށj
255+function returnFound(type,color){
256+ var cHash=(type=="res")?foundRes:highlight;
257+ var nDIV="";var numArray=cHash[color[0]]; var display=new Array(["none","POP"],["inline","LST"]);
258+ if(searchView=="resPopup" || numArray.length>=listLimit){display=display.reverse();}
259+ // ƒ|ƒbƒvƒAƒbƒv
260+ var nTT="";for(var i=0;i<color.length;i++){nTT+='<tt style="background-color:'+color[i]+'"> '+cHash[color[i]].word+'</tt>';}
261+ nDIV+='<span rel="'+type+'" style="display:'+display[0][0]+'">'+nTT+'</span>';
262+ // ƒŠƒXƒg
263+ var nA="";for(var i=0;i<numArray.length;i++){nA+=addAnchor(numArray[i],numArray[i])+" "}
264+ nDIV+='<tt style="background-color:'+color[0]+'" style="display:'+display[1][0]+'"> '+nA+'</tt>';
265+ // ŒÂ”
266+ nDIV+='&nbsp;'+numArray.length+' ';
267+ var buttons='<input type="button" value="'+display[0][1]+'" onclick="changeSearchView();blur()"><input type="button" value="É" onclick="moveToSearchRes(\''+type+'\',\''+color+'\')" title="‰º‚ÖŒŸõ"><input type="button" value="È" onclick="moveToSearchRes(\''+type+'\',\''+color+'\')" title="ã‚ÖŒŸõ"><input type="button" value="CLR" onclick="clearColor(\''+type+'\',\''+color+'\')" title="Alt‰Ÿ‰ºŽž\n’…FƒŒƒX‘S‚Ä"><input type="button" value="DEL" onclick="clearColor(\''+type+'\',\''+color+'\')" title="Alt‰Ÿ‰ºŽž\n’…FƒŒƒX‘S‚Ä">';
268+ fp.innerHTML+='<div id="c'+color[0]+'">'+nDIV+buttons+'</div>';
269+ fp.style.visibility="visible";searched=true;
270+}
271+// ‘ΏۃŒƒX‚ɃWƒƒƒ“ƒv
272+var markedDT;
273+function moveToSearchRes(type,color){
274+ if(color.match(/(.*?),/)){color=RegExp.$1}
275+ var scope = (event && event.srcElement.value=="È") ? false : true ;
276+ var numArray= (type=="res") ? foundRes[color] : highlight[color];
277+ if(isNaN(numArray.justMovedRes)){numArray.justMovedRes=0}
278+ else{
279+ markedDT.style.borderColor="#999";
280+ if(scope){numArray.justMovedRes++;if(numArray.justMovedRes>=numArray.length){numArray.justMovedRes--;alert("‚±‚ê‚æ‚艺‚É‚Í‚ ‚è‚Ü‚¹‚ñ")}}
281+ else {numArray.justMovedRes--;if(numArray.justMovedRes<0){numArray.justMovedRes++;alert("‚±‚ê‚æ‚èã‚É‚Í‚ ‚è‚Ü‚¹‚ñ")}}
282+ }
283+ markedDT=getDTfromAnc(numArray[numArray.justMovedRes]); markedDT.style.borderColor="red";
284+ markedDT.scrollIntoView(true);
285+ setTimeout('markedDT.style.borderColor="#999"',5000);
286+}
287+// ƒ|ƒbƒvƒAƒbƒv‚ƃŠƒXƒg•\Ž¦Ø‚è‘Ö‚¦
288+function changeSearchView(){
289+ var e=event.srcElement;
290+ if(e.value=="POP"){
291+ e.value="LST";
292+ e.parentElement.childNodes[0].style.display="inline";
293+ e.parentElement.childNodes[1].style.display="none";
207294 }else{
208- for(var i=l;i--;){
209- var dt=eval(arrayElement); var dd=dt.nextSibling;
210- //Live‹@”\’ljÁ - “§–¾‚ ‚ځ`‚ñ
211- if(browser=="Live2ch"){location.href='func:ABONECLEAR?'+dt.firstChild.innerText;}
212- dt.removeNode(true); dd.removeNode(true);
213- }
295+ e.value="POP";
296+ e.parentElement.childNodes[0].style.display="none";
297+ e.parentElement.childNodes[1].style.display="inline";
214298 }
215- if(fR){fR.innerText="";fR.style.visibility="hidden";}
216299 }
217300
218301 //==========’PŒêŒŸõ
219-function findIt(word){
220- if(!word){
221- var word = prompt("ŒŸõ‚·‚镶Žš‚ð“ü—Í‚µ‚Ä‚­‚¾‚³‚¢B","");
222- word = unescape(escape(word).split("%00")[0]); //IE5‚̃oƒO‘΍ô
302+function findIt(arg){createSearchPanel(arg);}
303+var searchWindow=null;
304+// ŒŸõƒEƒBƒ“ƒhƒE‚Ì•\Ž¦
305+function createSearchPanel(arg){ // ê—pƒuƒ‰ƒEƒU‚Å‚ÌmodelessDialog‚Ö‚ÌŠO•”“ǂݍž‚݂ł́AdialogArguments‚ª‘—‚ê‚È‚¢‚Ì‚Å’¼Ú‘‚«o‚·
306+ if(arg){word=arg}
307+ if(searchWindow && !searchWindow.closed){return}
308+ var skinPath=document.getElementsByName("SkinPath")[0].content;
309+ searchWindow=showModelessDialog("",window,'dialogWidth:500px;dialogHeight:200px;dialogTop:0px;dialogLeft:0px;help:no;resizable:yes;status:no;unadorned:yes;');
310+ var nWin='<html><head><title>’PŒê‚ÌŒŸõ<\/title>'
311+ +'<script type="text/javascript">function submitEvent(){var fo=document.forms[0]; dialogArguments.word=fo.word.value; var i=-1;do{i++;dialogArguments.expression =fo.expression[i].value;}while(!fo.expression[i].checked); var i=0; while(fo.searchTarget[i]){dialogArguments.searchTarget[fo.searchTarget[i].value]=fo.searchTarget[i].checked;i++;} var i=-1;do{i++;dialogArguments.searchView =fo.searchView[i].value;}while(!fo.searchView[i].checked); dialogArguments.searchWord();}</script>'
312+ +'<style type="text/css">body{background:ThreeDFace;padding:0.5em;overflow:auto} fieldset{padding:0.5em;margin-top:0.5em;} legend,label,input{font:message-box;}</style>'
313+ +'<\/head><body onunload="unloadEvent()"><form onsubmit="submitEvent();return false;"><table width="100%"><tr><td valign="top" colspan="3">'
314+ +'<label for="word">ŒŸõ•¶Žš—ñF</label><input type="text" name="word" id="word" size="50" value="'+word+'" tabindex="0"><br>'
315+ +'</td><td align="right" valign="top" rowspan="2">'
316+ +'<input type="submit" name="submit" value="@ŒŸ@õ@" tabindex="7"><br><br><input type="button" name="cancel" value="ƒLƒƒƒ“ƒZƒ‹" onclick="window.close()" tabindex="8">'
317+ +'</td></tr><tr valign="top">'
318+ +'<td><fieldset><legend>ŒŸõ•û–@</legend><input type="radio" name="expression" value="default" id="tDef" tabindex="1"> <label for="tDef">’ʏ팟õ</label><br><input type="radio" name="expression" value="regExp" id="tReg"> <label for="tReg">³‹K•\Œ»</label><br><input type="radio" name="expression" value="multiAND" id="tAND"> <label for="tAND">ANDŒŸõ</label><br><input type="radio" name="expression" value="multiOR" id="tOR"> <label for="tOR">ORŒŸõ</label></fieldset></td>'
319+ +'<td><fieldset><legend>ŒŸõ‘ΏÛ</legend><input type="checkbox" name="searchTarget" value="name" id="tName" tabindex="2" checked> <label for="tName">–¼‘O</label><br><input type="checkbox" name="searchTarget" value="mail" id="tMail" tabindex="3" checked> <label for="tMail">ƒ[ƒ‹</label><br><input type="checkbox" name="searchTarget" value="id" id="tID" tabindex="4" checked> <label for="tID">“ú•t‚ÆID</label><br><input type="checkbox" name="searchTarget" value="mess" id="tMess" tabindex="5" checked> <label for="tMess">–{•¶</label></fieldset></td>'
320+ +'<td><fieldset><legend>Œ‹‰Ê•\Ž¦</legend><input type="radio" name="searchView" value="resList" id="rList" tabindex="6"> <label for="rList">ƒŒƒX”ԍ†‚ð•\Ž¦</label><br><input type="radio" name="searchView" value="resPopup" id="rPop"> <label for="rPop">ƒŒƒX‚ðƒ|ƒbƒvƒAƒbƒv</label><br><input type="radio" name="searchView" value="resJump" id="rJump"> <label for="rJump">ƒŒƒX‚ÖƒWƒƒƒ“ƒv</label></fieldset></td>'
321+ +'</tr></table></form><\/body><\/html>';
322+ searchWindow.document.write(nWin);
323+ sdf=searchWindow.document.forms[0]; sdf.elements[0].select();
324+ var ex=sdf.expression;for(var i=0;i<ex.length;i++){if(ex[i].value==expression){ex[i].checked=true}}
325+ var sv=sdf.searchView;for(var i=0;i<sv.length;i++){if(sv[i].value==searchView){sv[i].checked=true}}
326+ range=document.body.createTextRange();
327+}
328+// ŒŸõˆ—ƒƒCƒ“
329+var word="";var range;var searchTarget={"word":true};
330+function searchWord(){
331+ if(!word){return}
332+ var matchs=new Array(); var color=new Array();
333+ // ŒŸõ•û–@
334+ if(expression=="regExp" || expression=="default" || (expression.match(/multi/) && !word.match(/\s/))){ // AND/OR‚ňê’PŒê‚È‚çdefault‚ÅŒŸõ
335+ // ŒŸõŒêŽw’èid•¡”rœ‚ō‚‘¬‰»Hj
336+ if(expression=="regExp"){
337+ var regWord=word.replace(/[\^\$]/g,"");
338+ var reg=new RegExp(regWord,"g"); var tmpArr=range.text.match(reg); var tmp;
339+ if(!tmpArr || !tmpArr.length){tmpArr=new Array(tmpArr)} // ŒŸõŒ‹‰Ê0or1‚È‚çA”z—ñì¬
340+ tmpArr.sort();for(var i=0;i<tmpArr.length;i++){if(tmp!=tmpArr[i]){matchs.push(tmpArr[i])}tmp=tmpArr[i]}
341+ if(!matchs || !matchs.length){matchs[0]=word} // ŒŸõŒ‹‰Ê0or1‚È‚çA”z—ñì¬
342+ }else{matchs[0]=word}
343+ // ƒnƒCƒ‰ƒCƒg
344+ for(var i=0;i<matchs.length;i++){color.push(setHighlight(matchs[i]));}
345+ highlight[color[0]].word=word;
346+ }else{
347+ // ŒŸõŒêŽw’è
348+ var matchs=word.split(" "); var tmpArr=new Array(); var tmp;
349+ // ƒnƒCƒ‰ƒCƒg¨d•¡ˆ—
350+ for(var i=0;i<matchs.length;i++){
351+ color.unshift(setHighlight(matchs[i]));
352+ highlight[color[0]].word=matchs[i];
353+ tmpArr=tmpArr.concat(highlight[color[0]])
354+ }
355+ color.reverse();tmpArr.sort();createHash(highlight,color[0],"",matchs[0]); // ˆê’U‰Šú‰»
356+ var judge = (expression=="multiAND") ? "tmp==tmpArr[i]" : "tmp!=tmpArr[i]";
357+ for(var i=0;i<tmpArr.length;i++){if(eval(judge)){highlight[color[0]].push(tmpArr[i])}tmp=tmpArr[i]} // ŒŸõŒ‹‰Ê‚Íhighlight[color[0]]‚É“ü‚ê‚é
223358 }
224- if(!word || word=="null"){return}
359+ // Œ‹‰Ê•\Ž¦
360+ if (searchView=="resList") {returnFound("search",color);searchWindow.close();}
361+ else if(searchView=="resPopup"){returnFound("search",color);searchWindow.close();}
362+ else if(searchView=="resJump") {returnFound("search",color);searchWindow.close();if(highlight[color[0]].length){moveToSearchRes("search",color.join(","))}}
363+}
364+// ƒnƒCƒ‰ƒCƒgŒŸõ
365+function setHighlight(reg){
225366 // ƒJƒ‰[‘I‘ð
226- var singleColor=event.altKey;
227- var c = singleColor ? 0 : selectColor();
228- if (c=="restart"){c=0;singleColor=true}
229- else if(c=="exit"){return;}
367+ var c=selectColor("highlight"); if(!c){return}
230368 // ŒŸõ
231- var found=new Array; var l=dds.length;
232- var bodyText=document.body.createTextRange();
233- for(var i=l;i--;){
234- var dt=dts[i]; var dd=dds[i]; if(dt.parentElement.className=="refResult"){continue} // ‹tŽQÆ“à‚ÌDT‚È‚ç‰ñ”ð
235- bodyText.moveToElementText(dt); var checkDT=bodyText.findText(word,0);
236- bodyText.moveToElementText(dd); var checkDD=bodyText.findText(word,0);
237- if(checkDT || checkDD){activate(dt,c);found.unshift(dt.firstChild.innerText)}
238- else if(singleColor) {deactivate(dt);}
369+ while(range.findText(reg)){
370+ var dt=range.parentElement();var tag=dt.tagName; var thisRange;
371+ // ŒŸõ‘Ώۂōi‚荞‚Ý
372+ if(tag=="B"||tag=="U"){thisRange="name"}
373+ else if(tag=="DT") {thisRange="mail"}
374+ else if(tag=="SPAN") {thisRange="id"}
375+ else if(tag=="DD" || tag=="A" && dt.parentElement.tagName=="DD"){thisRange="mess"}
376+ else if(tag=="STRONG"){thisRange="word"}
377+ else{/*alert("tagF"+tag+"\ndt:"+dt.outerHTML);*/range.collapse(false);continue;} // ƒŒƒX”ԍ†(A)‚⌟õŒ‹‰ÊŽ©‘Ì(TT)
378+ if(!searchTarget[thisRange]){range.collapse(false);continue;}
379+ // ³‹K•\Œ»‚̈ʒuŽw’èŽq‚ª‚ ‚éê‡A•ïŠÜ—v‘f“à•”‚ōČŸõ
380+ if(expression=="regExp" && word.match(/[\^|\$]/)){
381+ var thisReg=new RegExp(word); var targetText=(tag=="STRONG") ? dt.parentElement.innerText : dt.innerText;
382+ if(!targetText.match(thisReg)){range.collapse(false);continue}
383+ }
384+ // dtŽæ“¾¨ƒŒƒX”ԍ†Žæ“¾¨ƒnƒCƒ‰ƒCƒg
385+ if(dt.tagName!="DT"){
386+ while(dt.tagName!="DT" && dt.tagName!="DD"){dt=dt.parentElement}
387+ if(dt.tagName=="DD"){dt=dt.previousSibling}
388+ }
389+ var num=dt.firstChild.innerText;
390+ if(dt.parentElement.className!="refResult" && num!=highlight[c][highlight[c].length-1]){highlight[c].push(num)} // ‹tŽQÆ“à‚ÌDT,“¯ˆê”ԍ†‚È‚ç‰ñ”ð
391+ range.pasteHTML('<strong style="background-color:'+c+'">'+range.text+'</strong>');
392+ range.collapse(false);
239393 }
240- if(found){foundReturn(found)}
394+ range=document.body.createTextRange(); // ƒŒƒ“ƒW‚ðŒ³‚É–ß‚µ‚Ä‚¨‚­
395+ return(c);
241396 }
242397 //==========‹tŽQÆ
243398 function searchRef(obj){
@@ -245,16 +400,7 @@ function searchRef(obj){
245400 var num=obj.firstChild.innerText;
246401 if(refHash[num]){
247402 var refArr=refHash[num].split(/\s/); var refs="";
248- for(var i=0;i<refArr.length;i++){
249- var dtOrg=getDTfromAnc(refArr[i]); var dt=dtOrg.cloneNode(true); var dd=dtOrg.nextSibling.cloneNode(true);
250- // –{•¶ˆÈŠO‚ðíœ
251- if(dd.lastChild){
252- if(dd.lastChild.tagName=="DL"){dd.lastChild.removeNode(true);} //‹tŽQÆ‚̏œ‹Ž
253- if(dd.lastChild.name){dd.lastChild.removeNode(true);} // LABELNUMBER‚ª‚È‚¢‚à‚Ì‚ÉŒW‚é•s—vƒAƒ“ƒJ[‚̏œ‹Ž
254- }
255- // –{•¶‚ðŠi”[
256- refs+=dt.outerHTML.replace(/name=.*?>/,">")+dd.outerHTML.replace(/<a name=.*>/i,"");
257- }
403+ for(var i=0;i<refArr.length;i++){refs+=returnString(refArr[i]);}
258404 obj.nextSibling.insertAdjacentHTML("beforeEnd",'<dl class="refResult">'+refs+'</dl>')
259405 obj.name="referred";
260406 }
@@ -282,9 +428,26 @@ function getDTfromAnc(num){
282428 var anc=ancs(anchorHead+num);
283429 if(!anc){return("")} //LABELNUMBER‘Ήž‚Ì‚ ‚ځ`‚ñŽá‚µ‚­‚Í–¢o”ԍ†‚È‚çI—¹
284430 var obj=anc.parentElement; //LABELNUMBER‘Ήž‚Ì‚à‚Ì
431+ if(!obj || !obj.tagName){return false;}
285432 if(obj.tagName!="DT"){ //LABELNUMBER”ñ‘Ήž‚Ì‚à‚Ì
286433 if(num==1){if(anc){obj=anc.nextSibling} else{return("")}}
287434 else {if(!anc.nextSibling){obj=anc.parentElement.nextSibling}else{return("")}}
288435 }
289436 return(obj);
290-}
\ No newline at end of file
437+}
438+
439+// ‰æ‘œ”Š֘A
440+var regIMG=new RegExp(".*?\\s.*?\\s.*:.*?\\sIMG:(.*?)(\\s|$)"); // ‰æ‘œ‚à‰Â”\‚É‚µ‚Ä‚Ý‚é
441+function getIMG(obj){
442+ if(regIMG.test(obj.innerText)){
443+ var filename=RegExp.$1;
444+ var tmp=filename.match(/(\d\d\d\d)(\d\d\d\d)(\d\d)/);
445+ var today=new Date();var last=new Date(today-7*24*60*60*1000);var date="";
446+ date+=last.getMonth()<9 ? "0"+(last.getMonth()+1) : last.getMonth()+1;
447+ date+=last.getDate()<10 ? "0"+last.getDate() : last.getDate();
448+ var log= (RegExp.$1+""+RegExp.$2 < last.getYear()+""+date) ? "_kako/" : "_img/";
449+ var fileurl="http://up01.2ch.io/"+log+RegExp.$1+"/"+RegExp.$1+RegExp.$2+"/"+RegExp.$3+"/"+filename;
450+ return(fileurl)
451+ }else{return(false)}
452+}
453+
--- a/res/skin/skin30-3G/Header.html
+++ b/res/skin/skin30-3G/Header.html
@@ -15,7 +15,7 @@
1515 var start_time = new Date();
1616 //==========ƒOƒ[ƒoƒ‹•Ï”
1717 var anchorHead="";
18-var skinName="skin30-3 v3.5.0704";
18+var skinName="skin30-3 v3.6.1231";
1919 var browser="ƒMƒRƒiƒr";
2020 //==========ƒMƒRƒiƒr—pƒAƒ“ƒJ[‚Ì”»’èi0:ˆ—–³‚µ,1:ƒ|ƒbƒvƒAƒbƒv,2:ƒ{ƒ^ƒ“‘}“üj
2121 // ƒMƒRƒiƒr‚ł́AƒŒƒXƒAƒ“ƒJ[‚Í‘Š‘΃AƒhƒŒƒX‚Å‹Lq‚³‚ê‚é
@@ -47,6 +47,16 @@ function threadurl(){
4747 t_bbs=RegExp.$1;
4848 t_key=RegExp.$2;
4949 }
50+//==========”ñ•\Ž¦ƒŒƒX‚Ì•\Ž¦-ƒMƒRƒiƒr‚Ì‚Ý
51+function hiddenRes(e){
52+ var number=tohan(event.srcElement.innerText.replace(/>|„/g,""));
53+ var i=0;while(document.anchors[i].name.match(/\D/)){i++}
54+ var startRes=parseInt(document.anchors[i+1].name.replace(/\D/g,""));
55+ if(number.match(/(\d*)\D+(\d*)/)){var start=parseInt(RegExp.$1);}
56+ else {var start=parseInt(number);}
57+ //alert(startRes+">"+start+" && "+start+"!="+1);
58+ if(startRes>start && start!=1){return true}else{return false}
59+}
5060 </script>
5161 </head>
5262 <body>
--- a/res/skin/skin30-3G/chie_base.css
+++ b/res/skin/skin30-3G/chie_base.css
@@ -7,8 +7,11 @@ dt a{text-decoration:none;}
77 dd a{text-decoration:underline;line-height:1.1}
88
99 /* ŒŸõŒ‹‰Ê */
10-#foundResult a {color:LightSlateGray;}
11-#foundResult a:hover{color:#000;}
10+#foundPanel{color:LightSlateGray;}
11+#foundPanel div {font-family:"‚l‚r ƒSƒVƒbƒN";}
12+#foundPanel div span{font-family:Times;cursor:hand;}
13+#foundPanel a {color:LightSlateGray;}
14+#foundPanel a:hover{color:#000;}
1215
1316 /* dt */
1417 dt{
--- a/res/skin/skin30-3G/chie_event.js
+++ b/res/skin/skin30-3G/chie_event.js
@@ -1,18 +1,22 @@
1+//========V’…ƒWƒƒƒ“ƒvÝ’è
2+var buffer=1; // ’ᑬ‰ñü‚â’ᑬƒ}ƒVƒ“‚̏ꍇ‚É‚Íbuffer‚̐”’l‚𑝂₷‚Æ‚æ‚萳Šm‚ɃWƒƒƒ“ƒvi1‘‚â‚·‚Æ0.1•b’x‚ê‚éj
3+var newResJump=1; // V’…ƒŒƒXƒWƒƒƒ“ƒvi0:ƒuƒ‰ƒEƒU”C‚¹A1:“Ç—¹Žž‚̂݁A2:íŽžj–‚©‚¿‚ãAOpenJaneAtwintail‚݂̂̐ݒè
4+//==========ˆÈ‰º‚̓XƒNƒŠƒvƒg–{•¶‚Å‚·‚æB
15 //ƒCƒxƒ“ƒgƒnƒ“ƒhƒ‰’è‹`
26 //ŠO•”ŠÖ”Ftohan
37 //ŠO•”•Ï”FanchorHead,lightmode,getID,skinName,browser,dts
4-//ƒOƒ[ƒoƒ‹•Ï”
5-var buffer=1; // ’ᑬ‰ñü‚â’ᑬƒ}ƒVƒ“‚̏ꍇ‚É‚Íbuffer‚̐”’l‚𑝂₷‚Æ‚æ‚萳Šm‚ɃWƒƒƒ“ƒvi1‘‚â‚·‚Æ0.1•b’x‚ê‚éj
6-var newResJump=1; // V’…ƒŒƒXƒWƒƒƒ“ƒvi0:ƒuƒ‰ƒEƒU”C‚¹A1:“Ç—¹Žž‚̂݁A2:íŽžj–‚©‚¿‚ãAOpenJaneAtwintail‚݂̂̐ݒè
8+//=========ŠO•”ƒtƒ@ƒCƒ‹‹¤—p‚̃Oƒ[ƒoƒ‹•Ï”
9+var waited=false;//command•\Ž¦Œãtrue‚É‚µA‘I‘ðŒã‚Éfalse‚É‚·‚éB
10+var viewed=false;//thumb“Ǎž‚ÝŒãtrue‚É‚µAthumbPanel‚ɏæ~Œãfalse‚É‚·‚éB
11+var searched=false; //ŒŸõŒã‚ɁAtrue‚É‚µAfoundPanel‚ɏæ~Œãfalse‚É‚·‚éB
12+var cp,tp,vp,fp;
713 //========Clickˆ—¨search,‘¼
814 document.onclick = clickEvent;
915 function clickEvent(){
1016 if(clickCancel){return false}else{clearTimeout(clickTimer);if(document.getElementById("context")){document.getElementById("context").removeNode(true);}}
1117 var obj=window.event.srcElement;
1218 var tag=obj.tagName;
13- if (tag=="B") {search(obj.parentElement)} //–¼‘O
14- else if(tag=="U") {search(obj)} //ƒgƒŠƒbƒv
15- else if(tag=="SPAN"){if(getID(obj)){searchID(obj)}} //ID
19+ if(tag=="B"||tag=="U"||tag=="SPAN"){searchPerson(obj)} //–¼‘O,ƒgƒŠƒbƒv,ID
1620 else if(tag=="DT") {searchRef(obj)}
1721 else if(tag=="DD") {defaultPopup()}
1822 else if(tag=="A"){
@@ -23,7 +27,7 @@ function clickEvent(){
2327 if(obj.href.match(/^http:.*#/)){window.open(obj.href,"_parent");return false}
2428 }
2529 //A Bone•â³i”ñ•\Ž¦ƒŒƒX‚Ì•\Ž¦j
26- if(browser=="A Bone" && hidedRes(obj)){showModelessDialog(document.getElementsByName("ThreadURL")[0].content+tohan(obj.innerText.replace(/[>„]/g,"")),window,"dialogWidth:"+document.body.clientWidth+"px;help:no;resizable:yes;status:no;unadorned:yes;");window.focus();}
30+ if((browser=="A Bone"||browser=="ƒMƒRƒiƒr") && hiddenRes(obj)){showModelessDialog(document.getElementsByName("ThreadURL")[0].content.replace(/\/l50$/,"/")+tohan(obj.innerText.replace(/[>„]/g,"")),window,"dialogWidth:"+document.body.clientWidth+"px;help:no;resizable:yes;status:no;unadorned:yes;");window.focus();}
2731 //Jane,Live,ƒMƒRƒiƒr•â³iskin30-2Normal‹y‚уMƒRƒiƒrj–ƒŒƒXƒWƒƒƒ“ƒv‚ªscrollIntoView‚Å‚È‚¢‚à‚Ì‚ÉŒW‚é•â³
2832 if(browser=="A Bone" || browser=="OpenJane" || browser=="Live2ch" || browser=="ƒMƒRƒiƒr"){if(obj.href.match(/^about|jumpres/)){
2933 var h=tohan(obj.innerText.replace(/[>„]/g,""));
@@ -32,17 +36,17 @@ function clickEvent(){
3236 }}
3337 return true;
3438 }
35- else{return}
39+ else{panelOver();return}
3640 }
3741
3842 //=========MouseOverˆ—¨image,popup
3943 document.onmouseover = mouseOverEvent;
4044 function mouseOverEvent() {
4145 var e = window.event.srcElement;
42- if(e.tagName=='B'){
46+ if(e.tagName=='B'){if(browser!="twintail2"){
4347 if(e.innerText.match(/^([^\d‚O-‚X]*)([\d‚O-‚X]+)([^\d‚O-‚X]*.*)/)){namePopup(e,RegExp.$1,RegExp.$2,RegExp.$3);}
4448 else if(e.innerText.match(/^‚ ‚ځ`‚ñ$/)) {abonePopup(e);}
45- }
49+ }}
4650 if(e.tagName=='A'){
4751 if(!e.innerText.match(/%/)){ // URLƒGƒ“ƒR[ƒh‚Å‚ ‚肪‚¿‚È%‚ª‚È‚¯‚ê‚Î
4852 //e.href=e.href.replace(/>/g,"");
@@ -55,9 +59,8 @@ function mouseOverEvent() {
5559 }
5660 }
5761 if (checkAnchor(e.href)==2){insButton(e);return;}
58- else if(checkAnchor(e.href)==1){
62+ else if(checkAnchor(e.href)==1){ // ‘½’iƒ|ƒbƒvƒAƒbƒv
5963 if(event.shiftKey){if(e.rel){e.href=e.rel}return}
60- // ‘½’iƒ|ƒbƒvƒAƒbƒv
6164 var parent=e.parentElement;
6265 var aNum= (parent.tagName!="DD") ? parent.firstChild.sourceIndex : parent.previousSibling.firstChild.innerText;
6366 if(!document.getElementById("p"+aNum)){
@@ -66,49 +69,48 @@ function mouseOverEvent() {
6669 if(!onPopup){removePopup()}
6770 makePopContent(e);return;
6871 }
72+ }else if(checkAnchor(e.href)==0){ // ‹tŽQÆƒ|ƒbƒvƒAƒbƒv
73+ if(e.href.match(/menu:/) && event.shiftKey){searchPopup(e)}
6974 }
75+ }else if(e.tagName=="SPAN"||e.tagName=="TT"){
76+ var obj=e;var onPopup;
77+ while(obj.tagName!="BODY"){if(obj.id.match(/p\d+/)){onPopup=true;break}else{obj=obj.parentElement}}
78+ if(e.tagName=="SPAN"){
79+ if(!onPopup && event.shiftKey){searchPopup(e)}
80+ }else{searchPopup(e)}
7081 }else{ // ‘½’iƒ|ƒbƒvƒAƒbƒvÁ‹Ž
7182 var obj=e;var onPopup;
7283 if(obj.sourceIndex<0){obj=document.body;if(document.getElementById("popupBase")){onPopup=true;}} // namePopup‚Æ‚Ì‹£‡‚Ńm[ƒh‚ªŠO‚ê‚éuŠÔ‚̉ñ”ð
73- while(obj.tagName!="BODY"){if(obj.id.match(/p\d+/)){onPopup=true;break}else{obj=obj.parentElement;}}
84+ while(obj.tagName!="BODY"){if(obj.id.match(/(p\d+)/)){onPopup=true;break}else{obj=obj.parentElement;}}
7485 if(onPopup){while(obj.id!=obj.parentElement.lastChild.id){obj.parentElement.lastChild.removeNode(true)}}
7586 else {removePopup()}
7687 }
77- if(e.tagName=="DT"){setHash();}
78- if(e.tagName=="SPAN"){
79- var obj=e;var onPopup;
80- while(obj.tagName!="BODY"){if(obj.id.match(/p\d+/)){onPopup=true;break}else{obj=obj.parentElement}}
81- if(!onPopup && event.shiftKey){searchPopup(event.toElement);} return;
82- }
8388 }
84-//=========MouseMoveˆ—¨menuOver(),tpOver()
89+//=========MouseMoveˆ—¨panelOver()
8590 document.onmousemove=mouseMoveEvent;
86-var waited=false;//command•\Ž¦Œãtrue‚É‚µA‘I‘ðŒã‚Éfalse‚É‚·‚éB
87-var viewed=false;//thumb“Ǎž‚ÝŒãtrue‚É‚µAthumbPanel‚ɏæ~Œãfalse‚É‚·‚éB
88-var cp,tp,vp;
8991 function mouseMoveEvent() {
9092 if(!cp){
91- var nHTML ="<div id='controlPanel'><input type='button' value='TOP' onclick='scroll_Top();blur()'><input type='button' value='END' onclick='scroll_End();blur()'><input type='button' value='IMG' onmouseup='imgCommand();blur()'><input type='button' value='FND' onclick='findIt(document.selection.createRange().text);blur()'></div>";
92- if(skinName.match(/30-2/)){nHTML+="<div id='thumbPanel' onmouseout='viewed=false'></div><div id='viewPanel'></div>";}
93- document.body.insertAdjacentHTML('afterBegin',nHTML);
94- cp=document.getElementById("controlPanel");
95- if(skinName.match(/30-2/)){tp=document.getElementById("thumbPanel");vp=document.getElementById("viewPanel");}
93+ var nHTML ='<div id="controlPanel"><input type="button" value="TOP" onclick="scroll_Top();blur()"><input type="button" value="END" onclick="scroll_End();blur()"><input type="button" value="IMG" onmouseup="imgCommand();blur()"><input type="button" value="FND" onclick="fndCommand();blur();"></div><div id="foundPanel" onmouseout="searched=false"></div>';
94+ if(skinName.match(/30-2/)){nHTML+='<div id="thumbPanel" onmouseout="viewed=false"></div><div id="viewPanel"></div>';}
95+ document.body.insertAdjacentHTML("afterBegin",nHTML);
96+ cp=document.getElementById("controlPanel");fp=document.getElementById("foundPanel");
97+ if(skinName.match(/30-2/)){tp=document.getElementById("thumbPanel");vp=document.getElementById("viewPanel");}else{tp=vp=new Object()}
98+ cp.condition="waited";tp.condition="vp.firstChild || viewed || !lightmode";fp.condition=resultView ? "fp.hasChildNodes()" : "searched";
99+ cp.territory="<25"; tp.territory=">20"; fp.territory="<(30+fp.clientHeight) && fp.hasChildNodes()";
96100 }
97- cpOver();
98- tpOver();
101+ if(event){panelOver();}
102+ if(!idHash.length){setHash();searchColoring();}
99103 }
100-// ƒRƒ“ƒgƒ[ƒ‹ƒpƒlƒ‹
101-function cpOver(){
104+// Šeƒpƒlƒ‹
105+function panelOver(){
102106 var territoryW=document.body.clientWidth-120;var territoryH=25;
103- if(waited){cp.style.visibility="visible";return}
104- if(event.y<territoryH && event.x>territoryW){cp.style.visibility="visible";}else{cp.style.visibility="hidden";}
105-}
106-// ƒTƒ€ƒlƒCƒ‹ƒpƒlƒ‹
107-function tpOver(){
108- if(skinName.match(/30-3/) || !lightmode){return}
109- var territoryW=document.body.clientWidth-120;var territoryH=20;
110- if(document.getElementById("viewPanel").firstChild || viewed){tp.style.visibility="visible";return}
111- if(event.y>territoryH && event.x>territoryW){tp.style.visibility="visible";}else{tp.style.visibility="hidden";}
107+ var panels=new Array("cp","tp","fp");
108+ for(var i in panels){
109+ if(skinName.match(/30-3/)&&panels[i]=="tp"){continue}
110+ var panel=eval(panels[i]); var territoryY=eval("event.y"+panel.territory); var territoryX=eval(event.x>document.body.clientWidth-panel.offsetWidth-15);
111+ if(eval(panel.condition)){panel.style.visibility="visible";return}
112+ if(territoryY && territoryX){panel.style.visibility="visible";}else{panel.style.visibility="hidden";}
113+ }
112114 }
113115 // TOP,END
114116 function scroll_Top(){document.getElementsByTagName("DL")[0].firstChild.scrollIntoView(true);}
@@ -127,6 +129,14 @@ function imgCommand(mode,s){
127129 clearCommand();
128130 }
129131 }
132+function fndCommand(mode,s){
133+ if(!waited){
134+ findIt(document.selection.createRange().text);
135+ event.cancelBubble=true;
136+ }else{
137+ clearCommand();
138+ }
139+}
130140 function clearCommand(){
131141 waited=false;
132142 document.getElementById("command").removeNode(true);
@@ -174,7 +184,7 @@ function key(){
174184 else if(code=="36"){scroll_Top()}
175185 else if(code=="35"){scroll_End()}
176186 else if(code=="73" && event.shiftKey){changePanel();return false;} // shift+I
177- else if(code=="70" && event.shiftKey){cp.childNodes[3].click();return false;} // shift+F
187+ else if(code=="70" && event.shiftKey){findIt(document.selection.createRange().text);return false;} // shift+F
178188 else if(code=="78" && event.shiftKey && firstNew){firstNew.scrollIntoView(true)} // shift+N
179189 else if(code=="82" && event.shiftKey && event.ctrlKey){ // ctrl+shift+R
180190 //‚©‚¿‚ã`‚µ‚á•â³i”XV‚̃Vƒ‡[ƒgƒJƒbƒgƒL[j
@@ -190,7 +200,7 @@ function key(){
190200 //=========‚©‚¿‚ãAABoneAƒ]ƒk‚Q
191201 var newResNum=parseInt(document.getElementsByName("GetRescount")[0].content)+1;
192202 var k=0;
193-function loadEvent(num){ //setTimeout("setHash();",100);
203+function loadEvent(num){
194204 //====V’…ƒŒƒXƒWƒƒƒ“ƒv
195205 if(newResJump==0){clearInterval(timerID);return} //uƒuƒ‰ƒEƒU”C‚¹v‚È‚çI—¹
196206 //V’…ƒŒƒX‚ÌŠJŽn”ԍ†‚ðŽæ“¾
@@ -209,7 +219,7 @@ function loadEvent(num){ //setTimeout("setHash();",100);
209219 //=========V’…ƒŒƒXŽæ“¾Œãˆ—i•W€ƒXƒLƒ“‘Ήžƒuƒ‰ƒEƒU—pj©NewMark‚©‚çŒÄ‚яo‚µ
210220 //=========OpenJAtwin
211221 var scr,viewPos,endPos=0;
212-function reloadEvent(){ //setTimeout("setHash();",100);
222+function reloadEvent(){
213223 //====Šù“lj»
214224 var lastDt=dts[dts.length-2];if(!lastDt){return}// ‘S•”V’…‚È‚çI—¹
215225 while(lastDt && lastDt.className=="new"){lastDt.className="";lastDt=lastDt.previousSibling.previousSibling;}
@@ -242,10 +252,10 @@ function defaultPopup(){
242252 obj.innerText=num;
243253 obj.href="#"+hnum;
244254 makePopContent(obj);
245- }else if(num.match(/\w/) && num.length==8){ //\w{8}‚Å‚Í‚¾‚߂ہH
246- var obj=document.createElement("span");
247- obj.innerText="date time ID:"+num;
248- setHash();searchID(obj);
255+ }else if(num.match(/\w{8,9}/)){ //\w{8}‚Å‚Í‚¾‚߂ہH
256+ var obj=document.createElement("DT");
257+ obj.innerHTML="<span>date time ID:"+num+"</span>";
258+ searchPerson(obj.firstChild);
249259 }
250260 }
251261
@@ -260,5 +270,14 @@ function copyEvent(){
260270 copyText.execCommand("Copy");
261271 return false;
262272 }
263-//=========onLoadˆ—iDAT2HTML‚̂݁j
264-window.onload=function(){setHash()}
273+//=========onScrollˆ—
274+//window.onscroll=function(){clearInterval(beforeScrollTimer);onLoadEvent()}
275+window.onscroll=function(){onLoadEvent()}
276+if(document.getElementById("dl")){
277+ document.getElementById("dl").onscroll=function(){onLoadEvent()}
278+}
279+//=========onLoadˆ—
280+window.onload=onLoadEvent;
281+function onLoadEvent(){mouseMoveEvent();setHash();searchColoring();}
282+setTimeout("onLoadEvent()",1000); // ˆê‰ñ‚¾‚¯’…F
283+
--- a/res/skin/skin30-3G/chie_image2.js
+++ b/res/skin/skin30-3G/chie_image2.js
@@ -1,7 +1,8 @@
11 // ƒCƒxƒ“ƒgƒnƒ“ƒhƒ‰FonMouseover
22 // ŠO•”•Ï”FanchorHead,dds
3-//======‰æ‘œ“ǂݍž‚݂̐ݒè
4-var onMouseLoad=true; // true:ƒJ[ƒ\ƒ‹‚ð‡‚í‚¹‚½‚¾‚¯Afalse:LOADƒ{ƒ^ƒ“‚ðƒNƒŠƒbƒN‚µ‚Ä‚©‚ç
3+//======‰æ‘œ“ǂݍž‚Ý‚ÌÝ’è i’jWindowsXP SP2‚Å‚Í‚±‚ê‚ç‚̐ݒè‚Í—LŒø‚É‹@”\‚µ‚Ü‚¹‚ñB
4+var onOpenLoad =1; // 0:“ǂݍž‚Ü‚È‚¢A1:V’…ƒŒƒX‚̂݁A2:‘S•”
5+var onMouseLoad=true; // true:ƒJ[ƒ\ƒ‹‚ð‡‚í‚¹‚½‚¾‚¯Afalse:LOADƒ{ƒ^ƒ“‚ðƒNƒŠƒbƒN‚µ‚Ä‚©‚ç
56 //==========ƒOƒ[ƒoƒ‹•Ï”
67 var lightmode=true; // Live,twin‚̃Wƒƒƒ“ƒv—p”»’è‚Å—p‚¢‚Ä‚¢‚é‚Ì‚Å•K{
78 //==========‰æ‘œˆ—“™
--- a/res/skin/skin30-3G/chie_popup.js
+++ b/res/skin/skin30-3G/chie_popup.js
@@ -1,4 +1,6 @@
1+//==========ˆÈ‰º‚̓XƒNƒŠƒvƒg–{•¶‚Å‚·‚æB
12 // ƒCƒxƒ“ƒgƒnƒ“ƒhƒ‰FonMouseover
3+// ŠO•”•Ï”FidHash,refHash,foudRes,highlight
24 // ŠO•”ŠÖ”FaddAnchor,getDTfromAnc
35 // “Á’¥FDIV#popupBase‰º‚Ɂuƒtƒ‰ƒbƒg‚ŃŠƒjƒAv‚ÉDL#p\d‚ðì¬‚·‚éB
46 //==========CSS‚̏o—Í
@@ -9,65 +11,65 @@ nCSS+='#popupBase dl{position:absolute; background-color:window; border:outset 1
911 nCSS+='#popupBase dt span{float:none; margin-left:1em;}';
1012 nCSS+='#popupBase dd{margin:auto 1em}';
1113 document.write('<style type="text/css">'+nCSS+'</style>\n');
12-//=========ƒOƒ[ƒoƒ‹•Ï”
13-var pb;
14+//=========ŠO•”ƒtƒ@ƒCƒ‹‹¤—p‚̃Oƒ[ƒoƒ‹•Ï”
1415 //=========ƒiƒ“ƒo[‚È–¼‘O‚̃|ƒbƒvƒAƒbƒv
1516 function namePopup(e,before,num,after){
1617 var hnum=tohan(num);
17- //‚RŽü”NA‚SŽü”NASocket774A774KBA21‹ÖA[1-30]A‚È‚Ç‚Í–³Ž‹
18- if(before){if(hnum==5 || hnum==774 || hnum==4 || hnum==21 || hnum==1 || hnum==30){return}}
18+ if(hnum==774 || hnum==21 || hnum==1 || hnum==30){return} // Socket774A774KBA21‹ÖA[1-30]A‚È‚Ç‚Í–³Ž‹
19+ if(before && before.match(/–¼–³/)){return} //–¼–³‚µ‚Á‚Û‚¢‚Ì‚Í–³Ž‹
20+ if(after) {if(after=="Žü”N"){return}} // ƒfƒtƒHƒ‹ƒg‚È"‚ŽŽü”N"‚Í–³Ž‹
1921 var nB = before ? "<b>"+before+"</b><b>":"<b>"; nB+=addAnchor(hnum,num); nB+=after ? "</b><b>"+after+"</b>":"</b>";
2022 e.outerHTML=nB;
2123 }
2224 //=========Žã‚ ‚ځ`‚ñ‚̃|ƒbƒvƒAƒbƒv
23-function abonePopup(e){
24- var hnum=e.parentElement.previousSibling.innerText;
25- e.outerHTML = "<b>"+addAnchor(hnum,'‚ ‚ځ`‚ñ')+"</b>";
25+function abonePopup(e){e.outerHTML = "<b>"+addAnchor(e.parentElement.previousSibling.innerText,'‚ ‚ځ`‚ñ')+"</b>";}
26+//=========ŒŸõ‚µ‚½ƒŒƒX‚̃|ƒbƒvƒAƒbƒv
27+function searchPopup(obj){
28+ var reg,cArray;var tag=obj.tagName;
29+ /*ref Popup*/if (tag=="A") {if(refHash[obj.innerText]){cArray=refHash[obj.innerText].split(" ")}else{return}}
30+ /*ID Popup*/ else if(tag=="SPAN"){reg=getID(obj);if(reg&&reg.length>3){cArray=idHash[reg].split(" ");}else{return} if(cArray.length==1){return}}
31+ /*ŒŸõPopup*/else if(tag=="TT") {var cHash=(obj.parentElement.rel=="res")?foundRes:highlight;cArray=cHash[obj.parentElement.firstChild.style.backgroundColor];if(!cArray){return}}
32+ var targetString=""; for(var i=0;i<cArray.length;i++){targetString+=returnString(cArray[i]);} //’†g‚̐؂èo‚µ
33+ if(targetString){popup(targetString);} //‘Ώۂª‘¶Ý‚µ‚½‚çƒ|ƒbƒvƒAƒbƒv
2634 }
2735 //=========‘½’iƒ|ƒbƒvƒAƒbƒv
2836 //Eƒ|ƒbƒvƒAƒbƒv‚̍쐬
29-var startRes;
3037 function makePopContent(obj){
3138 //Ž–‘O€”õ
32- var num=obj.innerText.replace(/[>„]/g,"");
33- var number=tohan(num);
34- if(!obj.rel){obj.rel=obj.href;}
35- obj.href="decoy:";
36- //’²¸
37- if(document.anchors.length==1){return} //ƒŒƒX”‚ª1‚È‚çI—¹
38- if(!startRes){startRes=parseInt(document.anchors[1].name.replace(/\D/g,""))}
39+ var num=obj.innerText.replace(/[>„]/g,""); var number=tohan(num);
40+ if(!obj.rel){obj.rel=obj.href;} obj.href="decoy:"; // ƒuƒ‰ƒEƒU–{‘̂̃|ƒbƒvƒAƒbƒv‰ñ”ð
41+ //”ԍ†’²¸
3942 if(number.match(/(\d*)\D+(\d*)/)){var start=parseInt(RegExp.$1); var end=parseInt(RegExp.$2);}
4043 else {var start=end=parseInt(number);}
41-// alert(startRes+">"+end+" && "+end+"!=1")
42- if(startRes>end && end!=1){obj.href=obj.rel;return}//‘¶Ý‚µ‚Ä‚¢‚È‚¯‚ê‚ΏI—¹
44+ if(end-start>100){end=start+100} // 100ˆÈã•\Ž¦‚µ‚È‚¢
4345 //’†g‚̐؂èo‚µ
44- var targetString=""; if(end-start>100){end=start+100}
45- if(start==end){targetString=returnString(start)}
46- else {for(var i=0;i<=end-start;i++){targetString+=returnString(start+i)}}
46+ var targetString=""; for(var i=0;i<=end-start;i++){targetString+=returnString(start+i)}
4747 //‘Ώۂª‘¶Ý‚µ‚½‚çrel‚É‘Þ”ð‚µ‚Äƒ|ƒbƒvƒAƒbƒv
4848 if(targetString){popup(targetString);}else{obj.href=obj.rel;}
4949 }
5050 //E’†g‚̐؂èo‚µ
5151 function returnString(num){
5252 var obj=getDTfromAnc(num);
53+ setSearchColor(obj);//ƒ|ƒbƒvƒAƒbƒvæ‚Ì’…F
5354 if(!obj){return("")} //‘Ώۂª“§–¾‚ ‚ځ`‚ñ‚È‚çI—¹
54- var dt,dd,dtOuter,ddOuter;
55- dt=obj.cloneNode(true);
56- dtOuter=dt.outerHTML.replace(/name=.*?>/,">"); // LABELNUMBER‘Ήž‚Ì‚à‚Ì‚ÉŒW‚郊ƒ“ƒNƒAƒ“ƒJ[‚̏œ‹Ž
57- dd=obj.nextSibling.cloneNode(true);
55+ var dt=obj.cloneNode(true);
56+ var dtOuter=dt.outerHTML.replace(/name=.*?>/,">"); // LABELNUMBER‘Ήž‚Ì‚à‚Ì‚ÉŒW‚郊ƒ“ƒNƒAƒ“ƒJ[‚̏œ‹Ž
57+ var dd=obj.nextSibling.cloneNode(true);
5858 if(dd.hasChildNodes()){
5959 while(dd.lastChild.name){dd.lastChild.removeNode(true)} // LABELNUMBER”ñ‘Ήž‚Ì‚à‚Ì‚ÉŒW‚郊ƒ“ƒNƒAƒ“ƒJ[‚̏œ‹Ž
6060 if(dd.lastChild.tagName=="DL"){dd.lastChild.removeNode(true)} // ‹tŽQÆ‚̏œ‹Ž
6161 }
62- ddOuter=dd.outerHTML;
62+ var ddOuter=dd.outerHTML;
6363 return(dtOuter+ddOuter);
6464 }
6565 //Eƒ|ƒbƒvƒAƒbƒv
66+var pb;
6667 function popup(inner){
6768 if(!pb){document.body.insertAdjacentHTML('afterBegin','<div id="popupBase"></div>');pb=document.getElementById("popupBase")}
6869 //—v‘f‚̍쐬
6970 var parent=event.srcElement.parentElement;
70- var aNum= (parent.tagName!="DD") ? parent.firstChild.sourceIndex : parent.previousSibling.firstChild.innerText; // DDˆÈŠO–¼‘O—“A‰æ‘œAIDŒŸõ
71+ //var aNum= (parent.tagName!="DD") ? parent.firstChild.sourceIndex : parent.previousSibling.firstChild.innerText; // DDˆÈŠO–¼‘O—“A‰æ‘œAIDŒŸõ
72+ var aNum=event.srcElement.sourceIndex;if(!aNum){alert("aNumŽæ“¾ƒGƒ‰[")}
7173 if(document.getElementById('p'+aNum)){return} // ƒ|ƒbƒvƒAƒbƒv‚µ‚Ä‚½‚çI—¹
7274 pb.insertAdjacentHTML("beforeEnd",'<dl id="p'+aNum+'">'+inner+'</dl>');
7375 //—v‘f‚Ì”z’u
@@ -75,16 +77,16 @@ function popup(inner){
7577 // yŽ²’²®
7678 var pos=Math.min(event.y,document.body.clientHeight-event.y);
7779 var scTop=document.body.scrollTop+event.y;
78- if(pos==event.y){var y=scTop-30;} // ‰º
79- else {var y=scTop+10-p.clientHeight;} // ã
80+ if(pos==event.y){var y=scTop-30;} // ƒJ[ƒ\ƒ‹‚̉º‚Ö•\Ž¦
81+ else {var y=scTop+10-p.clientHeight;} // ƒJ[ƒ\ƒ‹‚̏ã‚Ö•\Ž¦
8082 if(y<0){y=0}
81- if(event.srcElement.parentElement.id=="foundResult"){y+=30}
83+ if(event.srcElement.parentElement.tagName=="TT"){y+=35;}
8284 p.style.pixelTop=y;
8385 // xŽ²’²®
8486 var pos=Math.min(event.x,document.body.clientWidth-event.x);
8587 var scLeft=document.body.scrollLeft+event.x;
86- if(pos==event.x){var x=scLeft-2} // ‰E
87- else {var x=scLeft-4-p.clientWidth;} // ¶
88+ if(pos==event.x){var x=scLeft-2} // ƒJ[ƒ\ƒ‹‚̉E‚Ö•\Ž¦
89+ else {var x=scLeft-4-p.clientWidth;} // ƒJ[ƒ\ƒ‹‚̍¶‚Ö•\Ž¦
8890 if(x<0){x=0}
8991 p.style.pixelLeft=x;
9092 // ‚‚³’²®iscrollBar‚ð—v‚·ê‡‚Æ—v‚µ‚È‚¢ê‡‚ª‚ ‚éj¨yŽ²’²®
--- a/res/skin/skin30-3G/chie_search.js
+++ b/res/skin/skin30-3G/chie_search.js
@@ -1,243 +1,398 @@
1-// “ú•t•¶Žš—ñ‚Ì’…FÝ’è@’…F‚·‚é:1@’…F‚µ‚È‚¢:0
2-coloring=1;
3-threshold1=[2,"#0000FF"]; // ‘‚«ž‚Ý‚ª•¡”‚ ‚éID ‚Ì‚µ‚«‚¢’l‚ƐF
4-threshold2=[5,"#FF0000"]; // ‘‚«ž‚Ý‚ª‘½”‚ ‚éID ‚Ì‚µ‚«‚¢’l‚ƐF
5-threshold3=[1,"#0000FF"]; // ‘‚«ž‚Ý‚ª‚ ‚é ƒŒƒX ‚Ì‚µ‚«‚¢’l‚ƃŒƒX”ԍ†‚̐F
6-threshold4=[4,"#FF0000"]; // ‘‚«ž‚Ý‚ª‘½”‚ ‚郌ƒX ‚Ì‚µ‚«‚¢’l‚ƃŒƒX”ԍ†‚̐F
7-// ƒCƒxƒ“ƒgƒnƒ“ƒhƒ‰FonClick
8-// ŠO•”ŠÖ”FaddAnchor,checkAnchor,tohan
9-// ŠO•”•Ï”FanchorHead,browser
10-// “Á’¥FƒCƒxƒ“ƒg”­¶DT‚ɑΉž‚·‚éDD‰º‚ɁADL-DT-DD\‘¢‚ðì¬‚·‚éB
1+beID=false; // be‚ɃƒOƒCƒ“o—ˆ‚éê‡‚́Atrue
2+//==========ŒŸõÝ’è
3+var expression="multiAND"; // ŒŸõ•û–@@@default:•W€AregExp:³‹K•\Œ»AmultiAnd:ANDŒŸõAmultiOR:ORŒŸõ
4+var searchView="resList"; // ŒŸõŒ‹‰Ê•\Ž¦@@resList:ŠY“–ƒŒƒX”ԍ†•\Ž¦AresPopup:ŠY“–ƒŒƒXƒ|ƒbƒvƒAƒbƒvA
5+var resultView=false; // ŒŸõŒ‹‰Ê‚̏펞•\Ž¦@@true:íŽž•\Ž¦Afalse:ƒ}ƒEƒX‚ŋ߂¯‚½‚Æ‚«‚Ì‚Ý•\Ž¦
6+var listLimit =10; // searchView‚ªresPopup‚Å‚È‚¢ê‡‚́AƒŒƒX”ԍ†‚Ì•\Ž¦§ŒÀ
7+//==========ƒŒƒX”ԍ†A“ú•t•¶Žš—ñ‚Ì’…FÝ’è
8+coloring=1; // ’…F‚·‚é:1@’…F‚µ‚È‚¢:0
9+threshold1=[2,"#0000ff"]; // ‘‚«ž‚Ý‚ª•¡”‚ ‚éID ‚Ì‚µ‚«‚¢’l‚ƐF
10+threshold2=[5,"#aaaa00"]; // ‘‚«ž‚Ý‚ª‘½”‚ ‚éID ‚Ì‚µ‚«‚¢’l‚ƐF
11+threshold3=[8,"#ff0000"]; // ‘‚«ž‚Ý‚ª‘½”‚ ‚éID ‚Ì‚µ‚«‚¢’l‚ƐF
12+threshold4=[1,"#0000FF"]; // ‘‚«ž‚Ý‚ª‚ ‚é ƒŒƒX ‚Ì‚µ‚«‚¢’l‚ƃŒƒX”ԍ†‚̐F
13+threshold5=[4,"#aaaa00"]; // ‘‚«ž‚Ý‚ª‘½”‚ ‚郌ƒX ‚Ì‚µ‚«‚¢’l‚ƃŒƒX”ԍ†‚̐F
14+threshold6=[7,"#ff0000"]; // ‘‚«ž‚Ý‚ª‘½”‚ ‚郌ƒX ‚Ì‚µ‚«‚¢’l‚ƃŒƒX”ԍ†‚̐F
15+//==========–¼‘OEIDŒŸõ‚É‚æ‚郌ƒX‚̑т̐FŽw’èi16i”–”‚ÍWebŒ`Ž®‚̐F–¼‚ÅŽw’èB‚¢‚­‚‚łà‰ÂBƒAƒ‹ƒtƒ@ƒxƒbƒg‚͏¬•¶Žš‚Å‚¨Šè‚¢j
16+var foundResColor =new Array("#ffdfee","#eeffdf","#ffeedf","#dfffee","#eedfff","#ffffe1");
17+//==========’PŒêŒŸõ‚É‚æ‚éƒnƒCƒ‰ƒCƒgFŽw’èi“¯ãj
18+var highlightColor=new Array("#ffff66","#a0ffff","#99ff99","#ff9999","#ff66ff","#880000","#00aa00","#886800","#004699","#990099");
19+//==========ˆÈ‰º‚̓XƒNƒŠƒvƒg–{•¶‚Å‚·‚æB
20+// ƒCƒxƒ“ƒgƒnƒ“ƒhƒ‰FonClick,onScroll,onMousemove
21+// ŠO•”ŠÖ”FaddAnchor,checkAnchor,tohan,searchPopup
22+// ŠO•”•Ï”FanchorHead,browser,fp
23+// ‹tŽQÆ‚Ì“Á’¥FƒCƒxƒ“ƒg”­¶DT‚ɑΉž‚·‚éDD‰º‚ɁADL-DT-DD\‘¢‚ðì¬‚·‚éB
1124 //==========CSS‚̏o—Í
1225 var nCSS='';
13-nCSS+='#foundResult{position:absolute;top:expression(body.scrollTop+25);right:18px;padding:2px 5px;z-index:6;background-color:white;border:1px solid #999}';
26+nCSS+='#foundPanel {position:absolute;top:expression(body.scrollTop+25);right:18px;padding:2px 5px;z-index:6;background-color:white;border:1px solid #999;visibility:hidden}';
27+nCSS+='#foundPanel div{padding-left:5px;text-align:right;font-size:100%;}';
1428 nCSS+='.refResult{margin:0.5em 0.3em; border:1px solid #666;padding-right:0px}';
1529 nCSS+='.refResult{border-top:none}';
1630 nCSS+='.refResult dt{margin-right:0px;}';
1731 nCSS+='.refResult dd{margin-left:0.8em;}';
1832 document.write('<style type="text/css">'+nCSS+'</style>\n');
19-//==========ŒŸõ‚É‚æ‚éFŽw’èi16i”–”‚ÍWebŒ`Ž®‚̐F–¼‚ÅŽw’èB‚¢‚­‚‚łà‰Âj
20-var foundColor = new Array("#ffdfee","#eeffdf","#ffeedf","#dfffee","#eedfff","#ffffe1");
2133 var nCSS='';
22-for(var css=0;css<foundColor.length;css++){
23- nCSS+='#COLOR'+css+" a{border-color:"+foundColor[css]+"}";
24- nCSS+='#COLOR'+css+" a:hover{border-color:red}";
34+for(var css in foundResColor){
35+ var c=foundResColor[css].replace(/#/,"");
36+ nCSS+='#COLOR'+c+" a{border-color:"+foundResColor[css]+"}\n";
37+ nCSS+='#COLOR'+c+" a:hover{border-color:red}\n";
2538 }
2639 document.write('<style type="text/css">'+nCSS+'</style>\n');
27-//==========ƒOƒ[ƒoƒ‹•Ï”
40+//=========ŠO•”ƒtƒ@ƒCƒ‹‹¤—p‚̃Oƒ[ƒoƒ‹•Ï”
2841 var dts=document.getElementsByTagName('DT');
2942 var dds=document.getElementsByTagName('DD');
30-var fR;
43+var idHash=new Array(); var refHash=new Array();
44+var foundRes,highlight;
3145 //==========ID‚ÆŽQÆ‚ðƒnƒbƒVƒ…‚ÉŠi”[
32-var idHash=new Array(); var refHash=new Array(); var searchEnd=0;
46+// ”z—ñ‚̃nƒbƒVƒ…‚æ‚èŒy‚¢‚Á‚Û‚¢‚̂ŁA‹ó”’‹æØ‚è‚Ì’l‚É‚æ‚é’Pƒ‚ȃnƒbƒVƒ…‚É‚µ‚Ä‚Ý‚éƒeƒXƒgB
47+// setEndIdx:–{•¶‚Ì“¯ƒŒƒX‚ðd•¡ˆ—‚µ‚È‚¢‚悤‚ɁAHash‰»ˆÊ’u‚Æ‚µ‚Ä‚Ìdts‚̍ŏIindex‚ð‹L‰¯
48+// setEndNum:–{•¶ˆÈŠOƒŒƒX‚ðd•¡ˆ—‚µ‚È‚¢‚悤‚ɁAÅIƒŒƒX”ԍ†‚ð‹L‰¯
49+var setEndIdx=setEndNum=0;
3350 function setHash(){
34- var l=dts.length;
35- if(dts[l-1].rel=="setEnd"){return} // ÅŒã‚Ü‚Å’²¸Ï‚Ý‚È‚ç‰ñ”ð
36- for(var i=searchEnd;i<l;i++){
51+ //var t0=new Date();
52+ var l=Math.min(dts.length,dds.length);
53+ var lastNum=l ? parseInt(dts[l-1].firstChild.innerText) : 0;
54+ if(isNaN(lastNum)&&l>1){lastNum=parseInt(dts[l-2].firstChild.innerText)} //Footer‚ ‚è‚È‚çˆê‚‘O
55+ if(l==0 || lastNum<=setEndNum){return} // ÅŒã‚Ü‚Å’²¸Ï‚Ý‚È‚ç‰ñ”ð
56+ for(var i=setEndIdx;i<l;i++){
3757 if(dds[i].parentElement.className=="refResult"){continue} // ‹tŽQÆ“à‚ÌDD‚È‚ç‰ñ”ð
3858 var num=dts[i].firstChild.innerText; var span=dts[i].lastChild;
3959 // ID
40- var t=getID(span); idHash[t] = idHash[t] ? idHash[t]+" "+num : num;
41- // ref
60+ var t=getID(span); if(t&&t.length>3){idHash[t] = idHash[t] ? idHash[t]+" "+num : num;} // ???‚âID:0,ID:#(@ƒ]ƒk)‚̓Xƒ‹[B
61+ // ‰æ‘œ”Â
62+ var imgURL=getIMG(span);
63+ if(imgURL){
64+ var dd=dts[i].nextSibling;
65+ if(tp && imgURL && !dd.getElementsByTagName("IMG").length){
66+ var aObj=(dd.innerText)?'<br><a href="'+imgURL+'">'+imgURL+'</a>':'<a href="'+imgURL+'">'+imgURL+'</a>';
67+ if(!beID && imgURL.match(/kako/)){/*dd.insertAdjacentHTML("beforeEnd","<br>Be‚ɃƒOƒCƒ“‚µ‚Ä‚È‚¢‚Ǝ擾‚Å‚«‚Ü‚¹‚ñ");*/}else{dd.insertAdjacentHTML("beforeEnd",aObj)}
68+ }
69+ }
70+ // ref,IMG
4271 var ddAnc=dds[i].getElementsByTagName("A");
43- for(var j=ddAnc.length;j--;){
44- if(checkAnchor(ddAnc[j].href)!=1){continue}
45- var anc=tohan(ddAnc[j].innerText.replace(/[>„]/g,""));
46- if(anc.match(/(\d*)\D+(\d*)/)){
47- var start=parseInt(RegExp.$1); var end=parseInt(RegExp.$2);
48- if(end-start>100){continue} // >>1-1000‚Æ‚©‚͉ؗí‚ɃXƒ‹[
49- else if(num-end<3 && start==1){continue} // >>1-n(’¼‘OƒŒƒX)‚ÍŽ‚Ë,‚Æ‚©‚àƒXƒ‹[
50- for(var k=start;k<=end;k++){
51- if(refHash[k] && refHash[k].indexOf(num)!=-1){continue} // d•¡‚̓Xƒ‹[
52- if(num>=k){refHash[k]=refHash[k] ? refHash[k]+" "+num : num;} // –¢—ˆ‚ւ̃Aƒ“ƒJ[‚̓Xƒ‹[
72+ for(var j=0;j<ddAnc.length;j++){
73+ if (checkAnchor(ddAnc[j].href)==0){
74+ continue;
75+ }else if(checkAnchor(ddAnc[j].href)==1){
76+ var anc=tohan(ddAnc[j].innerText.replace(/[>„]/g,""));var start,end;
77+ if(anc.match(/(\d*)\D+(\d*)/)){
78+ start=parseInt(RegExp.$1); end=parseInt(RegExp.$2);
79+ if( (end-start>100) || (num-end<4 && start==1) ){continue} // >>1-1000‚Æ‚©>>1-n(’¼‘OƒŒƒX)‚Æ‚©‚͉ؗí‚ɃXƒ‹[
80+ }else{
81+ start=end=parseInt(anc);
5382 }
54- }else{anc=parseInt(anc);
55- if(refHash[anc] && refHash[anc].indexOf(num)!=-1){continue} // d•¡‚̓Xƒ‹[
56- if(num>=anc){refHash[anc]=refHash[anc] ? refHash[anc]+" "+num : num;} // –¢—ˆ‚ւ̃Aƒ“ƒJ[‚̓Xƒ‹[
83+ var k=start-1;do{k++;
84+ if((!refHash[k] || refHash[k].indexOf(num)==-1) && num>k){refHash[k]=refHash[k] ? refHash[k]+" "+num : num;} // d•¡‚â–¢—ˆ‚ւ̃Aƒ“ƒJ[‚̓Xƒ‹[
85+ }while(k<end);
86+ }else if(imageExt2(ddAnc[j].href) && onOpenLoad!=0){
87+ if(onOpenLoad==1){if(dds[i].previousSibling.className!="new"){continue}}
88+ insButton(ddAnc[j],ddAnc[j].href);
5789 }
5890 }
5991 }
60- dts[l-1].rel="setEnd"; searchEnd=l;
92+ setEndIdx=l;setEndNum=lastNum;
93+ //var t1=new Date(); var t=(t1-t0)/1000; if(t){alert(t+"•b");}
94+}
95+// ƒXƒŒƒbƒhƒEƒBƒ“ƒhƒE’†S‚É‘OŒã5ƒŒƒX‚𒅐F
96+var resUnit=new Array();
97+function searchColoring(){
6198 if(!coloring){return;} // ’…F•s—v‚È‚çI—¹
62- for(var i=l;i--;){
63- if(!dts[i].innerText){continue}
64- //if(dts[i].innerText.match(/id:/i)){ // ID‚ª‚È‚¢”‚ŁA‚‘¬‰»‚·‚é‚©‚àH
65- var span=dts[i].lastChild; var t=getID(span); if(browser=="ƒzƒbƒgƒ]ƒk‚Q"){span=span.lastChild}
66- if(t && idHash[t] && span){
67- var idResult=idHash[t].split(/\s/); if(t.match(/\?\?\?/)){idResult="";idHash[t]="";}
68- if (idResult.length>=threshold2[0]){span.style.color=threshold2[1];span.title="“¯ˆêID ("+idResult.length+"‰ñ)\n"+idHash[t]}
69- else if(idResult.length>=threshold1[0]){span.style.color=threshold1[1];span.title="“¯ˆêID ("+idResult.length+"‰ñ)\n"+idHash[t]}
70- else if(idResult.length==1){span.title="“¯ˆêID‚Í\n‚ ‚è‚Ü‚¹‚ñ"}
71- }
72- //}
73- var imgURL=getIMG(span);
74- if(imgURL){dds[i].insertAdjacentHTML("afterBegin",'<img src="'+imgURL+'"><br>')}
75- //
76- var numA=dts[i].firstChild; var num=numA.innerText;
77- if(refHash[num]){
78- var refResult=refHash[num].split(/\s/);
79- if (refResult.length>=threshold4[0]){numA.style.color=threshold4[1];dts[i].title="‚±‚ê‚ւ̃ŒƒX ("+refResult.length+"ŒÂ)\n"+refHash[num];}
80- else if(refResult.length>=threshold3[0]){numA.style.color=threshold3[1];dts[i].title="‚±‚ê‚ւ̃ŒƒX ("+refResult.length+"ŒÂ)\n"+refHash[num];}
81- else{numA.title="‚±‚ê‚ւ̃ŒƒX‚Í‚È‚¢–Í—l"}
99+ if(!scr){scr=lightmode ? document.body : document.getElementById("dl");}
100+ var nowScrollPos=scr.scrollTop+document.body.clientHeight/2;
101+ var l=Math.min(dts.length,dds.length);var st,ed;
102+ // dt‚ÌoffsetTop‚ðŠi”[i25ƒŒƒX’PˆÊj
103+ if(resUnit.length<=Math.floor(dts.length/25)){resUnit[0]=0;
104+ for(var i=25;i<l;i+=25){resUnit[i/25]=dts[i].offsetTop;}
105+ }
106+ // Œ»Ý‚Ç‚Ì‚ ‚½‚è‚܂ŃXƒNƒ[ƒ‹‚µ‚Ä‚é‚©’²¸
107+ var rul=resUnit.length-1;
108+ if (rul==0) {st=0;ed=l-1;} //25–¢–ž
109+ else if(resUnit[0]>nowScrollPos) {st=0;ed=24;} //0-24
110+ else if(resUnit[rul]<nowScrollPos){st=l-26;ed=l-1;} // ÅI25ƒŒƒX
111+ else{
112+ for(var i=rul;i--;){
113+ if(resUnit[i+1]>nowScrollPos&&resUnit[i]<=nowScrollPos){st=i*25;ed=st+25;break}
82114 }
83115 }
84-}
85-var regIMG=new RegExp(".*?\\s.*?\\s.*:.*?\\sIMG:(.*?)(\\s|$)"); // ‰æ‘œ‚à‰Â”\‚É‚µ‚Ä‚Ý‚é
86-function getIMG(obj){
87- if(regIMG.test(obj.innerText)){
88- var filename=RegExp.$1;
89- var tmp=filename.match(/(\d\d\d\d)(\d\d\d\d)(\d\d)/);
90- var fileurl="http://up01.2ch.io/_img/"+RegExp.$1+"/"+RegExp.$1+RegExp.$2+"/"+RegExp.$3+"/"+filename;
91- return(fileurl)
92- }else{return(false)}
93-}
94-//==========–¼‘OEIDŒŸõ“™
95-// ID‚ÌŒŸõEíœ
96-function searchID(obj){
97- var singleColor=event.altKey;
98- var decoy=obj.parentElement ? obj.parentElement : obj;
99- var reg=getID(obj);
100- if(!decoy.id.match(/^COLOR/)){
101- if(!idHash[reg]){return}
102- var target=new Array();target=idHash[reg].split(" ");
103- // ƒJƒ‰[‘I‘ð
104- var c = singleColor ? 0 : selectColor();
105- if (c=="restart"){c=0;singleColor=true}
106- else if(c=="exit"){return;}
107- // ŒŸõ
108- for(i in target){var dt=getDTfromAnc(target[i]);activate(dt,c);}
109- foundReturn(target);
110- }else{
111- clearResult(obj);return;
116+ // Œ»Ý‚Ì”ÍˆÍ“à‚©‚çƒEƒBƒ“ƒhƒE‚̐^‚ñ’†‚ ‚½‚è‚É•\Ž¦‚µ‚Ă郌ƒX‚ðŽæ“¾i‚±‚±‚Å’…F‚·‚é‚ƁA25ƒŒƒX’PˆÊ‚̐ؑ֎ž‚ɐ”ƒŒƒX‚ª’…F‚³‚ê‚È‚¢j
117+ var dtIdx=0; //if(cp){cp.childNodes[1].value=(st+1)+"-"+(ed+1);cp.style.visibility="visible";}
118+ for(var i=st;i<=ed;i++){if(!dts[i+1]){dtIdx=ed;break;}
119+ if(dts[i+1].offsetTop>nowScrollPos && dts[i].offsetTop<=nowScrollPos){dtIdx=i;break;}
120+ }
121+ // dtIdx‚©‚ç‚»‚ÌŽü•Ó‚ð“Á’è
122+ var start=dtIdx-5;var end=dtIdx+5;//
123+ for(var i=start;i<=end;i++){
124+ if(dts[i]){setSearchColor(dts[i])}
112125 }
113126 }
114-// IDƒ|ƒbƒvƒAƒbƒv
115-function searchPopup(obj){
116- var objs=document.getElementsByTagName(obj.tagName);
117- var reg=getID(obj);if(!reg){return}
118- var target=idHash[reg].split(" ");
119- if(target.length==1){return}
120- if(!obj.rel){obj.rel=obj.href;} obj.href="decoy:";
121- var targetString=""; for(i in target){targetString+=returnString(target[i])} //’†g‚̐؂èo‚µ
122- if(targetString){popup(targetString);}else{obj.href=obj.rel;} //‘Ώۂª‘¶Ý‚µ‚½‚çrel‚É‘Þ”ð‚µ‚Äƒ|ƒbƒvƒAƒbƒv
127+// IDHashArefHash‚ðŒ³‚É’…F
128+function setSearchColor(dt){
129+ if(!dt.innerText){return}
130+ // ID
131+ var span=dt.lastChild; var t=getID(span);//alert(t +"&&"+ idHash[t] +"&&"+ span);
132+ if (browser=="ƒzƒbƒgƒ]ƒk‚Q"){span=span.lastChild}
133+ else if(browser=="A Bone") {span=span.childNodes[1]}
134+ if(t && idHash[t] && span){
135+ var idResult=idHash[t].split(" "); if(t.match(/\?\?\?/)){idResult="";idHash[t]="";}
136+ if (idResult.length>=threshold3[0]){span.style.color=threshold3[1];span.title="“¯ˆêID ("+idResult.length+"‰ñ)\n"+idHash[t]}
137+ else if(idResult.length>=threshold2[0]){span.style.color=threshold2[1];span.title="“¯ˆêID ("+idResult.length+"‰ñ)\n"+idHash[t]}
138+ else if(idResult.length>=threshold1[0]){span.style.color=threshold1[1];span.title="“¯ˆêID ("+idResult.length+"‰ñ)\n"+idHash[t]}
139+ else if(idResult.length==1){span.title="“¯ˆêID‚Í\n‚ ‚è‚Ü‚¹‚ñ"}
140+ }
141+ // ref
142+ var numA=dt.firstChild; var num=numA.innerText;
143+ if(refHash[num]){
144+ var refResult=refHash[num].split(" ");
145+ if (refResult.length>=threshold6[0]){numA.style.color=threshold6[1];dt.title="‚±‚ê‚ւ̃ŒƒX ("+refResult.length+"ŒÂ)\n"+refHash[num];}
146+ else if(refResult.length>=threshold5[0]){numA.style.color=threshold5[1];dt.title="‚±‚ê‚ւ̃ŒƒX ("+refResult.length+"ŒÂ)\n"+refHash[num];}
147+ else if(refResult.length>=threshold4[0]){numA.style.color=threshold4[1];dt.title="‚±‚ê‚ւ̃ŒƒX ("+refResult.length+"ŒÂ)\n"+refHash[num];}
148+ else{numA.title="‚±‚ê‚ւ̃ŒƒX‚Í‚È‚¢–Í—l"}
149+ }
123150 }
124-// –¼‘O‚ÌŒŸõEíœ
125-function search(obj){
126- var singleColor=event.altKey;
127- var objs=document.getElementsByTagName(obj.tagName);
128- var reg=obj.innerText; var target="objs[i].innerText"; //–¼‘OEƒgƒŠƒbƒv
129- var decoy=obj.parentElement ? obj.parentElement : obj;
130- if(!decoy.id.match(/^COLOR/)){
131- // ƒJƒ‰[‘I‘ð
132- var c = singleColor ? 0 : selectColor();
133- if (c=="restart"){c=0;singleColor=true}
134- else if(c=="exit"){return;}
135- // ŒŸõ
136- var found=new Array; var l=objs.length;
137- for(var i=l;i--;){
138- var dt=objs[i].parentElement; if(dt.parentElement.className=="refResult"){continue} // ‹tŽQÆ“à‚ÌDT‚È‚ç‰ñ”ð
139- if(eval(target)==reg){activate(dt,c);found.unshift(dt.firstChild.innerText);}
140- else if(singleColor) {deactivate(dt)}
151+//==========–¼‘OEIDŒŸõ“™
152+function searchPerson(obj){
153+ var by,thisDT,reg;
154+ if (obj.tagName=="DT") {by="ID"; thisDT=obj; reg=getID(obj)}
155+ else if(obj.tagName=="SPAN"){by="ID"; thisDT=obj.parentElement;reg=getID(obj)}
156+ else if(obj.tagName=="U") {by="NAME";thisDT=obj.parentElement; reg=obj.innerHTML.replace(/<B>(.*?)<\/B>/ig,"");if(!reg){reg=RegExp.$1.replace(/<.*?A.*?>/ig,"")}/*–¼‘O‚ª”Žš*/}
157+ else if(obj.tagName=="B") {by="NAME";thisDT=obj.parentElement.parentElement;reg=obj.innerText}
158+ else{return}
159+ if(!thisDT.rel){
160+ var c=selectColor("res"); if(!c){return} var color=new Array(c); // ƒJƒ‰[‘I‘ð
161+ if(by=="ID"){
162+ if(!reg || !idHash[reg]){return} // ID‚È‚µAID:???A–{•¶’†‚Ì‘¼ƒXƒŒ‚̃RƒsƒyID
163+ // ŒŸõƒnƒbƒVƒ…‚É’l‚ðÝ’肵‚āA‚»‚ê‚ÉŠî‚«ƒŒƒX’…F
164+ foundRes[c]=idHash[reg].split(" "); foundRes[c].word="ID:"+reg;
165+ for(i in foundRes[c]){var dt=getDTfromAnc(foundRes[c][i]);toggleResColor(dt,c);}
166+ }else{
167+ var us=document.getElementsByTagName("U"); var l=us.length;
168+ var regName=new RegExp();regName.compile(reg);
169+ // ƒ‹[ƒv’†‚ɃŒƒX’…FE’l‚̐ݒè‚𓯎žŽÀs
170+ for(var i=l;i--;){var dt=us[i].parentElement;
171+ if(dt.parentElement.className=="refResult"){continue} // ‹tŽQÆ“à‚ÌDT‚È‚ç‰ñ”ð
172+ if(regName.test(us[i].innerText)){toggleResColor(dt,c);foundRes[c].unshift(dt.firstChild.innerText);}
173+ }
174+ foundRes[c].word=reg;
141175 }
142- foundReturn(found);
176+ returnFound("res",color);
143177 }else{
144- clearResult(obj);return;
178+ clearColor("res",thisDT.style.backgroundColor);
145179 }
146180 }
147-
148181 // ID•¶Žš—ñ‚Ì’Šo
149-//var regID=new RegExp("ID:(.*)$");
150-var regID=new RegExp(".*?\\s.*?\\s.*:(.*?)(\\s|$)"); // HOST‚â‚炵‚½‚ç‚΂à‰Â”\‚É‚µ‚Ä‚Ý‚é
151-function getID(obj){
152- if(regID.test(obj.innerText)){return(RegExp.$1)}else{return(false)}
182+var regID=new RegExp(); // HOST‚à‰Â”\‚É‚µ‚Ä‚Ý‚é
183+regID.compile(".*?\\s.*?\\s.*:(.*?)(\\s|$)"); // 1000res‚Å0.02•b‚قǍ‚‘¬
184+function getID(span){
185+ if(regID.test(span.innerText)){return(RegExp.$1)}else{return(false)}
153186 }
154-// FÝ’è
155-function activate(obj,c){
156- var color=foundColor[c];
157- obj.rev=obj.style.backgroundColor;
158- obj.style.backgroundColor=color;
159- obj.id="COLOR"+c; // “¯ˆêid‚ª•¡”¶‚¶‚邪ByName‚Å‚Ídt‚Ìname‚©‚çŽæ“¾‚Å‚«‚È‚¢‚½‚ß‚â‚Þ‚È‚µ
187+//==========FÝ’è‰ðœ
188+// ƒIƒuƒWƒFƒNƒg‚̏‰Šú‰»
189+function createHash(name,key,arr,word){
190+ name[key]=arr?arr:new Array();
191+ name[key].word=word?word:"";
192+ name[key].justMovedRes=undefined;
160193 }
161-// F•œ‹A
162-function deactivate(obj){if(!obj){return}
163- obj.style.backgroundColor=obj.rev;
164- if(obj.id!="sizeinfo"){obj.removeAttribute("id");}
165- obj.removeAttribute("rev");
166- obj.removeAttribute("title");
194+// F‘I‘ð(ŠY“–ƒŒƒX”ԍ†”z—ñ‚ðŽ‚½‚È‚¢ƒL[‚ð•Ô‚·)
195+function selectColor(type){
196+ if(!foundRes) {foundRes =new Array();for(var i in foundResColor) {createHash(foundRes,foundResColor[i]);}} // Hash foundRes ={F:ŠY“–ƒŒƒX”ԍ†”z—ñ}
197+ if(!highlight){highlight=new Array();for(var i in highlightColor){createHash(highlight,highlightColor[i]);}} // Hash hightLight={F:ŠY“–ƒŒƒX”ԍ†”z—ñ}
198+ var cHash,cArray,cMess;
199+ if(type=="res"){cHash=foundRes; cArray=foundResColor; cMess="¡‚܂ł̃ŒƒX’…F‚ð‰ðœ‚µ‚Ü‚·‚©H";}
200+ else {cHash=highlight;cArray=highlightColor;cMess="¡‚܂ł̃nƒCƒ‰ƒCƒg‚ð‰ðœ‚µ‚Ü‚·‚©H";}
201+ var i=0; while(cHash[cArray[i]].word){
202+ i++; if(i==cArray.length){if(confirm(cMess)){clearColor(type);i=0;break}else{i=null;break}}
203+ }
204+ return(cArray[i]);
167205 }
168-// ƒJƒ‰[‘I‘ð
169-function selectColor(){
170- var c=0;
171- while(document.getElementById("COLOR"+c)){
172- c++;
173- if(!foundColor[c]){if(confirm("F‚ð‰Šú‰»‚µ‚Ü‚·‚©H")){return("restart")}else{return("exit")}}
206+// F‰ðœiƒnƒbƒVƒ…A‘ΏہAfoundPanelj
207+function clearColor(type,color){
208+ var cHash=(type=="res")?foundRes:highlight;
209+ if(event && event.altKey){color=""}
210+ for(var i in cHash){
211+ if(type=="res"){
212+ if(color && i!=color){continue} // Žw’èF‚Å‚È‚¯‚ê‚΃Xƒ‹[
213+ for(var j in cHash[i]){
214+ if(event.srcElement.value=="DEL"){removeRes(getDTfromAnc(cHash[i][j]))}else{toggleResColor(getDTfromAnc(cHash[i][j]))}
215+ }
216+ cHash[i]=new Array();
217+ document.getElementById("c"+i).removeNode(true);
218+ }else{
219+ var strongs=document.getElementsByTagName("STRONG");
220+ var reg=new RegExp(i);
221+ if(!color.match(i)){continue} // Žw’èF‚Å‚È‚¯‚ê‚΃Xƒ‹[
222+ for(var j=0;j<strongs.length;j++){
223+ if(strongs[j].style.backgroundColor==i){
224+ if(event.srcElement.value=="DEL"){removeRes(strongs[j].parentElement.previousSibling);j--}else{strongs[j].removeNode(false);j--}
225+ }
226+ }
227+ cHash[i]=new Array();
228+ if(document.getElementById("c"+i)){document.getElementById("c"+i).removeNode(true);} // and,orŒŸõ‚Å‚PF–Ú‚Ì‚Ý
229+ }
174230 }
175- return(c);
231+ if(!fp.hasChildNodes()){fp.style.visibility="hidden";searched=false;}
176232 }
177-// Œ‹‰Ê•\Ž¦
178-function foundReturn(found){
179- if(!fR){document.body.insertAdjacentHTML('afterBegin','<div id="foundResult"></div>');fR=document.getElementById("foundResult");}
180- //dt‚Ìtitle‚É
181- for(var i=found.length;i--;){dt=getDTfromAnc(found[i]);dt.title=found.join(" ");}
182- //foundResult‚É
183- var buttons='<input type="button" value="CLR" onclick="clearResult(this)" title="Alt‰Ÿ‰ºŽž\n’…FƒŒƒX‘S‚Ä"><input type="button" value="DEL" onclick="clearResult(this)" title="Alt‰Ÿ‰ºŽž\n’…FƒŒƒX‘S‚Ä">';
184- if(found.length>=20 && confirm("20ˆÈã‚ ‚邯‚Ç•\Ž¦‚·‚éH")==false){
185- fR.innerHTML=buttons; fR.title=found.join(" ");
233+// ƒŒƒXFƒgƒOƒ‹
234+function toggleResColor(dt,c){
235+ if(!dt){return} // for-in‚Å‘—‚ç‚ê‚é”ԍ†ˆÈŠO‚Ìobj‚È‚çI—¹
236+ if(c){
237+ dt.rev=dt.style.backgroundColor;
238+ dt.rel="colored";
239+ dt.id ="COLOR"+c.replace(/#/,"");
240+ dt.style.backgroundColor=c;
186241 }else{
187- for(var i=0;i<found.length;i++){found[i] = addAnchor(found[i],found[i])}
188- fR.innerHTML=found.join(" ")+buttons;
242+ dt.style.backgroundColor=dt.rev;
243+ if(dt.id.match(/COLOR/)){dt.removeAttribute("id")}//else{alert("dt‚ÉCOLOR***ˆÈŠO‚Ìidi"+dt.id+"j‚ªÝ’肳‚ê‚Ä‚¢‚Ü‚·")}
244+ dt.removeAttribute("rev");
245+ dt.removeAttribute("rel");
189246 }
190- fR.style.visibility="visible";
191247 }
192-// Œ‹‰ÊÁ‹ŽAŒ‹‰Êíœ
193-function clearResult(obj){
194- var fromObj=obj.parentElement;
195- var singleColor=event.altKey;
196- var result=new Array();var arrayElement; var numbers=fromObj.title ? fromObj.title : fromObj.innerText;
197- if(singleColor){result=dts; arrayElement="result[i]";}
198- else {result=numbers.split(" ");arrayElement="getDTfromAnc(result[i])";}
199- var l=result.length;
200- if(!result[0]){
201- /* ŒŸõŒ‹‰Êƒ[ƒ‚Å‚àresult‚ªnull‚É‚È‚ç‚È‚¢‘΍ô */
202- }else if(event.srcElement.value!="DEL"){
203- for(var i=l;i--;){
204- var dt=eval(arrayElement);
205- deactivate(dt);
206- }
248+// ŒŸõŒ‹‰Ê‚ÉŠî‚«Á‹Ž
249+function removeRes(dt){if(!dt){return} // cHash[i][j]=ID:xxxxxxxx‚Ì‚Æ‚«
250+ if(browser=="Live2ch"){location.href='func:ABONECLEAR?'+dt.firstChild.innerText;} // Live‚Ì‚Ý-“§–¾‚ ‚ځ`‚ñ
251+ dt.nextSibling.removeNode(true);dt.removeNode(true);
252+}
253+//==========Œ‹‰Ê•\Ž¦
254+// ƒŒƒX”ԍ†ƒŠƒXƒgiƒ|ƒbƒvƒAƒbƒvƒAƒ“ƒJ[‚ðŠÜ‚ށj
255+function returnFound(type,color){
256+ var cHash=(type=="res")?foundRes:highlight;
257+ var nDIV="";var numArray=cHash[color[0]]; var display=new Array(["none","POP"],["inline","LST"]);
258+ if(searchView=="resPopup" || numArray.length>=listLimit){display=display.reverse();}
259+ // ƒ|ƒbƒvƒAƒbƒv
260+ var nTT="";for(var i=0;i<color.length;i++){nTT+='<tt style="background-color:'+color[i]+'"> '+cHash[color[i]].word+'</tt>';}
261+ nDIV+='<span rel="'+type+'" style="display:'+display[0][0]+'">'+nTT+'</span>';
262+ // ƒŠƒXƒg
263+ var nA="";for(var i=0;i<numArray.length;i++){nA+=addAnchor(numArray[i],numArray[i])+" "}
264+ nDIV+='<tt style="background-color:'+color[0]+'" style="display:'+display[1][0]+'"> '+nA+'</tt>';
265+ // ŒÂ”
266+ nDIV+='&nbsp;'+numArray.length+' ';
267+ var buttons='<input type="button" value="'+display[0][1]+'" onclick="changeSearchView();blur()"><input type="button" value="É" onclick="moveToSearchRes(\''+type+'\',\''+color+'\')" title="‰º‚ÖŒŸõ"><input type="button" value="È" onclick="moveToSearchRes(\''+type+'\',\''+color+'\')" title="ã‚ÖŒŸõ"><input type="button" value="CLR" onclick="clearColor(\''+type+'\',\''+color+'\')" title="Alt‰Ÿ‰ºŽž\n’…FƒŒƒX‘S‚Ä"><input type="button" value="DEL" onclick="clearColor(\''+type+'\',\''+color+'\')" title="Alt‰Ÿ‰ºŽž\n’…FƒŒƒX‘S‚Ä">';
268+ fp.innerHTML+='<div id="c'+color[0]+'">'+nDIV+buttons+'</div>';
269+ fp.style.visibility="visible";searched=true;
270+}
271+// ‘ΏۃŒƒX‚ɃWƒƒƒ“ƒv
272+var markedDT;
273+function moveToSearchRes(type,color){
274+ if(color.match(/(.*?),/)){color=RegExp.$1}
275+ var scope = (event && event.srcElement.value=="È") ? false : true ;
276+ var numArray= (type=="res") ? foundRes[color] : highlight[color];
277+ if(isNaN(numArray.justMovedRes)){numArray.justMovedRes=0}
278+ else{
279+ markedDT.style.borderColor="#999";
280+ if(scope){numArray.justMovedRes++;if(numArray.justMovedRes>=numArray.length){numArray.justMovedRes--;alert("‚±‚ê‚æ‚艺‚É‚Í‚ ‚è‚Ü‚¹‚ñ")}}
281+ else {numArray.justMovedRes--;if(numArray.justMovedRes<0){numArray.justMovedRes++;alert("‚±‚ê‚æ‚èã‚É‚Í‚ ‚è‚Ü‚¹‚ñ")}}
282+ }
283+ markedDT=getDTfromAnc(numArray[numArray.justMovedRes]); markedDT.style.borderColor="red";
284+ markedDT.scrollIntoView(true);
285+ setTimeout('markedDT.style.borderColor="#999"',5000);
286+}
287+// ƒ|ƒbƒvƒAƒbƒv‚ƃŠƒXƒg•\Ž¦Ø‚è‘Ö‚¦
288+function changeSearchView(){
289+ var e=event.srcElement;
290+ if(e.value=="POP"){
291+ e.value="LST";
292+ e.parentElement.childNodes[0].style.display="inline";
293+ e.parentElement.childNodes[1].style.display="none";
207294 }else{
208- for(var i=l;i--;){
209- var dt=eval(arrayElement); var dd=dt.nextSibling;
210- //Live‹@”\’ljÁ - “§–¾‚ ‚ځ`‚ñ
211- if(browser=="Live2ch"){location.href='func:ABONECLEAR?'+dt.firstChild.innerText;}
212- dt.removeNode(true); dd.removeNode(true);
213- }
295+ e.value="POP";
296+ e.parentElement.childNodes[0].style.display="none";
297+ e.parentElement.childNodes[1].style.display="inline";
214298 }
215- if(fR){fR.innerText="";fR.style.visibility="hidden";}
216299 }
217300
218301 //==========’PŒêŒŸõ
219-function findIt(word){
220- if(!word){
221- var word = prompt("ŒŸõ‚·‚镶Žš‚ð“ü—Í‚µ‚Ä‚­‚¾‚³‚¢B","");
222- word = unescape(escape(word).split("%00")[0]); //IE5‚̃oƒO‘΍ô
302+function findIt(arg){createSearchPanel(arg);}
303+var searchWindow=null;
304+// ŒŸõƒEƒBƒ“ƒhƒE‚Ì•\Ž¦
305+function createSearchPanel(arg){ // ê—pƒuƒ‰ƒEƒU‚Å‚ÌmodelessDialog‚Ö‚ÌŠO•”“ǂݍž‚݂ł́AdialogArguments‚ª‘—‚ê‚È‚¢‚Ì‚Å’¼Ú‘‚«o‚·
306+ if(arg){word=arg}
307+ if(searchWindow && !searchWindow.closed){return}
308+ var skinPath=document.getElementsByName("SkinPath")[0].content;
309+ searchWindow=showModelessDialog("",window,'dialogWidth:500px;dialogHeight:200px;dialogTop:0px;dialogLeft:0px;help:no;resizable:yes;status:no;unadorned:yes;');
310+ var nWin='<html><head><title>’PŒê‚ÌŒŸõ<\/title>'
311+ +'<script type="text/javascript">function submitEvent(){var fo=document.forms[0]; dialogArguments.word=fo.word.value; var i=-1;do{i++;dialogArguments.expression =fo.expression[i].value;}while(!fo.expression[i].checked); var i=0; while(fo.searchTarget[i]){dialogArguments.searchTarget[fo.searchTarget[i].value]=fo.searchTarget[i].checked;i++;} var i=-1;do{i++;dialogArguments.searchView =fo.searchView[i].value;}while(!fo.searchView[i].checked); dialogArguments.searchWord();}</script>'
312+ +'<style type="text/css">body{background:ThreeDFace;padding:0.5em;overflow:auto} fieldset{padding:0.5em;margin-top:0.5em;} legend,label,input{font:message-box;}</style>'
313+ +'<\/head><body onunload="unloadEvent()"><form onsubmit="submitEvent();return false;"><table width="100%"><tr><td valign="top" colspan="3">'
314+ +'<label for="word">ŒŸõ•¶Žš—ñF</label><input type="text" name="word" id="word" size="50" value="'+word+'" tabindex="0"><br>'
315+ +'</td><td align="right" valign="top" rowspan="2">'
316+ +'<input type="submit" name="submit" value="@ŒŸ@õ@" tabindex="7"><br><br><input type="button" name="cancel" value="ƒLƒƒƒ“ƒZƒ‹" onclick="window.close()" tabindex="8">'
317+ +'</td></tr><tr valign="top">'
318+ +'<td><fieldset><legend>ŒŸõ•û–@</legend><input type="radio" name="expression" value="default" id="tDef" tabindex="1"> <label for="tDef">’ʏ팟õ</label><br><input type="radio" name="expression" value="regExp" id="tReg"> <label for="tReg">³‹K•\Œ»</label><br><input type="radio" name="expression" value="multiAND" id="tAND"> <label for="tAND">ANDŒŸõ</label><br><input type="radio" name="expression" value="multiOR" id="tOR"> <label for="tOR">ORŒŸõ</label></fieldset></td>'
319+ +'<td><fieldset><legend>ŒŸõ‘ΏÛ</legend><input type="checkbox" name="searchTarget" value="name" id="tName" tabindex="2" checked> <label for="tName">–¼‘O</label><br><input type="checkbox" name="searchTarget" value="mail" id="tMail" tabindex="3" checked> <label for="tMail">ƒ[ƒ‹</label><br><input type="checkbox" name="searchTarget" value="id" id="tID" tabindex="4" checked> <label for="tID">“ú•t‚ÆID</label><br><input type="checkbox" name="searchTarget" value="mess" id="tMess" tabindex="5" checked> <label for="tMess">–{•¶</label></fieldset></td>'
320+ +'<td><fieldset><legend>Œ‹‰Ê•\Ž¦</legend><input type="radio" name="searchView" value="resList" id="rList" tabindex="6"> <label for="rList">ƒŒƒX”ԍ†‚ð•\Ž¦</label><br><input type="radio" name="searchView" value="resPopup" id="rPop"> <label for="rPop">ƒŒƒX‚ðƒ|ƒbƒvƒAƒbƒv</label><br><input type="radio" name="searchView" value="resJump" id="rJump"> <label for="rJump">ƒŒƒX‚ÖƒWƒƒƒ“ƒv</label></fieldset></td>'
321+ +'</tr></table></form><\/body><\/html>';
322+ searchWindow.document.write(nWin);
323+ sdf=searchWindow.document.forms[0]; sdf.elements[0].select();
324+ var ex=sdf.expression;for(var i=0;i<ex.length;i++){if(ex[i].value==expression){ex[i].checked=true}}
325+ var sv=sdf.searchView;for(var i=0;i<sv.length;i++){if(sv[i].value==searchView){sv[i].checked=true}}
326+ range=document.body.createTextRange();
327+}
328+// ŒŸõˆ—ƒƒCƒ“
329+var word="";var range;var searchTarget={"word":true};
330+function searchWord(){
331+ if(!word){return}
332+ var matchs=new Array(); var color=new Array();
333+ // ŒŸõ•û–@
334+ if(expression=="regExp" || expression=="default" || (expression.match(/multi/) && !word.match(/\s/))){ // AND/OR‚ňê’PŒê‚È‚çdefault‚ÅŒŸõ
335+ // ŒŸõŒêŽw’èid•¡”rœ‚ō‚‘¬‰»Hj
336+ if(expression=="regExp"){
337+ var regWord=word.replace(/[\^\$]/g,"");
338+ var reg=new RegExp(regWord,"g"); var tmpArr=range.text.match(reg); var tmp;
339+ if(!tmpArr || !tmpArr.length){tmpArr=new Array(tmpArr)} // ŒŸõŒ‹‰Ê0or1‚È‚çA”z—ñì¬
340+ tmpArr.sort();for(var i=0;i<tmpArr.length;i++){if(tmp!=tmpArr[i]){matchs.push(tmpArr[i])}tmp=tmpArr[i]}
341+ if(!matchs || !matchs.length){matchs[0]=word} // ŒŸõŒ‹‰Ê0or1‚È‚çA”z—ñì¬
342+ }else{matchs[0]=word}
343+ // ƒnƒCƒ‰ƒCƒg
344+ for(var i=0;i<matchs.length;i++){color.push(setHighlight(matchs[i]));}
345+ highlight[color[0]].word=word;
346+ }else{
347+ // ŒŸõŒêŽw’è
348+ var matchs=word.split(" "); var tmpArr=new Array(); var tmp;
349+ // ƒnƒCƒ‰ƒCƒg¨d•¡ˆ—
350+ for(var i=0;i<matchs.length;i++){
351+ color.unshift(setHighlight(matchs[i]));
352+ highlight[color[0]].word=matchs[i];
353+ tmpArr=tmpArr.concat(highlight[color[0]])
354+ }
355+ color.reverse();tmpArr.sort();createHash(highlight,color[0],"",matchs[0]); // ˆê’U‰Šú‰»
356+ var judge = (expression=="multiAND") ? "tmp==tmpArr[i]" : "tmp!=tmpArr[i]";
357+ for(var i=0;i<tmpArr.length;i++){if(eval(judge)){highlight[color[0]].push(tmpArr[i])}tmp=tmpArr[i]} // ŒŸõŒ‹‰Ê‚Íhighlight[color[0]]‚É“ü‚ê‚é
223358 }
224- if(!word || word=="null"){return}
359+ // Œ‹‰Ê•\Ž¦
360+ if (searchView=="resList") {returnFound("search",color);searchWindow.close();}
361+ else if(searchView=="resPopup"){returnFound("search",color);searchWindow.close();}
362+ else if(searchView=="resJump") {returnFound("search",color);searchWindow.close();if(highlight[color[0]].length){moveToSearchRes("search",color.join(","))}}
363+}
364+// ƒnƒCƒ‰ƒCƒgŒŸõ
365+function setHighlight(reg){
225366 // ƒJƒ‰[‘I‘ð
226- var singleColor=event.altKey;
227- var c = singleColor ? 0 : selectColor();
228- if (c=="restart"){c=0;singleColor=true}
229- else if(c=="exit"){return;}
367+ var c=selectColor("highlight"); if(!c){return}
230368 // ŒŸõ
231- var found=new Array; var l=dds.length;
232- var bodyText=document.body.createTextRange();
233- for(var i=l;i--;){
234- var dt=dts[i]; var dd=dds[i]; if(dt.parentElement.className=="refResult"){continue} // ‹tŽQÆ“à‚ÌDT‚È‚ç‰ñ”ð
235- bodyText.moveToElementText(dt); var checkDT=bodyText.findText(word,0);
236- bodyText.moveToElementText(dd); var checkDD=bodyText.findText(word,0);
237- if(checkDT || checkDD){activate(dt,c);found.unshift(dt.firstChild.innerText)}
238- else if(singleColor) {deactivate(dt);}
369+ while(range.findText(reg)){
370+ var dt=range.parentElement();var tag=dt.tagName; var thisRange;
371+ // ŒŸõ‘Ώۂōi‚荞‚Ý
372+ if(tag=="B"||tag=="U"){thisRange="name"}
373+ else if(tag=="DT") {thisRange="mail"}
374+ else if(tag=="SPAN") {thisRange="id"}
375+ else if(tag=="DD" || tag=="A" && dt.parentElement.tagName=="DD"){thisRange="mess"}
376+ else if(tag=="STRONG"){thisRange="word"}
377+ else{/*alert("tagF"+tag+"\ndt:"+dt.outerHTML);*/range.collapse(false);continue;} // ƒŒƒX”ԍ†(A)‚⌟õŒ‹‰ÊŽ©‘Ì(TT)
378+ if(!searchTarget[thisRange]){range.collapse(false);continue;}
379+ // ³‹K•\Œ»‚̈ʒuŽw’èŽq‚ª‚ ‚éê‡A•ïŠÜ—v‘f“à•”‚ōČŸõ
380+ if(expression=="regExp" && word.match(/[\^|\$]/)){
381+ var thisReg=new RegExp(word); var targetText=(tag=="STRONG") ? dt.parentElement.innerText : dt.innerText;
382+ if(!targetText.match(thisReg)){range.collapse(false);continue}
383+ }
384+ // dtŽæ“¾¨ƒŒƒX”ԍ†Žæ“¾¨ƒnƒCƒ‰ƒCƒg
385+ if(dt.tagName!="DT"){
386+ while(dt.tagName!="DT" && dt.tagName!="DD"){dt=dt.parentElement}
387+ if(dt.tagName=="DD"){dt=dt.previousSibling}
388+ }
389+ var num=dt.firstChild.innerText;
390+ if(dt.parentElement.className!="refResult" && num!=highlight[c][highlight[c].length-1]){highlight[c].push(num)} // ‹tŽQÆ“à‚ÌDT,“¯ˆê”ԍ†‚È‚ç‰ñ”ð
391+ range.pasteHTML('<strong style="background-color:'+c+'">'+range.text+'</strong>');
392+ range.collapse(false);
239393 }
240- if(found){foundReturn(found)}
394+ range=document.body.createTextRange(); // ƒŒƒ“ƒW‚ðŒ³‚É–ß‚µ‚Ä‚¨‚­
395+ return(c);
241396 }
242397 //==========‹tŽQÆ
243398 function searchRef(obj){
@@ -245,16 +400,7 @@ function searchRef(obj){
245400 var num=obj.firstChild.innerText;
246401 if(refHash[num]){
247402 var refArr=refHash[num].split(/\s/); var refs="";
248- for(var i=0;i<refArr.length;i++){
249- var dtOrg=getDTfromAnc(refArr[i]); var dt=dtOrg.cloneNode(true); var dd=dtOrg.nextSibling.cloneNode(true);
250- // –{•¶ˆÈŠO‚ðíœ
251- if(dd.lastChild){
252- if(dd.lastChild.tagName=="DL"){dd.lastChild.removeNode(true);} //‹tŽQÆ‚̏œ‹Ž
253- if(dd.lastChild.name){dd.lastChild.removeNode(true);} // LABELNUMBER‚ª‚È‚¢‚à‚Ì‚ÉŒW‚é•s—vƒAƒ“ƒJ[‚̏œ‹Ž
254- }
255- // –{•¶‚ðŠi”[
256- refs+=dt.outerHTML.replace(/name=.*?>/,">")+dd.outerHTML.replace(/<a name=.*>/i,"");
257- }
403+ for(var i=0;i<refArr.length;i++){refs+=returnString(refArr[i]);}
258404 obj.nextSibling.insertAdjacentHTML("beforeEnd",'<dl class="refResult">'+refs+'</dl>')
259405 obj.name="referred";
260406 }
@@ -282,9 +428,26 @@ function getDTfromAnc(num){
282428 var anc=ancs(anchorHead+num);
283429 if(!anc){return("")} //LABELNUMBER‘Ήž‚Ì‚ ‚ځ`‚ñŽá‚µ‚­‚Í–¢o”ԍ†‚È‚çI—¹
284430 var obj=anc.parentElement; //LABELNUMBER‘Ήž‚Ì‚à‚Ì
431+ if(!obj || !obj.tagName){return false;}
285432 if(obj.tagName!="DT"){ //LABELNUMBER”ñ‘Ήž‚Ì‚à‚Ì
286433 if(num==1){if(anc){obj=anc.nextSibling} else{return("")}}
287434 else {if(!anc.nextSibling){obj=anc.parentElement.nextSibling}else{return("")}}
288435 }
289436 return(obj);
290-}
\ No newline at end of file
437+}
438+
439+// ‰æ‘œ”Š֘A
440+var regIMG=new RegExp(".*?\\s.*?\\s.*:.*?\\sIMG:(.*?)(\\s|$)"); // ‰æ‘œ‚à‰Â”\‚É‚µ‚Ä‚Ý‚é
441+function getIMG(obj){
442+ if(regIMG.test(obj.innerText)){
443+ var filename=RegExp.$1;
444+ var tmp=filename.match(/(\d\d\d\d)(\d\d\d\d)(\d\d)/);
445+ var today=new Date();var last=new Date(today-7*24*60*60*1000);var date="";
446+ date+=last.getMonth()<9 ? "0"+(last.getMonth()+1) : last.getMonth()+1;
447+ date+=last.getDate()<10 ? "0"+last.getDate() : last.getDate();
448+ var log= (RegExp.$1+""+RegExp.$2 < last.getYear()+""+date) ? "_kako/" : "_img/";
449+ var fileurl="http://up01.2ch.io/"+log+RegExp.$1+"/"+RegExp.$1+RegExp.$2+"/"+RegExp.$3+"/"+filename;
450+ return(fileurl)
451+ }else{return(false)}
452+}
453+