FWarnScopeChangeInSynchronize: boolean;
FNeedConfirmBeforeSend: boolean;
FShowRuler: boolean;
+ FHideGhosts: boolean;
+ FVisibleGhostsList: TStringList;
procedure SetDblClkInsert(const Value: boolean);
procedure SetDefaultScript(const Value: String);
procedure SetIgnoreTimeCritical(const Value: boolean);
procedure SetWarnYenTNotExist(const Value: boolean);
procedure SetNeedConfirmBeforeSend(const Value: boolean);
procedure SetShowRuler(const Value: boolean);
+ procedure SetHideGhosts(const Value: boolean);
+ procedure SetVisibleGhostsList(const Value: TStringList);
public
property NoSendGhostList: boolean read FNoSendGhostList write SetNoSendGhostList;
property ConfirmOnExit: boolean read FConfirmOnExit write SetConfirmOnExit;
property LogWindowPreviewStyle: TLogWindowPreviewStyle read FLogWindowPreviewStyle write SetLogWindowPreviewStyle;
//\8fÚ\8d×\90Ý\92è
property FMOName: TStrings read FFMOName write SetFMOName;
+ property HideGhosts: boolean read FHideGhosts write SetHideGhosts;
+ property VisibleGhostsList: TStringList read FVisibleGhostsList write SetVisibleGhostsList;
//\83R\83\93\83X\83g\83\89\83N\83^\81E\83f\83X\83g\83\89\83N\83^\81E\95Û\91¶
constructor Create;
destructor Destroy; override;
FAutoJoinChannels := TStringList.Create;
FDefaultScript := TStringList.Create;
FFMOName := TStringList.Create;
+ FVisibleGhostsList := TStringList.Create;
try
FIni := TIniFile.Create(ChangeFileExt(Application.ExeName, '.ini'));
//
LogWindowPreviewStyle := TLogWindowPreviewStyle(FIni.ReadInteger('System', 'LogWindowPreviewStyle', 0));
//\8fÚ\8d×
FMOName.CommaText := FIni.ReadString('System', 'FMOName', 'Sakura');
+ HideGhosts := FIni.ReadBool('System', 'HideGhosts', false);
+ VisibleGhostsList.CommaText := FIni.ReadString('System', 'VisibleGhostsList', '');
except
ShowMessage('INI\83t\83@\83C\83\8b\93Ç\82Ý\8d\9e\82Ý\83G\83\89\81[');
Application.Terminate;
begin
inherited;
SaveSettings;
- FIni.Free;
- FAutoJoinChannels.Free;
- FDefaultScript.Free;
- FFMOName.Free;
+ if FIni <> nil then
+ FIni.Free;
+ if FAutoJoinChannels <> nil then
+ FAutoJoinChannels.Free;
+ if FDefaultScript <> nil then
+ FDefaultScript.Free;
+ if FFMOName <> nil then
+ FFMOName.Free;
+ if FVisibleGhostsList <> nil then
+ FVisibleGhostsList.Free;
end;
procedure TBottlePrefs.SetAutoStart(const Value: boolean);
//
FIni.WriteInteger('System', 'LogWindowPreviewStyle', Ord(LogWindowPreviewStyle));
FIni.WriteString('System', 'FMOName', FFMOName.CommaText);
+ FIni.WriteBool('System', 'HideGhosts', HideGhosts);
+ FIni.WriteString('System', 'VisibleGhostsList', VisibleGhostsList.CommaText);
end;
function TBottlePrefs.GetDefaultScript: String;
FShowRuler := Value;
end;
+procedure TBottlePrefs.SetHideGhosts(const Value: boolean);
+begin
+ FHideGhosts := Value;
+end;
+
+procedure TBottlePrefs.SetVisibleGhostsList(const Value: TStringList);
+begin
+ FVisibleGhostsList.Assign(Value);
+end;
+
{ TChannelListItem }
procedure TChannelListItem.SetGhost(const Value: String);
procedure TfrmSender.UpdateIfGhostBox;
var
Selected: String;
- i: integer;
+ i, dum: integer;
begin
cbxTargetGhost.DropDownCount := Pref.GhostDropDownCount;
Selected := cbxTargetGhost.Text;
for i := 0 to SakuraSeeker.Count-1 do begin
// \94j\91¹FMO\91Î\8dô\81BHWND\82Ì\92f\95Ð\82ª\8ec\82Á\82Ä\82¢\82é\82ªName\82ª\8fÁ\82¦\82Ä\82¢\82é\8fê\8d\87\82ª\82 \82é
if Length(SakuraSeeker[i].Name) = 0 then Continue;
+ if Pref.HideGhosts then
+ if Pref.VisibleGhostsList.IndexOf(SakuraSeeker[i].Name) < 0 then
+ Continue;
if cbxTargetGhost.Items.IndexOf(SakuraSeeker[i].Name) < 0 then
cbxTargetGhost.Items.Add(SakuraSeeker[i].Name);
end;
Top = 8
Width = 379
Height = 306
- ActivePage = tstGeneral
+ ActivePage = tstDetailed
Anchors = [akLeft, akTop, akRight, akBottom]
TabOrder = 0
object tstGeneral: TTabSheet
end
object grpProxy: TGroupBox
Left = 8
- Top = 120
+ Top = 160
Width = 353
- Height = 137
+ Height = 113
Caption = 'HTTP Proxy'#35373#23450
TabOrder = 1
object lblProxyAddress: TLabel
Left = 16
- Top = 84
+ Top = 68
Width = 56
Height = 12
Caption = #12450#12489#12524#12473'(&D)'
end
object lblProxyPort: TLabel
Left = 16
- Top = 108
+ Top = 92
Width = 47
Height = 12
Caption = #12509#12540#12488'(&O)'
end
object edtProxyAddress: TEdit
Left = 80
- Top = 80
+ Top = 64
Width = 257
Height = 20
Hint = 'Proxy'#12469#12540#12496#12398#12450#12489#12524#12473
end
object edtProxyPort: TEdit
Left = 80
- Top = 104
+ Top = 88
Width = 81
Height = 20
Hint = 'Proxy'#12469#12540#12496#12398#12509#12540#12488#30058#21495
end
object cbxUseHttpProxy: TCheckBox
Left = 16
- Top = 48
+ Top = 40
Width = 153
Height = 17
Hint = 'HTTP Proxy'#12434#36890#12376#12390#12508#12488#12523#12469#12540#12496#12395#25509#32154#12375#12414#12377
TabOrder = 0
end
end
+ object cbxHideGhosts: TCheckBox
+ Left = 8
+ Top = 128
+ Width = 249
+ Height = 17
+ Hint = 'IfGhost'#36984#25246#12508#12483#12463#12473#12395#25351#23450#12375#12383#12468#12540#12473#12488#12364#29694#12428#12394#12356#12424#12358#12395#12375#12414#12377#12290#21463#20449#23554#29992#12468#12540#12473#12488#12398#25351#23450#12364#21487#33021
+ Caption = #25351#23450#12468#12540#12473#12488#20197#22806#12434#36984#25246#12508#12483#12463#12473#12363#12425#38560#12377'(&H)'
+ TabOrder = 2
+ end
+ object btnVisibleGhosts: TButton
+ Left = 264
+ Top = 124
+ Width = 99
+ Height = 25
+ Caption = #12468#12540#12473#12488#25351#23450'(&G)...'
+ TabOrder = 3
+ OnClick = btnVisibleGhostsClick
+ end
end
end
object btnClose: TButton
Windows, Messages, SysUtils, Classes, Graphics, Controls, Forms, Dialogs,
ComCtrls, StdCtrls, ExtCtrls, BottleDef, Spin,
CPCConfigTreeView, ColorSettingFrame, BottleChainListFrame, SakuraSeekerInstance,
- ImgList;
+ ImgList, StrListEditor;
type
TfrmSetting = class(TForm)
Label6: TLabel;
ImageList: TImageList;
cbxShowRuler: TCheckBox;
+ cbxHideGhosts: TCheckBox;
+ btnVisibleGhosts: TButton;
procedure FormClose(Sender: TObject; var Action: TCloseAction);
procedure edtProxyPortKeyPress(Sender: TObject; var Key: Char);
procedure ctvBottleNodeChecked(Sender: TObject;
Node: TCPCConfigItemNode; var Allow: Boolean);
procedure tstRuleShow(Sender: TObject);
procedure btnUseCurrentJoinChannelsClick(Sender: TObject);
+ procedure btnVisibleGhostsClick(Sender: TObject);
private
{ Private \90é\8c¾ }
public
edtProxyPort.Text := IntToStr(Pref.ProxyPort);
//
memFMOName.Lines := Pref.FMOName;
+ cbxHideGhosts.Checked := Pref.HideGhosts;
memAutoJoinChannels.Lines := Pref.AutoJoinChannels;
//
ShowModal;
//
Pref.FMOName := memFMOName.Lines;
SakuraSeeker.FileMappingTarget := Pref.FMOName;
+ Pref.HideGhosts := cbxHideGhosts.Checked;
//
Pref.AutoJoinChannels := memAutoJoinChannels.Lines;
end;
memAutoJoinChannels.Lines := JoinChannels;
end;
+procedure TfrmSetting.btnVisibleGhostsClick(Sender: TObject);
+var i: integer;
+ FullGhosts: TStringList;
+begin
+ FullGhosts := TStringList.Create;
+ SakuraSeeker.BeginDetect;
+ try
+ for i := 0 to SakuraSeeker.Count-1 do
+ FullGhosts.Add(SakuraSeeker[i].Name);
+ StrListEdit(Pref.VisibleGhostsList, '\83S\81[\83X\83g\82ð\8ew\92è', true, FullGhosts);
+ finally
+ FullGhosts.Free;
+ end;
+end;
+
end.