Ejemplo n.º 1
0
        void AddDropdownCallbackDelegate(Rect buttonRect, ReorderableList list)
        {
            var databases = new[]
            {
                TypeSearcherDatabase.GetBuildStepsDatabase(
                    new HashSet <Type>(BuildStep.GetAvailableTypes(type => !IsShown(type))), GetDisplayName),
            };

            var searcher = new Searcher(
                databases,
                new AddTypeSearcherAdapter("Add Build Step"));

            var editorWindow = EditorWindow.focusedWindow;

            SearcherWindow.Show(
                editorWindow,
                searcher,
                AddStep,
                buttonRect.min + Vector2.up * 35.0f,
                a => { },
                new SearcherWindow.Alignment(SearcherWindow.Alignment.Vertical.Top,
                                             SearcherWindow.Alignment.Horizontal.Left)
                );
        }