OSDN Git Service

This commit was manufactured by cvs2svn to create branch 'Bb62'.
[gikonavigoeson/gikonavi.git] / KuroutSetting.pas
index ca72cc7..32e7f62 100644 (file)
@@ -4,7 +4,7 @@ interface
 
 uses
   Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
-  Dialogs, StdCtrls, ComCtrls, GikoSystem, GikoUtil, ExtCtrls;
+  Dialogs, StdCtrls, ComCtrls, GikoSystem, GikoUtil, ExtCtrls, StrUtils;
 
 type
   TKuroutOption = class(TForm)
@@ -50,9 +50,6 @@ type
     GroupBox1: TGroupBox;
     GengoSupport: TCheckBox;
     Label5: TLabel;
-    GroupBox2: TGroupBox;
-    LocalTrapAtt: TCheckBox;
-    RemoteTrapAtt: TCheckBox;
     Label6: TLabel;
     ReadTimeOut: TEdit;
     Label7: TLabel;
@@ -67,9 +64,39 @@ type
     Label11: TLabel;
     AHandredGroupBox: TGroupBox;
     AHandredLabeledEdit: TLabeledEdit;
-    UpDown1: TUpDown;
-    HTMLGroupBox: TGroupBox;
+    AHandredUpDown: TUpDown;
+    ThreadGroupBox: TGroupBox;
     AddKeywordCheckBox: TCheckBox;
+    TabSheet2: TTabSheet;
+    SecurityGroupBox: TGroupBox;
+    GroupBox2: TGroupBox;
+    LocalTrapAtt: TCheckBox;
+    RemoteTrapAtt: TCheckBox;
+    ReplaceDatCheckBox: TCheckBox;
+    Label12: TLabel;
+    GroupBox4: TGroupBox;
+    SentIniFileSizeEdit: TEdit;
+    SentIniFileSizeUpDown: TUpDown;
+    Label13: TLabel;
+    Label14: TLabel;
+    ExtListLabeledEdit: TLabeledEdit;
+    Label15: TLabel;
+    LogGroupBox: TGroupBox;
+    CheckDatFileCheckBox: TCheckBox;
+    RespopupTabSheet: TTabSheet;
+    RespopuGroupBox: TGroupBox;
+    DeltaXLabeledEdit: TLabeledEdit;
+    DeltaYLabeledEdit: TLabeledEdit;
+    DeltaXUpDown: TUpDown;
+    DeltaYUpDown: TUpDown;
+    Label16: TLabel;
+    RespopupWaitLabeledEdit: TLabeledEdit;
+    RespopupWaitUpDown: TUpDown;
+    Label19: TLabel;
+    RespopupMailToCheckBox: TCheckBox;
+    ResRangeLabeledEdit: TLabeledEdit;
+    ResRangeCountUpDown: TUpDown;
+    UseGobakuCheckBox: TCheckBox;
        procedure OkBottonClick(Sender: TObject);
        procedure FormCreate(Sender: TObject);
        procedure CDeleteButtonClick(Sender: TObject);
@@ -82,6 +109,11 @@ type
     procedure BDownButtonClick(Sender: TObject);
     procedure MoveHistoryMaxEditExit(Sender: TObject);
     procedure AHandredLabeledEditExit(Sender: TObject);
+    procedure ExtListLabeledEditExit(Sender: TObject);
+    procedure DeltaXLabeledEditExit(Sender: TObject);
+    procedure DeltaYLabeledEditExit(Sender: TObject);
+    procedure RespopupWaitLabeledEditExit(Sender: TObject);
+    procedure ResRangeLabeledEditExit(Sender: TObject);
   private
        { Private \90é\8c¾ }
        procedure SetValue;
@@ -137,9 +169,23 @@ begin
     // \83\8a\83\93\83N\88Ú\93®\97\9a\97ð
     MoveHistoryMaxEdit.Text := IntToStr( GikoSys.Setting.MoveHistorySize );
     //\81@\90æ\93ª\95\\8e¦\83\8c\83X\90\94
-    AHandredLabeledEdit.Text := IntToStr( GikoSys.Setting.HeadResCount );
+    AHandredUpDown.Position := GikoSys.Setting.HeadResCount;
+    // \95\\8e¦\83\8c\83X\90\94
+    ResRangeCountUpDown.Position := GikoSys.Setting.ResRangeExCount;
     // \8aÖ\98A\83L\81[\83\8f\81[\83h\92Ç\89Á\83t\83\89\83O
     AddKeywordCheckBox.Checked := GikoSys.Setting.AddKeywordLink;
+    // \8cë\94½\89\9e\91Î\8dô
+    ReplaceDatCheckBox.Checked := GikoSys.Setting.ReplaceDat;
+    SentIniFileSizeUpDown.Position := GikoSys.Setting.SentIniFileSize;
+    ExtListLabeledEdit.Text := GikoSys.Setting.ExtList;
+    // Folder.idx\93Ç\82Ý\8d\9e\82Ý\8e\9edat\83`\83F\83b\83N
+    CheckDatFileCheckBox.Checked := GikoSys.Setting.CheckDatFile;
+    DeltaXUpDown.Position := GikoSys.Setting.RespopupDeltaX;
+    DeltaYUpDown.Position := GikoSys.Setting.RespopupDeltaY;
+    RespopupWaitUpDown.Position := GikoSys.Setting.RespopupWait;
+    RespopupMailToCheckBox.Checked := GikoSys.Setting.RespopupMailTo;
+    // \8cë\94\9a\83`\83F\83b\83N
+    UseGobakuCheckBox.Checked := GikoSys.Setting.UseGobakuCheck;
 end;
 
 procedure TKuroutOption.SaveSetting;
