Exemplo n.º 1
0
        /// <summary>
        /// Initiates an IPE session or terminates it
        /// </summary>
        public static void SetIPE(IExternalInput target = null, CGModuleEditorBase initiatedBy = null)
        {
            
            if (InPlaceEditTarget != null)
                InPlaceEditTarget.EndIPE();

            InPlaceEditInitiatedBy = initiatedBy;

            if (target != null)
            {
                InPlaceEditTarget = initiatedBy.Graph.GetModuleEditor((CGModule)target);

                if (SceneView.currentDrawingSceneView)
                    SceneView.currentDrawingSceneView.Focus();

                SyncIPE();
                InPlaceEditTarget.BeginIPE();
            }
        }
Exemplo n.º 2
0
 public void destroyEditors()
 {
     var ed = new List<CGModuleEditorBase>(ModuleEditors.Values);
     for (int i = ed.Count - 1; i >= 0; i--)
         DestroyImmediate(ed[i]);
     ModuleEditors.Clear();
     InPlaceEditTarget = null;
     InPlaceEditInitiatedBy = null;
 }