Пример #1
0
 public static Editor CreateEditor(UnityEngine.Object targetObject, [DefaultValue("null")] Type editorType)
 {
     return(Editor.CreateEditorWithContext(new UnityEngine.Object[]
     {
         targetObject
     }, null, editorType));
 }
Пример #2
0
 public static void CreateCachedEditorWithContext(UnityEngine.Object[] targetObjects, UnityEngine.Object context, Type editorType, ref Editor previousEditor)
 {
     if (!(previousEditor != null) || !ArrayUtility.ArrayEquals <UnityEngine.Object>(previousEditor.m_Targets, targetObjects) || !(previousEditor.m_Context == context))
     {
         if (previousEditor != null)
         {
             UnityEngine.Object.DestroyImmediate(previousEditor);
         }
         previousEditor = Editor.CreateEditorWithContext(targetObjects, context, editorType);
     }
 }
Пример #3
0
        public static Editor CreateEditorWithContext(UnityEngine.Object[] targetObjects, UnityEngine.Object context)
        {
            Type editorType = null;

            return(Editor.CreateEditorWithContext(targetObjects, context, editorType));
        }