From 1002db24f219b8d81f2e9a5dc0016f08f8a1f1bf Mon Sep 17 00:00:00 2001 From: Simon Jackson Date: Sat, 4 Feb 2023 10:30:40 +0000 Subject: [PATCH] Resolves issue in 2022 with the missing Text component Fixes: https://github.com/Unity-UI-Extensions/com.unity.uiextensions/issues/424 --- Runtime/Scripts/Controls/ComboBox/DropDownListButton.cs | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/Runtime/Scripts/Controls/ComboBox/DropDownListButton.cs b/Runtime/Scripts/Controls/ComboBox/DropDownListButton.cs index 2558fba..19cc182 100644 --- a/Runtime/Scripts/Controls/ComboBox/DropDownListButton.cs +++ b/Runtime/Scripts/Controls/ComboBox/DropDownListButton.cs @@ -8,7 +8,11 @@ namespace UnityEngine.UI.Extensions { public RectTransform rectTransform; public Button btn; +#if UNITY_2022_1_OR_NEWER + public TMPro.TMP_Text txt; +#else public Text txt; +#endif public Image btnImg; public Image img; public GameObject gameobject; @@ -19,7 +23,11 @@ namespace UnityEngine.UI.Extensions rectTransform = btnObj.GetComponent(); btnImg = btnObj.GetComponent(); btn = btnObj.GetComponent