Version: 2021.2
public static Search.ISearchView ShowContextual (params string[] providerIds);

参数

providerIds Unique IDs of search providers to enable when opening the search view.

返回

ISearchView Returns the search view window instance.

描述

Open the search window using a specific context (activating specific filters).

[MenuItem("Tools/Search Menus _F1")]
public static void SearchMenuItems()
{
    SearchService.ShowContextual("menu");
}