private void frmMain_FormClosing(object sender, FormClosingEventArgs e)
 {
     GlobeControl.Dispose();
     MapControl.Dispose();
     TOCControl.Dispose();
     ESRI.ArcGIS.ADF.COMSupport.AOUninitialize.Shutdown();
 }
Example #2
0
        public Form1()
        {
            InitializeComponent();

            this.Closing += new CancelEventHandler(Form1_Closing);

            // create the control and set Forms properties.
            this.globeControl = new GlobeControl();
            this.SuspendLayout();
            this.globeControl.Location = new System.Drawing.Point(0, 0);
            this.globeControl.Name     = "globeControl";
//            this.globeControl.Size = this.ClientSize;
//            this.globeControl.Anchor = AnchorStyles.Left | AnchorStyles.Right | AnchorStyles.Top | AnchorStyles.Bottom;
            this.globeControl.Dock     = DockStyle.Fill;
            this.globeControl.TabIndex = 0;
//            this.globeControl.SendToBack(); // we want the button to be on top

            this.toolStripContainer1.ContentPanel.Controls.Add(this.globeControl);
            this.ResumeLayout(false);

            this.loader = PlugInLoader.CreateLoader(this.globeControl.Host);

            // at this stage, it is safe to attach events to the control, but otherwise wait until Initialized.
            this.globeControl.Host.RenderEngine.Initialized += new EventHandler(Initialized);
        }
Example #3
0
    // Use this for initialization
    void Start()
    {
        cam                   = Camera.main;
        globeState            = GlobeState.IDLE;
        spinScript.globeState = (GlobeControl.GlobeState)GlobeState.IDLE;
        spinScript            = globe.GetComponent <GlobeControl>();

        rots  = new LinkedList <Quaternion> ();
        times = new LinkedList <float> ();
    }