Browse Source

WIP: UndoRedo refactor distribution GUI elements updated so they can handle undo-redo better

BearishSun 6 years ago
parent
commit
a6087a3ef3

+ 143 - 36
Source/EditorCore/GUI/BsGUIFloatDistributionField.cpp

@@ -30,6 +30,81 @@ namespace bs
 	/** Spacing between two internal elements, in pixels. */
 	static constexpr UINT32 ELEM_SPACING = 5;
 
+	namespace impl
+	{
+		template<class T, class F>
+		void addOnConfirmCallback(T* field, F func)
+		{
+			field->onConfirm.connect([func]() { func(VectorComponent::X); });
+		}
+
+		template<class F>
+		void addOnConfirmCallback(GUIVector2Field* field, F func)
+		{
+			field->onConfirm.connect([func](VectorComponent x) { func(x); });
+		}
+
+		template<class F>
+		void addOnConfirmCallback(GUIVector3Field* field, F func)
+		{
+			field->onConfirm.connect([func](VectorComponent x) { func(x); });
+		}
+
+		template<class T, class F>
+		void addOnValueChangedCallback(T* field, F func)
+		{
+			field->onValueChanged.connect([func](float val) { func(val, VectorComponent::X); });
+		}
+
+		template<class F>
+		void addOnValueChangedCallback(GUIVector2Field* field, F func)
+		{
+			field->onComponentChanged.connect([func](float val, VectorComponent x) { func(val, x); });
+		}
+
+		template<class F>
+		void addOnValueChangedCallback(GUIVector3Field* field, F func)
+		{
+			field->onComponentChanged.connect([func](float val, VectorComponent x) { func(val, x); });
+		}
+
+		template<class T, class F>
+		void addOnInputChangedCallback(T* field, F func)
+		{
+			field->onFocusChanged.connect([func](bool val) { func(val, VectorComponent::X); });
+		}
+
+		template<class F>
+		void addOnInputChangedCallback(GUIVector2Field* field, F func)
+		{
+			field->onComponentFocusChanged.connect([func](bool val, VectorComponent x) { func(val, x); });
+		}
+
+		template<class F>
+		void addOnInputChangedCallback(GUIVector3Field* field, F func)
+		{
+			field->onComponentFocusChanged.connect([func](bool val, VectorComponent x) { func(val, x); });
+		}
+
+		template<class T>
+		void setFocus(T* field, VectorComponent component, bool focus)
+		{
+			field->setFocus(focus);
+		}
+
+		template<>
+		void setFocus(GUIVector2Field* field, VectorComponent component, bool focus)
+		{
+			field->setInputFocus(component, focus);
+		}
+
+		template<>
+		void setFocus(GUIVector3Field* field, VectorComponent component, bool focus)
+		{
+			field->setInputFocus(component, focus);
+		}
+	}
+
 	template<class T, class SELF>
 	TGUIDistributionField<T, SELF>::TGUIDistributionField(const PrivatelyConstruct& dummy, const GUIContent& labelContent, 
 		UINT32 labelWidth, const String& style, const GUIDimensions& dimensions, bool withLabel)
@@ -166,6 +241,33 @@ namespace bs
 		return false;
 	}
 
+	template <class T, class SELF>
+	void TGUIDistributionField<T, SELF>::setInputFocus(RangeComponent rangeComponent, VectorComponent vectorComponent, bool focus)
+	{
+		switch(mPropertyType)
+		{
+		case PDT_Constant:
+		case PDT_RandomRange:
+			if(rangeComponent == RangeComponent::Min)
+				impl::setFocus(mMinInput, vectorComponent, focus);
+			else
+				impl::setFocus(mMaxInput, vectorComponent, focus);
+
+			break;
+		case PDT_Curve:
+		case PDT_RandomCurveRange:
+		{
+			for (UINT32 i = 0; i < NumComponents; i++)
+			{
+				if ((VectorComponent)i == vectorComponent && mCurveDisplay[i])
+					mCurveDisplay[i]->setFocus(focus);
+			}
+		}
+			break;
+		}
+		
+	}
+
 	template<class T, class SELF>
 	void TGUIDistributionField<T, SELF>::setTint(const Color& color)
 	{
@@ -277,24 +379,6 @@ namespace bs
 		}
 	}
 
