Пример #1
0
        public static void Show(FieldInfo fieldInfo, SerializedProperty serializedProperty)
        {
            // Reset to Default Values
            _fieldInfo          = fieldInfo;
            _serializedProperty = serializedProperty;

            // Set _searchString to the value of the serialized property.
            var syringe = SyringePropertyDrawer.GetSelectedValueFromSerializedProperty(fieldInfo, serializedProperty, out _arrayIndex, out _listIndex);

            _searchString = syringe == null ? "" : syringe.FullName;

            // Open the SyringeEditorWindow near the InspectorWindow.
            GetWindowWithRect(typeof(SyringeEditorWindow), GetWindow(Type.GetType(typeof(EditorWindow).AssemblyQualifiedName.Replace("EditorWindow", "InspectorWindow"))).position, true, "Syringe - Select Type");
        }