a
This commit is contained in:
@@ -0,0 +1,128 @@
|
||||
// opcesptrectgldlg.cpp : implementation file
|
||||
//
|
||||
|
||||
#include "stdafx.h"
|
||||
#include "geomative.h"
|
||||
#include "opcesptrectgldlg.h"
|
||||
|
||||
#ifdef _DEBUG
|
||||
#define new DEBUG_NEW
|
||||
#undef THIS_FILE
|
||||
static char THIS_FILE[] = __FILE__;
|
||||
#endif
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// COpCESptRECTGLDlg dialog
|
||||
|
||||
|
||||
COpCESptRECTGLDlg::COpCESptRECTGLDlg(CWnd* pParent /*=NULL*/)
|
||||
: CDialog(COpCESptRECTGLDlg::IDD, pParent)
|
||||
{
|
||||
//{{AFX_DATA_INIT(COpCESptRECTGLDlg)
|
||||
m_strStacking = _T("1");
|
||||
m_unIterNum = 0;
|
||||
//}}AFX_DATA_INIT
|
||||
}
|
||||
|
||||
|
||||
void COpCESptRECTGLDlg::DoDataExchange(CDataExchange* pDX)
|
||||
{
|
||||
CDialog::DoDataExchange(pDX);
|
||||
//{{AFX_DATA_MAP(COpCESptRECTGLDlg)
|
||||
DDX_Control(pDX, IDC_SPT_ROWSPACE, m_edRowSpace);
|
||||
DDX_Control(pDX, IDC_SPT_COLSPACE, m_edColSpace);
|
||||
DDX_Control(pDX, IDC_SPT_B, m_edB);
|
||||
DDX_Control(pDX, IDC_SPT_A, m_edA);
|
||||
DDX_Text(pDX, IDC_ITER_NUM, m_strStacking);
|
||||
//}}AFX_DATA_MAP
|
||||
}
|
||||
|
||||
|
||||
BEGIN_MESSAGE_MAP(COpCESptRECTGLDlg, CDialog)
|
||||
//{{AFX_MSG_MAP(COpCESptRECTGLDlg)
|
||||
ON_WM_SHOWWINDOW()
|
||||
//}}AFX_MSG_MAP
|
||||
END_MESSAGE_MAP()
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// COpCESptRECTGLDlg message handlers
|
||||
|
||||
void COpCESptRECTGLDlg::OnShowWindow(BOOL bShow, UINT nStatus)
|
||||
{
|
||||
CDialog::OnShowWindow(bShow, nStatus);
|
||||
|
||||
// TODO: Add your message handler code here
|
||||
int iN = (int)VAL_ZERO;
|
||||
CString szLabel = _T("");
|
||||
|
||||
if (TRUE == bShow)
|
||||
{
|
||||
m_edA.SetIntLimitLen(5);
|
||||
m_edA.SetDecLimitLen(2);
|
||||
m_edA.SetWindowText(_T("0"));
|
||||
|
||||
m_edB.SetIntLimitLen(5);
|
||||
m_edB.SetDecLimitLen(2);
|
||||
m_edB.SetWindowText(_T("0"));
|
||||
|
||||
// m_edMaxRow.SetIntLimitLen(4);
|
||||
// m_edMaxRow.SetDecLimitLen(0);
|
||||
// m_edMaxRow.SetWindowText(_T("0"));
|
||||
|
||||
// m_edMaxCol.SetIntLimitLen(4);
|
||||
// m_edMaxCol.SetDecLimitLen(0);
|
||||
// m_edMaxCol.SetWindowText(_T("0"));
|
||||
|
||||
// m_edRowSpace.SetIntLimitLen(5);
|
||||
// m_edRowSpace.SetDecLimitLen(2);
|
||||
m_edRowSpace.SetWindowText(_T("0"));
|
||||
|
||||
// m_edColSpace.SetIntLimitLen(5);
|
||||
// m_edColSpace.SetDecLimitLen(2);
|
||||
m_edColSpace.SetWindowText(_T("0"));
|
||||
|
||||
((CEdit*)GetDlgItem(IDC_SPT_ROWSPACE))->SetLimitText(10);
|
||||
((CEdit*)GetDlgItem(IDC_SPT_COLSPACE))->SetLimitText(10);
|
||||
iN = 1;
|
||||
// while (iN <= MAXN) //useless by waston
|
||||
// while (iN <= 30) //useless by waston
|
||||
// {
|
||||
// szLabel.Empty();
|
||||
// szLabel.Format(_T("%d"), iN);
|
||||
//
|
||||
// this->m_cbN.AddString(szLabel);
|
||||
// iN++;
|
||||
// }
|
||||
// this->m_cbN.SetCurSel((int)VAL_ZERO);
|
||||
}
|
||||
}
|
||||
|
||||
BOOL COpCESptRECTGLDlg::PreTranslateMessage(MSG* pMsg)
|
||||
{
|
||||
// TODO: Add your specialized code here and/or call the base class
|
||||
if(pMsg->message==WM_KEYDOWN && pMsg->wParam==VK_RETURN)
|
||||
{
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
if(pMsg->message==WM_KEYDOWN && pMsg->wParam==VK_ESCAPE)
|
||||
{
|
||||
return TRUE;
|
||||
}
|
||||
return CDialog::PreTranslateMessage(pMsg);
|
||||
}
|
||||
|
||||
BOOL COpCESptRECTGLDlg::OnInitDialog()
|
||||
{
|
||||
CDialog::OnInitDialog();
|
||||
|
||||
// TODO: Add extra initialization here
|
||||
GetDlgItem(IDC_ITER_NUM)->SetWindowText(_T("1"));
|
||||
GetDlgItem(IDC_SPT_MAXROW)->ShowWindow(SW_HIDE);
|
||||
GetDlgItem(IDC_SPT_MAXCOL)->ShowWindow(SW_HIDE);
|
||||
GetDlgItem(IDC_STATIC_GRID)->ShowWindow(SW_HIDE);
|
||||
GetDlgItem(IDC_STATIC_PLUS)->ShowWindow(SW_HIDE);
|
||||
|
||||
return TRUE; // return TRUE unless you set the focus to a control
|
||||
// EXCEPTION: OCX Property Pages should return FALSE
|
||||
}
|
||||
Reference in New Issue
Block a user