From 05682c7dd98e85a95be6460999152b3bda0417ba Mon Sep 17 00:00:00 2001 From: Kurante <36455439+Kurante2801@users.noreply.github.com> Date: Fri, 19 Apr 2024 18:07:33 +0200 Subject: [PATCH 1/2] Add SetXWithoutNotify and SetYWithoutNotify to BoxSlider Adds functions to set the X and Y values without calling OnValueChanged --- Runtime/Scripts/Controls/Sliders/BoxSlider.cs | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/Runtime/Scripts/Controls/Sliders/BoxSlider.cs b/Runtime/Scripts/Controls/Sliders/BoxSlider.cs index 9360300..ce0e6b4 100644 --- a/Runtime/Scripts/Controls/Sliders/BoxSlider.cs +++ b/Runtime/Scripts/Controls/Sliders/BoxSlider.cs @@ -367,5 +367,14 @@ namespace UnityEngine.UI.Extensions eventData.useDragThreshold = false; } + public void SetXWithoutNotify(float x) + { + SetX(x, false); + } + + public void SetYWithoutNotify(float y) + { + SetY(y, false); + } } } From 86744455f1bc44b71b41718d96701b58ce39737c Mon Sep 17 00:00:00 2001 From: bluefallsky Date: Sun, 28 Apr 2024 20:48:09 +0900 Subject: [PATCH 2/2] fix radial triangle add order(#384) --- Runtime/Scripts/Effects/Gradient2.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Runtime/Scripts/Effects/Gradient2.cs b/Runtime/Scripts/Effects/Gradient2.cs index 624326a..2197b88 100644 --- a/Runtime/Scripts/Effects/Gradient2.cs +++ b/Runtime/Scripts/Effects/Gradient2.cs @@ -218,7 +218,7 @@ namespace UnityEngine.UI.Extensions helper.AddVert(centralVertex); - for (int i = 1; i < steps; i++) helper.AddTriangle(i - 1, i, steps); + for (int i = 1; i < steps; i++) helper.AddTriangle(i, i-1, steps); helper.AddTriangle(0, steps - 1, steps); }