Merged in sushanta1991/unity-ui-extensions-3/sushanta-chakraborty/textpiccs-edited-online-with-bitbucket-1-1565460043403 (pull request #54)
TextPic.cs edited online with Bitbucket Approved-by: sushanta chakraborty <kumar.suresh761651@gmail.com> Approved-by: Simon Jackson <darkside@xna-uk.net>pull/413/head
commit
9dac6864c1
|
@ -339,7 +339,7 @@ namespace UnityEngine.UI.Extensions {
|
||||||
m_HrefInfos.Add(hrefInfo);
|
m_HrefInfos.Add(hrefInfo);
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
if (m_HrefInfos.Count > 0) {
|
if (count <= m_HrefInfos.Count - 1) {
|
||||||
// Hyperlinks in text starting index
|
// Hyperlinks in text starting index
|
||||||
m_HrefInfos[count].startIndex = (usesNewRendering ? s_TextBuilder.Length : s_TextBuilder.Length * 4);
|
m_HrefInfos[count].startIndex = (usesNewRendering ? s_TextBuilder.Length : s_TextBuilder.Length * 4);
|
||||||
m_HrefInfos[count].endIndex = (usesNewRendering ? (s_TextBuilder.Length + href_matches[i].Groups[2].Length - 1) : (s_TextBuilder.Length + href_matches[i].Groups[2].Length - 1) * 4 + 3);
|
m_HrefInfos[count].endIndex = (usesNewRendering ? (s_TextBuilder.Length + href_matches[i].Groups[2].Length - 1) : (s_TextBuilder.Length + href_matches[i].Groups[2].Length - 1) * 4 + 3);
|
||||||
|
@ -624,12 +624,14 @@ namespace UnityEngine.UI.Extensions {
|
||||||
// Update the quad images
|
// Update the quad images
|
||||||
updateQuad = true;
|
updateQuad = true;
|
||||||
|
|
||||||
|
if (inspectorIconList != null) {
|
||||||
for (int i = 0; i < inspectorIconList.Length; i++) {
|
for (int i = 0; i < inspectorIconList.Length; i++) {
|
||||||
if (inspectorIconList[i].scale == Vector2.zero) {
|
if (inspectorIconList[i].scale == Vector2.zero) {
|
||||||
inspectorIconList[i].scale = Vector2.one;
|
inspectorIconList[i].scale = Vector2.one;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
protected override void OnEnable() {
|
protected override void OnEnable() {
|
||||||
|
|
Loading…
Reference in New Issue