summaryrefslogtreecommitdiff
path: root/Client/Assets/Scripts/XMainClient/UI/GuildMiniReportItem.cs
blob: c1f987daeeb3a9471b93cb4b0f2cf4a7d605b135 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
using System;
using UILib;
using UnityEngine;

namespace XMainClient.UI
{
	public class GuildMiniReportItem : MonoBehaviour
	{
		public IXUILabel m_lblContent;

		public IXUISprite m_sprRoot;

		private void Awake()
		{
			this.m_sprRoot = (base.GetComponent("XUISprite") as IXUISprite);
			this.m_lblContent = (base.transform.Find("content").GetComponent("XUILabel") as IXUILabel);
		}

		public void Refresh(string content)
		{
			bool flag = this.m_lblContent != null && !string.IsNullOrEmpty(content);
			if (flag)
			{
				this.m_lblContent.SetText(content);
				this.m_sprRoot.spriteHeight = 10 + this.m_lblContent.spriteHeight;
			}
		}
	}
}