• R/O
  • HTTP
  • SSH
  • HTTPS

gikonavi: Commit


Commit MetaInfo

Revision7a79136c6d6b3605d4af9096ea259a654615bc14 (tree)
Time2004-10-03 03:37:53
Authorcvs2git <cvs2git>
Commitercvs2git

Log Message

This commit was manufactured by cvs2svn to create tag 'v1_49_0_545'.

Change Summary

Incremental Difference

--- a/ExternalBoardPlugInMain.pas
+++ b/ExternalBoardPlugInMain.pas
@@ -229,8 +229,7 @@ var
229229 // httpSocket : TIdHTTP;
230230 resStream : TMemoryStream;
231231 content : string;
232-const
233- LIVEDOOR_URL = 'http://jbbs.livedoor.jp/';
232+
234233 begin
235234
236235 {$IFDEF DEBUG}
@@ -271,8 +270,7 @@ begin
271270 Result := socket.ResponseCode;
272271 if (Length( content ) = 0) and (Result = 206) then
273272 Result := 304;
274- //したらばJBBSはヘッダにエラー情報が載るらしいので、ここでチェック
275- if ( AnsiPos(LIVEDOOR_URL, inURL) > 0 ) and (Result = 200) then begin
273+ if ( AnsiPos('http://jbbs.livedoor.com/', inURL) > 0 ) and (Result = 200) then begin
276274 if( AnsiPos('STORAGE IN', socket.Response.RawHeaders.Text) > 0 ) then begin
277275 Result := 302;
278276 end;
--- a/Favorite.pas
+++ b/Favorite.pas
@@ -117,50 +117,13 @@ function TFavoriteBoardItem.GetItem : TBoard;
117117 var
118118 protocol, host, path, document, port, bookmark : string;
119119 BBSID{, BBSKey} : string;
120- tmpURL, boardURL : string;
120+ tmpURL : string;
121121 // category : TCategory;
122- i, bi: Integer;
123- tmpThread: TThreadItem;
124- tmpBoard: TBoard;
125122 begin
126123
127124 if FItem = nil then begin
128125 FItem := BBSsFindBoardFromURL( URL );
129126 if FItem = nil then begin
130- //===== プラグイン
131- try
132- //作業中//
133- bi := High( BoardPlugIns );
134- for i := Low( BoardPlugIns ) to bi do begin
135- if Assigned( Pointer( BoardPlugIns[ i ].Module ) ) then begin
136- case BoardPlugIns[ i ].AcceptURL( URL ) of
137- atThread:
138- begin
139- tmpThread := TThreadItem.Create( BoardPlugIns[ i ], URL );
140- boardURL := tmpThread.BoardPlugIn.GetBoardURL( DWORD( tmpThread ) );
141- FItem := BBSsFindBoardFromURL( boardURL );
142- URL := FItem.URL;
143- tmpThread.Free;
144- break;
145- end;
146- atBoard:
147- begin
148- tmpBoard := TBoard.Create(BoardPlugIns[ i ], URL);
149- FItem := BBSsFindBoardFromURL( tmpBoard.URL );
150- tmpBoard.Free;
151- if FItem <> nil then begin
152- URL := FItem.URL;
153- end;
154- break;
155- end;
156- end;
157- end;
158- end;
159- except
160- // exception が発生した場合は内部処理に任せたいのでここでは何もしない
161- end;
162- end;
163- if FItem = nil then begin
164127 tmpURL := URL;
165128 GikoSys.ParseURI( tmpURL, protocol, host, path, document, port, bookmark );
166129 if GikoSys.Is2chHost( host ) then begin
--- a/Giko.dfm
+++ b/Giko.dfm
@@ -1,11 +1,11 @@
11 object GikoForm: TGikoForm
2- Left = 246
3- Top = 188
2+ Left = 87
3+ Top = 96
44 HorzScrollBar.Visible = False
55 VertScrollBar.Visible = False
66 AutoScroll = False
77 Caption = '-'
8- ClientHeight = 404
8+ ClientHeight = 545
99 ClientWidth = 854
1010 Color = clBtnFace
1111 Font.Charset = SHIFTJIS_CHARSET
@@ -27,7 +27,7 @@ object GikoForm: TGikoForm
2727 TextHeight = 12
2828 object StatusBar: TStatusBar
2929 Left = 0
30- Top = 384
30+ Top = 525
3131 Width = 854
3232 Height = 20
3333 Panels = <
@@ -47,13 +47,13 @@ object GikoForm: TGikoForm
4747 Left = 0
4848 Top = 77
4949 Width = 854
50- Height = 307
50+ Height = 448
5151 Align = alClient
5252 BevelOuter = bvNone
5353 TabOrder = 1
5454 object MessageSplitter: TSplitter
5555 Left = 0
56- Top = 268
56+ Top = 409
5757 Width = 854
5858 Height = 5
5959 Cursor = crVSplit
@@ -66,7 +66,7 @@ object GikoForm: TGikoForm
6666 Left = 0
6767 Top = 0
6868 Width = 854
69- Height = 268
69+ Height = 409
7070 Align = alClient
7171 BevelOuter = bvNone
7272 TabOrder = 0
@@ -74,7 +74,7 @@ object GikoForm: TGikoForm
7474 Left = 145
7575 Top = 0
7676 Width = 5
77- Height = 268
77+ Height = 409
7878 Cursor = crHSplit
7979 AutoSnap = False
8080 ResizeStyle = rsUpdate
@@ -83,7 +83,7 @@ object GikoForm: TGikoForm
8383 Left = 0
8484 Top = 0
8585 Width = 145
86- Height = 268
86+ Height = 409
8787 Align = alLeft
8888 BevelOuter = bvNone
8989 TabOrder = 0
@@ -270,7 +270,7 @@ object GikoForm: TGikoForm
270270 Left = 150
271271 Top = 0
272272 Width = 704
273- Height = 268
273+ Height = 409
274274 Align = alClient
275275 BevelOuter = bvNone
276276 TabOrder = 1
@@ -548,7 +548,7 @@ object GikoForm: TGikoForm
548548 Left = 0
549549 Top = 194
550550 Width = 704
551- Height = 74
551+ Height = 215
552552 Align = alClient
553553 BevelOuter = bvNone
554554 TabOrder = 1
@@ -556,7 +556,7 @@ object GikoForm: TGikoForm
556556 Left = 0
557557 Top = 46
558558 Width = 704
559- Height = 8
559+ Height = 149
560560 Align = alClient
561561 BevelOuter = bvNone
562562 UseDockManager = False
@@ -566,7 +566,7 @@ object GikoForm: TGikoForm
566566 Left = 0
567567 Top = 0
568568 Width = 704
569- Height = 8
569+ Height = 149
570570 Align = alClient
571571 TabOrder = 0
572572 OnEnter = BrowserEnter
@@ -575,7 +575,7 @@ object GikoForm: TGikoForm
575575 OnNewWindow2 = BrowserNewWindow2
576576 OnDocumentComplete = BrowserDocumentComplete
577577 ControlData = {
578- 4C000000C3480000D40000000000000000000000000000000000000000000000
578+ 4C000000C3480000660F00000000000000000000000000000000000000000000
579579 000000004C000000000000000000000001000000E0D057007335CF11AE690800
580580 2B2E12620A000000000000004C0000000114020000000000C000000000000046
581581 8000000000000000000000000000000000000000000000000000000000000000
@@ -584,7 +584,7 @@ object GikoForm: TGikoForm
584584 end
585585 object BrowserBottomPanel: TGikoPanel
586586 Left = 0
587- Top = 54
587+ Top = 195
588588 Width = 704
589589 Height = 20
590590 Align = alBottom
@@ -862,7 +862,7 @@ object GikoForm: TGikoForm
862862 end
863863 object MessagePanel: TPanel
864864 Left = 0
865- Top = 273
865+ Top = 414
866866 Width = 854
867867 Height = 34
868868 Align = alBottom
@@ -1199,7 +1199,7 @@ object GikoForm: TGikoForm
11991199 Left = 4
12001200 Top = 212
12011201 Bitmap = {
1202- 494C010113001800040010001000FFFFFFFFFF10FFFFFFFFFFFFFFFF424D3600
1202+ 494C010113001800040010001000FFFFFFFFFF00FFFFFFFFFFFFFFFF424D3600
12031203 0000000000003600000028000000400000006000000001001000000000000030
12041204 0000000000000000000000000000000000000000000000000000000000000000
12051205 0000000000000000000000000000000000000000000000000000000000000000
@@ -1611,8 +1611,7 @@ object GikoForm: TGikoForm
16111611 FFFFFFFF8000C000E003E0038000C000FC1FFC1F80008000FFEFFFEF80008000
16121612 FFE7FFE780000000FFF7FFF780000000FFF7FFF780000000F7F7F7F780008000
16131613 F7F7F7F780008000F3E7F3E780018001FB9FFB9FC07FC07FFC3FFC3FE0FFE0FF
1614- FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF00000000000000000000000000000000
1615- 000000000000}
1614+ FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF}
16161615 end
16171616 object ItemIcon32: TImageList
16181617 Height = 32
@@ -1620,7 +1619,7 @@ object GikoForm: TGikoForm
16201619 Left = 36
16211620 Top = 212
16221621 Bitmap = {
1623- 494C01010F001300040020002000FFFFFFFFFF10FFFFFFFFFFFFFFFF424D3600
1622+ 494C01010F001300040020002000FFFFFFFFFF00FFFFFFFFFFFFFFFF424D3600
16241623 000000000000360000002800000080000000A0000000010010000000000000A0
16251624 0000000000000000000000000000000000000000000000000000000000000000
16261625 0000000000000000000000000000000000000000000000000000000000000000
@@ -2984,8 +2983,7 @@ object GikoForm: TGikoForm
29842983 FFDFCFFFFFDFCFFF8000FFFFF0001FFFFFE03FFFFFE03FFFC001FFFFF8003FFF
29852984 FFFFFFFFFFFFFFFFE003FFFFFC007FFFFFFFFFFFFFFFFFFFF007FFFFFE00FFFF
29862985 FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF
2987- FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF00000000000000000000000000000000
2988- 000000000000}
2986+ FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF}
29892987 end
29902988 object HotToobarImageList: TImageList
29912989 Left = 4
--- a/Giko.pas
+++ b/Giko.pas
@@ -1105,11 +1105,8 @@ type
11051105 { Public 宣言 }
11061106 // FDownload: TDownload;
11071107 FControlThread: TThreadControl;
1108- procedure MoveToURL(const inURL: string);
1109- function InsertBrowserTab(
1110- ThreadItem : TThreadItem;
1111- ActiveTab : Boolean = True
1112- ) : TBrowserRecord;
1108+ procedure MoveToURL(URL: string);
1109+ procedure InsertBrowserTab(ThreadItem: TThreadItem; ActiveTab: Boolean = True);
11131110 procedure ReloadBBS;
11141111 function GetHttpState: Boolean;
11151112 procedure SetEnabledCloseButton(Enabled: Boolean);
@@ -1194,18 +1191,18 @@ type
11941191 TBrowserRecord = class( TObject )
11951192 private
11961193 FBrowser : TWebBrowser;
1197- FEvent: THTMLDocumentEventSink; //!< ブラウザドキュメントイベント
1194+ FEvent: THTMLDocumentEventSink;//ブラウザドキュメントイベント
11981195 FThread : TThreadItem;
11991196 FLastSize : Integer;
12001197 FRepaint : Boolean;
1201- FMovement : string; //!< スクロール先アンカー
1198+ // FOnlyHundred: Boolean;
12021199 public
12031200 destructor Destroy; override;
12041201 property Browser : TWebBrowser read FBrowser write FBrowser;
12051202 property Thread : TThreadItem read FThread write FThread;
12061203 property LastSize : Integer read FLastSize write FLastSize;
12071204 property Repaint : Boolean read FRepaint write FRepaint;
1208- property Movement : string read FMovement write FMovement;
1205+// property OnlyHundred : Boolean read FOnlyHundred write FOnlyHundred;
12091206 end;
12101207
12111208 var
@@ -1721,7 +1718,7 @@ begin
17211718 //Samba24のファイルチェック
17221719 GikoSys.SambaFileExists();
17231720
1724- //にちゃん語ファイル読み出し
1721+ //タブ自動読み込み (AV発生のため一時封印)
17251722 end;
17261723
17271724 // CoolBar の設定を変数に保存
@@ -1885,12 +1882,6 @@ begin
18851882 if GikoSys.Setting.TabAutoLoadSave then begin
18861883 TabAutoLoadAction.Execute;
18871884 end;
1888- //にちゃん語案内サポート機能
1889- if GikoSys.Setting.GengoSupport then begin
1890- //予定地
1891- //Test向け
1892- end;
1893-
18941885 FStartUp := true;
18951886 end;
18961887 end;
@@ -2877,32 +2868,44 @@ begin
28772868 end else begin
28782869 threadItem := GetActiveContent;
28792870 if Pos('about:blank..', Text) = 1 then begin
2880- wkInt := LastDelimiter( '/', threadItem.URL );
2881- if Pos( '?', Copy( threadItem.URL, wkInt, MaxInt ) ) = 0 then begin
2882- // Thread.URL は PATH_INFO 渡し
2883- URL := Copy( threadItem.URL, 1, LastDelimiter( '/', threadItem.URL ) );
2884- wkInt := LastDelimiter( '/', Text );
2885- if Pos( '?', Copy( Text, wkInt, MaxInt ) ) = 0 then
2886- // Text も PATH_INFO 渡し
2887- URL := URL + Copy( Text, LastDelimiter( '/', Text ) + 1, MaxInt )
2888- else
2889- // Text は QUERY_STRING 渡し
2890- URL := URL + Copy( Text, LastDelimiter( '?', Text ) + 1, MaxInt );
2871+ if (AnsiPos('http://jbbs.livedoor.com/', threadItem.URL) <> 0) or
2872+ (AnsiPos('http://jbbs.shitaraba.com/', threadItem.URL) <> 0) then begin
2873+ URL := Copy(threadItem.URL, 1, LastDelimiter('/',threadItem.URL));
2874+ Gikosys.GetPopupResNumber(Text,PathRec.FSt,PathRec.FTo);
2875+ if ( PathRec.FSt <> 0 ) and ( PathRec.FTo <> 0 ) then
2876+ buf := IntToStr(PathRec.FSt) + '-' + IntToStr(PathRec.FTo)
2877+ else if( PathRec.FSt <> 0 ) then
2878+ buf := IntToStr(PathRec.FSt);
2879+ end else if AnsiPos('machi.to/bbs/', threadItem.URL) <> 0 then begin
2880+ URL := threaditem.URL;
2881+ buf := Copy(Text,AnsiPos('&st=',Text),Length(Text)-AnsiPos('&st=',Text) + 1);
28912882 end else begin
2892- // Thread.URL は QUERY_STRING 渡し
2893- URL := Copy( threadItem.URL, 1, LastDelimiter( '?', threadItem.URL ) );
2894- wkInt := LastDelimiter( '/', Text );
2895- if Pos( '?', Copy( Text, wkInt, MaxInt ) ) = 0 then begin
2896- // Text は PATH_INFO 渡し
2897- // URL に板とキーが足らないので Text から頂戴する
2898- wkInt := LastDelimiter( '/', Copy( Text, 1, wkInt - 1 ) );
2899- wkInt := LastDelimiter( '/', Copy( Text, 1, wkInt - 1 ) );
2900- URL := Copy( URL, 1, Length( URL ) - 1 ) + Copy( Text, wkInt, MaxInt );
2883+ if (AnsiPos('&', threadItem.URL) <> 0) and (AnsiPos('&', Text) = 0)then begin
2884+ URL := threadItem.URL;
2885+ buf := Copy(Text,LastDelimiter('/',Text)+1,Length(Text)-LastDelimiter('/',Text));
2886+ if AnsiPos('-', buf) <> 0 then begin
2887+ buf2 := Copy(buf, AnsiPos('-', buf) + 1, Length(buf));
2888+ Delete(buf, AnsiPos('-', buf), Length(buf));
2889+ if (IsNumeric(buf)) and (IsNumeric(buf2)) then
2890+ buf := Format('&st=%s&to=%s', [buf, buf2])
2891+ else if (IsNumeric(buf)) then
2892+ buf := Format('&st=%s&to=%s', [buf, buf])
2893+ else if (IsNumeric(buf)) then
2894+ buf := Format('&st=%s&to=%s', [buf2, buf2])
2895+ else
2896+ buf := '';
2897+ end else begin
2898+ if IsNumeric(buf) then
2899+ buf := Format('&st=%s&to=%s', [buf, buf])
2900+ else
2901+ buf := '';
2902+ end;
29012903 end else begin
2902- // Text も QUERY_STRING 渡し
2903- URL := URL + Copy( Text, LastDelimiter( '?', Text ) + 1, MaxInt )
2904+ URL := Copy(threadItem.URL, 1, LastDelimiter('/',threadItem.URL));
2905+ buf := Copy(Text,LastDelimiter('/',Text)+1,Length(Text)-LastDelimiter('/',Text));
29042906 end;
29052907 end;
2908+ URL := URL + buf;
29062909 end else begin
29072910 URL := Text;
29082911 end;
@@ -2911,9 +2914,8 @@ begin
29112914 if (PathRec.FNoParam) then begin
29122915 PathRec.FSt := 1;
29132916 PathRec.FTo := 1;
2914- end else begin
2917+ end else
29152918 Gikosys.GetPopupResNumber(URL,PathRec.FSt,PathRec.FTo);
2916- end;
29172919 GikoSys.ParseURI( URL, Protocol, Host, Path, Document, Port, Bookmark );
29182920
29192921 if PathRec.FDone or (not GikoSys.Is2chHost( Host )) then begin
@@ -2940,10 +2942,10 @@ begin
29402942 // wkIntTo := 1;
29412943 //if PathRec.FFirst then
29422944 // wkIntSt := 1;
2943- //if PathRec.FStBegin then //http://〜〜〜〜/-50というとき
2944- // wkIntSt := 1; //
2945- //if PathRec.FToEnd then //http://〜〜〜〜/50-というとき
2946- // wkIntTo := 9999; // どちらの場合も、GetPopupResNumberでうまく番号を調整するのでふよう。
2945+ if PathRec.FStBegin then
2946+ wkIntSt := 1;
2947+ if PathRec.FToEnd then
2948+ wkIntTo := 9999;
29472949
29482950 //ATitle := ActiveFileName <> PathRec.FKey;
29492951 if (FActiveContent <> nil) and (FActiveContent.Thread.URL = URL) then
@@ -3459,7 +3461,6 @@ var
34593461 s: string;
34603462 boardPlugIn : TBoardPlugIn;
34613463 i: Integer;
3462- browserRec : TBrowserRecord;
34633464 begin
34643465 try
34653466 if Item.DownType = gdtBoard then
@@ -3501,15 +3502,11 @@ begin
35013502 end;
35023503 if GikoSys.Setting.BrowserTabVisible then begin
35033504 if GetActiveContent = Item.ThreadItem then
3504- browserRec := InsertBrowserTab(Item.ThreadItem)
3505+ InsertBrowserTab(Item.ThreadItem)
35053506 else if (ListView.Selected <> nil ) and ( TObject(ListView.Selected.Data) is TThreadItem ) and ( Item.ThreadItem = TThreadItem(ListView.Selected.Data)) then
3506- browserRec := InsertBrowserTab(Item.ThreadItem, True)
3507+ InsertBrowserTab(Item.ThreadItem, True)
35073508 else
3508- browserRec := InsertBrowserTab(Item.ThreadItem, False);
3509- if browserRec.Thread = BrowserNullTab.Thread then begin
3510- browserRec.Movement := BrowserNullTab.Movement;
3511- BrowserNullTab.Movement := '';
3512- end;
3509+ InsertBrowserTab(Item.ThreadItem, False);
35133510 end else begin
35143511 if (GetActiveContent = Item.ThreadItem) or (FActiveContent = nil) or(FActiveContent.Browser = BrowserNullTab.Browser) then
35153512 InsertBrowserTab(Item.ThreadItem);
@@ -3642,17 +3639,14 @@ begin
36423639 end;
36433640 end;}
36443641
3645-function TGikoForm.InsertBrowserTab(
3646- ThreadItem : TThreadItem;
3647- ActiveTab : Boolean = True
3648-) : TBrowserRecord;
3642+procedure TGikoForm.InsertBrowserTab(ThreadItem: TThreadItem; ActiveTab: Boolean = True);
3643+
36493644 var
3650- i, j, idx : Integer;
3651- favItem : TFavoriteThreadItem;
3645+ i, j, idx: Integer;
3646+ favItem : TFavoriteThreadItem;
36523647 newBrowser : TBrowserRecord;
36533648 begin
36543649
3655- Result := nil;
36563650 if Threaditem = nil then Exit;
36573651
36583652 if ThreadItem.IsLogFile then begin
@@ -3671,7 +3665,6 @@ begin
36713665 for i := 0 to BrowserTab.Tabs.Count - 1 do begin
36723666 if TObject(BrowserTab.Tabs.Objects[i]) is TBrowserRecord then begin
36733667 if TBrowserRecord(BrowserTab.Tabs.Objects[i]).Thread = ThreadItem then begin
3674- Result := TBrowserRecord( BrowserTab.Tabs.Objects[i] );
36753668 if TBrowserRecord(BrowserTab.Tabs.Objects[i]).FBrowser = nil then begin
36763669 for j := BrowserTab.Tabs.Count - 1 downto 0 do begin
36773670 if TBrowserRecord(BrowserTab.Tabs.Objects[j]).FBrowser = TWebBrowser(FBrowsers[BROWSER_COUNT - 1]) then begin
@@ -3758,7 +3751,6 @@ begin
37583751 BrowserTab.TabIndex := i;
37593752 end;
37603753 end;
3761- Result := newBrowser;
37623754 if(ActiveTab) or (idx = -1) then begin
37633755 BrowserTab.OnChange(nil);
37643756 end;
@@ -3768,7 +3760,6 @@ begin
37683760 BrowserNullTab.Browser := Browser;
37693761 end;
37703762 BrowserNullTab.thread := ThreadItem;
3771- Result := BrowserNullTab;
37723763 BrowserTab.TabIndex := -1;
37733764 SetContent(BrowserNullTab);
37743765 end;
@@ -3859,13 +3850,11 @@ begin
38593850
38603851
38613852 try
3862- {
38633853 if ThreadItem.UnRead then begin
38643854 ThreadItem.ParentBoard.UnRead := ThreadItem.ParentBoard.UnRead - 1;
38653855 if ThreadItem.ParentBoard.UnRead < 0 then ThreadItem.ParentBoard.UnRead := 0;
38663856 TreeView.Refresh;
38673857 end;
3868- }
38693858 if(FActiveContent <> nil) and (FActiveContent <> Thread) then begin
38703859 if (FActiveContent.Browser <> BrowserNullTab.Browser) then
38713860 ShowWindow(FActiveContent.Browser.Handle, SW_HIDE);
@@ -4008,16 +3997,12 @@ end;
40083997 procedure TGikoForm.SetListViewType(AViewType: TGikoViewType; SelectText: string; KubetsuChk: Boolean);
40093998 var
40103999 Board: TBoard;
4011- i: Integer;
40124000 begin
40134001 if ActiveList is TBoard then begin
4014- for i := Length( BBSs ) - 1 downto 0 do begin
4015- BBSs[i].SelectText := SelectText;
4016- BBSs[i].KubetsuChk := KubetsuChk;
4017- end;
40184002 Board := TBoard(ActiveList);
4019-// Board.ParentCategory.ParenTBBS.SelectText := SelectText;
4020-// Board.ParentCategory.ParenTBBS.KubetsuChk := KubetsuChk;
4003+
4004+ Board.ParentCategory.ParenTBBS.SelectText := SelectText;
4005+ Board.ParentCategory.ParenTBBS.KubetsuChk := KubetsuChk;
40214006 // Board.SelectText := SelectText;
40224007 // Board.KubetsuChk := KubetsuChk;
40234008 ViewType := AViewType;
@@ -6694,21 +6679,8 @@ begin
66946679 Assigned( BrowserRecord.Thread ) then begin
66956680 threadItem := BrowserRecord.Thread;
66966681
6697- if (BrowserRecord <> nil) and (Length( BrowserRecord.Movement ) > 0) then begin
6698- if threadItem.UnRead then begin
6699- threadItem.UnRead := False;
6700- threadItem.ParentBoard.UnRead := ThreadItem.ParentBoard.UnRead - 1;
6701- if threadItem.ParentBoard.UnRead < 0 then threadItem.ParentBoard.UnRead := 0;
6702- TreeView.Refresh;
6703- ListView.Refresh;
6704- end;
6705- BrowserMovement( BrowserRecord.Movement, BrowserRecord );
6706- BrowserRecord.Movement := '';
6707- end else if threadItem.UnRead then begin
6682+ if threadItem.UnRead then begin
67086683 threadItem.UnRead := False;
6709- threadItem.ParentBoard.UnRead := ThreadItem.ParentBoard.UnRead - 1;
6710- if threadItem.ParentBoard.UnRead < 0 then threadItem.ParentBoard.UnRead := 0;
6711- TreeView.Refresh;
67126684 BrowserMovement( 'new', BrowserRecord );
67136685 ListView.Refresh;
67146686 end else if threadItem.ScrollTop <> 0 then begin
@@ -7494,10 +7466,11 @@ begin
74947466 end;
74957467 end;
74967468
7497-procedure TGikoForm.MoveToURL(const inURL: string);
7469+procedure TGikoForm.MoveToURL(URL: string);
7470+
74987471 var
74997472 protocol, host, path, document, port, bookmark : string;
7500- URL, protocol2, host2, path2, document2, port2, bookmark2 : string;
7473+ URL2, protocol2, host2, path2, document2, port2, bookmark2 : string;
75017474 tmp1, tmp2: string;
75027475 BBSID, BBSKey: string;
75037476 tmpBoard, Board: TBoard;
@@ -7510,22 +7483,20 @@ var
75107483 // boardNode : TTreeNode;
75117484 shiftDown : Boolean;
75127485 ctrlDown : Boolean;
7513- stRes, edRes : Int64;
7514- browserRec : TBrowserRecord;
75157486 begin
75167487
7517- GikoSys.ParseURI( inURL, protocol, host, path, document, port, bookmark );
7518- GikoSys.Parse2chURL( inURL, path, document, BBSID, BBSKey );
7488+ GikoSys.ParseURI( URL, protocol, host, path, document, port, bookmark );
7489+ GikoSys.Parse2chURL( URL, path, document, BBSID, BBSKey );
75197490
75207491
75217492 shiftDown := GetAsyncKeyState(VK_SHIFT) = Smallint($8001);
7522- ctrlDown := GetAsyncKeyState(VK_CONTROL) = Smallint($8001);
7523- if shiftDown then begin
7524- GikoSys.OpenBrowser(inURL, gbtUserApp);
7525- Exit;
7526- end else if ctrlDown then begin
7527- GikoSys.OpenBrowser(inURL, gbtIE);
7528- Exit;
7493+ ctrlDown := GetAsyncKeyState(VK_CONTROL) = Smallint($8001);
7494+ if shiftDown then begin
7495+ GikoSys.OpenBrowser(URL, gbtUserApp);
7496+ Exit;
7497+ end else if ctrlDown then begin
7498+ GikoSys.OpenBrowser(URL, gbtIE);
7499+ Exit;
75297500 end;
75307501
75317502 //===== プラグイン
@@ -7534,16 +7505,15 @@ begin
75347505 bi := High( BoardPlugIns );
75357506 for i := Low( BoardPlugIns ) to bi do begin
75367507 if Assigned( Pointer( BoardPlugIns[ i ].Module ) ) then begin
7537- case BoardPlugIns[ i ].AcceptURL( inURL ) of
7508+ case BoardPlugIns[ i ].AcceptURL( URL ) of
75387509 atThread:
75397510 begin
7540- tmpThread := TThreadItem.Create( BoardPlugIns[ i ], inURL );
7511+ tmpThread := TThreadItem.Create( BoardPlugIns[ i ], URL );
75417512 boardURL := tmpThread.BoardPlugIn.GetBoardURL( DWORD( tmpThread ) );
75427513 Board := BBSsFindBoardFromURL( boardURL );
75437514 if Board = nil then begin
7544- //break;
75457515 // ※作っても追加するところが無いので激しく保留
7546- //GikoSys.OpenBrowser(inURL, gbtUserApp);
7516+ //GikoSys.OpenBrowser(URL, gbtUserApp);
75477517 //Exit;
75487518 {
75497519 Board := GikoSys.GetUnknownBoard( tmpThread.BoardPlugIn, boardURL );
@@ -7555,40 +7525,34 @@ begin
75557525 GikoSys.ReadSubjectFile( Board );
75567526 Exit;
75577527 end;
7558- ThreadItem := Board.FindThreadFromFileName( tmpThread.FileName );
7559- if ThreadItem = nil then begin
7560- ThreadItem := tmpThread;
7561- Board.Insert( 0, ThreadItem );
7562- if ActiveList is TBoard then begin
7563- if TBoard(ActiveList) = Board then
7564- ListView.Items.Count := ListView.Items.Count + 1;
7565- end;
7566- GikoSys.GetPopupResNumber( inURL, stRes, edRes );
7567- browserRec := InsertBrowserTab( ThreadItem );
7568- if (browserRec <> nil) and (stRes > 0) then
7569- browserRec.Movement := IntToStr( stRes );
7528+ end;
7529+
7530+ ThreadItem := Board.FindThreadFromFileName( tmpThread.FileName );
7531+ if ThreadItem = nil then begin
7532+ ThreadItem := tmpThread;
7533+ Board.Insert( 0, ThreadItem );
7534+ if ActiveList is TBoard then begin
7535+ if TBoard(ActiveList) = Board then
7536+ ListView.Items.Count := ListView.Items.Count + 1;
7537+ end;
7538+ InsertBrowserTab( ThreadItem );
7539+ DownloadContent( ThreadItem );
7540+ Exit;
7541+ end else begin
7542+ tmpThread.Free;
7543+ InsertBrowserTab( ThreadItem );
7544+ if not ThreadItem.IsLogFile then begin
75707545 DownloadContent( ThreadItem );
7571- Exit;
7572- end else begin
7573- tmpThread.Free;
7574- GikoSys.GetPopupResNumber( inURL, stRes, edRes );
7575- browserRec := InsertBrowserTab( ThreadItem );
7576- if ThreadItem.IsLogFile then begin
7577- if (browserRec <> nil) and (stRes > 0) then
7578- BrowserMovement( IntToStr( stRes ), browserRec );
7579- end else begin
7580- if (browserRec <> nil) and (stRes > 0) then
7581- browserRec.Movement := IntToStr( stRes );
7582- DownloadContent( ThreadItem );
7583- end;
7584- Exit;
75857546 end;
7547+ Exit;
75867548 end;
7549+
7550+ //Exit;
75877551 end;
75887552
75897553 atBoard:
75907554 begin
7591- tmpBoard := TBoard.Create(BoardPlugIns[ i ], inURL);
7555+ tmpBoard := TBoard.Create(BoardPlugIns[ i ], URL);
75927556 Board := BBSsFindBoardFromURL( tmpBoard.URL );
75937557 tmpBoard.Free;
75947558 if Board <> nil then begin
@@ -7607,7 +7571,7 @@ begin
76077571
76087572
76097573 if (Length( Trim(BBSKey) ) > 0) and (Length( Trim(BBSID) ) > 0) then begin
7610- boardURL := GikoSys.Get2chThreadURL2BoardURL( inURL );
7574+ boardURL := GikoSys.Get2chThreadURL2BoardURL( URL );
76117575 Board := BBSsFindBoardFromURL( boardURL );
76127576 if Board = nil then
76137577 Board := BBSsFindBoardFromBBSID( BBSID );
@@ -7619,23 +7583,23 @@ begin
76197583 end;
76207584 if Board = nil then begin
76217585 // 入るべき板が見つからなかったので、普通のブラウザで開く
7622- GikoSys.OpenBrowser(inURL, gbtUserApp);
7586+ GikoSys.OpenBrowser(URL, gbtUserApp);
76237587 Exit;
76247588 end else begin
76257589 // 外部の板なのに2chのURLにされてしまった奴をここで確認する
7626- URL := Board.URL;
7627- GikoSys.ParseURI(URL , protocol2, host2, path2, document2, port2, bookmark2 );
7590+ URL2 := Board.URL;
7591+ GikoSys.ParseURI(URL2 , protocol2, host2, path2, document2, port2, bookmark2 );
76287592 tmp1 := Copy(host, AnsiPos('.', host) + 1, Length(host));
76297593 tmp2 := Copy(host2, AnsiPos('.', host2) + 1, Length(host2));
76307594 if ( not GikoSys.Is2chHost(tmp1)) and (tmp1 <> tmp2) then begin
7631- GikoSys.OpenBrowser(inURL, gbtUserApp);
7595+ GikoSys.OpenBrowser(URL, gbtUserApp);
76327596 Exit;
76337597 end;
76347598 end;
76357599
76367600 if not Board.IsThreadDatRead then
76377601 GikoSys.ReadSubjectFile(Board);
7638- URL := GikoSys.Get2chBrowsableThreadURL( inURL );
7602+ URL := GikoSys.Get2chBrowsableThreadURL( URL );
76397603 ThreadItem := Board.FindThreadFromURL( URL );
76407604 // 過去ログ倉庫から、ダウソしたスレが発見できないのでここで探すようにする (2004/01/22)
76417605 if ThreadItem = nil then begin
@@ -7648,9 +7612,9 @@ begin
76487612 {shiftDown := GetAsyncKeyState(VK_SHIFT) = Smallint($8001);
76497613 ctrlDown := GetAsyncKeyState(VK_CONTROL) = Smallint($8001);
76507614 if shiftDown then
7651- GikoSys.OpenBrowser(URL1, gbtUserApp)
7615+ GikoSys.OpenBrowser(URL, gbtUserApp)
76527616 else if ctrlDown then
7653- GikoSys.OpenBrowser(URL1, gbtIE)
7617+ GikoSys.OpenBrowser(URL, gbtIE)
76547618 else begin
76557619 }
76567620 ThreadItem := TThreadItem.Create( nil, URL );
@@ -7664,34 +7628,25 @@ begin
76647628 if TBoard(ActiveList) = Board then
76657629 ListView.Items.Count := ListView.Items.Count + 1;
76667630 end;
7667- GikoSys.GetPopupResNumber( inURL, stRes, edRes );
7668- browserRec := InsertBrowserTab(ThreadItem);
7669- if (browserRec <> nil) and (stRes > 0) then
7670- browserRec.Movement := IntToStr( stRes );
7631+ InsertBrowserTab(ThreadItem);
76717632 DownloadContent(ThreadItem);
76727633 {end;}
76737634 end else begin
7674- if ThreadItem.IsLogFile then begin
7675- GikoSys.GetPopupResNumber( inURL, stRes, edRes );
7676- browserRec := InsertBrowserTab(ThreadItem);
7677- if (browserRec <> nil) and (stRes > 0) then
7678- browserRec.Movement := IntToStr( stRes );
7679- end else begin
7635+ if ThreadItem.IsLogFile then
7636+ InsertBrowserTab(ThreadItem)
7637+ else begin
76807638 if AnsiPos(Host, Board.URL) = 0 then
76817639 ThreadItem.DownloadHost := Host
76827640 else
76837641 ThreadItem.DownloadHost := '';
7684- GikoSys.GetPopupResNumber( inURL, stRes, edRes );
7685- browserRec := InsertBrowserTab(ThreadItem);
7686- if (browserRec <> nil) and (stRes > 0) then
7687- browserRec.Movement := IntToStr( stRes );
7642+ InsertBrowserTab(ThreadItem);
76887643 DownloadContent(ThreadItem);
76897644 end;
76907645 end;
76917646 end else begin
7692- Board := BBSsFindBoardFromURL( inURL );
7647+ Board := BBSsFindBoardFromURL( URL );
76937648 if Board = nil then begin
7694- GikoSys.OpenBrowser(inURL, gbtAuto);
7649+ GikoSys.OpenBrowser(URL, gbtAuto);
76957650 end else begin
76967651 if FActiveBBS <> Board.ParentCategory.ParenTBBS then
76977652 ShowBBSTree( Board.ParentCategory.ParenTBBS );
@@ -9010,10 +8965,9 @@ begin
90108965 ModifySelectList;
90118966 end else if Length( SelectComboBox.Text ) = 0 then
90128967 begin
9013- {* SelectComboBox.Textが空でも、入力途中でEscしたとか
9014- * 空のときにDelキーを押したとかなので、スレの絞込みを維持する。
9015- * (ここでは何もしない)
9016- *}
8968+ AllItemAction.Checked := True;
8969+ LogItemAction.Checked := False;
8970+ NewItemAction.Checked := False;
90178971 end else begin
90188972 // チラつくと嫌だから、一応押してあるときだけ処理する
90198973 if AllItemAction.Checked then
@@ -10134,12 +10088,7 @@ procedure TGikoForm.BrowserTabMouseUp(Sender: TObject;
1013410088 begin
1013510089 if FDragWFirst <> true then begin
1013610090 FDragWFirst := false;
10137-{
10138- end else if (abs( X - FMouseDownPos.X ) < Mouse.DragThreshold)
10139- and (abs( Y - FMouseDownPos.Y ) < Mouse.DragThreshold) then begin
10140-(*}
10141- end else begin
10142-//*)
10091+ end else if (X = FMouseDownPos.X) and (Y = FMouseDownPos.Y) then begin
1014310092 if GikoSys.Setting.ListOrientation = gloHorizontal then begin
1014410093 if GikoSys.Setting.ListWidthState = glsMin then begin
1014510094 BrowserMaxAndFocusAction.Execute;
@@ -11165,16 +11114,12 @@ begin
1116511114 SelectListItem(List);
1116611115 for i := 0 to List.Count - 1 do begin
1116711116 if TObject(List[i]) is TThreadItem then begin
11168- if (TThreadItem(List[i]).UnRead) then begin
11169- TThreadItem(List[i]).UnRead := false;
11170- TThreadItem(List[i]).ParentBoard.UnRead := TThreadItem(List[i]).ParentBoard.UnRead - 1;
11171- end;
11117+ TThreadItem(List[i]).UnRead := false;
11118+ TThreadItem(List[i]).ParentBoard.UnRead := TThreadItem(List[i]).ParentBoard.UnRead - 1;
1117211119 end;
1117311120 end;
1117411121 if TreeView.Visible then
1117511122 TreeView.Refresh;
11176- if ListView.Visible then
11177- ListView.Refresh;
1117811123 finally
1117911124 List.Free;
1118011125 end;
@@ -11190,16 +11135,12 @@ begin
1119011135 SelectListItem(List);
1119111136 for i := 0 to List.Count - 1 do begin
1119211137 if TObject(List[i]) is TThreadItem then begin
11193- if (TThreadItem(List[i]).IsLogFile) and (not TThreadItem(List[i]).UnRead) then begin
11194- TThreadItem(List[i]).UnRead := true;
11195- TThreadItem(List[i]).ParentBoard.UnRead := TThreadItem(List[i]).ParentBoard.UnRead + 1;
11196- end;
11138+ TThreadItem(List[i]).UnRead := true;
11139+ TThreadItem(List[i]).ParentBoard.UnRead := TThreadItem(List[i]).ParentBoard.UnRead + 1;
1119711140 end;
1119811141 end;
1119911142 if TreeView.Visible then
1120011143 TreeView.Refresh;
11201- if ListView.Visible then
11202- ListView.Refresh;
1120311144 finally
1120411145 List.Free;
1120511146 end;
--- a/GikoSystem.pas
+++ b/GikoSystem.pas
@@ -187,7 +187,7 @@ type
187187 function Is2chHost(Host: string): Boolean;
188188 function Parse2chURL(const url: string; const path: string; const document: string; var BBSID: string; var BBSKey: string): Boolean;
189189 function Parse2chURL2(URL: string): TPathRec;
190- procedure ParseURI(const URL : string; var Protocol, Host, Path, Document, Port, Bookmark: string);
190+ procedure ParseURI(var URL, Protocol, Host, Path, Document, Port, Bookmark: string);
191191 function GetVersionBuild: Integer;
192192 function GetBrowsableThreadURL( inURL : string ) : string;
193193 function GetThreadURL2BoardURL( inURL : string ) : string;
@@ -3424,7 +3424,7 @@ begin
34243424 end;
34253425 end;
34263426
3427-procedure TGikoSys.ParseURI(const URL : string; var Protocol, Host, Path, Document, Port, Bookmark: string);
3427+procedure TGikoSys.ParseURI(var URL, Protocol, Host, Path, Document, Port, Bookmark: string);
34283428 var
34293429 URI: TIdURI;
34303430 begin
--- a/ItemDownload.pas
+++ b/ItemDownload.pas
@@ -1259,10 +1259,8 @@ begin
12591259 OldCnt := Body.IndexOf(oldBody.Strings[ LastIdx ]) + 1;
12601260 until ( OldCnt <> 0 ) or (LastIdx = 0);
12611261
1262- if OldCnt >= Body.Count then OldCnt := Body.Count - 1;
12631262 NewRes := Body.Count - OldCnt;
12641263
1265-
12661264 finally
12671265 oldBody.Free;
12681266 end;
@@ -1299,10 +1297,8 @@ begin
12991297 ThreadItem.AllResCount := ThreadItem.Count;
13001298 ThreadItem.IsLogFile := True;
13011299 ThreadItem.RoundDate := Now;
1302- if not ThreadItem.UnRead then begin
1303- ThreadItem.UnRead := True;
1304- ThreadItem.ParentBoard.UnRead := ThreadItem.ParentBoard.UnRead + 1;
1305- end;
1300+ ThreadItem.UnRead := True;
1301+ ThreadItem.ParentBoard.UnRead := ThreadItem.ParentBoard.UnRead + 1;
13061302 // if ThreadItem.RoundNo = 6 then
13071303 // ThreadItem.RoundNo := 0;
13081304
--- a/KuroutSetting.dfm
+++ b/KuroutSetting.dfm
@@ -1,6 +1,6 @@
11 object KuroutOption: TKuroutOption
2- Left = 43
3- Top = 114
2+ Left = 311
3+ Top = 171
44 Width = 525
55 Height = 457
66 Caption = #35443#32048#35373#23450
@@ -140,30 +140,6 @@ object KuroutOption: TKuroutOption
140140 TabOrder = 3
141141 end
142142 end
143- object GroupBox1: TGroupBox
144- Left = 14
145- Top = 232
146- Width = 475
147- Height = 57
148- Caption = #12395#12385#12419#12435#35486#26696#20869#27231#33021
149- TabOrder = 2
150- Visible = False
151- object Label5: TLabel
152- Left = 8
153- Top = 16
154- Width = 234
155- Height = 12
156- Caption = #12395#12385#12419#12435#35486#12434#20351#12387#12390#12462#12467#12490#12499#12434#12469#12509#12540#12488#12375#12414#12377#12290
157- end
158- object GengoSupport: TCheckBox
159- Left = 8
160- Top = 32
161- Width = 201
162- Height = 17
163- Caption = #12395#12385#12419#12435#35486#26696#20869#27231#33021#12434#26377#21177#12395#12377#12427
164- TabOrder = 0
165- end
166- end
167143 end
168144 object ColumnTabSheet: TTabSheet
169145 Caption = #35443#32048#35373#23450'2'
--- a/KuroutSetting.pas
+++ b/KuroutSetting.pas
@@ -47,9 +47,6 @@ type
4747 CDownButton: TButton;
4848 BUpButton: TButton;
4949 BDownButton: TButton;
50- GroupBox1: TGroupBox;
51- GengoSupport: TCheckBox;
52- Label5: TLabel;
5350 procedure OkBottonClick(Sender: TObject);
5451 procedure FormCreate(Sender: TObject);
5552 procedure CDeleteButtonClick(Sender: TObject);
@@ -121,8 +118,6 @@ begin
121118 GikoSys.Setting.TimeAdjustSec := 0;
122119 GikoSys.Setting.TimeAdjust := PutPostTimeRadioButton.Checked;
123120
124- GikoSys.Setting.GengoSupport := GengoSupport.Checked;
125-
126121 GikoSys.Setting.KuroutSettingTabIndex := PageControl1.ActivePageIndex;
127122 end;
128123
--- a/Option.dfm
+++ b/Option.dfm
@@ -1,6 +1,6 @@
11 object OptionDialog: TOptionDialog
2- Left = 188
3- Top = 128
2+ Left = 410
3+ Top = 236
44 BorderStyle = bsDialog
55 Caption = #12458#12503#12471#12519#12531
66 ClientHeight = 428
@@ -252,7 +252,7 @@ object OptionDialog: TOptionDialog
252252 Top = 43
253253 Width = 417
254254 Height = 20
255- ItemHeight = 12
255+ ItemHeight = 0
256256 TabOrder = 0
257257 Text = 'BoardURLComboBox'
258258 end
@@ -654,7 +654,7 @@ object OptionDialog: TOptionDialog
654654 Left = 12
655655 Top = 8
656656 Width = 477
657- Height = 41
657+ Height = 64
658658 Caption = #34920#31034#35373#23450
659659 TabOrder = 0
660660 object ThreadListIconCheckBox: TCheckBox
@@ -665,10 +665,18 @@ object OptionDialog: TOptionDialog
665665 Caption = #12473#12524#12483#12489#26356#26032#12450#12452#12467#12531#12434#34920#31034#12377#12427'(&I)'
666666 TabOrder = 0
667667 end
668+ object NonAcquiredCountCheckBox: TCheckBox
669+ Left = 12
670+ Top = 40
671+ Width = 217
672+ Height = 17
673+ Caption = #21462#24471#25968#12398#20195#12431#12426#12395#26410#21462#24471#25968#12434#34920#31034#12377#12427
674+ TabOrder = 1
675+ end
668676 end
669677 object GroupBox16: TGroupBox
670678 Left = 12
671- Top = 52
679+ Top = 76
672680 Width = 477
673681 Height = 64
674682 Caption = #12473#12524#20316#25104#26085#26178#34920#31034#35373#23450
@@ -692,7 +700,7 @@ object OptionDialog: TOptionDialog
692700 end
693701 object GroupBox5: TGroupBox
694702 Left = 12
695- Top = 121
703+ Top = 145
696704 Width = 477
697705 Height = 86
698706 Caption = #12502#12521#12454#12470#12398#26368#22823#21270
@@ -720,7 +728,7 @@ object OptionDialog: TOptionDialog
720728 end
721729 object GroupBox17: TGroupBox
722730 Left = 12
723- Top = 212
731+ Top = 236
724732 Width = 477
725733 Height = 63
726734 Caption = #12502#12521#12454#12470#12479#12502#38750#34920#31034#26178#35373#23450
@@ -758,9 +766,9 @@ object OptionDialog: TOptionDialog
758766 end
759767 object GroupBox18: TGroupBox
760768 Left = 12
761- Top = 278
769+ Top = 302
762770 Width = 477
763- Height = 43
771+ Height = 41
764772 Caption = 'dat'#33853#12385#12473#12524#12477#12540#12488#38918
765773 TabOrder = 4
766774 object DatOchiSortCombo: TComboBox
--- a/Option.pas
+++ b/Option.pas
@@ -90,6 +90,7 @@ type
9090 TabSheet3: TTabSheet;
9191 GroupBox9: TGroupBox;
9292 ThreadListIconCheckBox: TCheckBox;
93+ NonAcquiredCountCheckBox: TCheckBox;
9394 GroupBox16: TGroupBox;
9495 CreationTimeLogsCheckBox: TCheckBox;
9596 FutureThreadCheckBox: TCheckBox;
@@ -765,6 +766,7 @@ begin
765766
766767 //スレッド一覧更新アイコン
767768 ThreadListIconCheckBox.Checked := GikoSys.Setting.ListIconVisible;
769+ NonAcquiredCountCheckBox.Checked := GikoSys.Setting.NonAcquiredCount;
768770 CreationTimeLogsCheckBox.Checked := GikoSys.Setting.CreationTimeLogs;
769771 FutureThreadCheckBox.Checked := GikoSys.Setting.FutureThread;
770772 SelectIntervalEdit.Text := IntToStr(GikoSys.Setting.SelectInterval);
@@ -805,6 +807,7 @@ begin
805807
806808 //TabAutoLoad
807809 TabLoadSave.Checked := Gikosys.Setting.TabAutoLoadSave;
810+
808811 end;
809812
810813 procedure TOptionDialog.SaveSetting;
@@ -997,6 +1000,11 @@ begin
9971000 //スレッド一覧更新アイコン
9981001 GikoSys.Setting.ListIconVisible := ThreadListIconCheckBox.Checked;
9991002
1003+ //取得数、未取得数
1004+ if (GikoSys.Setting.NonAcquiredCount <> NonAcquiredCountCheckBox.Checked) and (GikoForm.ActiveList Is TBoard) then
1005+ FRepaintList := true;
1006+ GikoSys.Setting.NonAcquiredCount := NonAcquiredCountCheckBox.Checked;
1007+
10001008 GikoSys.Setting.CreationTimeLogs := CreationTimeLogsCheckBox.Checked;
10011009 GikoSys.Setting.FutureThread := FutureThreadCheckBox.Checked;
10021010 if StrToIntDef(SelectIntervalEdit.Text, 110) > 55 then
--- a/Setting.pas
+++ b/Setting.pas
@@ -346,6 +346,8 @@ type
346346
347347 //スレッド一覧更新アイコン表示
348348 FListIconVisible: Boolean;
349+ //取得数ではなく未取得を表示する
350+ FNonAcquiredCount: Boolean;
349351
350352 //スレッド一覧でLogのあるスレッドのみスレ作成日を表示するか
351353 FCreationTimeLogs: Boolean;
@@ -390,10 +392,6 @@ type
390392
391393 //Tab自動保存
392394 FTabAutoLoadSave : Boolean;
393-
394- //にちゃん語案内サポート機能
395- F2chSupport : Boolean;
396-
397395 // エディタ
398396 FSpaceToNBSP : Boolean; ///< 半角スペース、Tab を &nbsp; に置換
399397 FAmpToCharRef : Boolean; ///< '&' を &amp; に置換
@@ -648,6 +646,7 @@ type
648646 property BrowserAutoMaximize: TGikoBrowserAutoMaximize read FBrowserAutoMaximize write FBrowserAutoMaximize;
649647
650648 property ListIconVisible: Boolean read FListIconVisible write FListIconVisible;
649+ property NonAcquiredCount: Boolean read FNonAcquiredCount write FNonAcquiredCount;
651650 property CreationTimeLogs: Boolean read FCreationTimeLogs write FCreationTimeLogs;
652651 property FutureThread: Boolean read FFutureThread write FFutureThread;
653652
@@ -687,7 +686,6 @@ type
687686 property SelectInterval : Integer read FSelectInterval write FSelectInterval;
688687 //Tab保存
689688 property TabAutoLoadSave: Boolean read FTabAutoLoadSave write FTabAutoLoadSave;
690- property GengoSupport : Boolean read F2chSupport write F2chSupport;
691689 property KuroutSettingTabIndex: Integer read FKuroutSettingTabIndex write FKuroutSettingTabIndex;
692690 end;
693691
@@ -1158,6 +1156,7 @@ begin
11581156
11591157 //スレッド一覧更新アイコン
11601158 FListIconVisible := ini.ReadBool('ThreadList', 'StateIconVisible', True);
1159+ FNonAcquiredCount := ini.ReadBool('ThreadList', 'NonAcquiredCount', False);
11611160 FCreationTimeLogs := ini.ReadBool('ThreadList', 'CreationTimeLogs', True);
11621161 FFutureThread := ini.ReadBool('ThreadList', 'FutureThread', True);
11631162 FSelectInterval := ini.ReadInteger('ThreadList', 'SelectInterval', 110);
@@ -1223,7 +1222,7 @@ begin
12231222 FDeleteSyria := ini.ReadBool('Abon','DeleteSyria',false);
12241223
12251224 // エディタ
1226- FSpaceToNBSP := ini.ReadBool( 'Editor', 'SpaceToNBSP', False );
1225+ FSpaceToNBSP := ini.ReadBool( 'Editor', 'SpaceToNBSP', True );
12271226 FAmpToCharRef := ini.ReadBool( 'Editor', 'AmpToCharRef', False );
12281227
12291228 //Tab自動保存、読み込み
@@ -1457,6 +1456,7 @@ begin
14571456
14581457 //スレッド一覧更新アイコン
14591458 ini.WriteBool('ThreadList', 'StateIconVisible', FListIconVisible);
1459+ ini.WriteBool('ThreadList', 'NonAcquiredCount', FNonAcquiredCount);
14601460 ini.WriteBool('ThreadList', 'CreationTimeLogs',FCreationTimeLogs);
14611461 ini.WriteBool('ThreadList', 'FutureThread', FFutureThread);
14621462 ini.WriteInteger('ThreadList', 'SelectInterval', FSelectInterval);
@@ -1555,15 +1555,11 @@ begin
15551555 ini.WriteBool( 'Editor', 'SpaceToNBSP', FSpaceToNBSP );
15561556 ini.WriteBool( 'Editor', 'AmpToCharRef', FAmpToCharRef );
15571557
1558- //タブ自動保存
15591558 ini.WriteBool('TabAuto', 'TabAutoLoadSave', FTabAutoLoadSave);
1560- //詳細設定
1561- ini.WriteInteger('OptionDialog', 'KuroutTabIndex', FKuroutSettingTabIndex);
15621559
1563- //にちゃん語案内機能
1564- ini.WriteBool('2chSupport', 'Support', F2chSupport);
1560+ ini.WriteInteger('OptionDialog', 'KuroutTabIndex', FKuroutSettingTabIndex);
15651561
1566- ini.UpdateFile;
1562+ ini.UpdateFile;
15671563 finally
15681564 ini.Free;
15691565 end;
--- a/Sort.pas
+++ b/Sort.pas
@@ -17,6 +17,7 @@ var
1717 SortOrder: Boolean;
1818 SortIndex: Integer;
1919 SortNoFlag: Boolean;
20+ SortNonAcquiredCountFlag: Boolean;
2021
2122 implementation
2223
--- a/YofUtils.pas
+++ b/YofUtils.pas
@@ -40,38 +40,11 @@ function MatchesMask(
4040 const filename, mask : string
4141 ) : boolean;
4242
43-/// メタキャラクタを正規表現扱いにならないように置換
43+// メタキャラクタを正規表現扱いにならないように置換
4444 function RegExpEncode(
4545 const text : string
4646 ) : string;
4747
48-{*!
49-\brief 表示メッセージの整形
50-\param msg 表示するメッセージ
51-\param elements 置換単語
52-
53-msg の中の置換される単語は '^番号' で表され、
54-elements は改行によって単語分けされます。<br>
55-
56-<pre><code>
57-elements := IntToStr( 10 ) + #10 + 'hoge';
58-m := MessageStyle(
59- '^0 個の“^1”を置換しました。',
60- elements );
61-</code></pre>
62-
63-で出力される m は「10 個の“hoge”を置換しました。」となります。
64-*}
65-function MessageStyle(
66- const msg : string;
67- const elements : string
68-) : string; overload;
69-
70-function MessageStyle(
71- const msg : string;
72- const elements : TStringList
73-) : string; overload;
74-
7548 type
7649 /// Mode 値がおかしい
7750 EMappedFileModeError = class( Exception );
@@ -104,8 +77,6 @@ const
10477 implementation
10578 //==================================================
10679
107-uses MojuUtils;
108-
10980 // とりあえずの代用品なので chrWhite を考慮していないことに注意!!!
11081 procedure ExtractHttpFields(
11182 const chrSep : TSysCharSet;
@@ -420,38 +391,6 @@ begin
420391
421392 end;
422393
423-function MessageStyle(
424- const msg : string;
425- const elements : string
426-) : string;
427-var
428- list : TStringList;
429-begin
430-
431- list := TStringList.Create;
432- try
433- list.Text := elements;
434- Result := MessageStyle( msg, list );
435- finally
436- list.Free;
437- end;
438-
439-end;
440-
441-function MessageStyle(
442- const msg : string;
443- const elements : TStringList
444-) : string;
445-var
446- i : Integer;
447-begin
448-
449- Result := msg;
450- for i := elements.Count - 1 downto 0 do
451- Result := CustomStringReplace( Result, '^' + IntToStr( i ), elements[ i ], false );
452-
453-end;
454-
455394 { TMappedFile }
456395
457396 {*!
Binary files a/gikoNavi.res and b/gikoNavi.res differ
--- a/readme/readme.txt
+++ b/readme/readme.txt
@@ -89,20 +89,16 @@ Windows Server 2003 Enterprise Edition IE6
8989 ------------------------------
9090 履歴
9191 ------------------------------
92-2004/10/XX
92+2004/XX/XX
9393 Version バタ49
9494 お気に入りの読み込みの高速化による起動時間の短縮
95+ スレ一覧の表示カラム(列)を設定できるようになった
9596 StatusBarにNGワードファイルの名前が出ない不具合の修正
9697 「指定した番号のレスに飛ぶ」機能追加(キー設定で、スレッドカテゴリの一番最後)
98+ レスアンカーでレスポップアップする形式の拡大(チャットちゃんねる等)
9799 ログを削除した際に未読スレッド数 (UnRead) の表示が更新されないバグを修正
98100 ここにレスだと、レスエディターのショートカットキーが設定されない不具合の修正
99101 あぼーん時にココまで読んだと新着レスを調整するのに不具合があったので修正
100- スレッド一覧の表示カラムの設定ができるようになった。「オプション」->「詳細設定」->「詳細設定2」
101- デフォルトでのレスアンカーポップアップが種種の形式に対応
102- 3ちゃんねる(8ちゃんねる)を登録すると2ちゃんねるの板が表示される不具合の解消
103- お気に入りで編集中にスペースキー入力の不具合の修正
104- したらばJBBSの過去ログに関する不具合の修正
105- スレッドのリンクでレス番があるものを踏んだときに、そのレス番号までスクロールするようにした。
106102
107103 2004/09/05
108104 Version バタ48
--- a/res/ExternalBoardPlugIn/ShitarabaJBBSPlugIn.dpr
+++ b/res/ExternalBoardPlugIn/ShitarabaJBBSPlugIn.dpr
@@ -3,7 +3,7 @@ library ShitarabaJBBSPlugIn;
33 {
44 ShitarabaJBBSPlugIn
55 したらば処理ユニット
6- $Id: ShitarabaJBBSPlugIn.dpr,v 1.36 2004/09/30 11:49:44 h677 Exp $
6+ $Id: ShitarabaJBBSPlugIn.dpr,v 1.30 2004/09/06 16:41:41 h677 Exp $
77 }
88
99 uses
@@ -33,7 +33,7 @@ type
3333
3434 private
3535 function Download : TDownloadState;
36- function StorageDownload(AURL : string) : TDownloadState;
36+ function StorageDownload(Path, Document : string) : TDownloadState;
3737 function Write( inName : string; inMail : string; inMessage : string ) : TDownloadState;
3838 function GetRes( inNo : Integer ) : string;
3939 function GetDat( inNo : Integer ) : string;
@@ -281,8 +281,7 @@ var
281281 // i : Integer;
282282 const
283283 BBS_HOST_OLD = 'jbbs.shitaraba.com';
284- BBS_HOST_OLD2 = 'jbbs.livedoor.com';
285- BBS_HOST = 'jbbs.livedoor.jp';
284+ BBS_HOST = 'jbbs.livedoor.com';
286285 THREAD_MARK = '/bbs/read.cgi';
287286 begin
288287
@@ -291,7 +290,7 @@ begin
291290 uri := TIdURI.Create( inURL );
292291 uriList := TStringList.Create;
293292 try
294- if (uri.Host = BBS_HOST_OLD) or (uri.Host = BBS_HOST_OLD2) then
293+ if uri.Host = BBS_HOST_OLD then
295294 uri.Host := BBS_HOST;
296295
297296 ExtractHttpFields( ['/'], [], uri.Path, uriList );
@@ -350,13 +349,12 @@ var
350349
351350 found : Integer;
352351 found2 : Integer;
353- pos : Integer;
354352 board : string;
355353 const
356354 CATEGORY_INPUT = 'カテゴリを入力してください';
357355 KEYWORD_INPUT = '検索する板名を入力してください';
358356 SAVEPATH_SELECT = '保存するファイル名を入力してください';
359- BBS_HOST = 'http://jbbs.livedoor.jp/';
357+ BBS_HOST = 'http://jbbs.livedoor.com/';
360358 label
361359 NextBoard;
362360 begin
@@ -439,12 +437,8 @@ begin
439437
440438 saveText.Add( board );
441439 NextBoard:
442- found := AnsiPos( '<a ', downResult );
440+ found := AnsiPos( '<a ', downResult );
443441 end;
444- pos := saveText.IndexOf('JBBS=/');
445- if pos > 0 then
446- saveText.Delete(pos);
447-
448442 saveText.SaveToFile( savepath );
449443 saveText.Free;
450444 end else begin
@@ -505,14 +499,22 @@ begin
505499 uriList := TStringList.Create;
506500 try
507501 ExtractHttpFields( ['/', '?'], [], uri.Path, uriList );
508- if uriList[ 5 ] = 'l100' then begin
509- FileName := uriList[ 4 ] + '.dat';
510- FilePath := MyLogFolder + uriList[ 2 ] + '\' + uriList[ 3 ] + '\' + uriList[ 4 ] + '.dat';
511- IsLogFile := FileExists( FilePath );
512- end else begin
513- FileName := uriList[ 5 ] + '.dat';
514- FilePath := MyLogFolder + uriList[ 3 ] + '\' + uriList[ 4 ] + '\' + uriList[ 5 ] + '.dat';
502+ if (AnsiPos('.html', uri.Document) = 0) then begin //通常
503+ if uriList[ 5 ] = 'l100' then begin
504+ FileName := uriList[ 4 ] + '.dat';
505+ FilePath := MyLogFolder + uriList[ 2 ] + '\' + uriList[ 3 ] + '\' + uriList[ 4 ] + '.dat';
506+ IsLogFile := FileExists( FilePath );
507+ end else begin
508+ FileName := uriList[ 5 ] + '.dat';
509+ FilePath := MyLogFolder + uriList[ 3 ] + '\' + uriList[ 4 ] + '\' + uriList[ 5 ] + '.dat';
510+ IsLogFile := FileExists( FilePath );
511+ end;
512+ end else begin //過去ログ
513+ //http://jbbs.livedoor.com/game/1578/storage/1086710948.html
514+ FileName := Copy(uri.Document, 1, Length(uri.Document) - 5) + '.dat';
515+ FilePath := MyLogFolder + CustomStringReplace(CustomStringReplace(uri.Path, '/storage', ''), '/', '\') + FileName;
515516 IsLogFile := FileExists( FilePath );
517+
516518 end;
517519 finally
518520 uri.Free;
@@ -549,109 +551,115 @@ var
549551 logStream : TFileStream;
550552 uri : TIdURI;
551553 uriList : TStringList;
552- datURL, tmpURL : string;
553- tmpText: string;
554+ datURL : string;
555+ tmpText: string;
554556 begin
555557
556558 Result := dsError;
557559
558560 uri := TIdURI.Create( ReadURL );
559- uriList := TStringList.Create;
560- try
561- ExtractHttpFields( ['/', '?'], [], uri.Path, uriList );
562- FileName := uriList[ 5 ] + '.dat';
563- // http://jbbs.livedoor.com/bbs/rawmode.cgi/game/1578/1067968274/l100
564- // protocol://host/1/2/3/4/5/uriList.Count - 1
565- if MyLogFolder = '' then begin
566- // どこに保存していいのか分からないので一時ファイルに保存
567- FilePath := TemporaryFile;
568- FIsTemporary := True;
569- end else begin
570- FilePath := MyLogFolder + uriList[ 3 ] + '\' + uriList[ 4 ] + '\' + uriList[ 5 ] + '.dat';
571- FIsTemporary := False;
572- end;
573- finally
561+ if(( AnsiPos('.html', uri.Document) >0 ) and ( AnsiPos('/storage/', uri.Path) > 0 )) then begin
562+ //過去ログ
563+ Result := StorageDownload(uri.Path, uri.Document);
574564 uri.Free;
575- uriList.Free;
576- end;
565+ end else begin
566+ //現在生きてるスレッド
567+ uriList := TStringList.Create;
568+ try
569+ ExtractHttpFields( ['/', '?'], [], uri.Path, uriList );
570+ FileName := uriList[ 5 ] + '.dat';
571+ // http://jbbs.livedoor.com/bbs/rawmode.cgi/game/1578/1067968274/l100
572+ // protocol://host/1/2/3/4/5/uriList.Count - 1
573+ if MyLogFolder = '' then begin
574+ // どこに保存していいのか分からないので一時ファイルに保存
575+ FilePath := TemporaryFile;
576+ FIsTemporary := True;
577+ end else begin
578+ FilePath := MyLogFolder + uriList[ 3 ] + '\' + uriList[ 4 ] + '\' + uriList[ 5 ] + '.dat';
579+ FIsTemporary := False;
580+ end;
581+ finally
582+ uri.Free;
583+ uriList.Free;
584+ end;
577585
578- // 保存用のディレクトリを掘る
579- ForceDirectoriesEx( Copy( FilePath, 1, LastDelimiter( '\', FilePath ) ) );
586+ // 保存用のディレクトリを掘る
587+ ForceDirectoriesEx( Copy( FilePath, 1, LastDelimiter( '\', FilePath ) ) );
580588
581- // 独自にダウンロードやフィルタリングを行わない場合は
582- // InternalDownload に任せることが出来る
583- modified := LastModified;
584- datURL := ReadURL + IntToStr( Count + 1 ) + '-'; // 新着のみ
585- responseCode := InternalDownload( PChar( datURL ), modified, tmp, 0 );
589+ // 独自にダウンロードやフィルタリングを行わない場合は
590+ // InternalDownload に任せることが出来る
591+ modified := LastModified;
592+ datURL := ReadURL + IntToStr( Count + 1 ) + '-'; // 新着のみ
593+ responseCode := InternalDownload( PChar( datURL ), modified, tmp, 0 );
586594
587- try
588- if (responseCode = 200) or (responseCode = 206) then begin
589- downResult := TStringList.Create;
590- try
591- tmpText := CustomStringReplace( string( tmp ), '。?ョ', ',' );
592- downResult.Text := EUCtoSJIS( tmpText );
593- ArrangeDownloadData(Count, downResult);
594- if downResult.Count > 0 then begin
595- if FileExists( FilePath ) then
596- logStream := TFileStream.Create( FilePath, fmOpenReadWrite or fmShareDenyWrite )
597- else
598- logStream := TFileStream.Create( FilePath, fmCreate or fmShareDenyWrite );
599- try
600- logStream.Position := logStream.Size;
601- logStream.Write( PChar( downResult.Text )^, Length( downResult.Text ) );
602- finally
603- logStream.Free;
604- end;
595+ try
596+ if (responseCode = 200) or (responseCode = 206) then begin
597+ downResult := TStringList.Create;
598+ try
599+ tmpText := CustomStringReplace( string( tmp ), '。?ョ', ',' );
600+ downResult.Text := EUCtoSJIS( tmpText );
601+ ArrangeDownloadData(Count, downResult);
602+ if downResult.Count > 0 then begin
603+ if FileExists( FilePath ) then
604+ logStream := TFileStream.Create( FilePath, fmOpenReadWrite or fmShareDenyWrite )
605+ else
606+ logStream := TFileStream.Create( FilePath, fmCreate or fmShareDenyWrite );
607+ try
608+ logStream.Position := logStream.Size;
609+ logStream.Write( PChar( downResult.Text )^, Length( downResult.Text ) );
610+ finally
611+ logStream.Free;
612+ end;
605613
606- if Count = 0 then
607- // 新規
608- Result := dsComplete
609- else
610- // 追記
611- Result := dsDiffComplete;
614+ if Count = 0 then
615+ // 新規
616+ Result := dsComplete
617+ else
618+ // 追記
619+ Result := dsDiffComplete;
612620
613- Size := Size + Length( downResult.Text );
614- // CGI からは正しい日付が得られないので現在に設定
615- LastModified := Now;
621+ Size := Size + Length( downResult.Text );
622+ // CGI からは正しい日付が得られないので現在に設定
623+ LastModified := Now;
616624
617625
618626
619- NewReceive := Count + 1;
620- Count := Count + downResult.Count;
621- NewResCount := downResult.Count;
627+ NewReceive := Count + 1;
628+ Count := Count + downResult.Count;
629+ NewResCount := downResult.Count;
622630
623631
624632
625- end else begin
626- Result := dsNotModify;
633+ end else begin
634+ Result := dsNotModify;
635+ end;
636+ finally
637+ downResult.Free;
627638 end;
628- finally
629- downResult.Free;
630- end;
631- end else if responseCode = 302 then begin
632- //http://jbbs.shitaraba.com/bbs/read.cgi/game/3477/1077473358/
633- //http://jbbs.shitaraba.com/game/bbs/read.cgi?BBS=3477&KEY=1077473358
634- //http://jbbs.shitaraba.com/game/3477/storage/1077473358.html
635- //過去ログ
636- //tmpURL := URL;
637- if Assigned( InternalPrint ) then
638- InternalPrint( '過去ログ倉庫入り' );
639- uri := TIdURI.Create( ReadURL );
640- uriList := TStringList.Create;
641- try
642- ExtractHttpFields( ['/', '?'], [], uri.Path, uriList );
643- tmpURL := uri.Protocol + '://' + uri.Host +
644- '/' + uriList[3] + '/' + uriList[4] + '/storage/' + uriList[ 5 ] + '.html';
645- finally
646- uriList.Free;
639+ end else if responseCode = 302 then begin
640+ //http://jbbs.shitaraba.com/bbs/read.cgi/game/3477/1077473358/
641+ //http://jbbs.shitaraba.com/game/bbs/read.cgi?BBS=3477&KEY=1077473358
642+ //http://jbbs.shitaraba.com/game/3477/storage/1077473358.html
643+ //過去ログ
644+ uri := TIdURI.Create( ReadURL );
645+ uriList := TStringList.Create;
646+ try
647+ ExtractHttpFields( ['/', '?'], [], uri.Path, uriList );
648+ URL := uri.Protocol + '://' + uri.Host +
649+ '/' + uriList[3] + '/' + uriList[4] + '/storage/' + uriList[ 5 ] + '.html';
650+ finally
651+ uriList.Free;
652+ uri.Free;
653+ end;
654+ uri := TIdURI.Create( ReadURL );
655+ Result := StorageDownload(uri.Path, uri.Document);
647656 uri.Free;
657+ end else if responseCode = 304 then begin
658+ Result := dsNotModify;
648659 end;
649- Result := StorageDownload(tmpURL);
650- end else if responseCode = 304 then begin
651- Result := dsNotModify;
660+ finally
661+ DisposeResultString( tmp );
652662 end;
653- finally
654- DisposeResultString( tmp );
655663 end;
656664
657665 end;
@@ -691,16 +699,17 @@ end;
691699 // 過去ログ用Download関数
692700 // *************************************************************************
693701 function TShitarabaThreadItem.StorageDownload(
694- AURL : string
702+ Path, Document : string
695703 ) : TDownloadState;
696704 var
697705 modified : Double;
698706 tmp : PChar;
699- uri : TIdURI;
700- uriList : TStringList;
701707 downResult : TStringList;
702708 responseCode : Longint;
703709 logStream : TFileStream;
710+ //uri : TIdURI;
711+ //uriList : TStringList;
712+ datURL : string;
704713 tmpText, tmpLine, tmpTitle: string;
705714 tmpHTML: TStringList;
706715
@@ -709,24 +718,23 @@ var
709718 begin
710719
711720 Result := dsError;
712- uri := TIdURI.Create( ReadURL );
713- uriList := TStringList.Create;
721+
722+ //uri := TIdURI.Create( ReadURL );
714723 try
715- ExtractHttpFields( ['/', '?'], [], uri.Path, uriList );
716- FileName := uriList[ 5 ] + '.dat';
717- // http://jbbs.livedoor.com/bbs/rawmode.cgi/game/1578/1067968274/l100
718- // protocol://host/1/2/3/4/5/uriList.Count - 1
724+ FileName := Copy(Document, 1, Length(Document) - 5) + '.dat';
719725 if MyLogFolder = '' then begin
720726 // どこに保存していいのか分からないので一時ファイルに保存
721727 FilePath := TemporaryFile;
722728 FIsTemporary := True;
723729 end else begin
724- FilePath := MyLogFolder + uriList[ 3 ] + '\' + uriList[ 4 ] + '\' + uriList[ 5 ] + '.dat';
730+ FilePath := MyLogFolder
731+ + CustomStringReplace(CustomStringReplace(Path, '/storage', ''), '/', '\')
732+ + FileName;
733+
725734 FIsTemporary := False;
726735 end;
727736 finally
728- uri.Free;
729- uriList.Free;
737+ //uri.Free;
730738 end;
731739
732740 // 保存用のディレクトリを掘る
@@ -738,7 +746,8 @@ begin
738746 // InternalDownload に任せることが出来る
739747 modified := LastModified;
740748
741- responseCode := InternalDownload( PChar( AURL ), modified, tmp, 0 );
749+ datURL := ReadURL;
750+ responseCode := InternalDownload( PChar( datURL ), modified, tmp, 0 );
742751
743752 try
744753 if (responseCode = 200) or (responseCode = 206) then begin
@@ -1149,8 +1158,7 @@ var
11491158 tmphost: String;
11501159 const
11511160 BBS_HOST_OLD = 'jbbs.shitaraba.com';
1152- BBS_HOST_OLD2 = 'jbbs.livedoor.com';
1153- BBS_HOST = 'jbbs.livedoor.jp';
1161+ BBS_HOST = 'jbbs.livedoor.com';
11541162 begin
11551163
11561164 uri := TIdURI.Create( ReadURL );
@@ -1160,15 +1168,22 @@ begin
11601168
11611169 tmphost := uri.Host;
11621170
1163- if (tmphost = BBS_HOST_OLD) or (tmphost = BBS_HOST_OLD2) then
1171+ if tmphost = BBS_HOST_OLD then
11641172 tmphost := BBS_HOST;
11651173
1166- FileName := uriList[ 5 ] + '.dat';
1167- // http://jbbs.livedoor.com/bbs/read.cgi/computer/351/1090404452/l100
1168- // http://jbbs.livedoor.com/bbs/read.cgi/game/1578/1067968274/l100
1169- // http://jbbs.livedoor.com/game/1000/subject.txt
1170- Result := CreateResultString(
1171- uri.Protocol + '://' + tmphost + '/' + uriList[ 3 ] + '/' + uriList[ 4 ] + '/' );
1174+ if( AnsiPos('.html', uri.Document) = 0 ) then begin //通常
1175+ FileName := uriList[ 5 ] + '.dat';
1176+ // http://jbbs.livedoor.com/bbs/read.cgi/computer/351/1090404452/l100
1177+ // http://jbbs.livedoor.com/bbs/read.cgi/game/1578/1067968274/l100
1178+ // http://jbbs.livedoor.com/game/1000/subject.txt
1179+ Result := CreateResultString(
1180+ uri.Protocol + '://' + tmphost + '/' + uriList[ 3 ] + '/' + uriList[ 4 ] + '/' );
1181+ end else begin
1182+ //http://jbbs.livedoor.com/game/1578/storage/1086710948.html
1183+ Result := CreateResultString(
1184+ uri.Protocol + '://' + tmphost + CustomStringReplace(uri.Path, '/storage', ''));
1185+ end;
1186+
11721187 finally
11731188 uri.Free;
11741189 uriList.Free;
@@ -1218,8 +1233,7 @@ var
12181233 dir, tmphost : string;
12191234 const
12201235 BBS_HOST_OLD = 'jbbs.shitaraba.com';
1221- BBS_HOST_OLD2 = 'jbbs.livedoor.com';
1222- BBS_HOST = 'jbbs.livedoor.jp';
1236+ BBS_HOST = 'jbbs.livedoor.com';
12231237 begin
12241238
12251239 foundPos := AnsiPos( '?', URL );
@@ -1232,7 +1246,7 @@ begin
12321246 dir := uriList[ 1 ];
12331247
12341248 tmphost := uri.Host;
1235- if (tmphost = BBS_HOST_OLD) or (tmphost = BBS_HOST_OLD2) then
1249+ if tmphost = BBS_HOST_OLD then
12361250 tmphost := BBS_HOST;
12371251
12381252 ExtractHttpFields( ['&'], [], Copy( URL, foundPos + 1, MaxInt ), uriList );
@@ -1254,7 +1268,7 @@ begin
12541268 ExtractHttpFields( ['/'], [], uri.Path, uriList );
12551269
12561270 tmphost := uri.Host;
1257- if (tmphost = BBS_HOST_OLD) or (tmphost = BBS_HOST_OLD2) then
1271+ if tmphost = BBS_HOST_OLD then
12581272 tmphost := BBS_HOST;
12591273
12601274 if( AnsiPos(THREAD_MARK, URL) > 0) and (uriList.Count > 5) then begin
@@ -1265,8 +1279,7 @@ begin
12651279 end else if AnsiPos(THREAD_MARK, URL) = 0 then begin
12661280 //ココで過去ログかどうかチェック?
12671281 if(AnsiPos('.html/', uri.Path) > 0) then begin
1268- Result := uri.Protocol + '://' + tmphost + THREAD_MARK +
1269- CustomStringReplace(CustomStringReplace(uri.Path, '/storage', ''), '.html/', '/') + 'l100';
1282+ Result := uri.Protocol + '://' + tmphost + Copy(uri.Path, 1, Length(uri.Path) - 1);
12701283 end else
12711284 Result := URL;
12721285 end;
@@ -1291,8 +1304,7 @@ var
12911304 dir, tmphost : string;
12921305 const
12931306 BBS_HOST_OLD = 'jbbs.shitaraba.com';
1294- BBS_HOST_OLD2 = 'jbbs.livedoor.com';
1295- BBS_HOST = 'jbbs.livedoor.jp';
1307+ BBS_HOST = 'jbbs.livedoor.com';
12961308 begin
12971309
12981310 foundPos := AnsiPos( '?', URL );
@@ -1305,7 +1317,7 @@ begin
13051317 dir := uriList[ 1 ];
13061318
13071319 tmphost := uri.Host;
1308- if (tmphost = BBS_HOST_OLD) or (tmphost = BBS_HOST_OLD2) then
1320+ if tmphost = BBS_HOST_OLD then
13091321 tmphost := BBS_HOST;
13101322
13111323 ExtractHttpFields( ['&'], [], Copy( URL, foundPos + 1, MaxInt ), uriList );
@@ -1327,13 +1339,19 @@ begin
13271339 ExtractHttpFields( ['/'], [], uri.Path, uriList );
13281340
13291341 tmphost := uri.Host;
1330- if (tmphost = BBS_HOST_OLD) or (tmphost = BBS_HOST_OLD2) then
1342+ if tmphost = BBS_HOST_OLD then
13311343 tmphost := BBS_HOST;
13321344 // http://jbbs.livedoor.com/bbs/read.cgi/game/1578/1067968274/l100
13331345 if( AnsiPos(THREAD_MARK, URL) > 0) and (uriList.Count > 5) then begin
13341346 Result :=
13351347 uri.Protocol + '://' + tmphost + '/bbs/rawmode.cgi/' +
13361348 uriList[ 3 ] + '/' + uriList[ 4 ] + '/' + uriList[ 5 ] + '/';
1349+ end else if AnsiPos(THREAD_MARK, URL) = 0 then begin
1350+ //ココで過去ログかどうかチェック?
1351+ if(AnsiPos('.html/', uri.Path) > 0) then begin
1352+ Result := uri.Protocol + '://' + tmphost + Copy(uri.Path, 1, Length(uri.Path) - 1);
1353+ end else
1354+ Result := URL;
13371355 end;
13381356 finally
13391357 uri.Free;
@@ -1415,8 +1433,7 @@ var
14151433 uriList : TStringList;
14161434 const
14171435 BBS_HOST_OLD = 'jbbs.shitaraba.com';
1418- BBS_HOST_OLD2 = 'jbbs.livedoor.com';
1419- BBS_HOST = 'jbbs.livedoor.jp';
1436+ BBS_HOST = 'jbbs.livedoor.com';
14201437 begin
14211438
14221439 inherited;
@@ -1433,7 +1450,7 @@ begin
14331450 uri := TIdURI.Create( SubjectURL );
14341451 uriList := TStringList.Create;
14351452 try
1436- if (uri.Host = BBS_HOST_OLD) or (uri.Host = BBS_HOST_OLD2) then
1453+ if uri.Host = BBS_HOST_OLD then
14371454 uri.Host := BBS_HOST;
14381455 URL := uri.Protocol + '://' + uri.Host + uri.Path;
14391456
--- a/res/skin/skin30-2G/Header.html
+++ b/res/skin/skin30-2G/Header.html
@@ -15,7 +15,7 @@
1515 var start_time = new Date();
1616 //==========グローバル変数
1717 var anchorHead="";
18-var skinName="skin30-2 v3.3.09xx";
18+var skinName="skin30-2 v3.1.11xx";
1919 var browser="ギコナビ";
2020 //==========ギコナビ用アンカーの判定(0:処理無し,1:ポップアップ,2:ボタン挿入)
2121 // ギコナビでは、レスアンカーは相対アドレスで記述される
@@ -27,22 +27,13 @@ function checkAnchor(href){if(!href){return(0)}
2727 //==========リンク設定
2828 function addAnchor(inner,num){
2929 if(!t_url){threadurl()}
30- var url=document.getElementsByName("ThreadURL")[0].content;
31- if(url.match(/&/)){
32- return('<a href="../test/read.cgi?bbs='+t_bbs+'&key='+t_key+'&st='+inner+'&to='+inner+'&nofirst=true" target="_blank" onclick="blur()">'+num+'</a>')
33- }else{
34- return('<a href="../test/read.cgi/'+t_bbs+'/'+t_key+'/'+inner+'" target="_blank" onclick="blur()">'+num+'</a>')
35- }
30+ return('<a href="../test/read.cgi/'+t_bbs+'/'+t_key+'/'+inner+'" target="_blank" onclick="blur()">'+num+'</a>')
3631 }
3732 // スレッドURLの取得
3833 var t_url=false,t_domain,t_bbs,t_key;
3934 function threadurl(){
4035 var threadurl=document.getElementsByName("ThreadURL")[0].content;
41- if(threadurl.match(/&/)){
42- threadurl.match(/bbs=(.*)&key=(\d*)/);
43- }else{
44- threadurl.match(/^.*\/test\/read.cgi\/(.*)\/(.*)\//);
45- }
36+ threadurl.match(/^.*\/test\/read.cgi\/(.*)\/(.*)\//);
4637 t_url=true;
4738 t_bbs=RegExp.$1;
4839 t_key=RegExp.$2;
--- a/res/skin/skin30-2G/chie_event.js
+++ b/res/skin/skin30-2G/chie_event.js
@@ -2,8 +2,7 @@
22 //外部関数:tohan
33 //外部変数:anchorHead,lightmode,getID,skinName,browser,dts
44 //グローバル変数
5-var buffer=1; // 低速回線や低速マシンの場合にはbufferの数値を増やすとより正確にジャンプ(1増やすと0.1秒遅れる)
6-var newResJump=1; // 新着レスジャンプ(0:ブラウザ任せ、1:読了時のみ、2:常時)*かちゅ、OpenJane、twintailのみの設定
5+var buffer=1; // 低速回線や低速マシンの場合にはbufferの数値を増やすとより正確にジャンプ(1増やすと0.1秒遅れる)
76 //========Click処理→search,他
87 document.onclick = clickEvent;
98 function clickEvent(){
@@ -41,19 +40,10 @@ function mouseOverEvent() {
4140 else if(e.innerText.match(/^あぼ〜ん$/)) {abonePopup(e);}
4241 }
4342 if(e.tagName=='A'){
44- if(!e.innerText.match(/%/)){ // URLエンコードでありがちな%がなければ
45- e.href=e.href.replace(/>/g,"");
46- e.href=e.href.replace(/\/ime.nu/g,"");
47- }else{
48- try{
49- e.title=decodeURI(e.innerText);
50- }catch(err){
51- // ShiftJIS,EUC-JPのデコードは面倒だからつけない。
52- }
53- }
43+ e.href=e.href.replace(/>/g,"");
44+ e.href=e.href.replace(/\/ime.nu/g,"");
5445 if (checkAnchor(e.href)==2){insButton(e);return;}
5546 else if(checkAnchor(e.href)==1){
56- if(event.shiftKey){if(e.rel){e.href=e.rel}return}
5747 // 多段ポップアップ
5848 var aNum=parseInt(e.sourceIndex)+1;
5949 if(!document.getElementById("p"+aNum)){
@@ -106,10 +96,10 @@ function scroll_End(){document.getElementsByTagName("DL")[0].lastChild.scrollInt
10696 // IMG
10797 function imgCommand(mode,s){
10898 if(!waited){
109- var nHTML='<div id="command" onclick="clearCommand()"><input type="button" onclick="allImageLoad(\'all\')" value="全レス一括読込"><br><input type="button" onclick="allImageLoad(\'new\')" value="新レス一括読込"><br><input type="button" onclick="removeError()" value="Error画像削除"><br></div>';
99+ var nHTML='<div id="command" onclick="clearCommand()"><input type="button" onclick="allImageLoad(\'all\')" value="全レス一括読込"><br><input type="button" onclick="allImageLoad(\'new\')" value="新レス一括読込"><br></div>';
110100 event.srcElement.parentElement.insertAdjacentHTML('beforeEnd',nHTML);
111101 if(skinName.match(/30-2/)){
112- //if(!lightmode){document.getElementById("command").insertAdjacentHTML('afterBegin','<input type="button" onclick="changePanel()" value="パネル切替"><br>')}
102+ if(!lightmode){document.getElementById("command").insertAdjacentHTML('afterBegin','<input type="button" onclick="changePanel()" value="パネル切替"><br>')}
113103 document.getElementById("command").insertAdjacentHTML('beforeEnd','<input type="button" onclick="changeMode()" value="モード切替">')
114104 }
115105 waited=true;
@@ -119,7 +109,7 @@ function imgCommand(mode,s){
119109 }
120110 function clearCommand(){
121111 waited=false;
122- document.getElementById("command").removeNode(true);
112+ event.srcElement.parentElement.removeNode(true);
123113 }
124114 //=========左長押処理→copyMenu()
125115 document.onmousedown=mousedownEvent;
@@ -132,7 +122,6 @@ function mousedownEvent(){
132122 clickTimer=setTimeout("copyMenu()",500);
133123 }
134124 }
135-
136125 //コピーメニュー→colorChange(),search::copyText()
137126 function copyMenu(){
138127 clickCancel=true; clearTimeout(clickTimer);
@@ -176,53 +165,27 @@ function key(){
176165 }
177166 }
178167
179-//=========新着レス取得後処理(標準スキン未対応ブラウザ用)←Timer又はFooterから呼び出し
180-//=========かちゅ、ABone、ゾヌ2
168+//=========Load(代替)処理(各Footerもしくは、Headerでのループから呼出し)
181169 var newResNum=parseInt(document.getElementsByName("GetRescount")[0].content)+1;
182170 var k=0;
183-function loadEvent(num){ // Timer又はFooterから
184- //====新着レスジャンプ
185- if(newResJump==0){clearInterval(timerID);return} //「ブラウザ任せ」なら終了
186- //新着レスの開始番号を取得
187- if (browser=="かちゅ〜しゃ"){if(isNaN(newResNum)){while(dts[k]){if(dts[k].className=="new"){newResNum=parseInt(dts[k].firstChild.innerText);break;} k++;}}}
188- else if(browser=="ホットゾヌ2"){newResNum=num+1;}
171+function loadEvent(){
172+ //GetRescount代替 "数字でなければ"
173+ if(isNaN(newResNum)){while(dts[k]){if(dts[k].className=="new"){newResNum=parseInt(dts[k].firstChild.innerText);break;} k++; }}
174+ //新着開始ナンバーを設定してジャンプ
189175 var anc=document.anchors(anchorHead+newResNum);
190- if(!anc || !anc.parentElement){return} // 透明あぼ〜んされてたら終了
191- //新着レスジャンプ
192- scr=lightmode ? document.body : document.getElementById("dl");
193- viewPos=scr.scrollTop+scr.clientHeight;// スクロール後の画面下部位置
194- endPos =anc.offsetTop+20; // 新レスアンカー位置
195- //最後まで読了 or 「常に新着ジャンプ」ならジャンプ
196- if(viewPos>endPos || newResJump==2){clearInterval(timerID);setTimeout("moveToNew("+newResNum+")",buffer*100)}
197- else{firstNew=document.anchors(anchorHead+newResNum).parentElement.nextSibling;}
198-}
199-//=========新着レス取得後処理(標準スキン対応ブラウザ用)←NewMarkから呼び出し
200-//=========OpenJ、twin
201-var scr,viewPos,endPos=0;
202-function reloadEvent(){
203- //====既読化
204- var lastDt=dts[dts.length-2];if(!lastDt){return}// 全部新着なら終了
205- while(lastDt && lastDt.className=="new"){lastDt.className="";lastDt=lastDt.previousSibling.previousSibling;}
206- //====新着レスジャンプ
207- if(newResJump==0){return} //「ブラウザ任せ」なら終了
208- var ancs=document.anchors;
209- var newResNum=parseInt(ancs[ancs.length-1].name)+1;
210- scr=lightmode ? document.body : document.getElementById("dl");
211- viewPos=scr.scrollTop;
212- endPos =scr.scrollHeight-scr.clientHeight-20;
213- //最後まで読了 or 「常に新着ジャンプ」ならジャンプ
214- if(viewPos>endPos || newResJump==2){setTimeout("moveToNew("+newResNum+")",buffer*100);}
176+ if(anc && anc.parentElement){
177+ if(buffer==0){clearInterval(timerID);moveToNew(newResNum);}
178+ else {buffer--;}
179+ }
215180 }
216-
217181 // 新着レス移動+新着レスの位置を記憶
218182 var firstNew;
219183 function moveToNew(num){
220184 firstNew=getDTfromAnc(num);
221- while(!firstNew){num--;firstNew=getDTfromAnc(num);} //対象が透明あぼ〜んなら数を減らす
222- firstNew.scrollIntoView(true);
185+ if(firstNew){firstNew.scrollIntoView(true);}
223186 }
224187
225-//=========DoubleClick処理→defaultPopup()
188+//=========DblClick処理→defaultPopup()
226189 document.ondblclick=defaultPopup;
227190 function defaultPopup(){
228191 var num=document.selection.createRange().text.replace(/\s$/,"");
@@ -237,17 +200,4 @@ function defaultPopup(){
237200 obj.innerText="ID:"+num;
238201 search(obj);
239202 }
240-}
241-
242-//=========Copy処理
243-//headから読むとbodyは見えないので、専用ブラウザの特質を利用してbodyの後ろに書き出す
244-//本来どおりheadに書き出すSkinManager対策で判定を一つ入れる
245- if(document.body) document.write('<script type="text/javascript">document.body.oncopy=copyEvent</script>\n');
246-function copyEvent(){
247- var textarea=document.createElement("TEXTAREA");
248- textarea.value=document.selection.createRange().text.replace(/\s(\r\n|$)/g,"\n");
249- var copyText=textarea.createTextRange();
250- copyText.execCommand("Copy");
251- return false;
252-}
253-
203+}
\ No newline at end of file
--- a/res/skin/skin30-2G/chie_image.js
+++ b/res/skin/skin30-2G/chie_image.js
@@ -2,8 +2,7 @@
22 // 外部関数:addAnchor
33 // 外部変数:cp,tp,vp,dds
44 //======画像読込の設定
5-var onMouseLoad=true; // true:カーソルを合わせただけ、false:LOADボタンをクリックしてから
6-var takeArisk=false; // true:画像読み込み時にモード切替、false:手動でモード切替
5+var onMouseLoad=true; // true:カーソルを合わせただけ、false:LOADボタンをクリックしてから
76 //==========グローバル変数
87 //==========画像処理等
98 var lightmode = true;
@@ -69,13 +68,12 @@ function insButton(a,hRH) {
6968 // 画像読込
7069 function loadImage(btn,href){
7170 if(!panel){changePanel()}
72- if(takeArisk && lightmode){changeMode()}
7371 if(btn.tagName!="A"){
7472 var thumbs = document.images;
7573 var l=thumbs.length;
7674 for(var i=l;i--;){if(thumbs[i].src==href){
7775 if(lightmode){tp.style.visibility="visible";viewed=true;}
78- //thumbs[i].scrollIntoView(true);
76+ thumbs[i].scrollIntoView(true);
7977 imgOver(thumbs[i],100);
8078 return true;
8179 }}
@@ -105,7 +103,7 @@ function loadImage(btn,href){
105103 function imgResult(img){
106104 var btn=img.parentElement.children.item(2);
107105 if(event.type=="load"){btn.value='___'; img.style.display='block';}
108- else {btn.value='NONE';btn.style.color='#C00';setTimeout("viewed=false",3000)}
106+ else {btn.value='NONE';btn.style.color='#C00';}
109107 }
110108 // サイズの切替
111109 function changeSize(btn){
@@ -124,15 +122,6 @@ function changeSize(btn){
124122 }
125123 // サムネイルの削除
126124 function removeThumb(btn){btn.parentElement.removeNode(true);}
127-function removeError(){
128- if(tp){
129- var l=tp.childNodes.length;
130- for(var i=l;i--;){
131- var stateBtn=tp.childNodes[i].childNodes[2];
132- if(stateBtn.tagName=="BUTTON" && stateBtn.innerText=="NONE"){stateBtn.parentElement.removeNode(true);}
133- }
134- }
135-}
136125 // 画像表示の切替
137126 function changeView(mode,href){
138127 if(!href){href=event.srcElement.src}
--- a/res/skin/skin30-2G/chie_popup.js
+++ b/res/skin/skin30-2G/chie_popup.js
@@ -15,7 +15,7 @@ var pb;
1515 function namePopup(e,before,num,after){
1616 var hnum=tohan(num);
1717 //3周年、4周年、Socket774、774KB、21禁、[1-30]、などに対応
18- if(before){if(hnum==5 || hnum==774 || hnum==4 || hnum==21 || hnum==1 || hnum==30){return}}
18+ if(before){if(hnum==3 || hnum==774 || hnum==4 || hnum==21 || hnum==1 || hnum==30){return}}
1919 e.outerHTML = "<b>"+before+"</b><b>"+addAnchor(hnum,num)+"</b><b>"+after+"</b>";
2020 }
2121 //=========弱あぼ〜んのポップアップ
--- a/res/skin/skin30-2G/chie_search.js
+++ b/res/skin/skin30-2G/chie_search.js
@@ -110,7 +110,7 @@ function clearResult(obj){
110110 for(var i=l;i--;){
111111 var dt=eval(arrayElement); var dd=dt.nextSibling;
112112 //Live機能追加 - 透明あぼ〜ん
113- if(browser=="Live2ch"){location.href='func:ABONECLEAR?'+dt.firstChild.innerText;}
113+ if(browser=="Live2ch"){location.href='func:ABONECLEAR?'+dt.firstChild.innerText;continue;}
114114 dt.removeNode(true); dd.removeNode(true);
115115 }
116116 }
@@ -144,7 +144,7 @@ function findIt(word){
144144
145145 //==========逆参照
146146 function searchRef(obj){
147- if(obj.name!='referred'){
147+ if(obj.name!='reffered'){
148148 var num=obj.firstChild.innerText;
149149 var l=dds.length;
150150 var found = new Array;
@@ -171,7 +171,7 @@ function searchRef(obj){
171171 if(exist){
172172 var dt=dds[i].previousSibling.cloneNode(true);
173173 found.unshift(dt.outerHTML.replace(/name=.*?>/,">")+dd.outerHTML.replace(/<a name=.*>/i,""));
174- obj.name="referred";
174+ obj.name="reffered";
175175 }
176176 }
177177 if(found.length){returnRef(obj.nextSibling,found)}
@@ -190,12 +190,13 @@ function returnRef(dd,found){
190190 function copyText(target){
191191 var num=event.srcElement.parentElement.name;
192192 var obj=getDTfromAnc(num);
193+ var decoy=document.createDocumentFragment();
193194 var textarea=document.createElement("TEXTAREA");
194- var message=obj.nextSibling.innerText.replace(/\s(\r\n|$)/g,"\n");
195- if (target=="res") {textarea.value=obj.firstChild.innerText+" :"+obj.childNodes[1].innerText+" :"+obj.lastChild.innerText+"\n"+message;}
195+ if (target=="res") {textarea.value=obj.firstChild.innerText+" :"+obj.childNodes[1].innerText+" :"+obj.lastChild.innerText+"\n"+obj.nextSibling.innerText+"\n";}
196196 else if(target=="name"){textarea.value=obj.childNodes[1].innerText+"\n";}
197- else if(target=="id") {textarea.value="ID:"+(obj.lastChild.innerText.split(/ID:/))[1]+"\n";}
198- var copyText=textarea.createTextRange();
197+ else if(target=="id") {textarea.value=obj.lastChild.innerText.substr(15)+"\n";}
198+ decoy.appendChild(textarea);
199+ var copyText=decoy.getElementsByTagName("TEXTAREA")[0].createTextRange();
199200 copyText.execCommand("Copy")
200201 event.srcElement.parentElement.removeNode(true);
201202 }
--- a/res/skin/skin30-3G/Header.html
+++ b/res/skin/skin30-3G/Header.html
@@ -15,11 +15,11 @@
1515 var start_time = new Date();
1616 //==========グローバル変数
1717 var anchorHead="";
18-var skinName="skin30-3 v3.3.09xx";
18+var skinName="skin30-3 v3.1.11xx";
1919 var browser="ギコナビ";
2020 //==========ギコナビ用アンカーの判定(0:処理無し,1:ポップアップ,2:ボタン挿入)
2121 // ギコナビでは、レスアンカーは相対アドレスで記述される
22-function checkAnchor(href){if(!href){return(0)}
22+function checkAnchor(href){
2323 if (href.match(/decoy:|about:blank/)){return(1)}
2424 else if(href.match(/menu:|read\.cgi|2ch\.net\/.*\/kako/)){return(0)}
2525 else{return(2)}
@@ -27,22 +27,13 @@ function checkAnchor(href){if(!href){return(0)}
2727 //==========リンク設定
2828 function addAnchor(inner,num){
2929 if(!t_url){threadurl()}
30- var url=document.getElementsByName("ThreadURL")[0].content;
31- if(url.match(/&/)){
32- return('<a href="../test/read.cgi?bbs='+t_bbs+'&key='+t_key+'&st='+inner+'&to='+inner+'&nofirst=true" target="_blank" onclick="blur()">'+num+'</a>')
33- }else{
34- return('<a href="../test/read.cgi/'+t_bbs+'/'+t_key+'/'+inner+'" target="_blank" onclick="blur()">'+num+'</a>')
35- }
30+ return('<a href="../test/read.cgi/'+t_bbs+'/'+t_key+'/'+inner+'" target="_blank" onclick="blur()">'+num+'</a>')
3631 }
3732 // スレッドURLの取得
3833 var t_url=false,t_domain,t_bbs,t_key;
3934 function threadurl(){
4035 var threadurl=document.getElementsByName("ThreadURL")[0].content;
41- if(threadurl.match(/&/)){
42- threadurl.match(/bbs=(.*)&key=(\d*)/);
43- }else{
44- threadurl.match(/^.*\/test\/read.cgi\/(.*)\/(.*)\//);
45- }
36+ threadurl.match(/^.*\/test\/read.cgi\/(.*)\/(.*)\//);
4637 t_url=true;
4738 t_bbs=RegExp.$1;
4839 t_key=RegExp.$2;
--- a/res/skin/skin30-3G/chie_event.js
+++ b/res/skin/skin30-3G/chie_event.js
@@ -2,8 +2,7 @@
22 //外部関数:tohan
33 //外部変数:anchorHead,lightmode,getID,skinName,browser,dts
44 //グローバル変数
5-var buffer=1; // 低速回線や低速マシンの場合にはbufferの数値を増やすとより正確にジャンプ(1増やすと0.1秒遅れる)
6-var newResJump=1; // 新着レスジャンプ(0:ブラウザ任せ、1:読了時のみ、2:常時)*かちゅ、OpenJane、twintailのみの設定
5+var buffer=1; // 低速回線や低速マシンの場合にはbufferの数値を増やすとより正確にジャンプ(1増やすと0.1秒遅れる)
76 //========Click処理→search,他
87 document.onclick = clickEvent;
98 function clickEvent(){
@@ -41,19 +40,10 @@ function mouseOverEvent() {
4140 else if(e.innerText.match(/^あぼ〜ん$/)) {abonePopup(e);}
4241 }
4342 if(e.tagName=='A'){
44- if(!e.innerText.match(/%/)){ // URLエンコードでありがちな%がなければ
45- e.href=e.href.replace(/>/g,"");
46- e.href=e.href.replace(/\/ime.nu/g,"");
47- }else{
48- try{
49- e.title=decodeURI(e.innerText);
50- }catch(err){
51- // ShiftJIS,EUC-JPのデコードは面倒だからつけない。
52- }
53- }
43+ e.href=e.href.replace(/>/g,"");
44+ e.href=e.href.replace(/\/ime.nu/g,"");
5445 if (checkAnchor(e.href)==2){insButton(e);return;}
5546 else if(checkAnchor(e.href)==1){
56- if(event.shiftKey){if(e.rel){e.href=e.rel}return}
5747 // 多段ポップアップ
5848 var aNum=parseInt(e.sourceIndex)+1;
5949 if(!document.getElementById("p"+aNum)){
@@ -106,10 +96,10 @@ function scroll_End(){document.getElementsByTagName("DL")[0].lastChild.scrollInt
10696 // IMG
10797 function imgCommand(mode,s){
10898 if(!waited){
109- var nHTML='<div id="command" onclick="clearCommand()"><input type="button" onclick="allImageLoad(\'all\')" value="全レス一括読込"><br><input type="button" onclick="allImageLoad(\'new\')" value="新レス一括読込"><br><input type="button" onclick="removeError()" value="Error画像削除"><br></div>';
99+ var nHTML='<div id="command" onclick="clearCommand()"><input type="button" onclick="allImageLoad(\'all\')" value="全レス一括読込"><br><input type="button" onclick="allImageLoad(\'new\')" value="新レス一括読込"><br></div>';
110100 event.srcElement.parentElement.insertAdjacentHTML('beforeEnd',nHTML);
111101 if(skinName.match(/30-2/)){
112- //if(!lightmode){document.getElementById("command").insertAdjacentHTML('afterBegin','<input type="button" onclick="changePanel()" value="パネル切替"><br>')}
102+ if(!lightmode){document.getElementById("command").insertAdjacentHTML('afterBegin','<input type="button" onclick="changePanel()" value="パネル切替"><br>')}
113103 document.getElementById("command").insertAdjacentHTML('beforeEnd','<input type="button" onclick="changeMode()" value="モード切替">')
114104 }
115105 waited=true;
@@ -119,7 +109,7 @@ function imgCommand(mode,s){
119109 }
120110 function clearCommand(){
121111 waited=false;
122- document.getElementById("command").removeNode(true);
112+ event.srcElement.parentElement.removeNode(true);
123113 }
124114 //=========左長押処理→copyMenu()
125115 document.onmousedown=mousedownEvent;
@@ -132,7 +122,6 @@ function mousedownEvent(){
132122 clickTimer=setTimeout("copyMenu()",500);
133123 }
134124 }
135-
136125 //コピーメニュー→colorChange(),search::copyText()
137126 function copyMenu(){
138127 clickCancel=true; clearTimeout(clickTimer);
@@ -176,53 +165,27 @@ function key(){
176165 }
177166 }
178167
179-//=========新着レス取得後処理(標準スキン未対応ブラウザ用)←Timer又はFooterから呼び出し
180-//=========かちゅ、ABone、ゾヌ2
168+//=========Load(代替)処理(各Footerもしくは、Headerでのループから呼出し)
181169 var newResNum=parseInt(document.getElementsByName("GetRescount")[0].content)+1;
182170 var k=0;
183-function loadEvent(num){ // Timer又はFooterから
184- //====新着レスジャンプ
185- if(newResJump==0){clearInterval(timerID);return} //「ブラウザ任せ」なら終了
186- //新着レスの開始番号を取得
187- if (browser=="かちゅ〜しゃ"){if(isNaN(newResNum)){while(dts[k]){if(dts[k].className=="new"){newResNum=parseInt(dts[k].firstChild.innerText);break;} k++;}}}
188- else if(browser=="ホットゾヌ2"){newResNum=num+1;}
171+function loadEvent(){
172+ //GetRescount代替 "数字でなければ"
173+ if(isNaN(newResNum)){while(dts[k]){if(dts[k].className=="new"){newResNum=parseInt(dts[k].firstChild.innerText);break;} k++; }}
174+ //新着開始ナンバーを設定してジャンプ
189175 var anc=document.anchors(anchorHead+newResNum);
190- if(!anc || !anc.parentElement){return} // 透明あぼ〜んされてたら終了
191- //新着レスジャンプ
192- scr=lightmode ? document.body : document.getElementById("dl");
193- viewPos=scr.scrollTop+scr.clientHeight;// スクロール後の画面下部位置
194- endPos =anc.offsetTop+20; // 新レスアンカー位置
195- //最後まで読了 or 「常に新着ジャンプ」ならジャンプ
196- if(viewPos>endPos || newResJump==2){clearInterval(timerID);setTimeout("moveToNew("+newResNum+")",buffer*100)}
197- else{firstNew=document.anchors(anchorHead+newResNum).parentElement.nextSibling;}
198-}
199-//=========新着レス取得後処理(標準スキン対応ブラウザ用)←NewMarkから呼び出し
200-//=========OpenJ、twin
201-var scr,viewPos,endPos=0;
202-function reloadEvent(){
203- //====既読化
204- var lastDt=dts[dts.length-2];if(!lastDt){return}// 全部新着なら終了
205- while(lastDt && lastDt.className=="new"){lastDt.className="";lastDt=lastDt.previousSibling.previousSibling;}
206- //====新着レスジャンプ
207- if(newResJump==0){return} //「ブラウザ任せ」なら終了
208- var ancs=document.anchors;
209- var newResNum=parseInt(ancs[ancs.length-1].name)+1;
210- scr=lightmode ? document.body : document.getElementById("dl");
211- viewPos=scr.scrollTop;
212- endPos =scr.scrollHeight-scr.clientHeight-20;
213- //最後まで読了 or 「常に新着ジャンプ」ならジャンプ
214- if(viewPos>endPos || newResJump==2){setTimeout("moveToNew("+newResNum+")",buffer*100);}
176+ if(anc && anc.parentElement){
177+ if(buffer==0){clearInterval(timerID);moveToNew(newResNum);}
178+ else {buffer--;}
179+ }
215180 }
216-
217181 // 新着レス移動+新着レスの位置を記憶
218182 var firstNew;
219183 function moveToNew(num){
220184 firstNew=getDTfromAnc(num);
221- while(!firstNew){num--;firstNew=getDTfromAnc(num);} //対象が透明あぼ〜んなら数を減らす
222- firstNew.scrollIntoView(true);
185+ if(firstNew){firstNew.scrollIntoView(true);}
223186 }
224187
225-//=========DoubleClick処理→defaultPopup()
188+//=========DblClick処理→defaultPopup()
226189 document.ondblclick=defaultPopup;
227190 function defaultPopup(){
228191 var num=document.selection.createRange().text.replace(/\s$/,"");
@@ -237,17 +200,4 @@ function defaultPopup(){
237200 obj.innerText="ID:"+num;
238201 search(obj);
239202 }
240-}
241-
242-//=========Copy処理
243-//headから読むとbodyは見えないので、専用ブラウザの特質を利用してbodyの後ろに書き出す
244-//本来どおりheadに書き出すSkinManager対策で判定を一つ入れる
245- if(document.body) document.write('<script type="text/javascript">document.body.oncopy=copyEvent</script>\n');
246-function copyEvent(){
247- var textarea=document.createElement("TEXTAREA");
248- textarea.value=document.selection.createRange().text.replace(/\s(\r\n|$)/g,"\n");
249- var copyText=textarea.createTextRange();
250- copyText.execCommand("Copy");
251- return false;
252-}
253-
203+}
\ No newline at end of file
--- a/res/skin/skin30-3G/chie_popup.js
+++ b/res/skin/skin30-3G/chie_popup.js
@@ -15,7 +15,7 @@ var pb;
1515 function namePopup(e,before,num,after){
1616 var hnum=tohan(num);
1717 //3周年、4周年、Socket774、774KB、21禁、[1-30]、などに対応
18- if(before){if(hnum==5 || hnum==774 || hnum==4 || hnum==21 || hnum==1 || hnum==30){return}}
18+ if(before){if(hnum==3 || hnum==774 || hnum==4 || hnum==21 || hnum==1 || hnum==30){return}}
1919 e.outerHTML = "<b>"+before+"</b><b>"+addAnchor(hnum,num)+"</b><b>"+after+"</b>";
2020 }
2121 //=========弱あぼ〜んのポップアップ
--- a/res/skin/skin30-3G/chie_search.js
+++ b/res/skin/skin30-3G/chie_search.js
@@ -110,7 +110,7 @@ function clearResult(obj){
110110 for(var i=l;i--;){
111111 var dt=eval(arrayElement); var dd=dt.nextSibling;
112112 //Live機能追加 - 透明あぼ〜ん
113- if(browser=="Live2ch"){location.href='func:ABONECLEAR?'+dt.firstChild.innerText;}
113+ if(browser=="Live2ch"){location.href='func:ABONECLEAR?'+dt.firstChild.innerText;continue;}
114114 dt.removeNode(true); dd.removeNode(true);
115115 }
116116 }
@@ -144,7 +144,7 @@ function findIt(word){
144144
145145 //==========逆参照
146146 function searchRef(obj){
147- if(obj.name!='referred'){
147+ if(obj.name!='reffered'){
148148 var num=obj.firstChild.innerText;
149149 var l=dds.length;
150150 var found = new Array;
@@ -171,7 +171,7 @@ function searchRef(obj){
171171 if(exist){
172172 var dt=dds[i].previousSibling.cloneNode(true);
173173 found.unshift(dt.outerHTML.replace(/name=.*?>/,">")+dd.outerHTML.replace(/<a name=.*>/i,""));
174- obj.name="referred";
174+ obj.name="reffered";
175175 }
176176 }
177177 if(found.length){returnRef(obj.nextSibling,found)}
@@ -190,12 +190,13 @@ function returnRef(dd,found){
190190 function copyText(target){
191191 var num=event.srcElement.parentElement.name;
192192 var obj=getDTfromAnc(num);
193+ var decoy=document.createDocumentFragment();
193194 var textarea=document.createElement("TEXTAREA");
194- var message=obj.nextSibling.innerText.replace(/\s(\r\n|$)/g,"\n");
195- if (target=="res") {textarea.value=obj.firstChild.innerText+" :"+obj.childNodes[1].innerText+" :"+obj.lastChild.innerText+"\n"+message;}
195+ if (target=="res") {textarea.value=obj.firstChild.innerText+" :"+obj.childNodes[1].innerText+" :"+obj.lastChild.innerText+"\n"+obj.nextSibling.innerText+"\n";}
196196 else if(target=="name"){textarea.value=obj.childNodes[1].innerText+"\n";}
197- else if(target=="id") {textarea.value="ID:"+(obj.lastChild.innerText.split(/ID:/))[1]+"\n";}
198- var copyText=textarea.createTextRange();
197+ else if(target=="id") {textarea.value=obj.lastChild.innerText.substr(15)+"\n";}
198+ decoy.appendChild(textarea);
199+ var copyText=decoy.getElementsByTagName("TEXTAREA")[0].createTextRange();
199200 copyText.execCommand("Copy")
200201 event.srcElement.parentElement.removeNode(true);
201202 }
Show on old repository browser