Class UIDeselector
By default in Unity, UI elements that are selected will remain selected until another GameObject is selected/clicked on. This is not ideal in the case the user has a UI button selected, and then hovers over another UI button without selecting it. In that case, the user will see two highlighted UI buttons. Attach this script to Selectables that you want to deselect if the user mouses off them.
Inheritance
System.Object
UIDeselector
Implements
IPointerExitHandler
Namespace: Ride
Assembly: cs.temp.dll.dll
Syntax
public class UIDeselector : MonoBehaviour
Methods
Name | Description |
---|---|
OnPointerExit(PointerEventData) |