Ejemplo n.º 1
0
        private void AddSearchScopes()
        {
            var searchService = Editor.Services.GetInstance <ISearchService>();

            if (searchService != null)
            {
                _currentSelectionSearchScope = new CurrentSelectionSearchScope(_documentService);
                searchService.SearchScopes.Insert(0, _currentSelectionSearchScope);
            }
        }
Ejemplo n.º 2
0
        private void RemoveSearchScopes()
        {
            var searchService = Editor.Services.GetInstance <ISearchService>();

            if (searchService != null && _currentSelectionSearchScope != null)
            {
                searchService.SearchScopes.Remove(_currentSelectionSearchScope);
            }

            _currentSelectionSearchScope = null;
        }