@@ -174,10 +220,25 @@ begin
     //\81@\90æ\93ª\95\\8e¦\83\8c\83X\90\94
     GikoSys.Setting.HeadResCount :=
         StrToIntDef( AHandredLabeledEdit.Text , 1);
-
+    GikoSys.Setting.ResRangeExCount :=
+        StrToIntDef( ResRangeLabeledEdit.Text , 100 );
        GikoSys.Setting.KuroutSettingTabIndex := PageControl1.ActivePageIndex;
     // \8aÖ\98A\83L\81[\83\8f\81[\83h\92Ç\89Á\83t\83\89\83O
     GikoSys.Setting.AddKeywordLink := AddKeywordCheckBox.Checked;
+    // \8cë\94½\89\9e\91Î\8dô
+    GikoSys.Setting.ReplaceDat := ReplaceDatCheckBox.Checked;
+    GikoSys.Setting.SentIniFileSize := SentIniFileSizeUpDown.Position;
+    GikoSys.Setting.ExtList := ExtListLabeledEdit.Text;
+    // Folder.idx\93Ç\82Ý\8d\9e\82Ý\8e\9edat\83`\83F\83b\83N
+    GikoSys.Setting.CheckDatFile := CheckDatFileCheckBox.Checked;
+
+    GikoSys.Setting.RespopupDeltaX := StrToInt(DeltaXLabeledEdit.Text);
+    GikoSys.Setting.RespopupDeltaY := StrToInt(DeltaYLabeledEdit.Text);
+    GikoSys.Setting.RespopupWait := StrToInt(RespopupWaitLabeledEdit.Text);
+    GikoForm.ResPopupClearTimer.Interval := GikoSys.Setting.RespopupWait;
+    GikoSys.Setting.RespopupMailTo := RespopupMailToCheckBox.Checked;
+    // \8cë\94\9a\83`\83F\83b\83N
+    GikoSys.Setting.UseGobakuCheck := UseGobakuCheckBox.Checked;
 
 end;
 
@@ -209,6 +270,10 @@ begin
        PostTimeEditExit(Sender);
     MoveHistoryMaxEditExit(Sender);
     AHandredLabeledEditExit(Sender);
+    ExtListLabeledEditExit(Sender);
+    DeltaXLabeledEditExit(Sender);
+    DeltaYLabeledEditExit(Sender);
+    RespopupWaitLabeledEditExit(Sender);
     PostColumnData();
        SaveSetting;
 end;
@@ -423,4 +488,53 @@ begin
 
 end;
 
+procedure TKuroutOption.ExtListLabeledEditExit(Sender: TObject);
+begin
+    if AnsiEndsStr(';', ExtListLabeledEdit.Text) then begin
+        ExtListLabeledEdit.Text :=
+            Copy(ExtListLabeledEdit.Text, 0,
+                Length(ExtListLabeledEdit.Text) - 1);
+    end;
+end;
+// \83\8c\83X\83|\83b\83v\83A\83b\83v\88Ê\92uX
+procedure TKuroutOption.DeltaXLabeledEditExit(Sender: TObject);
+begin
+       if not GikoSys.IsNumeric(DeltaXLabeledEdit.Text) then
+               DeltaXLabeledEdit.Text := IntToStr(GikoSys.Setting.RespopupDeltaX);
+    if StrToInt(DeltaXLabeledEdit.Text) < DeltaXUpDown.Min then
+        DeltaXLabeledEdit.Text := IntToStr(DeltaXUpDown.Min);
+    if StrToInt(DeltaXLabeledEdit.Text) > DeltaXUpDown.Max then
+        DeltaXLabeledEdit.Text:= IntToStr(DeltaXUpDown.Max);
+end;
+// \83\8c\83X\83|\83b\83v\83A\83b\83v\88Ê\92uY
+procedure TKuroutOption.DeltaYLabeledEditExit(Sender: TObject);
+begin
+       if not GikoSys.IsNumeric(DeltaYLabeledEdit.Text) then
+        DeltaYLabeledEdit.Text := IntToStr(GikoSys.Setting.RespopupDeltaY);
+    if StrToInt(DeltaYLabeledEdit.Text) < DeltaYUpDown.Min then
+        DeltaYLabeledEdit.Text := IntToStr(DeltaYUpDown.Min);
+    if StrToInt(DeltaYLabeledEdit.Text) > DeltaYUpDown.Max then
+        DeltaYLabeledEdit.Text := IntToStr(DeltaYUpDown.Max);
+end;
+
+procedure TKuroutOption.RespopupWaitLabeledEditExit(Sender: TObject);
+begin
+       if not GikoSys.IsNumeric(RespopupWaitLabeledEdit.Text) then
+               RespopupWaitLabeledEdit.Text := IntToStr(GikoSys.Setting.RespopupWait);
+    if StrToInt(RespopupWaitLabeledEdit.Text) < RespopupWaitUpDown.Min then
+               RespopupWaitLabeledEdit.Text := IntToStr(RespopupWaitUpDown.Min);
+    if StrToInt(RespopupWaitLabeledEdit.Text) > RespopupWaitUpDown.Max then
+               RespopupWaitLabeledEdit.Text := IntToStr(RespopupWaitUpDown.Max);
+end;
+
+procedure TKuroutOption.ResRangeLabeledEditExit(Sender: TObject);
+begin
+       if not GikoSys.IsNumeric(ResRangeLabeledEdit.Text) then
+               ResRangeLabeledEdit.Text := '100';
+    if StrToInt(ResRangeLabeledEdit.Text) < 100 then
+        ResRangeLabeledEdit.Text := '100';
+    if StrToInt(ResRangeLabeledEdit.Text) > 9999 then
+        ResRangeLabeledEdit.Text := '9999';
+end;
+
 end.