public override void EditProperty(EditHelp helper, SerializedProperty property) { helper.StartHelp(m_helpText); EditorGUILayout.Slider(property, m_minimum, m_maximum, m_label); helper.EndHelp(); }
public virtual void EditProperty(EditHelp helper, SerializedProperty property) { helper.StartHelp(m_helpText); EditorGUILayout.PropertyField(property, new GUIContent(m_label)); helper.EndHelp(); }
public override void EditProperty(EditHelp helper, SerializedProperty property) { string contextHelp; try { contextHelp = m_enumHelpLines[property.enumValueIndex]; } catch (System.IndexOutOfRangeException) { contextHelp = "ERROR: Due to version incompatibilities, you need to re-set this value"; } helper.StartHelp(m_helpText + "\n\n" + contextHelp); EditorGUILayout.PropertyField(property, new GUIContent(m_label)); helper.EndHelp(); }
public override void EditProperty(EditHelp helper, SerializedProperty property) { helper.StartHelp(m_helpText); EditorGUILayout.BeginVertical(); foldoutVisible = EditorGUILayout.Foldout(foldoutVisible, new GUIContent(m_label)); if (foldoutVisible) { EditorGUILayout.BeginHorizontal(); GUILayout.Space(10); EditorGUILayout.BeginVertical(GUILayout.ExpandWidth(true)); for (int i = 0; i < property.arraySize; ++i) { SerializedProperty childProperty = property.GetArrayElementAtIndex(i); EditorGUILayout.BeginHorizontal(GUI.skin.box); string propertyName = string.Format("{0} {1}", m_itemName, i); EditorGUILayout.PropertyField(childProperty, new GUIContent(propertyName), true);; if (GUILayout.Button("Del", GUILayout.ExpandWidth(false))) { property.DeleteArrayElementAtIndex(i); } EditorGUILayout.EndHorizontal(); } EditorGUILayout.BeginHorizontal(); GUILayout.FlexibleSpace(); if (GUILayout.Button("Add", GUILayout.ExpandWidth(false))) { property.arraySize = property.arraySize + 1; } EditorGUILayout.EndHorizontal(); EditorGUILayout.EndVertical(); EditorGUILayout.EndHorizontal(); } EditorGUILayout.EndVertical(); helper.EndHelp(); }
public override void EditProperty(EditHelp helper, SerializedProperty property) { helper.StartHelp(m_helpText); property.stringValue = EditorGUILayout.TagField(m_label, property.stringValue); helper.EndHelp(); }
public override void EditProperty(EditHelp helper, SerializedProperty property) { helper.StartHelp(m_helpText + "\n\n" + (property.boolValue ? m_trueHelp : m_falseHelp)); EditorGUILayout.PropertyField(property, new GUIContent(m_label)); helper.EndHelp(); }