docs.unity3d.com
Search Results for

    Show / Hide Table of Contents

    Interface IUpdateSelectedHandler

    Interface to implement if you wish to receive OnUpdateSelected callbacks.

    Namespace: UnityEngine.EventSystems
    Assembly: UnityEngine.UI.dll
    Syntax
    public interface IUpdateSelectedHandler : IEventSystemHandler
    Remarks

    Criteria for this event is implementation dependent. For example see StandAloneInputModule.

    Methods

    OnUpdateSelected(BaseEventData)

    Called by the EventSystem when the object associated with this EventTrigger is updated.

    Declaration
    void OnUpdateSelected(BaseEventData eventData)
    Parameters
    Type Name Description
    BaseEventData eventData
    Examples
    using UnityEngine;
    using UnityEngine.EventSystems;
    
    public class UpdateSelectedExample : MonoBehaviour, IUpdateSelectedHandler
    {
        public void OnUpdateSelected(BaseEventData data)
        {
            Debug.Log("OnUpdateSelected called.");
        }
    }
    In This Article
    Back to top
    Copyright © 2024 Unity Technologies — Trademarks and terms of use
    • Legal
    • Privacy Policy
    • Cookie Policy
    • Do Not Sell or Share My Personal Information
    • Your Privacy Choices (Cookie Settings)