Class UIButton
public class UIButton : MonoBehaviour
- Inheritance
-
UIButton
Fields
public Color backgroundColour
Field Value
- Color
public Color backgroundHoverColour
Field Value
- Color
public Color backgroundPressedColour
Field Value
- Color
Properties
public float height { get; set; }
Property Value
- float
public Sprite hoverImage { get; }
Property Value
- Sprite
public Sprite image { get; }
Property Value
- Sprite
public bool isPressed { get; }
Property Value
- bool
public Sprite pressedImage { get; }
Property Value
- Sprite
public float width { get; set; }
Property Value
- float
Methods
public void SetImages(Sprite image, Sprite hoverImage, Sprite pressedImage)
Parameters
image
Sprite
hoverImage
Sprite
pressedImage
Sprite
public void SetSortingLayer(string sortingLayer)
Parameters
sortingLayer
string
public void SetSortingLayer(string sortingLayer, int sortingOrder)
Parameters
sortingLayer
string
sortingOrder
int
public void SetSortingOrder(int sortingOrder)
Parameters
sortingOrder
int
SetText(string)
public void SetText(string text)
Parameters
text
string
public void SubscribeToClick(UnityAction call)
Parameters
call
UnityAction
public void SubscribeToHover(UnityAction call)
Parameters
call
UnityAction
public void SubscribeToIdle(UnityAction call)
Parameters
call
UnityAction
public void SubscribeToLeftClick(UnityAction call)
Parameters
call
UnityAction
public void SubscribeToRightClick(UnityAction call)
Parameters
call
UnityAction
public void UpdateDisplay()