Example #1
0
        /// <summary>
        /// Launch the editor
        /// </summary>
        /// <param name="storage">Storage to use</param>
        public void RunEditor(StorageBase storage)
        {
            bool mousestate = Mouse.Visible;

            Mouse.Visible = true;

            if (Window != null)
            {
                Window.Hide();
            }

            Editor = new EditorMainForm(storage);
            OnEditorEnter(Editor);
            Editor.ShowDialog();
            Editor = null;
            OnEditorLeave();

            if (Window != null)
            {
                Window.MakeCurrent();
                Window.Show();
                Window.BringToFront();
            }
            Mouse.Visible = mousestate;
        }
Example #2
0
 /// <summary>
 /// Method for raising the EditorEnter event.
 /// </summary>
 public virtual void OnEditorEnter(EditorMainForm form)
 {
     if (EditorEnter != null)
     {
         EditorEventArgs evt = new EditorEventArgs(form);
         EditorEnter(this, evt);
     }
 }