www.pudn.com > GroupCombo_demo.zip > ComboGroup.h


#if !defined(AFX_COMBOGROUP_H__3663AEAD_7E87_48CE_931D_B81973630015__INCLUDED_) 
#define AFX_COMBOGROUP_H__3663AEAD_7E87_48CE_931D_B81973630015__INCLUDED_ 
 
#if _MSC_VER > 1000 
#pragma once 
#endif // _MSC_VER > 1000 
// ComboGroup.h : header file 
// 
#include "DynamicCombo.h" 
///////////////////////////////////////////////////////////////////////////// 
// CComboGroup window 
class CDynamicCombo; 
 
class CStrNode 
{ 
public: 
    CStrNode * pNext; 
    CString    s; 
    CStrNode() { pNext = NULL; }; 
}; 
 
class CComboGroup : public CStatic 
{ 
// Construction 
public: 
	CComboGroup(); 
 
// Attributes 
public: 
 
// Operations 
public: 
    CDynamicCombo* pComboListHead; 
    CStrNode * pStrListHead; 
// Overrides 
	// ClassWizard generated virtual function overrides 
	//{{AFX_VIRTUAL(CComboGroup) 
	//}}AFX_VIRTUAL 
 
// Implementation 
private: 
    	void DeleteAllStrings(); 
public: 
	UINT GetCurIndex(int BoxNum); 
	CString GetBoxSelStr(int BoxNum); 
	void AddRemainingStrings(); 
	bool AllValuesSelected(); 
	void SelChanged(CDynamicCombo* box); 
	CString GetListString(int strIndex); 
	void AddComboBox(CDynamicCombo* box); 
	int numStringsAdded; 
	int numBoxesInGroup; 
	void AddSelectionString(CString string); 
	virtual ~CComboGroup(); 
 
	// Generated message map functions 
protected: 
    void MakeSelectedStringUnAvail(CString *str, int excludeBox); 
	void MakeSelectionStringAvail(CString* str, int excludeBox); 
 
	//{{AFX_MSG(CComboGroup) 
	//}}AFX_MSG 
 
	DECLARE_MESSAGE_MAP() 
}; 
 
///////////////////////////////////////////////////////////////////////////// 
 
//{{AFX_INSERT_LOCATION}} 
// Microsoft Visual C++ will insert additional declarations immediately before the previous line. 
 
#endif // !defined(AFX_COMBOGROUP_H__3663AEAD_7E87_48CE_931D_B81973630015__INCLUDED_)