uses
Windows, Classes, SysUtils,
IdHTTP, IdComponent, IdGlobal, IdException,
- AbonUnit;
+ ExternalBoardPlugInMain, ExternalFilePath, ExternalThreadItem, ExternalBoardItem;
type
// =========================================================================
- // PlugInMain \8aÖ\98A
- // =========================================================================
-
- // \83_\83E\83\93\83\8d\81[\83h\82ª\90¬\8c÷\82µ\82½\82©\82Ç\82¤\82©
- TDownloadState = (dsWait, dsWork, dsComplete, dsDiffComplete, dsNotModify, dsAbort, dsError);
-
- // *************************************************************************
- // \83v\83\89\83O\83C\83\93\82Ì\83o\81[\83W\83\87\83\93
- // *************************************************************************
- TOnVersionInfo = procedure(
- var outAgent : PChar; // \83o\81[\83W\83\87\83\93\82ð\88ê\90Ø\8aÜ\82Ü\82È\82¢\8f\83\90\88\82È\96¼\8fÌ
- var outMajor : DWORD; // \83\81\83W\83\83\81[\83o\81[\83W\83\87\83\93
- var outMinor : DWORD; // \83}\83C\83i\81[\83o\81[\83W\83\87\83\93
- var outRelease : PChar; // \83\8a\83\8a\81[\83X\92i\8aK\96¼
- var outRevision : DWORD // \83\8a\83r\83W\83\87\83\93\83i\83\93\83o\81[
- ); stdcall;
-
- // *************************************************************************
- // \8ew\92è\82µ\82½ URL \82ð\82±\82Ì\83v\83\89\83O\83C\83\93\82Å\8eó\82¯\95t\82¯\82é\82©\82Ç\82¤\82©
- // *************************************************************************
- TOnAcceptURL = function(
- inURL : PChar // \94»\92f\82ð\8bÂ\82¢\82Å\82¢\82é URL
- ): Boolean; stdcall; // \8eó\82¯\95t\82¯\82é\82È\82ç True
-
- // *************************************************************************
- // \83X\83\8c\88ê\97\97\82Ì URL \82©\82ç\83X\83\8c\83b\83h\82Ì URL \82ð\93±\82«\8fo\82·
- // *************************************************************************
- TOnListURL2ThreadURL = function(
- inListURL : PChar; // \83X\83\8c\88ê\97\97\82ð\8e¦\82µ\82½ URL
- inFileName : PChar // \83X\83\8c\83b\83h\83t\83@\83C\83\8b\96¼
- ) : PChar; stdcall; // \83X\83\8c\83b\83h\82Ì URL
-
-
-
- // =========================================================================
- // TThreadItem \8aÖ\98A
- // =========================================================================
-
- // TThreadItem \82Ì\83v\83\8d\83p\83e\83B\90Ý\92è\81^\8eæ\93¾ ID
- TThreadItemProperty = (
- tipContext, // : DWORD // \8e©\97R\82É\90Ý\92è\82µ\82Ä\82¢\82¢\92l
- tipNo, // : Integer // \94Ô\8d\86
- tipFileName, // : string // \83X\83\8c\83b\83h\83t\83@\83C\83\8b\96¼
- tipTitle, // : string // \83X\83\8c\83b\83h\83^\83C\83g\83\8b
- tipRoundDate, // : TDateTime // \83X\83\8c\83b\83h\82ð\8eæ\93¾\82µ\82½\93ú\8e\9e\81i\8f\84\89ñ\93ú\8e\9e\81j
- tipLastModified, // : TDateTime // \83X\83\8c\83b\83h\82ª\8dX\90V\82³\82ê\82Ä\82¢\82é\93ú\8e\9e\81i\83T\81[\83o\91¤\93ú\8e\9e\81j
- tipCount, // : Integer // \83X\83\8c\83b\83h\83J\83E\83\93\83g\81i\83\8d\81[\83J\83\8b\81j
- tipAllResCount, // : Integer // \83X\83\8c\83b\83h\83J\83E\83\93\83g\81i\83T\81[\83o\81j
- tipNewResCount, // : Integer // \83X\83\8c\83b\83h\90V\92\85\90\94
- tipSize, // : Integer // \83X\83\8c\83b\83h\83T\83C\83Y
- tipRound, // : Boolean // \8f\84\89ñ\83t\83\89\83O
- tipRoundName, // : string // \8f\84\89ñ\96¼
- tipIsLogFile, // : Boolean // \83\8d\83O\91¶\8dÝ\83t\83\89\83O
- tipKokomade, // : Integer // \83R\83R\82Ü\82Å\93Ç\82ñ\82¾\94Ô\8d\86
- tipNewReceive, // : Integer // \83R\83R\82©\82ç\90V\8bK\8eó\90M
- tipNewArrival, // : Boolean // \90V\92\85
- tipUnRead, // : Boolean // \96¢\93Ç\83t\83\89\83O
- tipScrollTop, // : Integer // \83X\83N\83\8d\81[\83\8b\88Ê\92u
- tipDownloadHost, // : string // \8d¡\82Ì\83z\83X\83g\82Æ\88á\82¤\8fê\8d\87\82Ì\83z\83X\83g
- tipAgeSage, // : TThreadAgeSage // \83A\83C\83e\83\80\82Ì\8fã\82°\89º\82°
- tipURL, // : string // \83X\83\8c\83b\83h\82ð\83u\83\89\83E\83U\82Å\95\\8e¦\82·\82é\8dÛ\82Ì URL
- tipFilePath // : string // \82±\82Ì\83X\83\8c\82ª\95Û\91¶\82³\82ê\82Ä\82¢\82é\83p\83X
- );
-
- // *************************************************************************
- // TThreadItem \82ª\90¶\90¬\82³\82ê\82½
- // *************************************************************************
- TThreadItemCreate = procedure(
- inInstance : DWORD
- ); stdcall;
-
- // *************************************************************************
- // TThreadItem \82ª\94j\8aü\82³\82ê\82½
- // *************************************************************************
- TThreadItemDispose = procedure(
- inInstance : DWORD
- ); stdcall;
-
- // *************************************************************************
- // \83_\83E\83\93\83\8d\81[\83h\82ð\8ew\8e¦\82³\82ê\82½
- // *************************************************************************
- TThreadItemOnDownload = function(
- inInstance : DWORD // \83C\83\93\83X\83^\83\93\83X
- ) : TDownloadState; stdcall; // \83_\83E\83\93\83\8d\81[\83h\82ª\90¬\8c÷\82µ\82½\82©\82Ç\82¤\82©
-
- // *************************************************************************
- // \83\8c\83X\94Ô\8d\86 n \82É\91Î\82·\82é html \82ð\97v\8b\81\82³\82ê\82½
- // *************************************************************************
- TThreadItemOnGetRes = function(
- inInstance : DWORD; // \83C\83\93\83X\83^\83\93\83X
- inNo : DWORD // \95\\8e¦\82·\82é\83\8c\83X\94Ô\8d\86
- ) : PChar; stdcall; // \95\\8e¦\82·\82é HTML
-
- // *************************************************************************
- // \83X\83\8c\83b\83h\82Ì\83w\83b\83_ html \82ð\97v\8b\81\82³\82ê\82½
- // *************************************************************************
- TThreadItemOnGetHeader = function(
- inInstance : DWORD; // \83N\83\89\83X\82Ì\83C\83\93\83X\83^\83\93\83X
- inOptionalHeader : PChar // \92Ç\89Á\82Ì\83w\83b\83_
- ) : PChar; stdcall; // \90®\8c`\82³\82ê\82½ HTML
-
- // *************************************************************************
- // \83X\83\8c\83b\83h\82Ì\83t\83b\83^ html \82ð\97v\8b\81\82³\82ê\82½
- // *************************************************************************
- TThreadItemOnGetFooter = function(
- inInstance : DWORD; // \83N\83\89\83X\82Ì\83C\83\93\83X\83^\83\93\83X
- inOptionalFooter : PChar // \92Ç\89Á\82Ì\83t\83b\83^
- ) : PChar; stdcall; // \90®\8c`\82³\82ê\82½ HTML
-
-
-
- // =========================================================================
- // TBoardItem \8aÖ\98A
- // =========================================================================
-
- // TBoardItem \82Ì\83v\83\8d\83p\83e\83B\90Ý\92è\81^\8eæ\93¾ ID
- TBoardItemProperty = (
- bipContext, // : DWORD // \8e©\97R\82É\90Ý\92è\82µ\82Ä\82¢\82¢\92l
- bipItems, // : TThreadItem // \94Â\82É\8cq\82ª\82ê\82Ä\82¢\82é\83X\83\8c\83b\83h
- bipNo, // : Integer // \94Ô\8d\86
- bipTitle, // : string // \94Â\83^\83C\83g\83\8b
- bipRoundDate, // : TDateTime // \94Â\82ð\8eæ\93¾\82µ\82½\93ú\8e\9e\81i\8f\84\89ñ\93ú\8e\9e\81j
- bipLastModified, // : TDateTime // \94Â\82ª\8dX\90V\82³\82ê\82Ä\82¢\82é\93ú\8e\9e\81i\83T\81[\83o\91¤\93ú\8e\9e\81j
- bipLastGetTime, // : TDateTime // \83X\83\8c\83b\83h\82Ü\82½\82Í\83X\83\8c\83b\83h\88ê\97\97\82ð\8dÅ\8cã\82É\8dX\90V\82µ\82½\93ú\8e\9e\81i\83T\81[\83o\91¤\93ú\8e\9e\81E\8f\91\82«\8d\9e\82Ý\8e\9e\82É\8eg\97p\82·\82é\81j
- bipRound, // : Boolean // \8f\84\89ñ\97\\96ñ
- bipRoundName, // : string // \8f\84\89ñ\96¼
- bipIsLogFile, // : Boolean // \83\8d\83O\91¶\8dÝ\83t\83\89\83O
- bipUnRead, // : Integer // \83X\83\8c\83b\83h\96¢\93Ç\90\94
- bipURL, // : string // \94Â\82ð\83u\83\89\83E\83U\82Å\95\\8e¦\82·\82é\8dÛ\82Ì URL
- bipFilePath // : string // \82±\82Ì\94Â\82ª\95Û\91¶\82³\82ê\82Ä\82¢\82é\83p\83X
- );
-
- // *************************************************************************
- // TBoardItem \82ª\90¶\90¬\82³\82ê\82½
- // *************************************************************************
- TBoardItemCreate = procedure(
- inInstance : DWORD
- ); stdcall;
-
- // *************************************************************************
- // TBoardItem \82ª\94j\8aü\82³\82ê\82½
- // *************************************************************************
- TBoardItemDispose = procedure(
- inInstance : DWORD
- ); stdcall;
-
- // *************************************************************************
- // \83_\83E\83\93\83\8d\81[\83h\82ð\8ew\8e¦\82³\82ê\82½
- // *************************************************************************
- TBoardItemOnDownload = function(
- inInstance : DWORD // \83C\83\93\83X\83^\83\93\83X
- ) : TDownloadState; stdcall; // \83_\83E\83\93\83\8d\81[\83h\82ª\90¬\8c÷\82µ\82½\82©\82Ç\82¤\82©
-
- // *************************************************************************
- // \8ae\83X\83\8c\82Ì\8fî\95ñ\82ð\95Ô\8bp
- // *************************************************************************
- TBoardItemEnumThreadCallBack = function(
- inURL : PChar; // \83X\83\8c\83b\83h\82Ì URL
- inTitle : PChar; // \83X\83\8c\83^\83C
- inCount : DWORD // \83\8c\83X\82Ì\90\94
- ) : Boolean; stdcall; // \97ñ\8b\93\82ð\91±\82¯\82é\82È\82ç True
-
- // *************************************************************************
- // \82±\82Ì\94Â\82É\95Û\97L\82µ\82Ä\82¢\82é\83X\83\8c\82ð\97ñ\8b\93
- // *************************************************************************
- TBoardItemOnEnumThread = procedure(
- inInstance : DWORD; // \83C\83\93\83X\83^\83\93\83X
- inCallBack : TBoardItemEnumThreadCallBack // \95Ô\8bp\82·\82×\82«\83R\81[\83\8b\83o\83b\83N
- ); stdcall;
-
-
-
- // =========================================================================
// \83v\83\89\83O\83C\83\93\82ð\8aÇ\97\9d\82·\82é TBoardPlugin \83N\83\89\83X
// =========================================================================
TBoardPlugIn = class( TObject )
FFilePath : string; // \83v\83\89\83O\83C\83\93\82ð\8e¦\82·\83p\83X
FModule : HMODULE; // \83v\83\89\83O\83C\83\93\82Ì\83\82\83W\83\85\81[\83\8b\83n\83\93\83h\83\8b
+ FLoad : TOnLoad;
FVersionInfo : TOnVersionInfo;
FAcceptURL : TOnAcceptURL;
+ FExtractBoardURL : TOnExtractBoardURL;
+ FPlugInMenu : TOnPlugInMenu;
FCreateThreadItem : TThreadItemCreate;
FDisposeThreadItem : TThreadItemDispose;
FDownloadThread : TThreadItemOnDownload;
+ FWriteThread : TThreadItemOnWrite;
FGetRes : TThreadItemOnGetRes;
+ FGetDat : TThreadItemOnGetDat;
FGetHeader : TThreadItemOnGetHeader;
FGetFooter : TThreadItemOnGetFooter;
+ FGetBoardURL : TThreadItemOnGetBoardURL;
FCreateBoardItem : TBoardItemCreate;
FDisposeBoardItem : TBoardItemDispose;
FDownloadBoard : TBoardItemOnDownload;
+ FCreateThread : TBoardItemOnCreateThread;
FEnumThread : TBoardItemOnEnumThread;
+ FFileName2ThreadURL : TBoardItemOnFileName2ThreadURL;
public
// \83R\83\93\83X\83g\83\89\83N\83^
constructor CreateFromName( inName : string );
// \83\82\83W\83\85\81[\83\8b\83n\83\93\83h\83\8b\82ð\8ew\92è\82µ\82Ä\8dì\90¬
constructor CreateFromModule( inModule : HMODULE );
+ // \83f\83X\83g\83\89\83N\83^
+ destructor Destroy; override;
// \83v\83\89\83O\83C\83\93\82Ì\83p\83X\82ð\8ew\92è\82µ\82Ä\83\8d\81[\83h
procedure LoadFromPath( inPath : string );
procedure LoadFromModule( inModule : HMODULE );
//===== PlugInMain \8aÖ\98A
+ // \83v\83\89\83O\83C\83\93\82ª(\90³\82µ\82)\83\8d\81[\83h\82³\82ê\82½
+ procedure Loaded;
// \83o\81[\83W\83\87\83\93\8fî\95ñ
procedure VersionInfo( var outAgent : string;
var outMajor : DWORD; var outMinor : DWORD;
var outRelease : string; var outRevision : DWORD );
// \8ew\92è\82µ\82½ URL \82ð\82±\82Ì\83v\83\89\83O\83C\83\93\82Å\8eó\82¯\95t\82¯\82é\82©\82Ç\82¤\82©
- function AcceptURL( inURL : string ) : Boolean;
+ function AcceptURL( inURL : string ) : TAcceptType;
+ // URL\82©\82ç\8eg\82¦\82éBoard\82ÌURL\82ð\93±\82«\8fo\82·
+ function ExtractBoardURL( inURL : string ): string;
+ // \83\81\83j\83\85\81[\83n\83\93\83h\83\89
+ procedure PlugInMenu( inHandle : HMENU );
//===== TThreadItem \8aÖ\98A
// TThreadItem \82ª\90¶\90¬\82³\82ê\82½
procedure DisposeThreadItem( threadItem : DWORD );
// \83_\83E\83\93\83\8d\81[\83h\82ð\8ew\8e¦
function DownloadThread( threadItem : DWORD ) : TDownloadState;
+ // \8f\91\82«\8d\9e\82Ý\82ð\8ew\8e¦
+ function WriteThread( threadItem : DWORD; inName : string; inMail : string; inMessage : string ) : TDownloadState;
// \83\8c\83X\94Ô\8d\86 n \82É\91Î\82·\82é html \82ð\97v\8b\81
function GetRes( threadItem : DWORD; inNo : DWORD ) : string;
+ // \83\8c\83X\94Ô\8d\86 n \82É\91Î\82·\82é Dat \82ð\97v\8b\81
+ function GetDat( threadItem : DWORD; inNo : DWORD ) : string;
// \83X\83\8c\83b\83h\82Ì\83w\83b\83_ html \82ð\97v\8b\81
function GetHeader( threadItem : DWORD; inOptionalHeader : string ) : string;
// \83X\83\8c\83b\83h\82Ì\83t\83b\83^ html \82ð\97v\8b\81
function GetFooter( threadItem : DWORD; inOptionalFooter : string ) : string;
+ // \82±\82Ì ThreadItem \82ª\91®\82·\82é\94Â\82Ì URL \82ð\97v\8b\81
+ function GetBoardURL( threadItem : DWORD ) : string;
//===== TBoardItem \8aÖ\98A
// TBoard \82ª\90¶\90¬\82³\82ê\82½
procedure DisposeBoardItem( boardItem : DWORD );
// \83_\83E\83\93\83\8d\81[\83h\82ð\8ew\8e¦
function DownloadBoard( boardItem : DWORD ) : TDownloadState;
+ // \83X\83\8c\97§\82Ä\82ð\8ew\8e¦
+ function CreateThread( boardItem : DWORD; inSubject : string; inName : string; inMail : string; inMessage : string ) : TDownloadState;
// \82±\82Ì\94Â\82É\95Û\97L\82µ\82Ä\82¢\82é\83X\83\8c\82ð\97ñ\8b\93
- procedure EnumThread( inInstance : DWORD; inCallBack : TBoardItemEnumThreadCallBack );
+ procedure EnumThread( boardItem : DWORD; inCallBack : TBoardItemEnumThreadCallBack );
+ // \83t\83@\83C\83\8b\96¼\82©\82ç\83X\83\8c\83b\83h\82Ì URL \82ð\97v\8b\81
+ function FileName2ThreadURL( boardItem : DWORD; inFileName : string ) : string;
private
procedure LoadPlugInAPI;
procedure InitializeBoardPlugIns;
-function CreateResultString(
- resultStr : string
-) : PChar; stdcall;
-
-function ThreadItemDat2HTML(
- inInstance : DWORD; // \83N\83\89\83X\82Ì\83C\83\93\83X\83^\83\93\83X
- inDatRes : PChar; // \96¼\91O<>\83\81\81[\83\8b<>\93ú\95tID<>\96{\95¶<> \82Å\8d\\90¬\82³\82ê\82½\83e\83L\83X\83g
- inResNo : DWORD; // \83\8c\83X\94Ô\8d\86
- inIsNew : Boolean // \90V\92\85\83\8c\83X\82È\82ç True
-) : PChar; stdcall; // \90®\8c`\82³\82ê\82½ HTML
-
-procedure DisposeResultString(
- resultStr : PChar
-); stdcall;
-
implementation
uses GikoSystem, BoardGroup;
pluginNames := TStringList.Create;
try
- GikoSys.GetFileList( GikoSys.Setting.GetBoardPlugInDir, '*', pluginNames, False, False );
+ //GikoSys.GetFileList( GikoSys.Setting.GetBoardPlugInDir, '*', pluginNames, False, False );
+ pluginNames.BeginUpdate;
+ GikoSys.GetFileList( GikoSys.Setting.GetBoardPlugInDir, '*.dll', pluginNames, False );
+ pluginNames.EndUpdate;
SetLength( BoardPlugIns, pluginNames.Count );
-
+ //
+ SetLength( BoardGroups, pluginNames.Count + 1 );
+ BoardGroups[0] := TBoardGroup.Create;
+ BoardGroups[0].Sorted := true;
+ BoardGroups[0].BoardPlugIn := nil;
+ //
bound := pluginNames.Count - 1;
- for i := 0 to bound do
- BoardPlugIns[ i ] := TBoardPlugIn.CreateFromName( pluginNames.Strings[ i ] );
+ for i := 0 to bound do begin
+ try
+ BoardPlugIns[ i ] := TBoardPlugIn.CreateFromName( pluginNames.Strings[ i ] );
+ BoardPlugIns[ i ].Loaded;
+ BoardGroups[ i + 1 ] := TBoardGroup.Create;
+ BoardGroups[ i + 1 ].Sorted := True;
+ BoardGroups[ i + 1 ].BoardPlugIn := BoardPlugIns[ i ];
+ except end;
+ end;
finally
pluginNames.Free;
end;
inherited;
+ FLoad := nil;
FVersionInfo := nil;
FAcceptURL := nil;
+ FExtractBoardURL := nil;
+ FPlugInMenu := nil;
FCreateThreadItem := nil;
FDisposeThreadItem := nil;
FDownloadThread := nil;
+ FWriteThread := nil;
FGetRes := nil;
+ FGetDat := nil;
FGetHeader := nil;
FGetFooter := nil;
FCreateBoardItem := nil;
FDisposeBoardItem := nil;
FDownloadBoard := nil;
+ FCreateThread := nil;
FEnumThread := nil;
+ FFileName2ThreadURL := nil;
end;
end;
// *************************************************************************
+// \83f\83X\83g\83\89\83N\83^
+// *************************************************************************
+destructor TBoardPlugIn.Destroy;
+begin
+
+ FreeLibrary( FModule );
+
+ inherited;
+
+end;
+
+// *************************************************************************
// \83v\83\89\83O\83C\83\93\82Ì\83p\83X\82ð\8ew\92è\82µ\82Ä\83\8d\81[\83h
// *************************************************************************
procedure TBoardPlugIn.LoadFromPath(
end;
// *************************************************************************
+// \83v\83\89\83O\83C\83\93\82ª(\90³\82µ\82)\83\8d\81[\83h\82³\82ê\82½
+// *************************************************************************
+procedure TBoardPlugIn.Loaded;
+begin
+
+ if Assigned( FLoad ) then
+ FLoad( DWORD( Self ) );
+
+end;
+
+// *************************************************************************
// \83o\81[\83W\83\87\83\93\8fî\95ñ
// *************************************************************************
procedure TBoardPlugIn.VersionInfo(
// *************************************************************************
function TBoardPlugIn.AcceptURL(
inURL : string
-) : Boolean;
+) : TAcceptType;
begin
if Assigned( FAcceptURL ) then
Result := FAcceptURL( PChar( inURL ) )
else
- Result := False;
+ Result := atNoAccept;
+
+end;
+// *************************************************************************
+// \8ew\92è\82µ\82½ URL \82©\82ç\8eg\82¦\82éBoard\82ÌURL\82ð\93±\82«\8fo\82·
+// *************************************************************************
+function TBoardPlugIn.ExtractBoardURL(
+ inURL : string
+) : string;
+var
+ URL : PChar;
+// tmp : string;
+begin
+ Result := inURL;
+ if Assigned( FExtractBoardURL ) then begin
+ FExtractBoardURL( PChar(inURL), URL);
+ Result := string(URL);
+ DisposeResultString(URL);
+ end;
+end;
+// *************************************************************************
+// \83\81\83j\83\85\81[\83n\83\93\83h\83\89
+// *************************************************************************
+procedure TBoardPlugIn.PlugInMenu(
+ inHandle : HMENU // \83\81\83j\83\85\81[\83n\83\93\83h\83\8b
+);
+begin
+
+ if Assigned( FPlugInMenu ) then
+ FPlugInMenu( inHandle );
end;
// TThreadItem \82ª\90¶\90¬\82³\82ê\82½
// *************************************************************************
procedure TBoardPlugIn.CreateThreadItem(
- threadItem : DWORD
+ threadItem : DWORD // ThreadItem \82Ì\83C\83\93\83X\83^\83\93\83X
);
begin
// TThreadItem \82ª\94j\8aü\82³\82ê\82½
// *************************************************************************
procedure TBoardPlugIn.DisposeThreadItem(
- threadItem : DWORD
+ threadItem : DWORD // ThreadItem \82Ì\83C\83\93\83X\83^\83\93\83X
);
begin
// \83_\83E\83\93\83\8d\81[\83h\82ð\8ew\8e¦
// *************************************************************************
function TBoardPlugIn.DownloadThread(
- threadItem : DWORD
+ threadItem : DWORD // ThreadItem \82Ì\83C\83\93\83X\83^\83\93\83X
) : TDownloadState;
begin
end;
// *************************************************************************
+// \8f\91\82«\8d\9e\82Ý\82ð\8ew\8e¦
+// *************************************************************************
+function TBoardPlugIn.WriteThread(
+ threadItem : DWORD; // ThreadItem \82Ì\83C\83\93\83X\83^\83\93\83X
+ inName : string; // \96¼\91O(\83n\83\93\83h\83\8b)
+ inMail : string; // \83\81\81[\83\8b\83A\83h\83\8c\83X
+ inMessage : string // \96{\95¶
+) : TDownloadState; // \8f\91\82«\8d\9e\82Ý\82ª\90¬\8c÷\82µ\82½\82©\82Ç\82¤\82©
+begin
+
+ if Assigned( FWriteThread ) then
+ Result := FWriteThread( threadItem, PChar( inName ), PChar( inMail ), PChar( inMessage ) )
+ else
+ Result := dsError;
+
+end;
+
+// *************************************************************************
// \83\8c\83X\94Ô\8d\86 n \82É\91Î\82·\82é html \82ð\97v\8b\81
// *************************************************************************
function TBoardPlugIn.GetRes(
- threadItem : DWORD; // \83C\83\93\83X\83^\83\93\83X
+ threadItem : DWORD; // ThreadItem \82Ì\83C\83\93\83X\83^\83\93\83X
inNo : DWORD // \95\\8e¦\82·\82é\83\8c\83X\94Ô\8d\86
) : string; // \95\\8e¦\82·\82é HTML
var
if Assigned( FGetRes ) then begin
tmp := FGetRes( threadItem, inNo );
- Result := string( tmp );
- DisposeResultString( tmp );
+ try
+ Result := string( tmp );
+ finally
+ DisposeResultString( tmp );
+ end;
+ end;
+
+end;
+
+// *************************************************************************
+// \83\8c\83X\94Ô\8d\86 n \82É\91Î\82·\82é Dat \82ð\97v\8b\81
+// *************************************************************************
+function TBoardPlugIn.GetDat(
+ threadItem : DWORD; // ThreadItem \82Ì\83C\83\93\83X\83^\83\93\83X
+ inNo : DWORD // \95\\8e¦\82·\82é\83\8c\83X\94Ô\8d\86
+) : string; // \82Q\82¿\82á\82ñ\82Ë\82é\82Ìdat\8c`\8e®
+var
+ tmp : PChar;
+begin
+
+ if Assigned( FGetDat ) then begin
+ tmp := FGetDat( threadItem, inNo );
+ try
+ Result := string( tmp );
+ finally
+ DisposeResultString(tmp); end;
end;
end;
// \83X\83\8c\83b\83h\82Ì\83w\83b\83_ html \82ð\97v\8b\81
// *************************************************************************
function TBoardPlugIn.GetHeader(
- threadItem : DWORD; // \83N\83\89\83X\82Ì\83C\83\93\83X\83^\83\93\83X
+ threadItem : DWORD; // ThreadItem \82Ì\83C\83\93\83X\83^\83\93\83X
inOptionalHeader : string // \92Ç\89Á\82Ì\83w\83b\83_
) : string; // \90®\8c`\82³\82ê\82½ HTML
var
if Assigned( FGetHeader ) then begin
tmp := FGetHeader( threadItem, PChar( inOptionalHeader ) );
- Result := string( tmp );
- DisposeResultString( tmp );
+ try
+ Result := string( tmp );
+ finally
+ DisposeResultString( tmp );
+ end;
end;
end;
// \83X\83\8c\83b\83h\82Ì\83t\83b\83^ html \82ð\97v\8b\81
// *************************************************************************
function TBoardPlugIn.GetFooter(
- threadItem : DWORD; // \83N\83\89\83X\82Ì\83C\83\93\83X\83^\83\93\83X
+ threadItem : DWORD; // ThreadItem \82Ì\83C\83\93\83X\83^\83\93\83X
inOptionalFooter : string // \92Ç\89Á\82Ì\83t\83b\83^
) : string; // \90®\8c`\82³\82ê\82½ HTML
var
end;
// *************************************************************************
+// \82±\82Ì ThreadItem \82ª\91®\82·\82é\94Â\82Ì URL \82ð\97v\8b\81
+// *************************************************************************
+function TBoardPlugIn.GetBoardURL(
+ threadItem : DWORD // ThreadItem \82Ì\83C\83\93\83X\83^\83\93\83X
+) : string;
+var
+ tmp : PChar;
+begin
+
+ if Assigned( FGetBoardURL ) then begin
+ tmp := FGetBoardURL( threadItem );
+ Result := string( tmp );
+ DisposeResultString( tmp );
+ end;
+
+end;
+
+// *************************************************************************
// TBoardItem \82ª\90¶\90¬\82³\82ê\82½
// *************************************************************************
procedure TBoardPlugIn.CreateBoardItem(
- BoardItem : DWORD
+ boardItem : DWORD // BoardItem \82Ì\83C\83\93\83X\83^\83\93\83X
);
begin
if Assigned( FCreateBoardItem ) then
- FCreateBoardItem( BoardItem );
+ FCreateBoardItem( boardItem );
end;
// TBoardItem \82ª\94j\8aü\82³\82ê\82½
// *************************************************************************
procedure TBoardPlugIn.DisposeBoardItem(
- BoardItem : DWORD
+ boardItem : DWORD // BoardItem \82Ì\83C\83\93\83X\83^\83\93\83X
);
begin
if Assigned( FDisposeBoardItem ) then
- FDisposeBoardItem( BoardItem );
+ FDisposeBoardItem( boardItem );
end;
// \83_\83E\83\93\83\8d\81[\83h\82ð\8ew\8e¦
// *************************************************************************
function TBoardPlugIn.DownloadBoard(
- BoardItem : DWORD
+ boardItem : DWORD // BoardItem \82Ì\83C\83\93\83X\83^\83\93\83X
) : TDownloadState;
begin
if Assigned( FDownloadBoard ) then
- Result := FDownloadBoard( BoardItem )
+ Result := FDownloadBoard( boardItem )
+ else
+ Result := dsError;
+
+end;
+
+// *************************************************************************
+// \83X\83\8c\97§\82Ä\82ð\8ew\8e¦
+// *************************************************************************
+function TBoardPlugIn.CreateThread(
+ boardItem : DWORD; // BoardItem \82Ì\83C\83\93\83X\83^\83\93\83X
+ inSubject : string; // \83X\83\8c\83^\83C
+ inName : string; // \96¼\91O(\83n\83\93\83h\83\8b)
+ inMail : string; // \83\81\81[\83\8b\83A\83h\83\8c\83X
+ inMessage : string // \96{\95¶
+) : TDownloadState; // \8f\91\82«\8d\9e\82Ý\82ª\90¬\8c÷\82µ\82½\82©\82Ç\82¤\82©
+begin
+
+ if Assigned( FCreateThread ) then
+ Result := FCreateThread( boardItem, PChar( inSubject ), PChar( inName ), PChar( inMail ), PChar( inMessage ) )
else
Result := dsError;
// \82±\82Ì\94Â\82É\95Û\97L\82µ\82Ä\82¢\82é\83X\83\8c\82ð\97ñ\8b\93
// *************************************************************************
procedure TBoardPlugIn.EnumThread(
- inInstance : DWORD;
+ boardItem : DWORD; // BoardItem \82Ì\83C\83\93\83X\83^\83\93\83X
inCallBack : TBoardItemEnumThreadCallBack
);
begin
if Assigned( FEnumThread ) then
- FEnumThread( inInstance, inCallBack );
+ FEnumThread( boardItem, inCallBack );
+
+end;
+
+// *************************************************************************
+// \83t\83@\83C\83\8b\96¼\82©\82ç\83X\83\8c\83b\83h\82Ì URL \82ð\97v\8b\81
+// *************************************************************************
+function TBoardPlugIn.FileName2ThreadURL(
+ boardItem : DWORD; // BoardItem \82Ì\83C\83\93\83X\83^\83\93\83X
+ inFileName : string
+) : string;
+var
+ tmp : PChar;
+begin
+
+ if Assigned( FFileName2ThreadURL ) then begin
+ tmp := FFileName2ThreadURL( boardItem, PChar( inFileName ) );
+ Result := string( tmp );
+ DisposeResultString( tmp );
+ end;
end;
try
if Assigned( Pointer( FModule ) ) then begin
+ FLoad := GetProcAddress( FModule, 'OnLoad' );
FVersionInfo := GetProcAddress( FModule, 'OnVersionInfo' );
FAcceptURL := GetProcAddress( FModule, 'OnAcceptURL' );
+ FExtractBoardURL := GetProcAddress( FModule, 'OnExtractBoardURL' );
+ FPlugInMenu := GetProcAddress( FModule, 'OnPlugInMenu' );
FCreateThreadItem := GetProcAddress( FModule, 'ThreadItemCreate' );
FDisposeThreadItem := GetProcAddress( FModule, 'ThreadItemDispose' );
FDownloadThread := GetProcAddress( FModule, 'ThreadItemOnDownload' );
+ FWriteThread := GetProcAddress( FModule, 'ThreadItemOnWrite' );
FGetRes := GetProcAddress( FModule, 'ThreadItemOnGetRes' );
+ FGetDat := GetProcAddress( FModule, 'ThreadItemOnGetDat' );
FGetHeader := GetProcAddress( FModule, 'ThreadItemOnGetHeader' );
FGetFooter := GetProcAddress( FModule, 'ThreadItemOnGetFooter' );
+ FGetBoardURL := GetProcAddress( FModule, 'ThreadItemOnGetBoardURL' );
FCreateBoardItem := GetProcAddress( FModule, 'BoardItemCreate' );
FDisposeBoardItem := GetProcAddress( FModule, 'BoardItemDispose' );
FDownloadBoard := GetProcAddress( FModule, 'BoardItemOnDownload' );
+ FCreateThread := GetProcAddress( FModule, 'BoardItemOnCreateThread' );
FEnumThread := GetProcAddress( FModule, 'BoardItemOnEnumThread' );
+ FFileName2ThreadURL := GetProcAddress( FModule, 'BoardItemOnFileName2ThreadURL' );
end;
except
end;
end;
-
-
-// =========================================================================
-// PlugInMain
-// =========================================================================
-
-// *************************************************************************
-// \96ß\82è\92l\82ª PChar \82Å\82 \82é API \82Ì\83\81\83\82\83\8a\82ð\8am\95Û\82·\82é
-// *************************************************************************
-function CreateResultString(
- resultStr : string
-) : PChar; stdcall;
-var
- tmp : PChar;
-begin
-
- tmp := PChar( resultStr );
- GetMem( Result, Length( tmp ) + 1 );
- Move( tmp^, Result^, Length( tmp ) + 1 );
-
-end;
-
-// *************************************************************************
-// \96ß\82è\92l\82ª PChar \82Å\82 \82é API \82Ì\83\81\83\82\83\8a\82ð\8aJ\95ú\82·\82é
-// *************************************************************************
-procedure DisposeResultString(
- resultStr : PChar
-); stdcall;
-begin
-
- FreeMem( resultStr );
-
-end;
-
-// *************************************************************************
-// \83v\83\8d\83O\83\89\83\80\96{\91Ì\82Ì\83o\81[\83W\83\87\83\93\82ð\8eæ\93¾\82·\82é
-// *************************************************************************
-procedure VersionInfo(
- var outAgent : PChar; // \83o\81[\83W\83\87\83\93\82ð\88ê\90Ø\8aÜ\82Ü\82È\82¢\8f\83\90\88\82È\96¼\8fÌ
- var outMajor : DWORD; // \83\81\83W\83\83\81[\83o\81[\83W\83\87\83\93
- var outMinor : DWORD; // \83}\83C\83i\81[\83o\81[\83W\83\87\83\93
- var outRelease : PChar; // \83\8a\83\8a\81[\83X\92i\8aK\96¼
- var outRevision : DWORD // \83\8a\83r\83W\83\87\83\93\83i\83\93\83o\81[
-); stdcall;
-begin
-
- outAgent := CreateResultString( PChar( APP_NAME ) );
- outMajor := 1;
- outMinor := 0;
- outRelease := CreateResultString( PChar( BETA_VERSION_NAME_E ) );
- outRevision := BETA_VERSION;
-
-end;
-
-// *************************************************************************
-// \8ew\92è\82µ\82½ URL \82ð\83_\83E\83\93\83\8d\81[\83h\82µ\82Ä\95Ô\82·
-// *************************************************************************
-function InternalDownload(
- inURL : PChar; // \83_\83E\83\93\83\8d\81[\83h\82·\82é URL
- var ioModified : Double; // \8dÅ\8cã\82É\8eæ\93¾\82µ\82½\93ú\8e\9e
- var outResultData : PChar; // \83_\83E\83\93\83\8d\81[\83h\82³\82ê\82½\95¶\8e\9a\97ñ
- inRangeStart : DWORD; // \8aJ\8en\88Ê\92u
- inRangeEnd : DWORD // \8fI\97¹\88Ê\92u
-) : Longint; stdcall; // \83\8c\83X\83|\83\93\83X\83R\81[\83h
-var
- httpSocket : TIdHTTP;
- resStream : TMemoryStream;
- content : string;
-begin
-
- Result := -1;
-
- httpSocket := TIdHTTP.Create( nil );
- try
- // \83C\83x\83\93\83g\82Ì\90Ý\92è
- if Assigned( OnWork ) then
- httpSocket.OnWork := OnWork;
- if Assigned( OnWorkBegin ) then
- httpSocket.OnWorkBegin := OnWorkBegin;
- if Assigned( OnWorkEnd ) then
- httpSocket.OnWorkEnd := OnWorkEnd;
-
- // \92Ê\90M\82É\8aÖ\82·\82é\90Ý\92è
- httpSocket.Request.CustomHeaders.Clear;
- httpSocket.Response.Clear;
- httpSocket.Request.Clear;
-
- httpSocket.Request.UserAgent := GikoSys.GetUserAgent;
- httpSocket.RecvBufferSize := Gikosys.Setting.RecvBufferSize;
- httpSocket.ProxyParams.BasicAuthentication := False;
- {$IFDEF DEBUG}
- Writeln('------------------------------------------------------------');
- {$ENDIF}
- //httpSocket.AllowCookies := False;
- if GikoSys.Setting.ReadProxy then begin
- if GikoSys.Setting.ProxyProtocol then
- httpSocket.ProtocolVersion := pv1_1
- else
- httpSocket.ProtocolVersion := pv1_0;
- httpSocket.ProxyParams.ProxyServer := GikoSys.Setting.ReadProxyAddress;
- httpSocket.ProxyParams.ProxyPort := GikoSys.Setting.ReadProxyPort;
- httpSocket.ProxyParams.ProxyUsername := GikoSys.Setting.ReadProxyUserID;
- httpSocket.ProxyParams.ProxyPassword := GikoSys.Setting.ReadProxyPassword;
- if GikoSys.Setting.ReadProxyUserID <> '' then
- httpSocket.ProxyParams.BasicAuthentication := True;
- {$IFDEF DEBUG}
- Writeln('\83v\83\8d\83L\83V\90Ý\92è\82 \82è');
- Writeln('\83z\83X\83g: ' + GikoSys.Setting.ReadProxyAddress);
- Writeln('\83|\81[\83g: ' + IntToStr( GikoSys.Setting.ReadProxyPort ));
- {$ENDIF}
- end else begin
- if GikoSys.Setting.Protocol then
- httpSocket.ProtocolVersion := pv1_1
- else
- httpSocket.ProtocolVersion := pv1_0;
- httpSocket.ProxyParams.ProxyServer := '';
- httpSocket.ProxyParams.ProxyPort := 80;
- httpSocket.ProxyParams.ProxyUsername := '';
- httpSocket.ProxyParams.ProxyPassword := '';
- {$IFDEF DEBUG}
- Writeln('\83v\83\8d\83L\83V\90Ý\92è\82È\82µ');
- {$ENDIF}
- end;
-
- httpSocket.Request.ContentRangeStart := inRangeStart;
- httpSocket.Request.ContentRangeEnd := inRangeEnd;
- if (ioModified <> 0) and (ioModified <> ZERO_DATE) then
- httpSocket.Request.LastModified := ioModified - OffsetFromUTC;
- if inRangeStart = 0 then
- httpSocket.Request.AcceptEncoding := 'gzip'
- else
- httpSocket.Request.AcceptEncoding := '';
- httpSocket.Request.Accept := 'text/html';
-
- resStream := TMemoryStream.Create;
- try
- try
- resStream.Clear;
-
- {$IFDEF DEBUG}
- Writeln('URL: ' + inURL);
- {$ENDIF}
- httpSocket.Get( inURL, resStream );
- {$IFDEF DEBUG}
- Writeln('\8eæ\93¾\82Å\97á\8aO\82È\82µ');
- {$ENDIF}
-
- content := GikoSys.GzipDecompress( resStream, httpSocket.Response.ContentEncoding );
- ioModified := httpSocket.Response.LastModified;
-
- Result := httpSocket.ResponseCode;
- if (Length( content ) = 0) and (Result = 206) then
- Result := 304;
-
- outResultData := CreateResultString( content );
- except
- on E: EIdSocketError do begin
- ioModified := ZERO_DATE;
- outResultData := nil;
- end;
- on E: EIdConnectException do begin
- ioModified := ZERO_DATE;
- outResultData := nil;
- //Item.ErrText := E.Message;
- end;
- on E: Exception do begin
- {$IFDEF DEBUG}
- Writeln('\8eæ\93¾\82Å\97á\8aO\82 \82è');
- Writeln('E.Message: ' + E.Message);
- {$ENDIF}
- ioModified := ZERO_DATE;
- outResultData := nil;
- Result := httpSocket.ResponseCode;
- //Item.ErrText := E.Message;
- end;
- end;
- finally
- resStream.Free;
- end;
-
- finally
- httpSocket.Free;
- end;
-
-end;
-
-// *************************************************************************
-// \82Q\82¿\82á\82ñ\82Ë\82é\82Ì dat \8c`\8e®\82ð\83\8d\81[\83J\83\8b\82 \82Ú\81`\82ñ\82É\92Ê\82·
-// *************************************************************************
-function InternalAbon(
- inDatText : PChar // \96¼\91O<>\83\81\81[\83\8b<>\93ú\95tID<>\96{\95¶<>[\89ü\8ds] \82Å\8d\\90¬\82³\82ê\82½\83e\83L\83X\83g
-) : PChar; stdcall; // \82 \82Ú\81`\82ñ\8dÏ\82Ý\82Ì dat \8c`\8e®\83e\83L\83X\83g
-var
- datList : TStringList;
-begin
-
- datList := TStringList.Create;
- datList.Text := string( inDatText );
- //GikoSys.FAbon.IndividualAbon( datList, ChangeFileExt(FileName,'.NG'));
- GikoSys.FAbon.Execute( datList );
- GikoSys.FSelectResFilter.Execute( datList );
-
- Result := CreateResultString( datList.Text );
-
-end;
-
-// *************************************************************************
-// \82Q\82¿\82á\82ñ\82Ë\82é\82Ì dat \8c`\8e® 1 \8ds\82ð HTML \82É\95Ï\8a·\82·\82é
-// *************************************************************************
-function InternalDat2HTML(
- inDatRes : PChar; // \96¼\91O<>\83\81\81[\83\8b<>\93ú\95tID<>\96{\95¶<> \82Å\8d\\90¬\82³\82ê\82½\83e\83L\83X\83g
- inResNo : DWORD; // \83\8c\83X\94Ô\8d\86
- inIsNew : Boolean // \90V\92\85\83\8c\83X\82È\82ç True
-) : PChar; stdcall; // \90®\8c`\82³\82ê\82½ HTML
-var
- board : TBoard;
- threadItem : TThreadItem;
-begin
-
- // \83_\83~\81[\82Ì\83N\83\89\83X
- board := TBoard.Create;
- threadItem := TThreadItem.Create;
-
- try
- threadItem.ParentBoard := Board;
-
- Result := ThreadItemDat2HTML( DWORD( threadItem ), inDatRes, inResNo, inIsNew );
- except
- Result := nil;
- end;
-
-end;
-
-
-
-// =========================================================================
-// FilePath
-// =========================================================================
-
-// *************************************************************************
-// \83u\83\89\83E\83U\96{\91Ì\82ª\92u\82¢\82Ä\82 \82é\83t\83H\83\8b\83_
-// *************************************************************************
-function ApplicationFolder : PChar; stdcall;
-begin
-
- Result := CreateResultString( GikoSys.GetAppDir );
-
-end;
-
-// *************************************************************************
-// \8f\89\8aú\90Ý\92è\83t\83H\83\8b\83_
-// *************************************************************************
-function PreferencesFolder : PChar; stdcall;
-begin
-
- Result := CreateResultString( GikoSys.GetConfigDir );
-
-end;
-
-// *************************************************************************
-// \8f\89\8aú\90Ý\92è\83t\83@\83C\83\8b
-// *************************************************************************
-function PreferencesFile : PChar; stdcall;
-begin
-
- Result := CreateResultString( GikoSys.GetAppDir + 'gikoNavi.ini' );
-
-end;
-
-// *************************************************************************
-// \83\8d\83O\83t\83H\83\8b\83_
-// *************************************************************************
-function LogFolder : PChar; stdcall;
-begin
-
- Result := CreateResultString( GikoSys.GetAppDir + 'Log\' );
-
-end;
-
-// *************************************************************************
-// CSS \83t\83H\83\8b\83_
-// *************************************************************************
-function CSSFolder : PChar; stdcall;
-begin
-
- Result := CreateResultString( GikoSys.GetStyleSheetDir );
-
-end;
-
-// *************************************************************************
-// \83X\83L\83\93\82ð\93ü\82ê\82Ä\82¨\82\83t\83H\83\8b\83_
-// *************************************************************************
-function SkinFolder : PChar; stdcall;
-begin
-
- Result := CreateResultString( GikoSys.GetSkinDir );
-
-end;
-
-// *************************************************************************
-// \8eg\97p\82µ\82Ä\82¢\82é CSS / \83X\83L\83\93
-// *************************************************************************
-function SkinFile : PChar; stdcall;
-begin
-
- Result := CreateResultString( GikoSys.Setting.CSSFileName );
-
-end;
-
-// *************************************************************************
-// \82 \82Ú\81[\82ñ\8bK\91¥\82ª\92u\82¢\82Ä\82 \82é\83f\83B\83\8c\83N\83g\83\8a
-// *************************************************************************
-function AbonFolder : PChar; stdcall;
-begin
-
- Result := CreateResultString( GikoSys.Setting.GetNGWordsDir );
-
-end;
-
-// *************************************************************************
-// \8eg\97p\82µ\82Ä\82¢\82é\82 \82Ú\81[\82ñ\8bK\91¥
-// *************************************************************************
-function AbonFile : PChar; stdcall;
-begin
-
- Result := CreateResultString( GikoSys.FAbon.GetNGwordpath );
-
-end;
-
-
-
-// =========================================================================
-// ThreadItem
-// =========================================================================
-
-// *************************************************************************
-// TThreadItem \83N\83\89\83X\82Ì\83v\83\8d\83p\83e\83B\82ð\8eæ\93¾\82·\82é
-// *************************************************************************
-function ThreadItemGetLong(
- instance : DWORD;
- propertyID : TThreadItemProperty
-) : DWORD; stdcall;
-var
- threadItem : TThreadItem;
-begin
-
- threadItem := TThreadItem( instance );
- case propertyID of
- tipContext: // : DWORD // \8e©\97R\82É\90Ý\92è\82µ\82Ä\82¢\82¢\92l
- Result := threadItem.Context;
- tipNo: // : Integer // \94Ô\8d\86
- Result := threadItem.No;
- tipFileName: // : string // \83X\83\8c\83b\83h\83t\83@\83C\83\8b\96¼
- Result := DWORD( CreateResultString( threadItem.FileName ) );
- tipTitle: // : string // \83X\83\8c\83b\83h\83^\83C\83g\83\8b
- Result := DWORD( CreateResultString( threadItem.Title ) );
- tipCount: // : Integer // \83X\83\8c\83b\83h\83J\83E\83\93\83g\81i\83\8d\81[\83J\83\8b\81j
- Result := threadItem.Count;
- tipAllResCount: // : Integer // \83X\83\8c\83b\83h\83J\83E\83\93\83g\81i\83T\81[\83o\81j
- Result := threadItem.AllResCount;
- tipNewResCount: // : Integer // \83X\83\8c\83b\83h\90V\92\85\90\94
- Result := threadItem.NewResCount;
- tipSize: // : Integer // \83X\83\8c\83b\83h\83T\83C\83Y
- Result := threadItem.Size;
- tipRound: // : Boolean // \8f\84\89ñ\83t\83\89\83O
- Result := DWORD( threadItem.Round );
- tipRoundName: // : string // \8f\84\89ñ\96¼
- Result := DWORD( CreateResultString( threadItem.RoundName ) );
- tipIsLogFile: // : Boolean // \83\8d\83O\91¶\8dÝ\83t\83\89\83O
- Result := DWORD( threadItem.IsLogFile );
- tipKokomade: // : Integer // \83R\83R\82Ü\82Å\93Ç\82ñ\82¾\94Ô\8d\86
- Result := threadItem.Kokomade;
- tipNewReceive: // : Integer // \83R\83R\82©\82ç\90V\8bK\8eó\90M
- Result := threadItem.NewReceive;
- tipNewArrival: // : Boolean // \90V\92\85
- Result := DWORD( threadItem.NewArrival );
- tipUnRead: // : Boolean // \96¢\93Ç\83t\83\89\83O
- Result := DWORD( threadItem.UnRead );
- tipScrollTop: // : Integer // \83X\83N\83\8d\81[\83\8b\88Ê\92u
- Result := threadItem.ScrollTop;
- tipDownloadHost: // : string // \8d¡\82Ì\83z\83X\83g\82Æ\88á\82¤\8fê\8d\87\82Ì\83z\83X\83g
- Result := DWORD( CreateResultString( threadItem.DownloadHost ) );
- tipAgeSage: // : TThreadAgeSage // \83A\83C\83e\83\80\82Ì\8fã\82°\89º\82°
- Result := DWORD( threadItem.AgeSage );
- tipURL: // : string // \83X\83\8c\83b\83h\82ð\83u\83\89\83E\83U\82Å\95\\8e¦\82·\82é\8dÛ\82Ì URL
- Result := DWORD( CreateResultString( threadItem.URL ) );
- tipFilePath: // \82±\82Ì\83X\83\8c\82ª\95Û\91¶\82³\82ê\82Ä\82¢\82é\83p\83X
- Result := DWORD( CreateResultString( threadItem.FilePath ) );
- else
- Result := 0;
- end;
-end;
-
-// *************************************************************************
-// TThreadItem \83N\83\89\83X\82Ì\83v\83\8d\83p\83e\83B\82ð\90Ý\92è\82·\82é
-// *************************************************************************
-procedure ThreadItemSetLong(
- instance : DWORD;
- propertyID : TThreadItemProperty;
- param : DWORD
-); stdcall;
-var
- threadItem : TThreadItem;
-begin
-
- threadItem := TThreadItem( instance );
- case propertyID of
- tipContext: // : DWORD // \8e©\97R\82É\90Ý\92è\82µ\82Ä\82¢\82¢\92l
- threadItem.Context := param;
- tipNo: // : Integer // \94Ô\8d\86
- threadItem.No := param;
- tipFileName: // : string // \83X\83\8c\83b\83h\83t\83@\83C\83\8b\96¼
- threadItem.FileName := string( PChar( param ) );
- tipTitle: // : string // \83X\83\8c\83b\83h\83^\83C\83g\83\8b
- threadItem.Title := string( PChar( param ) );
- tipCount: // : Integer // \83X\83\8c\83b\83h\83J\83E\83\93\83g\81i\83\8d\81[\83J\83\8b\81j
- threadItem.Count := param;
- tipAllResCount: // : Integer // \83X\83\8c\83b\83h\83J\83E\83\93\83g\81i\83T\81[\83o\81j
- threadItem.AllResCount := param;
- tipNewResCount: // : Integer // \83X\83\8c\83b\83h\90V\92\85\90\94
- threadItem.NewResCount := param;
- tipSize: // : Integer // \83X\83\8c\83b\83h\83T\83C\83Y
- threadItem.Size := param;
- tipRound: // : Boolean // \8f\84\89ñ\83t\83\89\83O
- threadItem.Round := Boolean( param );
- tipRoundName: // : string // \8f\84\89ñ\96¼
- threadItem.RoundName := string( PChar( param ) );
- tipIsLogFile: // : Boolean // \83\8d\83O\91¶\8dÝ\83t\83\89\83O
- threadItem.IsLogFile := Boolean( param );
- tipKokomade: // : Integer // \83R\83R\82Ü\82Å\93Ç\82ñ\82¾\94Ô\8d\86
- threadItem.Kokomade := param;
- tipNewReceive: // : Integer // \83R\83R\82©\82ç\90V\8bK\8eó\90M
- threadItem.NewReceive := param;
- tipNewArrival: // : Boolean // \90V\92\85
- threadItem.NewArrival := Boolean( param );
- tipUnRead: // : Boolean // \96¢\93Ç\83t\83\89\83O
- threadItem.UnRead := Boolean( param );
- tipScrollTop: // : Integer // \83X\83N\83\8d\81[\83\8b\88Ê\92u
- threadItem.ScrollTop := param;
- tipDownloadHost: // : string // \8d¡\82Ì\83z\83X\83g\82Æ\88á\82¤\8fê\8d\87\82Ì\83z\83X\83g
- threadItem.DownloadHost := string( PChar( param ) );
- tipAgeSage: // : TThreadAgeSage // \83A\83C\83e\83\80\82Ì\8fã\82°\89º\82°
- threadItem.AgeSage := TGikoAgeSage( param );
- tipURL: // : string // \83X\83\8c\83b\83h\82ð\83u\83\89\83E\83U\82Å\95\\8e¦\82·\82é\8dÛ\82Ì URL
- threadItem.URL := string( PChar( param ) );
- tipFilePath: // : string // \82±\82Ì\83X\83\8c\82ª\95Û\91¶\82³\82ê\82Ä\82¢\82é\83p\83X
- threadItem.FilePath := string( PChar( param ) );
- end;
-
-end;
-
-// *************************************************************************
-// TThreadItem \83N\83\89\83X\82Ì\83v\83\8d\83p\83e\83B\82ð\8eæ\93¾\82·\82é
-// *************************************************************************
-function ThreadItemGetDouble(
- instance : DWORD;
- propertyID : TThreadItemProperty
-) : Double; stdcall;
-var
- threadItem : TThreadItem;
-begin
-
- threadItem := TThreadItem( instance );
- case propertyID of
- tipRoundDate: // : TDateTime // \83X\83\8c\83b\83h\82ð\8eæ\93¾\82µ\82½\93ú\8e\9e\81i\8f\84\89ñ\93ú\8e\9e\81j
- Result := threadItem.RoundDate;
- tipLastModified: // : TDateTime // \83X\83\8c\83b\83h\82ª\8dX\90V\82³\82ê\82Ä\82¢\82é\93ú\8e\9e\81i\83T\81[\83o\91¤\93ú\8e\9e\81j
- Result := threadItem.LastModified;
- else
- Result := 0;
- end;
-
-end;
-
-// *************************************************************************
-// TThreadItem \83N\83\89\83X\82Ì\83v\83\8d\83p\83e\83B\82ð\90Ý\92è\82·\82é
-// *************************************************************************
-procedure ThreadItemSetDouble(
- instance : DWORD;
- propertyID : TThreadItemProperty;
- param : Double
-); stdcall;
-var
- threadItem : TThreadItem;
-begin
-
- threadItem := TThreadItem( instance );
- case propertyID of
- tipRoundDate: // : TDateTime // \83X\83\8c\83b\83h\82ð\8eæ\93¾\82µ\82½\93ú\8e\9e\81i\8f\84\89ñ\93ú\8e\9e\81j
- threadItem.RoundDate := param;
- tipLastModified: // : TDateTime // \83X\83\8c\83b\83h\82ª\8dX\90V\82³\82ê\82Ä\82¢\82é\93ú\8e\9e\81i\83T\81[\83o\91¤\93ú\8e\9e\81j
- threadItem.LastModified := param;
- end;
-
-end;
-
-// *************************************************************************
-// TThreadItem \83N\83\89\83X\82ð\8c³\82É\82Q\82¿\82á\82ñ\82Ë\82é\82Ì dat \8c`\8e® 1 \8ds\82ð HTML \82É\95Ï\8a·\82·\82é
-// *************************************************************************
-function ThreadItemDat2HTML(
- inInstance : DWORD; // \83N\83\89\83X\82Ì\83C\83\93\83X\83^\83\93\83X
- inDatRes : PChar; // \96¼\91O<>\83\81\81[\83\8b<>\93ú\95tID<>\96{\95¶<> \82Å\8d\\90¬\82³\82ê\82½\83e\83L\83X\83g
- inResNo : DWORD; // \83\8c\83X\94Ô\8d\86
- inIsNew : Boolean // \90V\92\85\83\8c\83X\82È\82ç True
-) : PChar; stdcall; // \90®\8c`\82³\82ê\82½ HTML
-var
- threadItem : TThreadItem;
- res : TResRec;
- no : string;
-begin
-
- threadItem := TThreadItem( inInstance );
- // \88ø\90\94\82ð\95ª\89ð
- res := GikoSys.DivideStrLine( string( inDatRes ) );
- no := IntToStr( inResNo );
-
- try
- if GikoSys.Setting.UseSkin then begin
- // \83X\83L\83\93
- if inIsNew then
- Result := CreateResultString( GikoSys.SkinedRes(
- GikoSys.LoadFromSkin(
- GikoSys.Setting.GetSkinNewResFileName, threadItem, threadItem.SizeByte
- ), res, no
- ) )
- else
- Result := CreateResultString( GikoSys.SkinedRes(
- GikoSys.LoadFromSkin(
- GikoSys.Setting.GetSkinResFileName, threadItem, threadItem.SizeByte
- ), res, no
- ) );
- end else begin
- // CSS or \83f\83t\83H\83\8b\83g
- if res.FName = '' then
- res.FName := ' ';
- if res.FMailTo = '' then
- Result := CreateResultString( '<a name="' + no + '"></a>'
- + '<div class="header"><span class="no"><a href="menu:' + No + '">' + no + '</a></span> '
- + '<span class="name_label">\96¼\91O\81F</span> '
- + '<span class="name"><b>' + res.FName + '</b></span> '
- + '<span class="date_label">\93\8a\8de\93ú\81F</span> '
- + '<span class="date">' + res.FDateTime+ '</span></div>'
- + '<div class="mes">' + res.FBody + ' </div>' )
- else if GikoSys.Setting.ShowMail then
- Result := CreateResultString( '<a name="' + no + '"></a>'
- + '<div class="header"><span class="no"><a href="menu:' + no + '">' + no + '</a></span>'
- + '<span class="name_label"> \96¼\91O\81F </span>'
- + '<a class="name_mail" href="mailto:' + res.FMailTo + '">'
- + '<b>' + res.FName + '</b></a><span class="mail"> [' + res.FMailTo + ']</span>'
- + '<span class="date_label"> \93\8a\8de\93ú\81F</span>'
- + '<span class="date"> ' + res.FDateTime+ '</span></div>'
- + '<div class="mes">' + res.FBody + ' </div>' )
- else
- Result := CreateResultString( '<a name="' + no + '"></a>'
- + '<div class="header"><span class="no"><a href="menu:' + no + '">' + no + '</a></span>'
- + '<span class="name_label"> \96¼\91O\81F </span>'
- + '<a class="name_mail" href="mailto:' + res.FMailTo + '">'
- + '<b>' + res.FName + '</b></a>'
- + '<span class="date_label"> \93\8a\8de\93ú\81F</span>'
- + '<span class="date"> ' + res.FDateTime+ '</span></div>'
- + '<div class="mes">' + res.FBody + ' </div>' );
- end;
- except
- Result := nil;
- end;
-
-end;
-
-// *************************************************************************
-// TThreadItem \83N\83\89\83X\82ð\8c³\82É\83X\83\8c\83b\83h\82Ì\83w\83b\83_\82ð\8eæ\93¾\82·\82é
-// *************************************************************************
-function ThreadItemGetHeader(
- inInstance : DWORD; // \83N\83\89\83X\82Ì\83C\83\93\83X\83^\83\93\83X
- inOptionalHeader : PChar // \92Ç\89Á\82Ì\83w\83b\83_
-) : PChar; stdcall; // \90®\8c`\82³\82ê\82½ HTML
-var
- threadItem : TThreadItem;
- skinHeader : string;
- optionalHeader : string;
-begin
-
- threadItem := TThreadItem( inInstance );
- optionalHeader := string( inOptionalHeader );
-
- try
- if GikoSys.Setting.UseSkin then begin
- // \83X\83L\83\93
- skinHeader := GikoSys.LoadFromSkin( GikoSys.Setting.GetSkinHeaderFileName, threadItem, threadItem.SizeByte );
- if Length( optionalHeader ) > 0 then
- skinHeader :=
- StringReplace( skinHeader, '</head>', optionalHeader + '</head>', [] );
- end else if GikoSys.Setting.UseCSS then begin
- // CSS
- skinHeader :=
- '<html><head>' +
- '<title>' + threadItem.Title + '</title>' +
- '<link rel="stylesheet" href="'+ GikoSys.Setting.GetStyleSheetDir + GikoSys.Setting.CSSFileName +'" type="text/css">' +
- optionalHeader +
- '</head>' +
- '<body>' +
- '<div class="title">' + threadItem.Title + '</div>';
- end else begin
- // \83f\83t\83H\83\8b\83g
- skinHeader :=
- '<html><head>' +
- '<title>' + threadItem.Title + '</title>' +
- optionalHeader +
- '</head>' +
- '<body>' +
- '<div class="title">' + threadItem.Title + '</div>';
- end;
- except
- end;
-
- Result := CreateResultString( skinHeader );
-
-end;
-
-// *************************************************************************
-// TThreadItem \83N\83\89\83X\82ð\8c³\82É\83X\83\8c\83b\83h\82Ì\83t\83b\83^\82ð\8eæ\93¾\82·\82é
-// *************************************************************************
-function ThreadItemGetFooter(
- inInstance : DWORD; // \83N\83\89\83X\82Ì\83C\83\93\83X\83^\83\93\83X
- inOptionalFooter : PChar // \92Ç\89Á\82Ì\83t\83b\83^
-) : PChar; stdcall; // \90®\8c`\82³\82ê\82½ HTML
-var
- threadItem : TThreadItem;
- skinFooter : string;
- optionalFooter : string;
-begin
-
- threadItem := TThreadItem( inInstance );
- optionalFooter := string( inOptionalFooter );
-
- try
- if GikoSys.Setting.UseSkin then begin
- skinFooter := GikoSys.LoadFromSkin( GikoSys.Setting.GetSkinFooterFileName, threadItem, threadItem.SizeByte );
- if Length( optionalFooter ) > 0 then
- skinFooter :=
- StringReplace( skinFooter, '</body>', optionalFooter + '</body>', [] );
- end else begin
- skinFooter :=
- '<a name="bottom"></a>' +
- optionalFooter +
- '</body></html>' +
- '<a name="last"></a>' +
- '</body></html>';
- end;
- except
- end;
-
- Result := CreateResultString( skinFooter );
-
-end;
-
-// *************************************************************************
-// \83X\83\8c\83b\83h\82Ì\83_\83E\83\93\83\8d\81[\83h\82ª\90i\8ds\82µ\82½
-// *************************************************************************
-procedure ThreadItemWork(
- inInstance : DWORD; // \83N\83\89\83X\82Ì\83C\83\93\83X\83^\83\93\83X
- inWorkCount : Integer // \8c»\8dÝ\82Ì\90i\95à\8fó\8bµ(\83J\83E\83\93\83g)
-); stdcall;
-begin
-
- if Assigned( OnWork ) then
- OnWork( TObject( inInstance ), wmRead, inWorkCount );
-
-end;
-
-// *************************************************************************
-// \83X\83\8c\83b\83h\82Ì\83_\83E\83\93\83\8d\81[\83h\82ª\8en\82Ü\82Á\82½
-// *************************************************************************
-procedure ThreadItemWorkBegin(
- inInstance : DWORD; // \83N\83\89\83X\82Ì\83C\83\93\83X\83^\83\93\83X
- inWorkCountMax : Integer // \92Ê\90M\82Ì\8fI\82í\82è\82ð\8e¦\82·\83J\83E\83\93\83g
-); stdcall;
-begin
-
- if Assigned( OnWorkBegin ) then
- OnWorkBegin( TObject( inInstance ), wmRead, inWorkCountMax );
-
-end;
-
-// *************************************************************************
-// \83X\83\8c\83b\83h\82Ì\83_\83E\83\93\83\8d\81[\83h\82ª\8fI\82í\82Á\82½
-// *************************************************************************
-procedure ThreadItemWorkEnd(
- inInstance : DWORD // \83N\83\89\83X\82Ì\83C\83\93\83X\83^\83\93\83X
-); stdcall;
-begin
-
- if Assigned( OnWorkEnd ) then
- OnWorkEnd( TObject( inInstance ), wmRead );
-
-end;
-
-
-
-// =========================================================================
-// BoardItem
-// =========================================================================
-
-// *************************************************************************
-// TBoardItem \83N\83\89\83X\82Ì\83v\83\8d\83p\83e\83B\82ð\8eæ\93¾\82·\82é
-// *************************************************************************
-function BoardItemGetLong(
- instance : DWORD;
- propertyID : TBoardItemProperty
-) : DWORD; stdcall;
-var
- boardItem : TBoard;
-begin
-
- boardItem := TBoard( instance );
- case propertyID of
- bipContext: // : DWORD // \8e©\97R\82É\90Ý\92è\82µ\82Ä\82¢\82¢\92l
- Result := boardItem.Context;
- bipNo: // : Integer // \94Ô\8d\86
- Result := boardItem.No;
- bipTitle: // : string // \83X\83\8c\83b\83h\83^\83C\83g\83\8b
- Result := DWORD( CreateResultString( boardItem.Title ) );
- bipRound: // : Boolean // \8f\84\89ñ\83t\83\89\83O
- Result := DWORD( boardItem.Round );
- bipRoundName: // : string // \8f\84\89ñ\96¼
- Result := DWORD( CreateResultString( boardItem.RoundName ) );
- bipIsLogFile: // : Boolean // \83\8d\83O\91¶\8dÝ\83t\83\89\83O
- Result := DWORD( boardItem.IsLogFile );
- bipUnRead: // : Integer // \83X\83\8c\83b\83h\96¢\93Ç\90\94
- Result := DWORD( boardItem.UnRead );
- bipURL: // : string // \83X\83\8c\83b\83h\82ð\83u\83\89\83E\83U\82Å\95\\8e¦\82·\82é\8dÛ\82Ì URL
- Result := DWORD( CreateResultString( boardItem.URL ) );
- bipFilePath: // \82±\82Ì\83X\83\8c\82ª\95Û\91¶\82³\82ê\82Ä\82¢\82é\83p\83X
- Result := DWORD( CreateResultString( boardItem.FilePath ) );
- else
- Result := 0;
- end;
-end;
-
-// *************************************************************************
-// TBoardItem \83N\83\89\83X\82Ì\83v\83\8d\83p\83e\83B\82ð\90Ý\92è\82·\82é
-// *************************************************************************
-procedure BoardItemSetLong(
- instance : DWORD;
- propertyID : TBoardItemProperty;
- param : DWORD
-); stdcall;
-var
- boardItem : TBoard;
-begin
-
- boardItem := TBoard( instance );
- case propertyID of
- bipContext: // : DWORD // \8e©\97R\82É\90Ý\92è\82µ\82Ä\82¢\82¢\92l
- boardItem.Context := param;
- bipNo: // : Integer // \94Ô\8d\86
- boardItem.No := param;
- bipTitle: // : string // \83X\83\8c\83b\83h\83^\83C\83g\83\8b
- boardItem.Title := string( PChar( param ) );
- bipRound: // : Boolean // \8f\84\89ñ\83t\83\89\83O
- boardItem.Round := Boolean( param );
- bipRoundName: // : string // \8f\84\89ñ\96¼
- boardItem.RoundName := string( PChar( param ) );
- bipIsLogFile: // : Boolean // \83\8d\83O\91¶\8dÝ\83t\83\89\83O
- boardItem.IsLogFile := Boolean( param );
- bipUnRead: // : Integer // \83X\83\8c\83b\83h\96¢\93Ç\90\94
- boardItem.UnRead := Integer( param );
- bipURL: // : string // \83X\83\8c\83b\83h\82ð\83u\83\89\83E\83U\82Å\95\\8e¦\82·\82é\8dÛ\82Ì URL
- boardItem.URL := string( PChar( param ) );
- bipFilePath: // : string // \82±\82Ì\83X\83\8c\82ª\95Û\91¶\82³\82ê\82Ä\82¢\82é\83p\83X
- boardItem.FilePath := string( PChar( param ) );
- end;
-
-end;
-
-// *************************************************************************
-// TBoardItem \83N\83\89\83X\82Ì\83v\83\8d\83p\83e\83B\82ð\8eæ\93¾\82·\82é
-// *************************************************************************
-function BoardItemGetDouble(
- instance : DWORD;
- propertyID : TBoardItemProperty
-) : Double; stdcall;
-var
- boardItem : TBoard;
-begin
-
- boardItem := TBoard( instance );
- case propertyID of
- bipRoundDate: // : TDateTime // \83X\83\8c\83b\83h\82ð\8eæ\93¾\82µ\82½\93ú\8e\9e\81i\8f\84\89ñ\93ú\8e\9e\81j
- Result := boardItem.RoundDate;
- bipLastModified: // : TDateTime // \83X\83\8c\83b\83h\82ª\8dX\90V\82³\82ê\82Ä\82¢\82é\93ú\8e\9e\81i\83T\81[\83o\91¤\93ú\8e\9e\81j
- Result := boardItem.LastModified;
- bipLastGetTime: // : TDateTime // \83X\83\8c\83b\83h\82Ü\82½\82Í\83X\83\8c\83b\83h\88ê\97\97\82ð\8dÅ\8cã\82É\8dX\90V\82µ\82½\93ú\8e\9e\81i\83T\81[\83o\91¤\93ú\8e\9e\81E\8f\91\82«\8d\9e\82Ý\8e\9e\82É\8eg\97p\82·\82é\81j
- Result := boardItem.LastGetTime;
- else
- Result := 0;
- end;
-
-end;
-
-// *************************************************************************
-// TBoardItem \83N\83\89\83X\82Ì\83v\83\8d\83p\83e\83B\82ð\90Ý\92è\82·\82é
-// *************************************************************************
-procedure BoardItemSetDouble(
- instance : DWORD;
- propertyID : TBoardItemProperty;
- param : Double
-); stdcall;
-var
- boardItem : TBoard;
-begin
-
- boardItem := TBoard( instance );
- case propertyID of
- bipRoundDate: // : TDateTime // \83X\83\8c\83b\83h\82ð\8eæ\93¾\82µ\82½\93ú\8e\9e\81i\8f\84\89ñ\93ú\8e\9e\81j
- boardItem.RoundDate := param;
- bipLastModified: // : TDateTime // \83X\83\8c\83b\83h\82ª\8dX\90V\82³\82ê\82Ä\82¢\82é\93ú\8e\9e\81i\83T\81[\83o\91¤\93ú\8e\9e\81j
- boardItem.LastModified := param;
- bipLastGetTime: // : TDateTime // \83X\83\8c\83b\83h\82Ü\82½\82Í\83X\83\8c\83b\83h\88ê\97\97\82ð\8dÅ\8cã\82É\8dX\90V\82µ\82½\93ú\8e\9e\81i\83T\81[\83o\91¤\93ú\8e\9e\81E\8f\91\82«\8d\9e\82Ý\8e\9e\82É\8eg\97p\82·\82é\81j
- boardItem.LastGetTime := param;
- end;
-
-end;
-
-// *************************************************************************
-// TBoardItem \83N\83\89\83X\82É\8cq\82ª\82ê\82Ä\82¢\82é TThreadItem \83N\83\89\83X\82ð\8eæ\93¾\82·\82é
-// *************************************************************************
-function BoardItemGetItems(
- instance : DWORD;
- index : Integer
-) : DWORD; stdcall;
-var
- boardItem : TBoard;
-begin
-
- boardItem := TBoard( instance );
- Result := DWORD( boardItem.Items[ index ] );
-
-end;
-
-// *************************************************************************
-// \94Â\82Ì\83_\83E\83\93\83\8d\81[\83h\82ª\90i\8ds\82µ\82½
-// *************************************************************************
-procedure BoardItemWork(
- inInstance : DWORD; // \83N\83\89\83X\82Ì\83C\83\93\83X\83^\83\93\83X
- inWorkCount : Integer // \8c»\8dÝ\82Ì\90i\95à\8fó\8bµ(\83J\83E\83\93\83g)
-); stdcall;
-begin
-
- if Assigned( OnWork ) then
- OnWork( TObject( inInstance ), wmRead, inWorkCount );
-
-end;
-
-// *************************************************************************
-// \94Â\82Ì\83_\83E\83\93\83\8d\81[\83h\82ª\8en\82Ü\82Á\82½
-// *************************************************************************
-procedure BoardItemWorkBegin(
- inInstance : DWORD; // \83N\83\89\83X\82Ì\83C\83\93\83X\83^\83\93\83X
- inWorkCountMax : Integer // \92Ê\90M\82Ì\8fI\82í\82è\82ð\8e¦\82·\83J\83E\83\93\83g
-); stdcall;
-begin
-
- if Assigned( OnWorkBegin ) then
- OnWorkBegin( TObject( inInstance ), wmRead, inWorkCountMax );
-
-end;
-
-// *************************************************************************
-// \94Â\82Ì\83_\83E\83\93\83\8d\81[\83h\82ª\8fI\82í\82Á\82½
-// *************************************************************************
-procedure BoardItemWorkEnd(
- inInstance : DWORD // \83N\83\89\83X\82Ì\83C\83\93\83X\83^\83\93\83X
-); stdcall;
-begin
-
- if Assigned( OnWorkEnd ) then
- OnWorkEnd( TObject( inInstance ), wmRead );
-
-end;
-
-// *************************************************************************
-// \94Â\82ª\95Û\97L\82·\82é\83X\83\8c\88ê\97\97\82Ì\97ñ\8b\93\8f\88\97\9d\82ð\83v\83\8d\83O\83\89\83\80\96{\91Ì\82É\94C\82³\82ê\82½
-// *************************************************************************
-procedure BoardItemEnumThread(
- inInstance : DWORD;
- inCallBack : TBoardItemEnumThreadCallBack;
- inSubjectText : PChar
-); stdcall;
-var
- board : TBoard;
- subject : TStringList;
- i : Integer;
- rec : TSubjectRec;
- isContinue : Boolean;
-begin
-
- try
- board := TBoard( inInstance );
- subject := TStringList.Create;
- try
- subject.Text := inSubjectText;
-
- for i := 0 to subject.Count - 1 do begin
- rec := GikoSys.DivideSubject( subject[i] );
- rec.FFileName := Trim(rec.FFileName);
- if (rec.FTitle = '') and (rec.FCount = 0) then
- Continue;
-
- isContinue := inCallBack(
- PChar( GikoSys.GetURL( board.BBSID, rec.FFileName ) ),
- PChar( rec.FTitle ),
- DWORD( rec.FCount ) );
-
- if ( not isContinue ) then
- Break;
- end;
- finally
- subject.Free;
- end;
- except
- end;
-
-end;
-
-exports
- CreateResultString,
- DisposeResultString,
- VersionInfo,
- ApplicationFolder,
- PreferencesFolder,
- PreferencesFile,
- LogFolder,
- CSSFolder,
- SkinFolder,
- SkinFile,
- AbonFolder,
- AbonFile,
- InternalDownload,
- InternalAbon,
- InternalDat2HTML,
- ThreadItemGetLong,
- ThreadItemSetLong,
- ThreadItemGetDouble,
- ThreadItemSetDouble,
- ThreadItemDat2HTML,
- ThreadItemGetHeader,
- ThreadItemGetFooter,
- ThreadItemWork,
- ThreadItemWorkBegin,
- ThreadItemWorkEnd,
- BoardItemGetLong,
- BoardItemSetLong,
- BoardItemGetDouble,
- BoardItemSetDouble,
- BoardItemGetItems,
- BoardItemEnumThread,
- BoardItemWork,
- BoardItemWorkBegin,
- BoardItemWorkEnd;
-
end.