| 117 |
var |
var |
| 118 |
protocol, host, path, document, port, bookmark : string; |
protocol, host, path, document, port, bookmark : string; |
| 119 |
BBSID{, BBSKey} : string; |
BBSID{, BBSKey} : string; |
| 120 |
tmpURL, boardURL : string; |
tmpURL{, boardURL} : string; |
| 121 |
// category : TCategory; |
// category : TCategory; |
| 122 |
i, bi: Integer; |
{i, bi: Integer;} |
| 123 |
tmpThread: TThreadItem; |
{tmpThread: TThreadItem;} |
| 124 |
tmpBoard: TBoard; |
{tmpBoard: TBoard;} |
| 125 |
begin |
begin |
| 126 |
|
|
| 127 |
if FItem = nil then begin |
if FItem = nil then begin |
| 128 |
FItem := BBSsFindBoardFromURL( URL ); |
FItem := BBSsFindBoardFromURL( URL ); |
| 129 |
if FItem = nil then begin |
if FItem = nil then begin |
|
//===== プラグイン |
|
|
try |
|
|
//作業中// |
|
|
bi := High( BoardPlugIns ); |
|
|
for i := Low( BoardPlugIns ) to bi do begin |
|
|
if Assigned( Pointer( BoardPlugIns[ i ].Module ) ) then begin |
|
|
case BoardPlugIns[ i ].AcceptURL( URL ) of |
|
|
atThread: |
|
|
begin |
|
|
tmpThread := TThreadItem.Create( BoardPlugIns[ i ], URL ); |
|
|
boardURL := tmpThread.BoardPlugIn.GetBoardURL( DWORD( tmpThread ) ); |
|
|
FItem := BBSsFindBoardFromURL( boardURL ); |
|
|
URL := FItem.URL; |
|
|
tmpThread.Free; |
|
|
break; |
|
|
end; |
|
|
atBoard: |
|
|
begin |
|
|
tmpBoard := TBoard.Create(BoardPlugIns[ i ], URL); |
|
|
FItem := BBSsFindBoardFromURL( tmpBoard.URL ); |
|
|
tmpBoard.Free; |
|
|
if FItem <> nil then begin |
|
|
URL := FItem.URL; |
|
|
end; |
|
|
break; |
|
|
end; |
|
|
end; |
|
|
end; |
|
|
end; |
|
|
except |
|
|
// exception が発生した場合は内部処理に任せたいのでここでは何もしない |
|
|
end; |
|
|
end; |
|
|
if FItem = nil then begin |
|
| 130 |
tmpURL := URL; |
tmpURL := URL; |
| 131 |
GikoSys.ParseURI( tmpURL, protocol, host, path, document, port, bookmark ); |
GikoSys.ParseURI( tmpURL, protocol, host, path, document, port, bookmark ); |
| 132 |
if GikoSys.Is2chHost( host ) then begin |
if GikoSys.Is2chHost( host ) then begin |
| 222 |
end; |
end; |
| 223 |
|
|
| 224 |
if FItem = nil then begin |
if FItem = nil then begin |
| 225 |
FItem := TThreadItem.Create( board.BoardPlugIn, browsableURL ); |
FItem := TThreadItem.Create( board.BoardPlugIn, board, browsableURL ); |
| 226 |
|
|
| 227 |
FItem.Title := Title; |
FItem.Title := Title; |
| 228 |
board.Add( FItem ); |
board.Add( FItem ); |
| 401 |
if threadItem = nil then begin |
if threadItem = nil then begin |
| 402 |
threadItem := TThreadItem.Create( |
threadItem := TThreadItem.Create( |
| 403 |
board.BoardPlugIn, |
board.BoardPlugIn, |
| 404 |
|
board, |
| 405 |
GikoSys.Get2chBoard2ThreadURL( board, ChangeFileExt( Node.Attributes[ 'thread' ], '' ) ) ); |
GikoSys.Get2chBoard2ThreadURL( board, ChangeFileExt( Node.Attributes[ 'thread' ], '' ) ) ); |
| 406 |
threadItem.Title := Node.Attributes[ 'title' ]; |
threadItem.Title := Node.Attributes[ 'title' ]; |
| 407 |
board.Add( threadItem ); |
board.Add( threadItem ); |