-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathCalculateValuesPg1.h
123 lines (99 loc) · 3.19 KB
/
CalculateValuesPg1.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
// CalculateValuesPg1.h : header file
//
// $Id$
//////////////////////////////////////////////////////////////////////
//{{AFX_INCLUDES()
#include "mshflexgrid.h"
//}}AFX_INCLUDES
#include "EditGrid.h"
#include "ClipListBox.h"
#include "KeywordPageListItems.h"
#include "BasicDesc2.h"
#ifndef __CCALCULATEVALUESPG1_H__
#define __CCALCULATEVALUESPG1_H__
/////////////////////////////////////////////////////////////////////////////
// CCalculateValuesPg1 dialog
#include "KeywordPage.h"
#ifndef baseCalculateValuesPg1
#define baseCalculateValuesPg1 CKeywordPage
#endif
class CCalculateValuesPg1 : public baseCalculateValuesPg1
{
DECLARE_DYNCREATE(CCalculateValuesPg1)
// inner class
protected:
class XGridTabItem
{
public:
CCalcValue calcValue;
long nRowIndex;
int nTabIndex;
XGridTabItem();
virtual ~XGridTabItem(){}
};
// Construction
public:
CCalculateValuesPg1();
~CCalculateValuesPg1();
std::list<CCalcValue> m_listCalcValues;
// Dialog Data
//{{AFX_DATA(CCalculateValuesPg1)
enum { IDD = IDD_KEY_CALCULATEVALUES_PG1 };
CTabCtrl m_tcNames;
CEdit m_eInputDesc;
CEditGrid m_egNames;
CEditGrid m_egBasic;
//}}AFX_DATA
CBasicDesc2 m_basicDesc;
protected:
void DDX_RateList(CDataExchange *pDX);
BOOL GetRate(long nRowIndex, CCalcValue* pCalcValue)const;
CString GetRateName(long nRowIndex)const;
BOOL DeleteRate(long nRowIndex);
void InsertRate(long nRowIndex, CCalcValue& calcValue);
void DisplayTab(int nTabIndex);
BOOL SetRateName(long nRowIndex, LPCTSTR lpszRateName);
// Overrides
// ClassWizard generate virtual function overrides
//{{AFX_VIRTUAL(CCalculateValuesPg1)
protected:
virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV support
//}}AFX_VIRTUAL
protected:
// Implementation
protected:
std::map<CString, CString> m_mapFuncs;
std::list<XGridTabItem> m_listItems;
bool m_bRenumbering;
#ifdef _DEBUG
virtual void AssertValid() const;
virtual void Dump(CDumpContext& dc) const;
#endif
// Generated message map functions
//{{AFX_MSG(CCalculateValuesPg1)
virtual BOOL OnInitDialog();
afx_msg void OnSelchangeLbFuncs();
afx_msg void OnSelchangeTcNames(NMHDR* pNMHDR, LRESULT* pResult);
afx_msg void OnSelchangingTcNames(NMHDR* pNMHDR, LRESULT* pResult);
afx_msg void OnKeyDownMshfgNames(short FAR* KeyCode, short Shift);
afx_msg void OnSize(UINT nType, int cx, int cy);
afx_msg void OnEnterCellMshfgNames();
afx_msg void OnSetfocusLbFuncs();
afx_msg void OnSetfocusEExplan();
afx_msg void OnSetfocusLbArgs();
afx_msg void OnEnterCellMshfgBasic();
afx_msg void OnKeyDownMshfgBasic(short FAR* KeyCode, short Shift);
afx_msg void OnBRenumber();
afx_msg BOOL OnHelpInfo(HELPINFO* pHelpInfo);
afx_msg void OnSetfocusTreeArgs(NMHDR* pNMHDR, LRESULT* pResult);
DECLARE_EVENTSINK_MAP()
//}}AFX_MSG
// custom BN_SETFOCUS notifications
afx_msg void OnSetfocusBRenumber();
// custom grid handlers
afx_msg LRESULT OnBeginCellEdit(WPARAM wParam, LPARAM lParam);
afx_msg LRESULT OnEndCellEdit(WPARAM wParam, LPARAM lParam);
afx_msg LRESULT OnSetfocusGrid(WPARAM wParam, LPARAM lParam);
DECLARE_MESSAGE_MAP()
};
#endif // __CCALCULATEVALUESPG1_H__