⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 settingdlg.cpp

📁 ti的数字电视芯片 tvp9000的源码
💻 CPP
字号:
// SettingDlg.cpp : implementation file
//

#include "stdafx.h"
#include "SettingDlg.h"

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

/////////////////////////////////////////////////////////////////////////////
// CSettingDlg dialog
/*

*/

CSettingDlg::CSettingDlg(CWnd* pParent /*=NULL*/)
	: CDialog(CSettingDlg::IDD, pParent)
{
	//{{AFX_DATA_INIT(CSettingDlg)
	m_nBitPerSec 	= DEFAULT_BitPerSec;	
	m_nSelCOM 		= DEFAULT_SelCOM;	
	m_nDataBits 	= DEFAULT_DataBits;	
	m_nFlowCtrl 	= DEFAULT_FlowCtrl;	
	m_nParity 		= DEFAULT_Parity;
	m_nBlockSize 	= DEFAULT_BlockSize;
	m_nTimeOut 		= DEFAULT_TimeOut;
	m_nStopBits = 0;		
	//}}AFX_DATA_INIT
}


void CSettingDlg::DoDataExchange(CDataExchange* pDX)
{
	CDialog::DoDataExchange(pDX);
	//{{AFX_DATA_MAP(CSettingDlg)
	DDX_CBIndex(pDX, IDC_COMBO_BITPERSEC, m_nBitPerSec);
	DDX_CBIndex(pDX, IDC_COMBO_COM, m_nSelCOM);
	DDX_CBIndex(pDX, IDC_COMBO_DATABITS, m_nDataBits);
	DDX_CBIndex(pDX, IDC_COMBO_FLOWCTRL, m_nFlowCtrl);
	DDX_CBIndex(pDX, IDC_COMBO_PARITY, m_nParity);
	DDX_Text(pDX, IDC_EDIT_BLOCKSIZE, m_nBlockSize);
	DDV_MinMaxInt(pDX, m_nBlockSize, 1, 1024000);
	DDX_Text(pDX, IDC_EDIT_TIMEOUT, m_nTimeOut);
	DDV_MinMaxUInt(pDX, m_nTimeOut, 1, 31536000);
	DDX_CBIndex(pDX, IDC_COMBO_STOPBITS, m_nStopBits);
	//}}AFX_DATA_MAP
}


BEGIN_MESSAGE_MAP(CSettingDlg, CDialog)
	//{{AFX_MSG_MAP(CSettingDlg)
	ON_BN_CLICKED(IDOK, OnOk)
	ON_BN_CLICKED(IDDEFAULT, OnDefault)
	//}}AFX_MSG_MAP
END_MESSAGE_MAP()

/////////////////////////////////////////////////////////////////////////////
// CSettingDlg message handlers

void CSettingDlg::OnOk() 
{
	// TODO: Add your control notification handler code here
	CDialog::OnOK();
}

void CSettingDlg::OnDefault() 
{
	// TODO: Add your control notification handler code here
	m_nBitPerSec 	= DEFAULT_BitPerSec;	
	m_nSelCOM 		= DEFAULT_SelCOM;	
	m_nDataBits 	= DEFAULT_DataBits;	
	m_nFlowCtrl 	= DEFAULT_FlowCtrl;	
	m_nParity 		= DEFAULT_Parity;
	m_nBlockSize 	= DEFAULT_BlockSize;
	m_nTimeOut 		= DEFAULT_TimeOut;

	UpdateData(FALSE);
}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -