#if !defined(AFX_CHECKPIPEDLG_H__23F5D4B4_08C0_42B0_A3DB_35D217F53824__INCLUDED_) #define AFX_CHECKPIPEDLG_H__23F5D4B4_08C0_42B0_A3DB_35D217F53824__INCLUDED_ #if _MSC_VER > 1000 #pragma once #endif // _MSC_VER > 1000 #include "resource.h" #include "ccolorbutton.h" #include "SymbDialog.h" class CEditOutdoorPipeDlg : public CModelessDialog { public: CEditOutdoorPipeDlg(CWnd* pParent = NULL); virtual ~CEditOutdoorPipeDlg(); //初始化不同管径对应的颜色 void InitPipeColor(); //初始化按钮颜色 void InitBtnColor(); //根据管径改变选中管线的颜色 void InitPipeDnGradient(); //设定按钮颜色 void SetBtnColor(); //设定按钮文字 void SetBtnText(); //获取用户选则的管线类型 int GetPipeSys(); //设定选中的管线 void SetPipes(PickSet &ss); //获取不同管径对应的管线颜色 BOOL GetPipeColor(int &nColor, double dDn); //获取管线原始颜色 void GetPipeOriginColor(PickSet &ssSel); //恢复管线原始颜色 void RecoverPipeOriginColor(); //设定选中管线的管径和坡度 void ChangePipeColorDnGradient(); //覆盖管线原始颜色 void ChangePipeColor(PickSet &ssSel); //设置list显示内容 void SetGradientList(); //闪烁函数 void ShowPipe(bool bIsShow); //用户手动更新管线 void SetPipeBySel(); //根据按钮状态设置管径和坡度 void GetButtonAct(const int &iIndex); DECLARE_DYNAMIC(CEditOutdoorPipeDlg) //{{AFX_DATA enum { IDD = IDD_EDIT_OUTDOORPIPE }; CButton m_wndBtnSetPipe; CButton m_wndBtnChange; CScrollBar m_wndScrollBar; CListBox m_wndLstGradient; double m_dDn; CString m_sGradient; //}}AFX_DATA //{{AFX_VIRTUAL protected: virtual void DoDataExchange(CDataExchange* pDX); //}}AFX_VIRTUAL protected: //{{AFX_MSG virtual BOOL OnInitDialog(); afx_msg void OnVScroll(UINT nSBCode, UINT nPos, CScrollBar* pScrollBar); afx_msg void OnRadioDn1(); afx_msg void OnRadioDn2(); afx_msg void OnRadioDn3(); afx_msg void OnRadioDn4(); afx_msg void OnRadioDn5(); afx_msg void OnRadioDn6(); afx_msg void OnRadioDn7(); afx_msg void OnRadioDn8(); afx_msg void OnRadioDn9(); afx_msg void OnSelchangeLstGradient(); afx_msg void OnTimer(UINT_PTR nIDEvent); afx_msg void OnClose(); afx_msg void OnBtnSetPipe(); afx_msg void OnChangeEditGradient(); afx_msg void OnSelChangeCmbPipesys(); afx_msg void OnBtnChangePipeByUser(); //}}AFX_MSG public: virtual BOOL DestroyWindow(); DECLARE_MESSAGE_MAP() private: CColorButton m_wndBtn[9]; //9个按钮变量 int m_nCurPos; //当前CSROLLBAR位置 bool m_bIsVisible; //闪烁变量 int m_iPipeSys; //系统类型 static int m_iPipeDn; //记忆按钮状态 double m_dGradient; std::vector m_vecIdAll; //保存选中管线 std::vector m_vecIdSel; //保存相应系统类型的管线 std::vector m_vecIdPipe; //保存闪烁管线 std::map m_mapBtnColor; //不同管径对应的按钮颜色值 std::map m_mapPipeColor; //不同管径对应的颜色值 std::map m_mapOriginColor; //管道对应的原始颜色 std::map > m_mapPipeGradient; //不同管径对应的坡度值 }; //{{AFX_INSERT_LOCATION}} // Microsoft Visual C++ will insert additional declarations immediately before the previous line. #endif // !defined(AFX_CHECKPIPEDLG_H__23F5D4B4_08C0_42B0_A3DB_35D217F53824__INCLUDED_)