//---------------------------------------------------------------------------
#ifndef FrmSetupH
#define FrmSetupH
//---------------------------------------------------------------------------
#include <Classes.hpp>
#include <Controls.hpp>
#include <StdCtrls.hpp>
#include <Forms.hpp>
#include <ComCtrls.hpp>
#include <Dialogs.hpp>
//---------------------------------------------------------------------------
#include "../kbtim/kbtim_SettingTimidity.h"

class TSetupForm : public TForm
{
__published:	// IDE 管理のコンポーネント
    TButton *btnOK;
    TButton *btnCancel;
    TButton *btnApply;
    TButton *btnNew;
    TButton *btnDel;
    TButton *btnUndo;
    TButton *btnHelp;
    TButton *btnDefAll;
    TButton *btnCfg;
    TButton *btnEdit;
    TButton *btnAutoLQ;
    TButton *btnAutoHQ;
    TButton *btnAutoDef;
    TButton *btnDefault;
    TOpenDialog *OpenDialog;
    TLabel *Label1;
    TLabel *Label2;
    TLabel *Label3;
    TLabel *Label4;
    TLabel *Label5;
    TLabel *Label6;
    TEdit *Edit;
    TEdit *Edit1;
    TEdit *Edit2;
    TEdit *Edit3;
    TEdit *Edit4;
    TEdit *Edit7;
    TMemo *Memo;
    TTreeView *TreeView;
    TComboBox *ComboBox1;
    TComboBox *ComboBox2;
    TComboBox *ComboBox3;
    TComboBox *ComboBox4;
    TCheckBox *CheckBox1;
    TCheckBox *CheckBox2;
    TCheckBox *CheckBox3;
    TCheckBox *CheckBox4;
    TCheckBox *CheckBox5;
    TCheckBox *CheckBox6;
    TCheckBox *CheckBox7;
    TCheckBox *CheckBox8;
    TCheckBox *CheckBox9;
    TCheckBox *CheckBox10;
    TCheckBox *CheckBox11;
    TCheckBox *CheckBox12;
    TCheckBox *CheckBox13;
    TCheckBox *CheckBox14;
    TCheckBox *CheckBox15;
    TCheckBox *CheckBox16;
    TCheckBox *CheckBox17;
    TCheckBox *CheckBox18;
    TCheckBox *CheckBox19;
    TRadioButton *RadioButton1;
    TRadioButton *RadioButton2;
    TRadioButton *RadioButton3;
    TGroupBox *GroupBox1;
    TGroupBox *GroupBox2;
    TGroupBox *GroupBox3;
    TGroupBox *GroupBox4;
    TComboBox *ComboBox5;
    TLabel *Label8;
    TEdit *Edit5;
    TGroupBox *GroupBox5;
    TComboBox *ComboBox6;
    TGroupBox *GroupBox6;
    TRadioButton *RadioButton4;
    TRadioButton *RadioButton5;
    TRadioButton *RadioButton6;
    TGroupBox *GroupBox7;
    TEdit *Edit8;
    TLabel *Label7;
    TLabel *Label9;
    TEdit *Edit9;
    TCheckBox *CheckBox20;
    TLabel *Label10;
    TEdit *Edit6;
    void __fastcall EditChange(TObject *Sender);
    void __fastcall TreeViewChanging(TObject *Sender, TTreeNode *Node, bool &AllowChange);
    void __fastcall TreeViewChange(TObject *Sender, TTreeNode *Node);
    void __fastcall btnClick(TObject *Sender);
private:	// ユーザー宣言
    BOOL m_bChanging;
    BOOL m_bModified; //選択中のテンプレートが設定変更されたか
    BOOL m_bModified2;//テンプレートの追加・削除・名称変更がされたか
    BOOL __fastcall CheckModified2(void);
    BOOL __fastcall Apply(TTreeNode *pNode);
    BOOL __fastcall Delete(TTreeNode *pNode);
    void __fastcall UpdateGUI(KbSettingTimidity *pSetting, TTreeNode *pNode);
    void __fastcall WMCopyData(TMessage &Message);
    void __fastcall DoCopyData(const char *cszCommand);

    BEGIN_MESSAGE_MAP
        MESSAGE_HANDLER(WM_COPYDATA, TMessage, WMCopyData)
    END_MESSAGE_MAP(TForm)

public:		// ユーザー宣言
    __fastcall TSetupForm(TComponent* Owner);
    __fastcall ~TSetupForm(void);
};
//---------------------------------------------------------------------------
extern PACKAGE TSetupForm *SetupForm;
//---------------------------------------------------------------------------
#endif
