Ejemplo n.º 1
0
        private void FormMain_FormClosing(object sender, FormClosingEventArgs e)
        {
            if (m_dlgShadowAnalysis != null)
            {
                m_dlgShadowAnalysis.Dispose();
                m_dlgShadowAnalysis = null;
            }
            if (m_dlgSightline != null)
            {
                m_dlgSightline.Dispose();
                m_dlgSightline = null;
            }
            if (m_dlgSkyline != null)
            {
                m_dlgSkyline.Dispose();
                m_dlgSkyline = null;
            }
            if (m_dlgProfileAnalysis != null)
            {
                m_dlgProfileAnalysis.Dispose();
                m_dlgProfileAnalysis = null;
            }

            if (m_dlgSunTrajectory != null)
            {
                m_dlgSunTrajectory.Dispose();
                m_dlgSunTrajectory = null;
            }
            if (m_dlgFloodAnalysis != null)
            {
                m_dlgFloodAnalysis.Dispose();
                m_dlgFloodAnalysis = null;
            }

            if (m_dlgClipPlane != null)
            {
                m_dlgClipPlane.Dispose();
                m_dlgClipPlane = null;
            }

            if (m_dlgContourMap != null)
            {
                m_dlgContourMap.Dispose();
                m_dlgContourMap = null;
            }

            if (m_dlgSlopeMap != null)
            {
                m_dlgSlopeMap.Dispose();
                m_dlgSlopeMap = null;
            }
            this.m_sceneControl.Scene.Close();
            this.workspace.Datasources.CloseAll();
            m_sceneControl.Dispose();
        }
Ejemplo n.º 2
0
        //剖面线分析
        private void Profile_ToolStripMenuItem_Click(object sender, EventArgs e)
        {
            this.panelDiagram.Visible = false;

            if (m_sceneControl.Scene.Name != "Model")
            {
                m_sceneControl.Scene.Layers.Clear();
                m_sceneControl.Scene.TerrainLayers.Clear();
                m_sceneControl.Scene.Open("Model");
            }
            if (m_dlgProfileAnalysis == null || m_dlgProfileAnalysis.IsDisposed)
            {
                m_dlgProfileAnalysis = new DlgProfileAnalysis();
            }

            m_dlgProfileAnalysis.Initialize(workspace, m_sceneControl);
            m_dlgProfileAnalysis.Show();

            //刷新场景,保证数据更新出来
            m_sceneControl.Scene.Refresh();
        }