-	template<class T, class F> 
-	void addOnConfirmCallback(T* field, F func)
-	{
-		field->onConfirm.connect(func);
-	}
-
-	template<class F> 
-	void addOnConfirmCallback(GUIVector2Field* field, F func)
-	{
-		field->onConfirm.connect([func](VectorComponent) { func(); });
-	}
-
-	template<class F> 
-	void addOnConfirmCallback(GUIVector3Field* field, F func)
-	{
-		field->onConfirm.connect([func](VectorComponent) { func(); });
-	}
-
 	template<class T, class SELF>
 	void TGUIDistributionField<T, SELF>::rebuild()
 	{
@@ -320,14 +404,22 @@ namespace bs
 				mCurveDisplay[i] = nullptr;
 
 			mMinInput->setValue(mMinConstant);
-			mMinInput->onValueChanged.connect([this](T value)
+
+			impl::addOnValueChangedCallback(mMinInput, [this](float value, VectorComponent component)
 			{
-				mMinConstant = value;
-				mValue = TDistribution<T>(value);
+				mMinConstant = mMinInput->getValue();
+				mValue = TDistribution<T>(mMinConstant);
 
-				onConstantModified();
+				onConstantModified(RangeComponent::Min, component);
+			});
+			impl::addOnConfirmCallback(mMinInput, [this](VectorComponent component)
+			{
+				onConstantConfirmed(RangeComponent::Min, component);
+			});
+			impl::addOnInputChangedCallback(mMinInput, [this](bool focus, VectorComponent component)
+			{
+				onConstantFocusChanged(focus, RangeComponent::Min, component);
 			});
-			addOnConfirmCallback(mMinInput, [this]() { onConstantConfirmed(); });
 
 			valueLayout->addElement(mMinInput);
 			break;
@@ -339,24 +431,40 @@ namespace bs
 				mCurveDisplay[i] = nullptr;
 
 			mMinInput->setValue(mMinConstant);
-			mMinInput->onValueChanged.connect([this](T value)
+
+			impl::addOnValueChangedCallback(mMinInput, [this](float value, VectorComponent component)
 			{
-				mMinConstant = value;
-				mValue = TDistribution<T>(value, mMaxConstant);
+				mMinConstant = mMinInput->getValue();
+				mValue = TDistribution<T>(mMinConstant, mMaxConstant);
 
-				onConstantModified();
+				onConstantModified(RangeComponent::Min, component);
+			});
+			impl::addOnConfirmCallback(mMinInput, [this](VectorComponent component)
+			{
+				onConstantConfirmed(RangeComponent::Min, component);
+			});
+			impl::addOnInputChangedCallback(mMinInput, [this](bool focus, VectorComponent component)
+			{
+				onConstantFocusChanged(focus, RangeComponent::Min, component);
 			});
-			addOnConfirmCallback(mMinInput, [this]() { onConstantConfirmed(); });
 
 			mMaxInput->setValue(mMaxConstant);
-			mMaxInput->onValueChanged.connect([this](T value)
+
+			impl::addOnValueChangedCallback(mMaxInput, [this](float value, VectorComponent component)
 			{
-				mMaxConstant = value;
-				mValue = TDistribution<T>(mMinConstant, value);
+				mMaxConstant = mMaxInput->getValue();
+				mValue = TDistribution<T>(mMinConstant, mMaxConstant);
 
-				onConstantModified();
+				onConstantModified(RangeComponent::Max, component);
+			});
+			impl::addOnConfirmCallback(mMaxInput, [this](VectorComponent component)
+			{
+				onConstantConfirmed(RangeComponent::Max, component);
+			});
+			impl::addOnInputChangedCallback(mMaxInput, [this](bool focus, VectorComponent component)
+			{
+				onConstantFocusChanged(focus, RangeComponent::Max, component);
 			});
-			addOnConfirmCallback(mMaxInput, [this]() { onConstantConfirmed(); });
 
 			mLabels[0] = valueLayout->addNewElement<GUILabel>(HString("Min."), "HeaderLight");
 			valueLayout->addElement(mMinInput);
@@ -386,13 +494,12 @@ namespace bs
 
 				mCurveDisplay[i]->setPadding(3);
 				mCurveDisplay[i]->centerAndZoom();
-				mCurveDisplay[i]->onClicked.connect([this,i]() { onClicked(i); });
+				mCurveDisplay[i]->onClicked.connect([this,i]() { onClicked((VectorComponent)i); });
 
 				if(i != 0)
 					valueLayout->addNewElement<GUIFixedSpace>(ELEM_SPACING);
 
 				valueLayout->addElement(mCurveDisplay[i]);
-
 			}
 
 			break;
@@ -417,7 +524,7 @@ namespace bs
 				mCurveDisplay[i]->setCurveRange(mMinCurve[i], mMaxCurve[i]);
 				mCurveDisplay[i]->setPadding(3);
 				mCurveDisplay[i]->centerAndZoom();
-				mCurveDisplay[i]->onClicked.connect([this,i]() { onClicked(i); });
+				mCurveDisplay[i]->onClicked.connect([this,i]() { onClicked((VectorComponent)i); });
 
 				if(i != 0)
 					valueLayout->addNewElement<GUIFixedSpace>(ELEM_SPACING);

+ 29 - 9
Source/EditorCore/GUI/BsGUIFloatDistributionField.h

@@ -69,26 +69,46 @@ namespace bs
 		BS_SCRIPT_EXPORT(pr:getter,n:HasInputFocus)
 		bool hasInputFocus() const;
 
+		/** 
+		 * Sets input focus to a specific component's input box. 
+		 *
+		 * @param[in]	rangeComponent		Whether to focus on the minimum or the maximum part of the range. Only relevant
+		 *									if the distribution represents a constant range.
+		 * @param[in]	vectorComponent		Vector component to focus on. Only relevant of the distribution constant is
+		 *									a vector type, and if the current distribution type is a non-curve (constant)
+		 *									type.
+		 * @param[in]	focus				True to enable focus, false to disable.
+		 */
+		BS_SCRIPT_EXPORT()
+		void setInputFocus(RangeComponent rangeComponent, VectorComponent vectorComponent, bool focus);
+
 		/** 
 		 * Triggered when the user clicks on the curve display. Only relevant if the distribution is a curve distribution. 
-		 * Provides the sequential index of the clicked curve (0 - x, 1 - y, 2 - z).
+		 * Provides the index of the clicked curve.
 		 */
 		BS_SCRIPT_EXPORT(in:true)
-		Event<void(INT32)> onClicked;
+		Event<void(VectorComponent)> onClicked;
 
 		/** 
-		 * Triggered when the user modifies either of the non-curve (constant) values of the distribution. Only relevant
+		 * Triggered when the user modifies the value of the non-curve (constant) values of the distribution. Only relevant 
 		 * if the distribution is not a curve distribution.
 		 */
-		BS_SCRIPT_EXPORT(in:true)
-		Event<void()> onConstantModified;
+		BS_SCRIPT_EXPORT()
+		Event<void(RangeComponent, VectorComponent)> onConstantModified;
 
 		/** 
-		 * Triggered when the user confirms inputs in either of the non-curve (constant) values of the distribution. Only 
-		 * relevant if the distribution is not a curve distribution.
+		 * Triggered when the user confirms inputs in the non-curve (constant) values of the distribution. Only relevant 
+		 * if the distribution is not a curve distribution.
 		 */
-		BS_SCRIPT_EXPORT(in:true)
-		Event<void()> onConstantConfirmed;
+		BS_SCRIPT_EXPORT()
+		Event<void(RangeComponent, VectorComponent)> onConstantConfirmed;
+
+		/**	
+		 * Triggered when a GUI field representing an individual component loses or gains focus. This only applies to
+		 * input fields representing the non-curve (constant) distribution types.
+		 */
+		BS_SCRIPT_EXPORT()
+		Event<void(bool, RangeComponent, VectorComponent)> onConstantFocusChanged;
 
 		/** @name Internal 
 		 *  @{

+ 5 - 20
Source/EditorManaged/GUI/GUIFloatDistributionField.cs

@@ -6,16 +6,11 @@ namespace bs.Editor
     partial class GUIFloatDistributionField
     {
         /// <summary>
-        /// Triggered when the distribution in the field changes.
+        /// Triggered when one of the curves in the distribution changes.
         /// </summary>
-        public event Action OnChanged;
+        public event Action OnCurveChanged;
 
-        /// <summary>
-        /// Triggered whenever user confirms input in one of the floating point fields.
-        /// </summary>
-        public event Action OnConfirmed;
-
-        partial void OnClicked(int component)
+        partial void OnClicked(VectorComponent component)
         {
             FloatDistribution distribution = Value;
 
@@ -27,7 +22,7 @@ namespace bs.Editor
                         return;
 
                     Value = new FloatDistribution(curve);
-                    OnChanged?.Invoke();
+                    OnCurveChanged?.Invoke();
                 });
             }
             else if (DistributionType == PropertyDistributionType.RandomCurveRange)
@@ -39,19 +34,9 @@ namespace bs.Editor
                             return;
 
                         Value = new FloatDistribution(minCurve, maxCurve);
-                        OnChanged?.Invoke();
+                        OnCurveChanged?.Invoke();
                     });
             }
         }
-
-        partial void OnConstantModified()
-        {
-            OnChanged?.Invoke();
-        }
-
-        partial void OnConstantConfirmed()
-        {
-            OnConfirmed?.Invoke();
-        }
     }
 }

+ 13 - 29
Source/EditorManaged/GUI/GUIVector2DistributionField.cs

@@ -6,35 +6,30 @@ namespace bs.Editor
     partial class GUIVector2DistributionField
     {
         /// <summary>
-        /// Triggered when the distribution in the field changes.
+        /// Triggered when one of the curves in the distribution changes.
         /// </summary>
-        public event Action OnChanged;
+        public event Action OnCurveChanged;
 
-        /// <summary>
-        /// Triggered whenever user confirms input in one of the floating point fields.
-        /// </summary>
-        public event Action OnConfirmed;
-
-        partial void OnClicked(int component)
+        partial void OnClicked(VectorComponent component)
         {
+            int componentIdx = (int) component;
             Vector2Distribution distribution = Value;
 
             if (DistributionType == PropertyDistributionType.Curve)
             {
                 AnimationCurve[] curves = AnimationUtility.SplitCurve2D(distribution.GetMinCurve());
-                if (component < curves.Length)
+                if (componentIdx < curves.Length)
                 {
-                    CurveEditorWindow.Show(curves[component], (success, curve) =>
+                    CurveEditorWindow.Show(curves[componentIdx], (success, curve) =>
                     {
                         if (!success)
                             return;
 
-                        curves[component] = curve;
+                        curves[componentIdx] = curve;
 
                         Vector2Curve compoundCurve = AnimationUtility.CombineCurve2D(curves);
                         Value = new Vector2Distribution(compoundCurve);
-                        OnChanged?.Invoke();
-                        OnConfirmed?.Invoke();
+                        OnCurveChanged?.Invoke();
                     });
                 }
             }
@@ -43,36 +38,25 @@ namespace bs.Editor
                 AnimationCurve[] minCurves = AnimationUtility.SplitCurve2D(distribution.GetMinCurve());
                 AnimationCurve[] maxCurves = AnimationUtility.SplitCurve2D(distribution.GetMaxCurve());
 
-                if (component < minCurves.Length && component < maxCurves.Length)
+                if (componentIdx < minCurves.Length && componentIdx < maxCurves.Length)
                 {
-                    CurveEditorWindow.Show(minCurves[component], maxCurves[component],
+                    CurveEditorWindow.Show(minCurves[componentIdx], maxCurves[componentIdx],
                         (success, minCurve, maxCurve) =>
                         {
                             if (!success)
                                 return;
 
-                            minCurves[component] = minCurve;
-                            maxCurves[component] = maxCurve;
+                            minCurves[componentIdx] = minCurve;
+                            maxCurves[componentIdx] = maxCurve;
 
                             Vector2Curve minCompoundCurves = AnimationUtility.CombineCurve2D(minCurves);
                             Vector2Curve maxCompoundCurves = AnimationUtility.CombineCurve2D(maxCurves);
 
                             Value = new Vector2Distribution(minCompoundCurves, maxCompoundCurves);
-                            OnChanged?.Invoke();
-                            OnConfirmed?.Invoke();
+                            OnCurveChanged?.Invoke();
                         });
                 }
             }
         }
-
-        partial void OnConstantModified()
-        {
-            OnChanged?.Invoke();
-        }
-
-        partial void OnConstantConfirmed()
-        {
-            OnConfirmed?.Invoke();
-        }
     }
 }

+ 13 - 29
Source/EditorManaged/GUI/GUIVector3DistributionField.cs

@@ -6,35 +6,30 @@ namespace bs.Editor
     partial class GUIVector3DistributionField
     {
         /// <summary>
-        /// Triggered when the distribution in the field changes.
+        /// Triggered when one of the curves in the distribution changes.
         /// </summary>
-        public event Action OnChanged;
+        public event Action OnCurveChanged;
 
-        /// <summary>
-        /// Triggered whenever user confirms input in one of the floating point fields.
-        /// </summary>
-        public event Action OnConfirmed;
-
-        partial void OnClicked(int component)
+        partial void OnClicked(VectorComponent component)
         {
+            int componentIdx = (int) component;
             Vector3Distribution distribution = Value;
 
             if (DistributionType == PropertyDistributionType.Curve)
             {
                 AnimationCurve[] curves = AnimationUtility.SplitCurve3D(distribution.GetMinCurve());
-                if (component < curves.Length)
+                if (componentIdx < curves.Length)
                 {
-                    CurveEditorWindow.Show(curves[component], (success, curve) =>
+                    CurveEditorWindow.Show(curves[componentIdx], (success, curve) =>
                     {
                         if (!success)
                             return;
 
-                        curves[component] = curve;
+                        curves[componentIdx] = curve;
 
                         Vector3Curve compoundCurve = AnimationUtility.CombineCurve3D(curves);
                         Value = new Vector3Distribution(compoundCurve);
-                        OnChanged?.Invoke();
-                        OnConfirmed?.Invoke();
+                        OnCurveChanged?.Invoke();
                     });
                 }
             }
@@ -43,36 +38,25 @@ namespace bs.Editor
                 AnimationCurve[] minCurves = AnimationUtility.SplitCurve3D(distribution.GetMinCurve());
                 AnimationCurve[] maxCurves = AnimationUtility.SplitCurve3D(distribution.GetMaxCurve());
 
-                if (component < minCurves.Length && component < maxCurves.Length)
+                if (componentIdx < minCurves.Length && componentIdx < maxCurves.Length)
                 {
-                    CurveEditorWindow.Show(minCurves[component], maxCurves[component],
+                    CurveEditorWindow.Show(minCurves[componentIdx], maxCurves[componentIdx],
                         (success, minCurve, maxCurve) =>
                         {
                             if (!success)
                                 return;
 
-                            minCurves[component] = minCurve;
-                            maxCurves[component] = maxCurve;
+                            minCurves[componentIdx] = minCurve;
+                            maxCurves[componentIdx] = maxCurve;
 
                             Vector3Curve minCompoundCurves = AnimationUtility.CombineCurve3D(minCurves);
                             Vector3Curve maxCompoundCurves = AnimationUtility.CombineCurve3D(maxCurves);
 
                             Value = new Vector3Distribution(minCompoundCurves, maxCompoundCurves);
-                            OnChanged?.Invoke();
-                            OnConfirmed?.Invoke();
+                            OnCurveChanged?.Invoke();
                         });
                 }
             }
         }
-
-        partial void OnConstantModified()
-        {
-            OnChanged?.Invoke();
-        }
-
-        partial void OnConstantConfirmed()
-        {
-            OnConfirmed?.Invoke();
-        }
     }
 }

+ 39 - 12
Source/EditorManaged/Generated/GUIFloatDistributionField.generated.cs

@@ -106,21 +106,42 @@ namespace bs.Editor
 
 		/// <summary>
 		/// Triggered when the user clicks on the curve display. Only relevant if the distribution is a curve distribution.  
-		/// Provides the sequential index of the clicked curve (0 - x, 1 - y, 2 - z).
+		/// Provides the index of the clicked curve.
 		/// </summary>
-		partial void OnClicked(int p0);
+		partial void OnClicked(VectorComponent p0);
 
 		/// <summary>
-		/// Triggered when the user modifies either of the non-curve (constant) values of the distribution. Only relevant if the 
+		/// Triggered when the user modifies the value of the non-curve (constant) values of the distribution. Only relevant  if 
+		/// the distribution is not a curve distribution.
+		/// </summary>
+		public event Action<RangeComponent, VectorComponent> OnConstantModified;
+
+		/// <summary>
+		/// Triggered when the user confirms inputs in the non-curve (constant) values of the distribution. Only relevant  if the 
 		/// distribution is not a curve distribution.
 		/// </summary>
-		partial void OnConstantModified();
+		public event Action<RangeComponent, VectorComponent> OnConstantConfirmed;
 
 		/// <summary>
-		/// Triggered when the user confirms inputs in either of the non-curve (constant) values of the distribution. Only  
-		/// relevant if the distribution is not a curve distribution.
+		/// Triggered when a GUI field representing an individual component loses or gains focus. This only applies to input 
+		/// fields representing the non-curve (constant) distribution types.
 		/// </summary>
-		partial void OnConstantConfirmed();
+		public event Action<bool, RangeComponent, VectorComponent> OnConstantFocusChanged;
+
+		/// <summary>Sets input focus to a specific component&apos;s input box.</summary>
+		/// <param name="rangeComponent">
+		/// Whether to focus on the minimum or the maximum part of the range. Only relevant if the distribution represents a 
+		/// constant range.
+		/// </param>
+		/// <param name="vectorComponent">
+		/// Vector component to focus on. Only relevant of the distribution constant is a vector type, and if the current 
+		/// distribution type is a non-curve (constant) type.
+		/// </param>
+		/// <param name="focus">True to enable focus, false to disable.</param>
+		public void SetInputFocus(RangeComponent rangeComponent, VectorComponent vectorComponent, bool focus)
+		{
+			Internal_setInputFocus(mCachedPtr, rangeComponent, vectorComponent, focus);
+		}
 
 		[MethodImpl(MethodImplOptions.InternalCall)]
 		private static extern FloatDistribution Internal_getValue(IntPtr thisPtr);
@@ -131,6 +152,8 @@ namespace bs.Editor
 		[MethodImpl(MethodImplOptions.InternalCall)]
 		private static extern bool Internal_hasInputFocus(IntPtr thisPtr);
 		[MethodImpl(MethodImplOptions.InternalCall)]
+		private static extern void Internal_setInputFocus(IntPtr thisPtr, RangeComponent rangeComponent, VectorComponent vectorComponent, bool focus);
+		[MethodImpl(MethodImplOptions.InternalCall)]
 		private static extern void Internal_create(GUIFloatDistributionField managedInstance, ref GUIContent labelContent, int labelWidth, string style);
 		[MethodImpl(MethodImplOptions.InternalCall)]
 		private static extern void Internal_create0(GUIFloatDistributionField managedInstance, ref GUIContent labelContent, string style);
@@ -140,17 +163,21 @@ namespace bs.Editor
 		private static extern void Internal_create2(GUIFloatDistributionField managedInstance, LocString labelText, string style);
 		[MethodImpl(MethodImplOptions.InternalCall)]
 		private static extern void Internal_create3(GUIFloatDistributionField managedInstance, string style);
-		private void Internal_onClicked(int p0)
+		private void Internal_onClicked(VectorComponent p0)
 		{
 			OnClicked(p0);
 		}
-		private void Internal_onConstantModified()
+		private void Internal_onConstantModified(RangeComponent p0, VectorComponent p1)
+		{
+			OnConstantModified?.Invoke(p0, p1);
+		}
+		private void Internal_onConstantConfirmed(RangeComponent p0, VectorComponent p1)
 		{
-			OnConstantModified();
+			OnConstantConfirmed?.Invoke(p0, p1);
 		}
-		private void Internal_onConstantConfirmed()
+		private void Internal_onConstantFocusChanged(bool p0, RangeComponent p1, VectorComponent p2)
 		{
-			OnConstantConfirmed();
+			OnConstantFocusChanged?.Invoke(p0, p1, p2);
 		}
 	}
 

+ 39 - 12
Source/EditorManaged/Generated/GUIVector2DistributionField.generated.cs

@@ -106,21 +106,42 @@ namespace bs.Editor
 
 		/// <summary>
 		/// Triggered when the user clicks on the curve display. Only relevant if the distribution is a curve distribution.  
-		/// Provides the sequential index of the clicked curve (0 - x, 1 - y, 2 - z).
+		/// Provides the index of the clicked curve.
 		/// </summary>
-		partial void OnClicked(int p0);
+		partial void OnClicked(VectorComponent p0);
 
 		/// <summary>
-		/// Triggered when the user modifies either of the non-curve (constant) values of the distribution. Only relevant if the 
+		/// Triggered when the user modifies the value of the non-curve (constant) values of the distribution. Only relevant  if 
+		/// the distribution is not a curve distribution.
+		/// </summary>
+		public event Action<RangeComponent, VectorComponent> OnConstantModified;
+
+		/// <summary>
+		/// Triggered when the user confirms inputs in the non-curve (constant) values of the distribution. Only relevant  if the 
 		/// distribution is not a curve distribution.
 		/// </summary>
-		partial void OnConstantModified();
+		public event Action<RangeComponent, VectorComponent> OnConstantConfirmed;
 
 		/// <summary>
-		/// Triggered when the user confirms inputs in either of the non-curve (constant) values of the distribution. Only  
-		/// relevant if the distribution is not a curve distribution.
+		/// Triggered when a GUI field representing an individual component loses or gains focus. This only applies to input 
+		/// fields representing the non-curve (constant) distribution types.
 		/// </summary>
-		partial void OnConstantConfirmed();
+		public event Action<bool, RangeComponent, VectorComponent> OnConstantFocusChanged;
+
+		/// <summary>Sets input focus to a specific component&apos;s input box.</summary>
+		/// <param name="rangeComponent">
+		/// Whether to focus on the minimum or the maximum part of the range. Only relevant if the distribution represents a 
+		/// constant range.
+		/// </param>
+		/// <param name="vectorComponent">
+		/// Vector component to focus on. Only relevant of the distribution constant is a vector type, and if the current 
+		/// distribution type is a non-curve (constant) type.
+		/// </param>
+		/// <param name="focus">True to enable focus, false to disable.</param>
+		public void SetInputFocus(RangeComponent rangeComponent, VectorComponent vectorComponent, bool focus)
+		{
+			Internal_setInputFocus(mCachedPtr, rangeComponent, vectorComponent, focus);
+		}
 
 		[MethodImpl(MethodImplOptions.InternalCall)]
 		private static extern Vector2Distribution Internal_getValue(IntPtr thisPtr);
@@ -131,6 +152,8 @@ namespace bs.Editor
 		[MethodImpl(MethodImplOptions.InternalCall)]
 		private static extern bool Internal_hasInputFocus(IntPtr thisPtr);
 		[MethodImpl(MethodImplOptions.InternalCall)]
+		private static extern void Internal_setInputFocus(IntPtr thisPtr, RangeComponent rangeComponent, VectorComponent vectorComponent, bool focus);
+		[MethodImpl(MethodImplOptions.InternalCall)]
 		private static extern void Internal_create(GUIVector2DistributionField managedInstance, ref GUIContent labelContent, int labelWidth, string style);
 		[MethodImpl(MethodImplOptions.InternalCall)]
 		private static extern void Internal_create0(GUIVector2DistributionField managedInstance, ref GUIContent labelContent, string style);
@@ -140,17 +163,21 @@ namespace bs.Editor
 		private static extern void Internal_create2(GUIVector2DistributionField managedInstance, LocString labelText, string style);
 		[MethodImpl(MethodImplOptions.InternalCall)]
 		private static extern void Internal_create3(GUIVector2DistributionField managedInstance, string style);
-		private void Internal_onClicked(int p0)
+		private void Internal_onClicked(VectorComponent p0)
 		{
 			OnClicked(p0);
 		}
-		private void Internal_onConstantModified()
+		private void Internal_onConstantModified(RangeComponent p0, VectorComponent p1)
+		{
+			OnConstantModified?.Invoke(p0, p1);
+		}
+		private void Internal_onConstantConfirmed(RangeComponent p0, VectorComponent p1)
 		{
-			OnConstantModified();
+			OnConstantConfirmed?.Invoke(p0, p1);
 		}
-		private void Internal_onConstantConfirmed()
+		private void Internal_onConstantFocusChanged(bool p0, RangeComponent p1, VectorComponent p2)
 		{
-			OnConstantConfirmed();
+			OnConstantFocusChanged?.Invoke(p0, p1, p2);
 		}
 	}
 

+ 39 - 12
Source/EditorManaged/Generated/GUIVector3DistributionField.generated.cs

@@ -106,21 +106,42 @@ namespace bs.Editor
 
 		/// <summary>
 		/// Triggered when the user clicks on the curve display. Only relevant if the distribution is a curve distribution.  
-		/// Provides the sequential index of the clicked curve (0 - x, 1 - y, 2 - z).
+		/// Provides the index of the clicked curve.
 		/// </summary>
-		partial void OnClicked(int p0);
+		partial void OnClicked(VectorComponent p0);
 
 		/// <summary>
-		/// Triggered when the user modifies either of the non-curve (constant) values of the distribution. Only relevant if the 
+		/// Triggered when the user modifies the value of the non-curve (constant) values of the distribution. Only relevant  if 
+		/// the distribution is not a curve distribution.
+		/// </summary>
+		public event Action<RangeComponent, VectorComponent> OnConstantModified;
+
+		/// <summary>
+		/// Triggered when the user confirms inputs in the non-curve (constant) values of the distribution. Only relevant  if the 
 		/// distribution is not a curve distribution.
 		/// </summary>
-		partial void OnConstantModified();
+		public event Action<RangeComponent, VectorComponent> OnConstantConfirmed;
 
 		/// <summary>
-		/// Triggered when the user confirms inputs in either of the non-curve (constant) values of the distribution. Only  
-		/// relevant if the distribution is not a curve distribution.
+		/// Triggered when a GUI field representing an individual component loses or gains focus. This only applies to input 
+		/// fields representing the non-curve (constant) distribution types.
 		/// </summary>
-		partial void OnConstantConfirmed();
+		public event Action<bool, RangeComponent, VectorComponent> OnConstantFocusChanged;
+
+		/// <summary>Sets input focus to a specific component&apos;s input box.</summary>
+		/// <param name="rangeComponent">
+		/// Whether to focus on the minimum or the maximum part of the range. Only relevant if the distribution represents a 
+		/// constant range.
+		/// </param>
+		/// <param name="vectorComponent">
+		/// Vector component to focus on. Only relevant of the distribution constant is a vector type, and if the current 
+		/// distribution type is a non-curve (constant) type.
+		/// </param>
+		/// <param name="focus">True to enable focus, false to disable.</param>
+		public void SetInputFocus(RangeComponent rangeComponent, VectorComponent vectorComponent, bool focus)
+		{
+			Internal_setInputFocus(mCachedPtr, rangeComponent, vectorComponent, focus);
+		}
 
 		[MethodImpl(MethodImplOptions.InternalCall)]
 		private static extern Vector3Distribution Internal_getValue(IntPtr thisPtr);
@@ -131,6 +152,8 @@ namespace bs.Editor
 		[MethodImpl(MethodImplOptions.InternalCall)]
 		private static extern bool Internal_hasInputFocus(IntPtr thisPtr);
 		[MethodImpl(MethodImplOptions.InternalCall)]
+		private static extern void Internal_setInputFocus(IntPtr thisPtr, RangeComponent rangeComponent, VectorComponent vectorComponent, bool focus);
+		[MethodImpl(MethodImplOptions.InternalCall)]
 		private static extern void Internal_create(GUIVector3DistributionField managedInstance, ref GUIContent labelContent, int labelWidth, string style);
 		[MethodImpl(MethodImplOptions.InternalCall)]
 		private static extern void Internal_create0(GUIVector3DistributionField managedInstance, ref GUIContent labelContent, string style);
@@ -140,17 +163,21 @@ namespace bs.Editor
 		private static extern void Internal_create2(GUIVector3DistributionField managedInstance, LocString labelText, string style);
 		[MethodImpl(MethodImplOptions.InternalCall)]
 		private static extern void Internal_create3(GUIVector3DistributionField managedInstance, string style);
-		private void Internal_onClicked(int p0)
+		private void Internal_onClicked(VectorComponent p0)
 		{
 			OnClicked(p0);
 		}
-		private void Internal_onConstantModified()
+		private void Internal_onConstantModified(RangeComponent p0, VectorComponent p1)
+		{
+			OnConstantModified?.Invoke(p0, p1);
+		}
+		private void Internal_onConstantConfirmed(RangeComponent p0, VectorComponent p1)
 		{
-			OnConstantModified();
+			OnConstantConfirmed?.Invoke(p0, p1);
 		}
-		private void Internal_onConstantConfirmed()
+		private void Internal_onConstantFocusChanged(bool p0, RangeComponent p1, VectorComponent p2)
 		{
-			OnConstantConfirmed();
+			OnConstantFocusChanged?.Invoke(p0, p1, p2);
 		}
 	}
 

+ 69 - 0
Source/EditorManaged/Generated/info.xml

@@ -135,6 +135,29 @@
 	</enum>
 	<class native="GUIVector2DistributionField" script="GUIVector2DistributionField">
 		<doc>A composite GUI object representing an editor field. Editor fields are a combination of a label and an input field. Label is optional. This specific implementation displays an input field for a 2D vector distribution.</doc>
+		<event native="onConstantModified" script="OnConstantModified" static="false">
+			<doc>Triggered when the user modifies the value of the non-curve (constant) values of the distribution. Only relevant  if the distribution is not a curve distribution.</doc>
+			<param name="p0" type="RangeComponent">
+			</param>
+			<param name="p1" type="VectorComponent">
+			</param>
+		</event>
+		<event native="onConstantConfirmed" script="OnConstantConfirmed" static="false">
+			<doc>Triggered when the user confirms inputs in the non-curve (constant) values of the distribution. Only relevant  if the distribution is not a curve distribution.</doc>
+			<param name="p0" type="RangeComponent">
+			</param>
+			<param name="p1" type="VectorComponent">
+			</param>
+		</event>
+		<event native="onConstantFocusChanged" script="OnConstantFocusChanged" static="false">
+			<doc>Triggered when a GUI field representing an individual component loses or gains focus. This only applies to input fields representing the non-curve (constant) distribution types.</doc>
+			<param name="p0" type="bool">
+			</param>
+			<param name="p1" type="RangeComponent">
+			</param>
+			<param name="p2" type="VectorComponent">
+			</param>
+		</event>
 	</class>
 	<enum native="EditorToggleIcon" script="EditorToggleIcon">
 		<doc>Types of icons used in various areas throughout the editor, for toggleable elements.</doc>
@@ -256,9 +279,55 @@
 	</class>
 	<class native="GUIFloatDistributionField" script="GUIFloatDistributionField">
 		<doc>A composite GUI object representing an editor field. Editor fields are a combination of a label and an input field. Label is optional. This specific implementation displays an input field for a floating point distribution.</doc>
+		<event native="onConstantModified" script="OnConstantModified" static="false">
+			<doc>Triggered when the user modifies the value of the non-curve (constant) values of the distribution. Only relevant  if the distribution is not a curve distribution.</doc>
+			<param name="p0" type="RangeComponent">
+			</param>
+			<param name="p1" type="VectorComponent">
+			</param>
+		</event>
+		<event native="onConstantConfirmed" script="OnConstantConfirmed" static="false">
+			<doc>Triggered when the user confirms inputs in the non-curve (constant) values of the distribution. Only relevant  if the distribution is not a curve distribution.</doc>
+			<param name="p0" type="RangeComponent">
+			</param>
+			<param name="p1" type="VectorComponent">
+			</param>
+		</event>
+		<event native="onConstantFocusChanged" script="OnConstantFocusChanged" static="false">
+			<doc>Triggered when a GUI field representing an individual component loses or gains focus. This only applies to input fields representing the non-curve (constant) distribution types.</doc>
+			<param name="p0" type="bool">
+			</param>
+			<param name="p1" type="RangeComponent">
+			</param>
+			<param name="p2" type="VectorComponent">
+			</param>
+		</event>
 	</class>
 	<class native="GUIVector3DistributionField" script="GUIVector3DistributionField">
 		<doc>A composite GUI object representing an editor field. Editor fields are a combination of a label and an input field. Label is optional. This specific implementation displays an input field for a 3D vector distribution.</doc>
+		<event native="onConstantModified" script="OnConstantModified" static="false">
+			<doc>Triggered when the user modifies the value of the non-curve (constant) values of the distribution. Only relevant  if the distribution is not a curve distribution.</doc>
+			<param name="p0" type="RangeComponent">
+			</param>
+			<param name="p1" type="VectorComponent">
+			</param>
+		</event>
+		<event native="onConstantConfirmed" script="OnConstantConfirmed" static="false">
+			<doc>Triggered when the user confirms inputs in the non-curve (constant) values of the distribution. Only relevant  if the distribution is not a curve distribution.</doc>
+			<param name="p0" type="RangeComponent">
+			</param>
+			<param name="p1" type="VectorComponent">
+			</param>
+		</event>
+		<event native="onConstantFocusChanged" script="OnConstantFocusChanged" static="false">
+			<doc>Triggered when a GUI field representing an individual component loses or gains focus. This only applies to input fields representing the non-curve (constant) distribution types.</doc>
+			<param name="p0" type="bool">
+			</param>
+			<param name="p1" type="RangeComponent">
+			</param>
+			<param name="p2" type="VectorComponent">
+			</param>
+		</event>
 	</class>
 	<struct native="SceneTreeViewElement" script="SceneTreeViewElement">
 		<doc>Information about a single element in GUISceneTreeView.</doc>

+ 40 - 4
Source/EditorManaged/Windows/Inspector/InspectableFloatDistribution.cs

@@ -38,10 +38,36 @@ namespace bs.Editor
             if (property != null)
             {
                 guiDistributionField = new GUIFloatDistributionField(new GUIContent(title));
-                guiDistributionField.OnChanged += OnFieldValueChanged;
-                guiDistributionField.OnConfirmed += OnFieldValueConfirm;
-                guiDistributionField.OnFocusLost += OnFieldValueConfirm;
-                guiDistributionField.OnFocusGained += StartUndo;
+                guiDistributionField.OnCurveChanged += () =>
+                {
+                    StartUndo();
+                    property.SetValue(guiDistributionField.Value);
+                    state |= InspectableState.ModifyInProgress;
+                    EndUndo();
+                };
+                    
+                guiDistributionField.OnConstantModified += (x, y) => OnFieldValueChanged();
+                guiDistributionField.OnConstantConfirmed += (rangeComp, vectorComp) =>
+                {
+                    OnFieldValueConfirm();
+
+                    if(rangeComp == RangeComponent.Min)
+                        StartUndo("min." + vectorComp.ToString());
+                    else
+                        StartUndo("max." + vectorComp.ToString());
+                };
+                guiDistributionField.OnConstantFocusChanged += (focus, rangeComp, vectorComp) =>
+                {
+                    if (focus)
+                    {
+                        if (rangeComp == RangeComponent.Min)
+                            StartUndo("min." + vectorComp.ToString());
+                        else
+                            StartUndo("max." + vectorComp.ToString());
+                    }
+                    else
+                        OnFieldValueConfirm();
+                };
 
                 layout.AddElement(layoutIndex, guiDistributionField);
             }
@@ -60,6 +86,16 @@ namespace bs.Editor
             return oldState;
         }
 
+        /// <inheritdoc />
+        public override void SetHasFocus(string subFieldName = null)
+        {
+            if (subFieldName != null && subFieldName.StartsWith("min."))
+                guiDistributionField.SetInputFocus(RangeComponent.Min, VectorComponent.X, true);
+
+            if (subFieldName != null && subFieldName.StartsWith("max."))
+                guiDistributionField.SetInputFocus(RangeComponent.Max, VectorComponent.X, true);
+        }
+
         /// <summary>
         /// Triggered when the user edits the distribution.
         /// </summary>

+ 54 - 5
Source/EditorManaged/Windows/Inspector/InspectableVector2Distribution.cs

@@ -38,14 +38,36 @@ namespace bs.Editor
             if (property != null)
             {
                 guiDistributionField = new GUIVector2DistributionField(new GUIContent(title));
-                guiDistributionField.OnChanged += OnFieldValueChanged;
-                guiDistributionField.OnConfirmed += () =>
+                guiDistributionField.OnCurveChanged += () =>
                 {
-                    OnFieldValueConfirm();
                     StartUndo();
+                    property.SetValue(guiDistributionField.Value);
+                    state |= InspectableState.ModifyInProgress;
+                    EndUndo();
+                };
+
+                guiDistributionField.OnConstantModified += (x, y) => OnFieldValueChanged();
+                guiDistributionField.OnConstantConfirmed += (rangeComp, vectorComp) =>
+                {
+                    OnFieldValueConfirm();
+
+                    if (rangeComp == RangeComponent.Min)
+                        StartUndo("min." + vectorComp.ToString());
+                    else
+                        StartUndo("max." + vectorComp.ToString());
+                };
+                guiDistributionField.OnConstantFocusChanged += (focus, rangeComp, vectorComp) =>
+                {
+                    if (focus)
+                    {
+                        if (rangeComp == RangeComponent.Min)
+                            StartUndo("min." + vectorComp.ToString());
+                        else
+                            StartUndo("max." + vectorComp.ToString());
+                    }
+                    else
+                        OnFieldValueConfirm();
                 };
-                guiDistributionField.OnFocusLost += OnFieldValueConfirm;
-                guiDistributionField.OnFocusGained += StartUndo;
 
                 layout.AddElement(layoutIndex, guiDistributionField);
             }
@@ -62,8 +84,35 @@ namespace bs.Editor
                 state = InspectableState.NotModified;
 
             return oldState;
+        }        
+        
+        /// <inheritdoc />
+        public override void SetHasFocus(string subFieldName = null)
+        {
+            if (subFieldName != null && subFieldName.StartsWith("min."))
+            {
+                string component = subFieldName.Remove(0, "min.".Length);
+                if (component == "X")
+                    guiDistributionField.SetInputFocus(RangeComponent.Min, VectorComponent.X, true);
+                else if (component == "Y")
+                    guiDistributionField.SetInputFocus(RangeComponent.Min, VectorComponent.Y, true);
+                else
+                    guiDistributionField.SetInputFocus(RangeComponent.Min, VectorComponent.X, true);
+            }
+
+            if (subFieldName != null && subFieldName.StartsWith("max."))
+            {
+                string component = subFieldName.Remove(0, "max.".Length);
+                if (component == "X")
+                    guiDistributionField.SetInputFocus(RangeComponent.Max, VectorComponent.X, true);
+                else if (component == "Y")
+                    guiDistributionField.SetInputFocus(RangeComponent.Max, VectorComponent.Y, true);
+                else
+                    guiDistributionField.SetInputFocus(RangeComponent.Max, VectorComponent.X, true);
+            }
         }
 
+
         /// <summary>
         /// Triggered when the user edits the distribution.
         /// </summary>

+ 57 - 5
Source/EditorManaged/Windows/Inspector/InspectableVector3Distribution.cs

@@ -38,14 +38,36 @@ namespace bs.Editor
             if (property != null)
             {
                 guiDistributionField = new GUIVector3DistributionField(new GUIContent(title));
-                guiDistributionField.OnChanged += OnFieldValueChanged;
-                guiDistributionField.OnConfirmed += () =>
+                guiDistributionField.OnCurveChanged += () =>
                 {
-                    OnFieldValueConfirm();
                     StartUndo();
+                    property.SetValue(guiDistributionField.Value);
+                    state |= InspectableState.ModifyInProgress;
+                    EndUndo();
+                };
+
+                guiDistributionField.OnConstantModified += (x, y) => OnFieldValueChanged();
+                guiDistributionField.OnConstantConfirmed += (rangeComp, vectorComp) =>
+                {
+                    OnFieldValueConfirm();
+
+                    if (rangeComp == RangeComponent.Min)
+                        StartUndo("min." + vectorComp.ToString());
+                    else
+                        StartUndo("max." + vectorComp.ToString());
+                };
+                guiDistributionField.OnConstantFocusChanged += (focus, rangeComp, vectorComp) =>
+                {
+                    if (focus)
+                    {
+                        if (rangeComp == RangeComponent.Min)
+                            StartUndo("min." + vectorComp.ToString());
+                        else
+                            StartUndo("max." + vectorComp.ToString());
+                    }
+                    else
+                        OnFieldValueConfirm();
                 };
-                guiDistributionField.OnFocusLost += OnFieldValueConfirm;
-                guiDistributionField.OnFocusGained += StartUndo;
 
                 layout.AddElement(layoutIndex, guiDistributionField);
             }
@@ -64,6 +86,36 @@ namespace bs.Editor
             return oldState;
         }
 
+        /// <inheritdoc />
+        public override void SetHasFocus(string subFieldName = null)
+        {
+            if (subFieldName != null && subFieldName.StartsWith("min."))
+            {
+                string component = subFieldName.Remove(0, "min.".Length);
+                if (component == "X")
+                    guiDistributionField.SetInputFocus(RangeComponent.Min, VectorComponent.X, true);
+                else if (component == "Y")
+                    guiDistributionField.SetInputFocus(RangeComponent.Min, VectorComponent.Y, true);
+                else if (component == "Z")
+                    guiDistributionField.SetInputFocus(RangeComponent.Min, VectorComponent.Z, true);
+                else
+                    guiDistributionField.SetInputFocus(RangeComponent.Min, VectorComponent.X, true);
+            }
+
+            if (subFieldName != null && subFieldName.StartsWith("max."))
+            {
+                string component = subFieldName.Remove(0, "max.".Length);
+                if (component == "X")
+                    guiDistributionField.SetInputFocus(RangeComponent.Max, VectorComponent.X, true);
+                else if (component == "Y")
+                    guiDistributionField.SetInputFocus(RangeComponent.Max, VectorComponent.Y, true);
+                else if (component == "Z")
+                    guiDistributionField.SetInputFocus(RangeComponent.Max, VectorComponent.Z, true);
+                else
+                    guiDistributionField.SetInputFocus(RangeComponent.Max, VectorComponent.X, true);
+            }
+        }
+
         /// <summary>
         /// Triggered when the user edits the distribution.
         /// </summary>

+ 24 - 10
Source/EditorScript/Generated/BsScriptGUIFloatDistributionField.generated.cpp

@@ -15,13 +15,15 @@ namespace bs
 	ScriptGUIFloatDistributionField::onClickedThunkDef ScriptGUIFloatDistributionField::onClickedThunk; 
 	ScriptGUIFloatDistributionField::onConstantModifiedThunkDef ScriptGUIFloatDistributionField::onConstantModifiedThunk; 
 	ScriptGUIFloatDistributionField::onConstantConfirmedThunkDef ScriptGUIFloatDistributionField::onConstantConfirmedThunk; 
+	ScriptGUIFloatDistributionField::onConstantFocusChangedThunkDef ScriptGUIFloatDistributionField::onConstantFocusChangedThunk; 
 
 	ScriptGUIFloatDistributionField::ScriptGUIFloatDistributionField(MonoObject* managedInstance, GUIFloatDistributionField* value)
 		:TScriptGUIElement(managedInstance, value)
 	{
 		value->onClicked.connect(std::bind(&ScriptGUIFloatDistributionField::onClicked, this, std::placeholders::_1));
-		value->onConstantModified.connect(std::bind(&ScriptGUIFloatDistributionField::onConstantModified, this));
-		value->onConstantConfirmed.connect(std::bind(&ScriptGUIFloatDistributionField::onConstantConfirmed, this));
+		value->onConstantModified.connect(std::bind(&ScriptGUIFloatDistributionField::onConstantModified, this, std::placeholders::_1, std::placeholders::_2));
+		value->onConstantConfirmed.connect(std::bind(&ScriptGUIFloatDistributionField::onConstantConfirmed, this, std::placeholders::_1, std::placeholders::_2));
+		value->onConstantFocusChanged.connect(std::bind(&ScriptGUIFloatDistributionField::onConstantFocusChanged, this, std::placeholders::_1, std::placeholders::_2, std::placeholders::_3));
 	}
 
 	void ScriptGUIFloatDistributionField::initRuntimeData()
@@ -30,30 +32,37 @@ namespace bs
 		metaData.scriptClass->addInternalCall("Internal_setValue", (void*)&ScriptGUIFloatDistributionField::Internal_setValue);
 		metaData.scriptClass->addInternalCall("Internal_getType", (void*)&ScriptGUIFloatDistributionField::Internal_getType);
 		metaData.scriptClass->addInternalCall("Internal_hasInputFocus", (void*)&ScriptGUIFloatDistributionField::Internal_hasInputFocus);
+		metaData.scriptClass->addInternalCall("Internal_setInputFocus", (void*)&ScriptGUIFloatDistributionField::Internal_setInputFocus);
 		metaData.scriptClass->addInternalCall("Internal_create", (void*)&ScriptGUIFloatDistributionField::Internal_create);
 		metaData.scriptClass->addInternalCall("Internal_create0", (void*)&ScriptGUIFloatDistributionField::Internal_create0);
 		metaData.scriptClass->addInternalCall("Internal_create1", (void*)&ScriptGUIFloatDistributionField::Internal_create1);
 		metaData.scriptClass->addInternalCall("Internal_create2", (void*)&ScriptGUIFloatDistributionField::Internal_create2);
 		metaData.scriptClass->addInternalCall("Internal_create3", (void*)&ScriptGUIFloatDistributionField::Internal_create3);
 
-		onClickedThunk = (onClickedThunkDef)metaData.scriptClass->getMethodExact("Internal_onClicked", "int")->getThunk();
-		onConstantModifiedThunk = (onConstantModifiedThunkDef)metaData.scriptClass->getMethodExact("Internal_onConstantModified", "")->getThunk();
-		onConstantConfirmedThunk = (onConstantConfirmedThunkDef)metaData.scriptClass->getMethodExact("Internal_onConstantConfirmed", "")->getThunk();
+		onClickedThunk = (onClickedThunkDef)metaData.scriptClass->getMethodExact("Internal_onClicked", "VectorComponent")->getThunk();
+		onConstantModifiedThunk = (onConstantModifiedThunkDef)metaData.scriptClass->getMethodExact("Internal_onConstantModified", "RangeComponent,VectorComponent")->getThunk();
+		onConstantConfirmedThunk = (onConstantConfirmedThunkDef)metaData.scriptClass->getMethodExact("Internal_onConstantConfirmed", "RangeComponent,VectorComponent")->getThunk();
+		onConstantFocusChangedThunk = (onConstantFocusChangedThunkDef)metaData.scriptClass->getMethodExact("Internal_onConstantFocusChanged", "bool,RangeComponent,VectorComponent")->getThunk();
 	}
 
-	void ScriptGUIFloatDistributionField::onClicked(int32_t p0)
+	void ScriptGUIFloatDistributionField::onClicked(VectorComponent p0)
 	{
 		MonoUtil::invokeThunk(onClickedThunk, getManagedInstance(), p0);
 	}
 
-	void ScriptGUIFloatDistributionField::onConstantModified()
+	void ScriptGUIFloatDistributionField::onConstantModified(RangeComponent p0, VectorComponent p1)
 	{
-		MonoUtil::invokeThunk(onConstantModifiedThunk, getManagedInstance());
+		MonoUtil::invokeThunk(onConstantModifiedThunk, getManagedInstance(), p0, p1);
 	}
 
-	void ScriptGUIFloatDistributionField::onConstantConfirmed()
+	void ScriptGUIFloatDistributionField::onConstantConfirmed(RangeComponent p0, VectorComponent p1)
 	{
-		MonoUtil::invokeThunk(onConstantConfirmedThunk, getManagedInstance());
+		MonoUtil::invokeThunk(onConstantConfirmedThunk, getManagedInstance(), p0, p1);
+	}
+
+	void ScriptGUIFloatDistributionField::onConstantFocusChanged(bool p0, RangeComponent p1, VectorComponent p2)
+	{
+		MonoUtil::invokeThunk(onConstantFocusChangedThunk, getManagedInstance(), p0, p1, p2);
 	}
 	MonoObject* ScriptGUIFloatDistributionField::Internal_getValue(ScriptGUIFloatDistributionField* thisPtr)
 	{
@@ -98,6 +107,11 @@ namespace bs
 		return __output;
 	}
 
+	void ScriptGUIFloatDistributionField::Internal_setInputFocus(ScriptGUIFloatDistributionField* thisPtr, RangeComponent rangeComponent, VectorComponent vectorComponent, bool focus)
+	{
+		static_cast<GUIFloatDistributionField*>(thisPtr->getGUIElement())->setInputFocus(rangeComponent, vectorComponent, focus);
+	}
+
 	void ScriptGUIFloatDistributionField::Internal_create(MonoObject* managedInstance, __GUIContentInterop* labelContent, uint32_t labelWidth, MonoString* style)
 	{
 		GUIContent tmplabelContent;

+ 12 - 6
Source/EditorScript/Generated/BsScriptGUIFloatDistributionField.generated.h

@@ -7,6 +7,8 @@
 #include "../../bsf/Source/Foundation/bsfCore/Particles/BsParticleDistribution.h"
 #include "../../bsf/Source/Foundation/bsfCore/Localization/BsHString.h"
 #include "../../bsf/Source/Foundation/bsfCore/Particles/BsParticleDistribution.h"
+#include "../../bsf/Source/Foundation/bsfCore/Utility/BsCommonTypes.h"
+#include "../../bsf/Source/Foundation/bsfCore/Utility/BsCommonTypes.h"
 
 namespace bs
 {
@@ -21,21 +23,25 @@ namespace bs
 		ScriptGUIFloatDistributionField(MonoObject* managedInstance, GUIFloatDistributionField* value);
 
 	private:
-		void onClicked(int32_t p0);
-		void onConstantModified();
-		void onConstantConfirmed();
+		void onClicked(VectorComponent p0);
+		void onConstantModified(RangeComponent p0, VectorComponent p1);
+		void onConstantConfirmed(RangeComponent p0, VectorComponent p1);
+		void onConstantFocusChanged(bool p0, RangeComponent p1, VectorComponent p2);
 
-		typedef void(BS_THUNKCALL *onClickedThunkDef) (MonoObject*, int32_t p0, MonoException**);
+		typedef void(BS_THUNKCALL *onClickedThunkDef) (MonoObject*, VectorComponent p0, MonoException**);
 		static onClickedThunkDef onClickedThunk;
-		typedef void(BS_THUNKCALL *onConstantModifiedThunkDef) (MonoObject*, MonoException**);
+		typedef void(BS_THUNKCALL *onConstantModifiedThunkDef) (MonoObject*, RangeComponent p0, VectorComponent p1, MonoException**);
 		static onConstantModifiedThunkDef onConstantModifiedThunk;
-		typedef void(BS_THUNKCALL *onConstantConfirmedThunkDef) (MonoObject*, MonoException**);
+		typedef void(BS_THUNKCALL *onConstantConfirmedThunkDef) (MonoObject*, RangeComponent p0, VectorComponent p1, MonoException**);
 		static onConstantConfirmedThunkDef onConstantConfirmedThunk;
+		typedef void(BS_THUNKCALL *onConstantFocusChangedThunkDef) (MonoObject*, bool p0, RangeComponent p1, VectorComponent p2, MonoException**);
+		static onConstantFocusChangedThunkDef onConstantFocusChangedThunk;
 
 		static MonoObject* Internal_getValue(ScriptGUIFloatDistributionField* thisPtr);
 		static void Internal_setValue(ScriptGUIFloatDistributionField* thisPtr, MonoObject* value);
 		static PropertyDistributionType Internal_getType(ScriptGUIFloatDistributionField* thisPtr);
 		static bool Internal_hasInputFocus(ScriptGUIFloatDistributionField* thisPtr);
+		static void Internal_setInputFocus(ScriptGUIFloatDistributionField* thisPtr, RangeComponent rangeComponent, VectorComponent vectorComponent, bool focus);
 		static void Internal_create(MonoObject* managedInstance, __GUIContentInterop* labelContent, uint32_t labelWidth, MonoString* style);
 		static void Internal_create0(MonoObject* managedInstance, __GUIContentInterop* labelContent, MonoString* style);
 		static void Internal_create1(MonoObject* managedInstance, MonoObject* labelText, uint32_t labelWidth, MonoString* style);

+ 24 - 10
Source/EditorScript/Generated/BsScriptGUIVector2DistributionField.generated.cpp

@@ -15,13 +15,15 @@ namespace bs
 	ScriptGUIVector2DistributionField::onClickedThunkDef ScriptGUIVector2DistributionField::onClickedThunk; 
 	ScriptGUIVector2DistributionField::onConstantModifiedThunkDef ScriptGUIVector2DistributionField::onConstantModifiedThunk; 
 	ScriptGUIVector2DistributionField::onConstantConfirmedThunkDef ScriptGUIVector2DistributionField::onConstantConfirmedThunk; 
+	ScriptGUIVector2DistributionField::onConstantFocusChangedThunkDef ScriptGUIVector2DistributionField::onConstantFocusChangedThunk; 
 
 	ScriptGUIVector2DistributionField::ScriptGUIVector2DistributionField(MonoObject* managedInstance, GUIVector2DistributionField* value)
 		:TScriptGUIElement(managedInstance, value)
 	{
 		value->onClicked.connect(std::bind(&ScriptGUIVector2DistributionField::onClicked, this, std::placeholders::_1));
-		value->onConstantModified.connect(std::bind(&ScriptGUIVector2DistributionField::onConstantModified, this));
-		value->onConstantConfirmed.connect(std::bind(&ScriptGUIVector2DistributionField::onConstantConfirmed, this));
+		value->onConstantModified.connect(std::bind(&ScriptGUIVector2DistributionField::onConstantModified, this, std::placeholders::_1, std::placeholders::_2));
+		value->onConstantConfirmed.connect(std::bind(&ScriptGUIVector2DistributionField::onConstantConfirmed, this, std::placeholders::_1, std::placeholders::_2));
+		value->onConstantFocusChanged.connect(std::bind(&ScriptGUIVector2DistributionField::onConstantFocusChanged, this, std::placeholders::_1, std::placeholders::_2, std::placeholders::_3));
 	}
 
 	void ScriptGUIVector2DistributionField::initRuntimeData()
@@ -30,30 +32,37 @@ namespace bs
 		metaData.scriptClass->addInternalCall("Internal_setValue", (void*)&ScriptGUIVector2DistributionField::Internal_setValue);
 		metaData.scriptClass->addInternalCall("Internal_getType", (void*)&ScriptGUIVector2DistributionField::Internal_getType);
 		metaData.scriptClass->addInternalCall("Internal_hasInputFocus", (void*)&ScriptGUIVector2DistributionField::Internal_hasInputFocus);
+		metaData.scriptClass->addInternalCall("Internal_setInputFocus", (void*)&ScriptGUIVector2DistributionField::Internal_setInputFocus);
 		metaData.scriptClass->addInternalCall("Internal_create", (void*)&ScriptGUIVector2DistributionField::Internal_create);
 		metaData.scriptClass->addInternalCall("Internal_create0", (void*)&ScriptGUIVector2DistributionField::Internal_create0);
 		metaData.scriptClass->addInternalCall("Internal_create1", (void*)&ScriptGUIVector2DistributionField::Internal_create1);
 		metaData.scriptClass->addInternalCall("Internal_create2", (void*)&ScriptGUIVector2DistributionField::Internal_create2);
 		metaData.scriptClass->addInternalCall("Internal_create3", (void*)&ScriptGUIVector2DistributionField::Internal_create3);
 
-		onClickedThunk = (onClickedThunkDef)metaData.scriptClass->getMethodExact("Internal_onClicked", "int")->getThunk();
-		onConstantModifiedThunk = (onConstantModifiedThunkDef)metaData.scriptClass->getMethodExact("Internal_onConstantModified", "")->getThunk();
-		onConstantConfirmedThunk = (onConstantConfirmedThunkDef)metaData.scriptClass->getMethodExact("Internal_onConstantConfirmed", "")->getThunk();
+		onClickedThunk = (onClickedThunkDef)metaData.scriptClass->getMethodExact("Internal_onClicked", "VectorComponent")->getThunk();
+		onConstantModifiedThunk = (onConstantModifiedThunkDef)metaData.scriptClass->getMethodExact("Internal_onConstantModified", "RangeComponent,VectorComponent")->getThunk();
+		onConstantConfirmedThunk = (onConstantConfirmedThunkDef)metaData.scriptClass->getMethodExact("Internal_onConstantConfirmed", "RangeComponent,VectorComponent")->getThunk();
+		onConstantFocusChangedThunk = (onConstantFocusChangedThunkDef)metaData.scriptClass->getMethodExact("Internal_onConstantFocusChanged", "bool,RangeComponent,VectorComponent")->getThunk();
 	}
 
-	void ScriptGUIVector2DistributionField::onClicked(int32_t p0)
+	void ScriptGUIVector2DistributionField::onClicked(VectorComponent p0)
 	{
 		MonoUtil::invokeThunk(onClickedThunk, getManagedInstance(), p0);
 	}
 
-	void ScriptGUIVector2DistributionField::onConstantModified()
+	void ScriptGUIVector2DistributionField::onConstantModified(RangeComponent p0, VectorComponent p1)
 	{
-		MonoUtil::invokeThunk(onConstantModifiedThunk, getManagedInstance());
+		MonoUtil::invokeThunk(onConstantModifiedThunk, getManagedInstance(), p0, p1);
 	}
 
-	void ScriptGUIVector2DistributionField::onConstantConfirmed()
+	void ScriptGUIVector2DistributionField::onConstantConfirmed(RangeComponent p0, VectorComponent p1)
 	{
-		MonoUtil::invokeThunk(onConstantConfirmedThunk, getManagedInstance());
+		MonoUtil::invokeThunk(onConstantConfirmedThunk, getManagedInstance(), p0, p1);
+	}
+
+	void ScriptGUIVector2DistributionField::onConstantFocusChanged(bool p0, RangeComponent p1, VectorComponent p2)
+	{
+		MonoUtil::invokeThunk(onConstantFocusChangedThunk, getManagedInstance(), p0, p1, p2);
 	}
 	MonoObject* ScriptGUIVector2DistributionField::Internal_getValue(ScriptGUIVector2DistributionField* thisPtr)
 	{
@@ -98,6 +107,11 @@ namespace bs
 		return __output;
 	}
 
+	void ScriptGUIVector2DistributionField::Internal_setInputFocus(ScriptGUIVector2DistributionField* thisPtr, RangeComponent rangeComponent, VectorComponent vectorComponent, bool focus)
+	{
+		static_cast<GUIVector2DistributionField*>(thisPtr->getGUIElement())->setInputFocus(rangeComponent, vectorComponent, focus);
+	}
+
 	void ScriptGUIVector2DistributionField::Internal_create(MonoObject* managedInstance, __GUIContentInterop* labelContent, uint32_t labelWidth, MonoString* style)
 	{
 		GUIContent tmplabelContent;

+ 12 - 6
Source/EditorScript/Generated/BsScriptGUIVector2DistributionField.generated.h

@@ -7,6 +7,8 @@
 #include "../../bsf/Source/Foundation/bsfCore/Particles/BsParticleDistribution.h"
 #include "../../bsf/Source/Foundation/bsfCore/Localization/BsHString.h"
 #include "../../bsf/Source/Foundation/bsfCore/Particles/BsParticleDistribution.h"
+#include "../../bsf/Source/Foundation/bsfCore/Utility/BsCommonTypes.h"
+#include "../../bsf/Source/Foundation/bsfCore/Utility/BsCommonTypes.h"
 
 namespace bs
 {
@@ -21,21 +23,25 @@ namespace bs
 		ScriptGUIVector2DistributionField(MonoObject* managedInstance, GUIVector2DistributionField* value);
 
 	private:
-		void onClicked(int32_t p0);
-		void onConstantModified();
-		void onConstantConfirmed();
+		void onClicked(VectorComponent p0);
+		void onConstantModified(RangeComponent p0, VectorComponent p1);
+		void onConstantConfirmed(RangeComponent p0, VectorComponent p1);
+		void onConstantFocusChanged(bool p0, RangeComponent p1, VectorComponent p2);
 
-		typedef void(BS_THUNKCALL *onClickedThunkDef) (MonoObject*, int32_t p0, MonoException**);
+		typedef void(BS_THUNKCALL *onClickedThunkDef) (MonoObject*, VectorComponent p0, MonoException**);
 		static onClickedThunkDef onClickedThunk;
-		typedef void(BS_THUNKCALL *onConstantModifiedThunkDef) (MonoObject*, MonoException**);
+		typedef void(BS_THUNKCALL *onConstantModifiedThunkDef) (MonoObject*, RangeComponent p0, VectorComponent p1, MonoException**);
 		static onConstantModifiedThunkDef onConstantModifiedThunk;
-		typedef void(BS_THUNKCALL *onConstantConfirmedThunkDef) (MonoObject*, MonoException**);
+		typedef void(BS_THUNKCALL *onConstantConfirmedThunkDef) (MonoObject*, RangeComponent p0, VectorComponent p1, MonoException**);
 		static onConstantConfirmedThunkDef onConstantConfirmedThunk;
+		typedef void(BS_THUNKCALL *onConstantFocusChangedThunkDef) (MonoObject*, bool p0, RangeComponent p1, VectorComponent p2, MonoException**);
+		static onConstantFocusChangedThunkDef onConstantFocusChangedThunk;
 
 		static MonoObject* Internal_getValue(ScriptGUIVector2DistributionField* thisPtr);
 		static void Internal_setValue(ScriptGUIVector2DistributionField* thisPtr, MonoObject* value);
 		static PropertyDistributionType Internal_getType(ScriptGUIVector2DistributionField* thisPtr);
 		static bool Internal_hasInputFocus(ScriptGUIVector2DistributionField* thisPtr);
+		static void Internal_setInputFocus(ScriptGUIVector2DistributionField* thisPtr, RangeComponent rangeComponent, VectorComponent vectorComponent, bool focus);
 		static void Internal_create(MonoObject* managedInstance, __GUIContentInterop* labelContent, uint32_t labelWidth, MonoString* style);
 		static void Internal_create0(MonoObject* managedInstance, __GUIContentInterop* labelContent, MonoString* style);
 		static void Internal_create1(MonoObject* managedInstance, MonoObject* labelText, uint32_t labelWidth, MonoString* style);

+ 24 - 10
Source/EditorScript/Generated/BsScriptGUIVector3DistributionField.generated.cpp

@@ -15,13 +15,15 @@ namespace bs
 	ScriptGUIVector3DistributionField::onClickedThunkDef ScriptGUIVector3DistributionField::onClickedThunk; 
 	ScriptGUIVector3DistributionField::onConstantModifiedThunkDef ScriptGUIVector3DistributionField::onConstantModifiedThunk; 
 	ScriptGUIVector3DistributionField::onConstantConfirmedThunkDef ScriptGUIVector3DistributionField::onConstantConfirmedThunk; 
+	ScriptGUIVector3DistributionField::onConstantFocusChangedThunkDef ScriptGUIVector3DistributionField::onConstantFocusChangedThunk; 
 
 	ScriptGUIVector3DistributionField::ScriptGUIVector3DistributionField(MonoObject* managedInstance, GUIVector3DistributionField* value)
 		:TScriptGUIElement(managedInstance, value)
 	{
 		value->onClicked.connect(std::bind(&ScriptGUIVector3DistributionField::onClicked, this, std::placeholders::_1));
-		value->onConstantModified.connect(std::bind(&ScriptGUIVector3DistributionField::onConstantModified, this));
-		value->onConstantConfirmed.connect(std::bind(&ScriptGUIVector3DistributionField::onConstantConfirmed, this));
+		value->onConstantModified.connect(std::bind(&ScriptGUIVector3DistributionField::onConstantModified, this, std::placeholders::_1, std::placeholders::_2));
+		value->onConstantConfirmed.connect(std::bind(&ScriptGUIVector3DistributionField::onConstantConfirmed, this, std::placeholders::_1, std::placeholders::_2));
+		value->onConstantFocusChanged.connect(std::bind(&ScriptGUIVector3DistributionField::onConstantFocusChanged, this, std::placeholders::_1, std::placeholders::_2, std::placeholders::_3));
 	}
 
 	void ScriptGUIVector3DistributionField::initRuntimeData()
@@ -30,30 +32,37 @@ namespace bs
 		metaData.scriptClass->addInternalCall("Internal_setValue", (void*)&ScriptGUIVector3DistributionField::Internal_setValue);
 		metaData.scriptClass->addInternalCall("Internal_getType", (void*)&ScriptGUIVector3DistributionField::Internal_getType);
 		metaData.scriptClass->addInternalCall("Internal_hasInputFocus", (void*)&ScriptGUIVector3DistributionField::Internal_hasInputFocus);
+		metaData.scriptClass->addInternalCall("Internal_setInputFocus", (void*)&ScriptGUIVector3DistributionField::Internal_setInputFocus);
 		metaData.scriptClass->addInternalCall("Internal_create", (void*)&ScriptGUIVector3DistributionField::Internal_create);
 		metaData.scriptClass->addInternalCall("Internal_create0", (void*)&ScriptGUIVector3DistributionField::Internal_create0);
 		metaData.scriptClass->addInternalCall("Internal_create1", (void*)&ScriptGUIVector3DistributionField::Internal_create1);
 		metaData.scriptClass->addInternalCall("Internal_create2", (void*)&ScriptGUIVector3DistributionField::Internal_create2);
 		metaData.scriptClass->addInternalCall("Internal_create3", (void*)&ScriptGUIVector3DistributionField::Internal_create3);
 
-		onClickedThunk = (onClickedThunkDef)metaData.scriptClass->getMethodExact("Internal_onClicked", "int")->getThunk();
-		onConstantModifiedThunk = (onConstantModifiedThunkDef)metaData.scriptClass->getMethodExact("Internal_onConstantModified", "")->getThunk();
-		onConstantConfirmedThunk = (onConstantConfirmedThunkDef)metaData.scriptClass->getMethodExact("Internal_onConstantConfirmed", "")->getThunk();
+		onClickedThunk = (onClickedThunkDef)metaData.scriptClass->getMethodExact("Internal_onClicked", "VectorComponent")->getThunk();
+		onConstantModifiedThunk = (onConstantModifiedThunkDef)metaData.scriptClass->getMethodExact("Internal_onConstantModified", "RangeComponent,VectorComponent")->getThunk();
+		onConstantConfirmedThunk = (onConstantConfirmedThunkDef)metaData.scriptClass->getMethodExact("Internal_onConstantConfirmed", "RangeComponent,VectorComponent")->getThunk();
+		onConstantFocusChangedThunk = (onConstantFocusChangedThunkDef)metaData.scriptClass->getMethodExact("Internal_onConstantFocusChanged", "bool,RangeComponent,VectorComponent")->getThunk();
 	}
 
-	void ScriptGUIVector3DistributionField::onClicked(int32_t p0)
+	void ScriptGUIVector3DistributionField::onClicked(VectorComponent p0)
 	{
 		MonoUtil::invokeThunk(onClickedThunk, getManagedInstance(), p0);
 	}
 
-	void ScriptGUIVector3DistributionField::onConstantModified()
+	void ScriptGUIVector3DistributionField::onConstantModified(RangeComponent p0, VectorComponent p1)
 	{
-		MonoUtil::invokeThunk(onConstantModifiedThunk, getManagedInstance());
+		MonoUtil::invokeThunk(onConstantModifiedThunk, getManagedInstance(), p0, p1);
 	}
 
-	void ScriptGUIVector3DistributionField::onConstantConfirmed()
+	void ScriptGUIVector3DistributionField::onConstantConfirmed(RangeComponent p0, VectorComponent p1)
 	{
-		MonoUtil::invokeThunk(onConstantConfirmedThunk, getManagedInstance());
+		MonoUtil::invokeThunk(onConstantConfirmedThunk, getManagedInstance(), p0, p1);
+	}
+
+	void ScriptGUIVector3DistributionField::onConstantFocusChanged(bool p0, RangeComponent p1, VectorComponent p2)
+	{
+		MonoUtil::invokeThunk(onConstantFocusChangedThunk, getManagedInstance(), p0, p1, p2);
 	}
 	MonoObject* ScriptGUIVector3DistributionField::Internal_getValue(ScriptGUIVector3DistributionField* thisPtr)
 	{
@@ -98,6 +107,11 @@ namespace bs
 		return __output;
 	}
 
+	void ScriptGUIVector3DistributionField::Internal_setInputFocus(ScriptGUIVector3DistributionField* thisPtr, RangeComponent rangeComponent, VectorComponent vectorComponent, bool focus)
+	{
+		static_cast<GUIVector3DistributionField*>(thisPtr->getGUIElement())->setInputFocus(rangeComponent, vectorComponent, focus);
+	}
+
 	void ScriptGUIVector3DistributionField::Internal_create(MonoObject* managedInstance, __GUIContentInterop* labelContent, uint32_t labelWidth, MonoString* style)
 	{
 		GUIContent tmplabelContent;

+ 12 - 6
Source/EditorScript/Generated/BsScriptGUIVector3DistributionField.generated.h

@@ -7,6 +7,8 @@
 #include "../../bsf/Source/Foundation/bsfCore/Particles/BsParticleDistribution.h"
 #include "../../bsf/Source/Foundation/bsfCore/Localization/BsHString.h"
 #include "../../bsf/Source/Foundation/bsfCore/Particles/BsParticleDistribution.h"
+#include "../../bsf/Source/Foundation/bsfCore/Utility/BsCommonTypes.h"
+#include "../../bsf/Source/Foundation/bsfCore/Utility/BsCommonTypes.h"
 
 namespace bs
 {
@@ -21,21 +23,25 @@ namespace bs
 		ScriptGUIVector3DistributionField(MonoObject* managedInstance, GUIVector3DistributionField* value);
 
 	private:
-		void onClicked(int32_t p0);
-		void onConstantModified();
-		void onConstantConfirmed();
+		void onClicked(VectorComponent p0);
+		void onConstantModified(RangeComponent p0, VectorComponent p1);
+		void onConstantConfirmed(RangeComponent p0, VectorComponent p1);
+		void onConstantFocusChanged(bool p0, RangeComponent p1, VectorComponent p2);
 
-		typedef void(BS_THUNKCALL *onClickedThunkDef) (MonoObject*, int32_t p0, MonoException**);
+		typedef void(BS_THUNKCALL *onClickedThunkDef) (MonoObject*, VectorComponent p0, MonoException**);
 		static onClickedThunkDef onClickedThunk;
-		typedef void(BS_THUNKCALL *onConstantModifiedThunkDef) (MonoObject*, MonoException**);
+		typedef void(BS_THUNKCALL *onConstantModifiedThunkDef) (MonoObject*, RangeComponent p0, VectorComponent p1, MonoException**);
 		static onConstantModifiedThunkDef onConstantModifiedThunk;
-		typedef void(BS_THUNKCALL *onConstantConfirmedThunkDef) (MonoObject*, MonoException**);
+		typedef void(BS_THUNKCALL *onConstantConfirmedThunkDef) (MonoObject*, RangeComponent p0, VectorComponent p1, MonoException**);
 		static onConstantConfirmedThunkDef onConstantConfirmedThunk;
+		typedef void(BS_THUNKCALL *onConstantFocusChangedThunkDef) (MonoObject*, bool p0, RangeComponent p1, VectorComponent p2, MonoException**);
+		static onConstantFocusChangedThunkDef onConstantFocusChangedThunk;
 
 		static MonoObject* Internal_getValue(ScriptGUIVector3DistributionField* thisPtr);
 		static void Internal_setValue(ScriptGUIVector3DistributionField* thisPtr, MonoObject* value);
 		static PropertyDistributionType Internal_getType(ScriptGUIVector3DistributionField* thisPtr);
 		static bool Internal_hasInputFocus(ScriptGUIVector3DistributionField* thisPtr);
+		static void Internal_setInputFocus(ScriptGUIVector3DistributionField* thisPtr, RangeComponent rangeComponent, VectorComponent vectorComponent, bool focus);
 		static void Internal_create(MonoObject* managedInstance, __GUIContentInterop* labelContent, uint32_t labelWidth, MonoString* style);
 		static void Internal_create0(MonoObject* managedInstance, __GUIContentInterop* labelContent, MonoString* style);
 		static void Internal_create1(MonoObject* managedInstance, MonoObject* labelText, uint32_t labelWidth, MonoString* style);

+ 1 - 1
Source/bsf

@@ -1 +1 @@
-Subproject commit 8c96e634f506d6ab62f33a414da575b2ded00c58
+Subproject commit 076adfce461cf5a3d48ca8e9afd080fa76ddd8ab