// EffectSetDetailDlg.cpp : implementation file
//

#include "stdafx.h"
#include "mapeditor.h"
#include "EffectSetDetailDlg.h"

#ifdef _DEBUG
#define new DEBUG_NEW
#undef THIS_FILE
static char THIS_FILE[] = __FILE__;
#endif

/////////////////////////////////////////////////////////////////////////////
// CEffectSetDetailDlg dialog


CEffectSetDetailDlg::CEffectSetDetailDlg(CWnd* pParent /*=NULL*/)
	: CDialog(CEffectSetDetailDlg::IDD, pParent)
{
	//{{AFX_DATA_INIT(CEffectSetDetailDlg)
	m_strEffectName = _T("");
	m_nEffectType = 0;
	m_bRegion = FALSE;
	m_bLoop = FALSE;
	m_fReTime = 0.0f;
	m_fPosX = 0.0f;
	m_fPosY = 0.0f;
	m_fPosZ = 0.0f;
	//}}AFX_DATA_INIT

	m_bEdit = FALSE;
}


void CEffectSetDetailDlg::DoDataExchange(CDataExchange* pDX)
{
	CDialog::DoDataExchange(pDX);
	//{{AFX_DATA_MAP(CEffectSetDetailDlg)
	DDX_Text(pDX, IDC_EDIT_EFFECTNAME, m_strEffectName);
	DDX_Text(pDX, IDC_EDIT_EFFECTTYPE, m_nEffectType);
	DDX_Check(pDX, IDC_CHECK_REGION, m_bRegion);
	DDX_Check(pDX, IDC_CHECK_LOOP, m_bLoop);
	DDX_Text(pDX, IDC_EDIT_RETIME, m_fReTime);
	DDX_Text(pDX, IDC_EDIT_POSITIN_X, m_fPosX);
	DDX_Text(pDX, IDC_EDIT_POSITIN_Y, m_fPosY);
	DDX_Text(pDX, IDC_EDIT_POSITIN_Z, m_fPosZ);
	//}}AFX_DATA_MAP
}


BEGIN_MESSAGE_MAP(CEffectSetDetailDlg, CDialog)
	//{{AFX_MSG_MAP(CEffectSetDetailDlg)
	ON_BN_CLICKED(IDC_CHECK_LOOP, OnCheckLoop)
	ON_BN_CLICKED(IDC_CHECK_REGION, OnCheckRegion)
	ON_EN_CHANGE(IDC_EDIT_EFFECTNAME, OnChangeEditEffectname)
	ON_EN_CHANGE(IDC_EDIT_EFFECTTYPE, OnChangeEditEffecttype)
	ON_EN_CHANGE(IDC_EDIT_POSITIN_X, OnChangeEditPositinX)
	ON_EN_CHANGE(IDC_EDIT_POSITIN_Y, OnChangeEditPositinY)
	ON_EN_CHANGE(IDC_EDIT_POSITIN_Z, OnChangeEditPositinZ)
	ON_EN_CHANGE(IDC_EDIT_RETIME, OnChangeEditRetime)
	//}}AFX_MSG_MAP
END_MESSAGE_MAP()

/////////////////////////////////////////////////////////////////////////////
// CEffectSetDetailDlg message handlers

void CEffectSetDetailDlg::OnCheckLoop() 
{
	// TODO: Add your control notification handler code here
	UpdateData();
}

void CEffectSetDetailDlg::OnCheckRegion() 
{
	// TODO: Add your control notification handler code here
	UpdateData();
}

void CEffectSetDetailDlg::OnChangeEditEffectname() 
{
	// TODO: If this is a RICHEDIT control, the control will not
	// send this notification unless you override the CDialog::OnInitDialog()
	// function and call CRichEditCtrl().SetEventMask()
	// with the ENM_CHANGE flag ORed into the mask.
	
	// TODO: Add your control notification handler code here
	UpdateData();	
}


void CEffectSetDetailDlg::OnChangeEditEffecttype() 
{
	// TODO: If this is a RICHEDIT control, the control will not
	// send this notification unless you override the CDialog::OnInitDialog()
	// function and call CRichEditCtrl().SetEventMask()
	// with the ENM_CHANGE flag ORed into the mask.
	
	// TODO: Add your control notification handler code here
	UpdateData();
}

void CEffectSetDetailDlg::OnChangeEditPositinX() 
{
	// TODO: If this is a RICHEDIT control, the control will not
	// send this notification unless you override the CDialog::OnInitDialog()
	// function and call CRichEditCtrl().SetEventMask()
	// with the ENM_CHANGE flag ORed into the mask.
	
	// TODO: Add your control notification handler code here
	UpdateData();
}

void CEffectSetDetailDlg::OnChangeEditPositinY() 
{
	// TODO: If this is a RICHEDIT control, the control will not
	// send this notification unless you override the CDialog::OnInitDialog()
	// function and call CRichEditCtrl().SetEventMask()
	// with the ENM_CHANGE flag ORed into the mask.
	
	// TODO: Add your control notification handler code here
	UpdateData();
}

void CEffectSetDetailDlg::OnChangeEditPositinZ() 
{
	// TODO: If this is a RICHEDIT control, the control will not
	// send this notification unless you override the CDialog::OnInitDialog()
	// function and call CRichEditCtrl().SetEventMask()
	// with the ENM_CHANGE flag ORed into the mask.
	
	// TODO: Add your control notification handler code here
	UpdateData();
}

void CEffectSetDetailDlg::OnChangeEditRetime() 
{
	// TODO: If this is a RICHEDIT control, the control will not
	// send this notification unless you override the CDialog::OnInitDialog()
	// function and call CRichEditCtrl().SetEventMask()
	// with the ENM_CHANGE flag ORed into the mask.
	
	// TODO: Add your control notification handler code here
	UpdateData();
}
