Code/Resource
Windows Develop
Linux-Unix program
Internet-Socket-Network
Web Server
Browser Client
Ftp Server
Ftp Client
Browser Plugins
Proxy Server
Email Server
Email Client
WEB Mail
Firewall-Security
Telnet Server
Telnet Client
ICQ-IM-Chat
Search Engine
Sniffer Package capture
Remote Control
xml-soap-webservice
P2P
WEB(ASP,PHP,...)
TCP/IP Stack
SNMP
Grid Computing
SilverLight
DNS
Cluster Service
Network Security
Communication-Mobile
Game Program
Editor
Multimedia program
Graph program
Compiler program
Compress-Decompress algrithms
Crypt_Decrypt algrithms
Mathimatics-Numerical algorithms
MultiLanguage
Disk/Storage
Java Develop
assembly language
Applications
Other systems
Database system
Embeded-SCM Develop
FlashMX/Flex
source in ebook
Delphi VCL
OS Develop
MiddleWare
MPI
MacOS develop
LabView
ELanguage
Software/Tools
E-Books
Artical/Document
CalDlg.cpp
Package: ebd_src.zip [view]
Upload User: kelijie
Upload Date: 2007-01-01
Package Size: 123k
Code Size: 2k
Category:
Graph program
Development Platform:
Visual C++
- // CalDlg.cpp : implementation file
- //
- #include "stdafx.h"
- #include "ebdlib2.h"
- #include "CalDlg.h"
- #ifdef _DEBUG
- #define new DEBUG_NEW
- #undef THIS_FILE
- static char THIS_FILE[] = __FILE__;
- #endif
- /////////////////////////////////////////////////////////////////////////////
- // CCalDlg dialog
- CCalDlg::CCalDlg(CWnd* pParent /*=NULL*/)
- : CDialog(CCalDlg::IDD, pParent)
- {
- //{{AFX_DATA_INIT(CCalDlg)
- // NOTE: the ClassWizard will add member initialization here
- //}}AFX_DATA_INIT
- m_iOperand = OPERAND_ADD;
- }
- void CCalDlg::DoDataExchange(CDataExchange* pDX)
- {
- CDialog::DoDataExchange(pDX);
- //{{AFX_DATA_MAP(CCalDlg)
- // NOTE: the ClassWizard will add DDX and DDV calls here
- //}}AFX_DATA_MAP
- }
- BEGIN_MESSAGE_MAP(CCalDlg, CDialog)
- //{{AFX_MSG_MAP(CCalDlg)
- ON_BN_CLICKED(IDC_ADD, OnAdd)
- ON_BN_CLICKED(IDC_DVD, OnDvd)
- ON_BN_CLICKED(IDC_MUL, OnMul)
- ON_BN_CLICKED(IDC_SUB, OnSub)
- //}}AFX_MSG_MAP
- END_MESSAGE_MAP()
- /////////////////////////////////////////////////////////////////////////////
- // CCalDlg message handlers
- void CCalDlg::OnAdd()
- {
- // TODO: Add your control notification handler code here
- m_iOperand = OPERAND_ADD;
- SetCheckBox();
- }
- void CCalDlg::OnDvd()
- {
- // TODO: Add your control notification handler code here
- m_iOperand = OPERAND_DVD;
- SetCheckBox();
- }
- void CCalDlg::OnMul()
- {
- // TODO: Add your control notification handler code here
- m_iOperand = OPERAND_MUL;
- SetCheckBox();
- }
- void CCalDlg::OnSub()
- {
- // TODO: Add your control notification handler code here
- m_iOperand = OPERAND_SUB;
- SetCheckBox();
- }
- BOOL CCalDlg::OnInitDialog()
- {
- CDialog::OnInitDialog();
- // TODO: Add extra initialization here
- SetCheckBox();
- return TRUE; // return TRUE unless you set the focus to a control
- // EXCEPTION: OCX Property Pages should return FALSE
- }
- void CCalDlg::SetCheckBox(void)
- {
- ((CButton*)GetDlgItem(IDC_ADD))->SetCheck(m_iOperand == OPERAND_ADD ? TRUE : FALSE);
- ((CButton*)GetDlgItem(IDC_SUB))->SetCheck(m_iOperand == OPERAND_SUB ? TRUE : FALSE);
- ((CButton*)GetDlgItem(IDC_MUL))->SetCheck(m_iOperand == OPERAND_MUL ? TRUE : FALSE);
- ((CButton*)GetDlgItem(IDC_DVD))->SetCheck(m_iOperand == OPERAND_DVD ? TRUE : FALSE);
- }