示例#1
0
        /// <summary>
        /// Displays a list of available types to use to repair the reference.
        /// </summary>
        /// <param name="typeOptions">The types that the user can choose from to repair the reference.</param>
        /// <param name="serializedTypeProperty">The serialized property that's missing the reference.</param>
        public static void Display(Type[] typeOptions, SerializedProperty serializedTypeProperty)
        {
            if (window != null)
            {
                window.Close();
            }

            repairedTypeOptions = typeOptions;
            property            = serializedTypeProperty;

            window = CreateInstance(typeof(SystemTypeRepairWindow)) as SystemTypeRepairWindow;
            Debug.Assert(window != null);
            window.titleContent = WindowTitleContent;
            window.ShowUtility();
        }
示例#2
0
 private void OnDisable() => window = null;