FLoopBrowserTabs : Boolean;
//! 100\83\8c\83X\95\\8e¦\82Ì\90æ\93ª\95\\8e¦\83\8c\83X\90\94
FHeadResCount : Integer;
+ //! 100\83\8c\83X\95\\8e¦\90\94\81i\8ag\92£\97p\81j
+ FResRangeExCount: Integer;
//! \8aÖ\98A\83L\81[\83\8f\81[\83h\92Ç\89Á\83t\83\89\83O
FAddKeywordLink: Boolean;
//! dat\92u\8a·\82ð\97L\8cø\82É\82·\82é
FRespopupWait: Integer;
//! \83\81\81[\83\8b\97\93\83\8c\83X\83|\83b\83v\83A\83b\83v
FRespopupMailTo: Boolean;
+ //! \8cë\94\9a\83`\83F\83b\83N
+ FUseGobakuCheck: Boolean;
+
+ //! \96`\8c¯\82Ì\8f\91\97pCookie
+ FBoukenCookieList: TStringList;
+
function GetMainCoolSet(Index: Integer): TCoolSet;
function GetBoardCoolSet(Index: Integer): TCoolSet;
function GetBrowserCoolSet(Index: Integer): TCoolSet;
procedure WriteNameMailSettingFile;
procedure WriteFolderSettingFile();
procedure WriteBoardURLSettingFile;
+ procedure WriteBoukenSettingFile;
function GetSoundCount: Integer;
function FindSoundFileName(Name: string): string;
procedure WriteLogFolder(AVal : String);
function GetInputAssistFileName : String;
function GetReplaceFileName: String;
+ function GetExtprevieFileName: String;
+ function GetBoukenCookie(AHostName: String): String;
+ procedure SetBoukenCookie(ACookieValue, AHostName: String);
{
\brief \83\8a\83\93\83N\97\9a\97ð\82Ì\95Û\8e\9d\83T\83C\83Y\82Ìsetter
- \param AVal \90Ý\92è\82·\82é\83T\83C\83Y( >0)
+ \param AVal \90Ý\92è\82·\82é\83T\83C\83Y( >0)
}
procedure SetMoveHistorySize(AVal : Integer);
//\8eó\90M\83o\83b\83t\83@\83T\83C\83Y
property LoopBrowserTabs : Boolean read FLoopBrowserTabs write FLoopBrowserTabs;
//! 100\83\8c\83X\95\\8e¦\82Ì\90æ\93ª\95\\8e¦\83\8c\83X\90\94
property HeadResCount : Integer read FHeadResCount write FHeadResCount;
+ //! 100\83\8c\83X\95\\8e¦\90\94\81i\8ag\92£\97p\81j
+ property ResRangeExCount: Integer read FResRangeExCount write FResRangeExCount;
//! \8aÖ\98A\83L\81[\83\8f\81[\83h\92Ç\89Á\83t\83\89\83O
property AddKeywordLink: Boolean read FAddKeywordLink write FAddKeywordLink;
//! dat\82Ì\92u\8a·\82ð\97L\8cø\82É\82·\82é\82©
//! \83\8c\83X\83|\83b\83v\83A\83b\83v\83^\83C\83}\81[
property RespopupWait: Integer read FRespopupWait write FRespopupWait;
property RespopupMailTo: Boolean read FRespopupMailTo write FRespopupMailTo;
+ //! \8cë\94\9a\83`\83F\83b\83N
+ property UseGobakuCheck: Boolean read FUseGobakuCheck write FUseGobakuCheck;
end;
SPAMFILTER_FILE_NAME = 'SpamFilter.ini';
LANGUAGE_FILE_NAME = 'language.ini';
INPUTASSIST_FILE_NAME = 'InputAssist.ini';
- FIXED_COOKIE = 'hana=mogera';
+ FIXED_COOKIE = '';
REPLACE_FILE_NAME = 'replace.ini';
+ EXT_PREVIEW_FILE_NAME = 'extpreview.ini';
implementation
FMailList.Duplicates := dupIgnore;
FBoardURLs.Duplicates := dupIgnore;
FSelectTextList.Duplicates := dupIgnore;
+ FBoukenCookieList := TStringList.Create;
ReadSettingFile();
ReadBoardURLsFile();
end;
//\83f\83X\83g\83\89\83N\83^
destructor TSetting.Destroy();
begin
- FreeAndNil(FSkinFiles);
- FreeAndNil(FGestures);
- FreeAndNil(FBoardColumnOrder);
- FreeAndNil(FCategoryColumnOrder);
- FreeAndNil(FBBSColumnOrder);
- FreeAndNil(FBoardURLs);
- FreeAndNil(FSelectTextList);
- FreeAndNil(FMailList);
- FreeAndNil(FNameList);
+ FBoukenCookieList.Free;
+ FBoardColumnOrder.Free;
+ FCategoryColumnOrder.Free;
+ FBBSColumnOrder.Free;
+ FSelectTextList.Free;
+ FBoardURLs.Free;
+ FMailList.Free;
+ FNameList.Free;
+ FGestures.Free;
+ FSkinFiles.Free;
inherited;
end;
s: string;
CoolSet: TCoolSet;
msg: String;
+ hostList: TStringList;
begin
Exists := FileExists(GetFileName);
ini := TMemIniFile.Create(GetFileName);
FResRange := ini.ReadInteger( 'Thread', 'ResRange', Ord( grrAll ) );
FResRangeHold := ini.ReadBool( 'Thread', 'ResRangeHold', False );
FHeadResCount := ini.ReadInteger('Thread', 'HeadResCount', 1);
+ FResRangeExCount:= ini.ReadInteger('Thread','ResRangeExCount', 100);
// \83X\83\8c\83b\83h\88ê\97\97\95\\8e¦\94Í\88Í
FThreadRange := TGikoThreadRange( ini.ReadInteger('ThreadList', 'ThreadRange', Ord( gtrAll )) );
//\94ñ\83A\83N\83e\83B\83u\8e\9e\83\8c\83X\83|\83b\83v\83A\83b\83v\95\\8e¦
//\83T\83E\83\93\83h
if Exists then begin
+ SetCurrentDir(ExtractFilePath(Application.ExeName));
for i := 0 to GetSoundCount - 1 do begin
SoundFileName[i] := ini.ReadString('Sound', SoundName[i], '');
- if not FileExists(SoundFileName[i]) then
- SoundFileName[i] := '';
+ // \91\8a\91Î\8eQ\8fÆ\91Î\8dô
+ // \83t\83@\83C\83\8b\82Ì\91¶\8dÝ\83`\83F\83b\83N
+ if not FileExists(ExpandFileName(SoundFileName[i])) then begin
+ SoundFileName[i] := '';
+ end;
end;
end else begin
- s := GetAppDir + '\sound\';
+ s := 'Sound\';
SoundFileName[0] := s + '\8eæ\93¾\90¬\8c÷.wav';
SoundFileName[1] := s + '\8eæ\93¾\90¬\8c÷(\8d·\95ª).wav';
SoundFileName[2] := s + '\96¢\8dX\90V.wav';
// \83G\83f\83B\83^
FSpaceToNBSP := ini.ReadBool( 'Editor', 'SpaceToNBSP', False );
FAmpToCharRef := ini.ReadBool( 'Editor', 'AmpToCharRef', False );
+ FUseGobakuCheck := ini.ReadBool( 'Editor', 'UseGobakuCheck', True );
//Tab\8e©\93®\95Û\91¶\81A\93Ç\82Ý\8d\9e\82Ý
FTabAutoLoadSave := ini.ReadBool('TabAuto', 'TabAutoLoadSave', False);
FCheckDatFile := ini.ReadBool('ThreadList', 'CheckDatFile', True);
FLimitResCountMessage := ini.ReadBool('Thread', 'LimitResCountMessage', True);
+
+ // \96`\8c¯\82Ì\8f\91Cookie\93Ç\82Ý\8d\9e\82Ý
+ hostList := TStringList.Create;
+ ini.ReadSection('Bouken', hostList);
+ for i := 0 to hostList.Count - 1 do begin
+ FBoukenCookieList.Add( hostList[i] + '=' +
+ ini.ReadString('Bouken', hostList[i], '') );
+ end;
+ hostList.Free;
+
+ // \83M\83R\83i\83r\8dX\90V\82Å\97\98\97p\82µ\82½\83C\83\93\83X\83g\81[\83\89\82Ì\8dí\8f\9c
+ s := ini.ReadString('Update', 'Remove0', '');
+ if (FileExists(s)) then begin
+ SysUtils.DeleteFile(s);
+ // \8dí\8f\9c\82É\8e¸\94s\82µ\82Ä\82à\96³\8e\8b\82·\82é
+ ini.DeleteKey('Update', 'Remove0');
+ end;
+
ini.UpdateFile;
finally
ini.Free;
ini.WriteInteger('Thread', 'ResRange', FResRange);
ini.WriteBool('Thread', 'ResRangeHold', FResRangeHold);
ini.WriteInteger('Thread', 'HeadResCount', FHeadResCount);
+ ini.WriteInteger('Thread','ResRangeExCount', FResRangeExCount);
// \83X\83\8c\83b\83h\88ê\97\97\95\\8e¦\94Í\88Í
ini.WriteInteger('ThreadList', 'ThreadRange', Ord( FThreadRange ));
//\83\8d\83O\8dí\8f\9c\8am\94F
// \83G\83f\83B\83^
ini.WriteBool( 'Editor', 'SpaceToNBSP', FSpaceToNBSP );
ini.WriteBool( 'Editor', 'AmpToCharRef', FAmpToCharRef );
+ ini.WriteBool( 'Editor', 'UseGobakuCheck', FUseGobakuCheck );
//\83^\83u\8e©\93®\95Û\91¶
ini.WriteBool('TabAuto', 'TabAutoLoadSave', FTabAutoLoadSave);
- ini.WriteString('Thread', 'LastCloseTabURL', FLastCloseTabURL);
+ ini.WriteString('Thread', 'LastCloseTabURL', FLastCloseTabURL);
//\8fÚ\8d×\90Ý\92è
ini.WriteInteger('OptionDialog', 'KuroutTabIndex', FKuroutSettingTabIndex);
ini.WriteString('Function', 'ExtList', FExtList);
ini.WriteBool('ThreadList', 'CheckDatFile', FCheckDatFile);
ini.WriteBool('Thread', 'LimitResCountMessage', FLimitResCountMessage);
+
+
+ ini.UpdateFile;
+ finally
+ ini.Free;
+ end;
+end;
+//\90Ý\92è\83t\83@\83C\83\8b\95Û\91¶(\96`\8c¯\82Ì\8f\91)
+procedure TSetting.WriteBoukenSettingFile;
+var
+ i: Integer;
+ ini: TMemIniFile;
+begin
+ ini := TMemIniFile.Create(GetFileName());
+ try
+ ini.EraseSection('Bouken');
+ // \96`\8c¯\82Ì\8f\91Cookie\8f\91\82«\8d\9e\82Ý
+ for i := 0 to FBoukenCookieList.Count - 1 do begin
+ ini.WriteString('Bouken', FBoukenCookieList.Names[i], FBoukenCookieList.Values[FBoukenCookieList.Names[i]]);
+ end;
ini.UpdateFile;
finally
ini.Free;
begin
for i := 0 to GetSoundCount - 1 do begin
if SoundName[i] = Name then begin
- Result := SoundFileName[i];
+ SysUtils.SetCurrentDir(GetAppDir);
+ Result := ExpandFileName(SoundFileName[i]);
Exit;
end;
end;
begin
Result := GetConfigDir + REPLACE_FILE_NAME;
end;
+function TSetting.GetExtprevieFileName: String;
+begin
+ Result := GetConfigDir + EXT_PREVIEW_FILE_NAME;
+end;
procedure TSetting.SetMoveHistorySize(AVal : Integer);
begin
if (AVal > 0) then begin
begin
Result := FSkinFiles.FileName;
end;
-
+function TSetting.GetBoukenCookie(AHostName: String): String;
+var
+ i : Integer;
+begin
+ for i := 0 to FBoukenCookieList.Count - 1 do begin
+ if ( AnsiPos(FBoukenCookieList.Names[i], AHostName) > 0 ) then begin
+ Result := FBoukenCookieList.Values[FBoukenCookieList.Names[i]];
+ Break;
+ end;
+ end;
+end;
+procedure TSetting.SetBoukenCookie(ACookieValue, AHostName: String);
+var
+ i : Integer;
+begin
+ for i := 0 to FBoukenCookieList.Count - 1 do begin
+ if ( FBoukenCookieList.Names[i] = AHostName ) then begin
+ FBoukenCookieList[i] := AHostName + '=' + ACookieValue;
+ Break;
+ end;
+ end;
+ if ( i = FBoukenCookieList.Count ) then begin
+ FBoukenCookieList.Add(AHostName + '=' + ACookieValue);
+ end;
+end;
end.