| | |
| | | }
|
| | |
|
| | | [XLua.LuaCallCSharp]
|
| | | public static void SetColorful(this Button _btn, Text _btnTxt, bool _colorful)
|
| | | {
|
| | | if (_btn != null)
|
| | | {
|
| | | var imageEx = _btn.image as ImageEx;
|
| | | if (imageEx != null)
|
| | | {
|
| | | imageEx.gray = !_colorful;
|
| | | }
|
| | | }
|
| | | if (_btnTxt != null)
|
| | | {
|
| | | _btnTxt.color = UIHelper.GetUIColor(_colorful ? TextColType.NavyBrown : TextColType.White);
|
| | | _btnTxt.color = _btnTxt.color.SetA(_colorful ? 1 : 0.5f);
|
| | | }
|
| | | }
|
| | |
|
| | | [XLua.LuaCallCSharp]
|
| | | public static void SetInteractable(this Button _btn, Text _btnText, bool _interactable)
|
| | | {
|
| | | if (_btn != null)
|