#pragma once #include "resource.h" #include "afxwin.h" #include "GsPreviewCtrl.h" #include "EarThwormDef.h" class AecDbX3dGroup; class CYXKKDlg : public CDialog { DECLARE_DYNAMIC(CYXKKDlg) public: CYXKKDlg(CWnd* pParent = NULL); virtual ~CYXKKDlg(); enum { IDD = IDD_YXKK_DLG }; void SetCrossSectionScr(LPCTSTR psz){ m_sCrossSectionScr = psz; } int GetX3dSolidRecs( AecDbX3dGroup*& group); int GetX3dSolidRecsShEw(AecDbX3dGroup*& pGroup); void SetEWFittingId(AcDbObjectId& id) {m_idEWFit = id;} protected: virtual void DoDataExchange(CDataExchange* pDX); DECLARE_MESSAGE_MAP() public: virtual BOOL OnInitDialog(); afx_msg void OnBnClickedRadio1(); afx_msg void OnBnClickedRadio13(); afx_msg void OnBnClickedOk(); afx_msg LRESULT OnViewLButtonDown(WPARAM wp,LPARAM lp); afx_msg void OnBnClickedButton1(); afx_msg void OnBnClickedButton2(); afx_msg void OnBnClickedButton3(); afx_msg void OnBnClickedButton4(); protected: void ShowEarthWorm(); //sh void ShowShEarthWorm(); void ShowAddtion(); void ShowRoomName(); void ExtractRegionRooms(); void FormatAddtionScr(); void ShowEwSection(); void ExtrAddtionToMap( ); STSection* GetShEwSection() const; void HitEarthWorm(int idxRoom); void HitShEarthWorm(int idxRoom); LRESULT OnViewShEwLButtonDown(WPARAM wp, LPARAM lp); public: double m_dL1; double m_dL2; double m_dL3; int m_nShape; int m_nPos; BOOL m_bAllEw; double m_dW1; int m_idxRoom; CString m_sCrossSectionScr; int m_nH; int m_nV; double m_dHSpace; double m_dVSpace; BOOL m_bSpecThick; double m_dSpecThick; BOOL m_bAddHoleCase; public: AcDbObjectId m_idEWFit; CGsPreviewCtrl m_wndViewCtrl; AcDbPolyline* m_pRectCell; CString m_sMaterial; CString m_sPoints; CString m_sPointsIn; BOOL m_bAddHoop; double m_dX; double m_dY; double m_dZ; double m_dt; protected://sh // 缓存,出图用 AcDbVoidPtrArray m_arDrawBuffer; //附属脚本如支架 CMapStringToString m_mapAddtion; //所有的舱室 AcDbVoidPtrArray m_arRegionRooms; // 舱体类型 std::vector m_roomTypes; CMapStringToPtr m_mapIndexToDbText; //点击的舱室 AcDbEntity* m_pRegionRoom; // 当前所选的截面描述 STSection m_curSection; CString m_sAddtionScr; //舱室名称和偏移 CMapStringToString m_mapIndexToName; public: double m_dHoleH; };