using UnityEngine; using UnityEditor; using UnityEditor.UIElements; using UnityEngine.UIElements; namespace UnityEngine.Perception.Randomization.Editor { class FloatRangeElement : VisualElement { public FloatRangeElement(SerializedProperty property) { var template = AssetDatabase.LoadAssetAtPath($"{StaticData.uxmlDir}/FloatRangeElement.uxml"); template.CloneTree(this); var minimumField = this.Q("minimum"); minimumField.bindingPath = property.propertyPath + ".minimum"; var maximumField = this.Q("maximum"); maximumField.bindingPath = property.propertyPath + ".maximum"; this.Bind(property.serializedObject); } } }