Class SearchAction | Quick Search | 1.5.4
docs.unity3d.com
    Show / Hide Table of Contents

    Class SearchAction

    Inheritance
    Object
    SearchAction
    Namespace: Unity.QuickSearch
    Syntax
    public class SearchAction

    Constructors

    SearchAction(String, GUIContent)

    Default constructor to build a search action.

    Declaration
    public SearchAction(string type, GUIContent content)
    Parameters
    Type Name Description
    String type
    GUIContent content

    SearchAction(String, String, Texture2D, String)

    Extended constructor to build a search action.

    Declaration
    public SearchAction(string type, string name, Texture2D icon = null, string tooltip = null)
    Parameters
    Type Name Description
    String type
    String name
    Texture2D icon
    String tooltip

    Fields

    closeWindowAfterExecution

    Indicates if the search view should be closed after the action execution.

    Declaration
    public bool closeWindowAfterExecution
    Field Value
    Type Description
    Boolean

    handler

    Called when an item is executed with this action

    Declaration
    public Action<SearchItem, SearchContext> handler
    Field Value
    Type Description
    Action<SearchItem, SearchContext>

    isEnabled

    Called before displaying the menu to see if an action is available for a given item.

    Declaration
    public Func<SearchItem, SearchContext, bool> isEnabled
    Field Value
    Type Description
    Func<SearchItem, SearchContext, Boolean>

    kContextualMenuAction

    Unique ID used for contextual action (i.e. to pop a contextual menu when the user right click on an item).

    Declaration
    public const string kContextualMenuAction = "context"
    Field Value
    Type Description
    String

    Properties

    DisplayName

    Name used to display

    Declaration
    public string DisplayName { get; }
    Property Value
    Type Description
    String

    Id

    Action unique identifier.

    Declaration
    public string Id { get; }
    Property Value
    Type Description
    String
    Back to top
    Copyright © 2023 Unity Technologies — Terms of use
    • Legal
    • Privacy Policy
    • Cookies
    • Do Not Sell or Share My Personal Information
    • Your Privacy Choices (Cookie Settings)
    "Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
    Generated by DocFX on 18 October 2023