예제 #1
0
        public MemberPickerVM(Language language, ITreeViewNodeFilter filter, IEnumerable <LoadedAssembly> assemblies)
        {
            this.Language        = language;
            this.ShowInternalApi = true;
            this.filter          = filter;
            this.origFilter      = filter;

            assemblyList = new AssemblyList("Member Picker List", false);
            foreach (var asm in assemblies)
            {
                assemblyList.ForceAddAssemblyToList(asm, true, false, -1, false);
            }

            this.assemblyListTreeNode             = new AssemblyListTreeNode(assemblyList);
            this.assemblyListTreeNode.DisableDrop = true;
            if (assemblyListTreeNode.Children.Count > 0)
            {
                SelectedItem = assemblyListTreeNode.Children[0];
            }

            // Make sure we don't hook this event before the assembly list node because we depend
            // on the new asm node being present when we restart the search.
            assemblyList.CollectionChanged += (s, e) => RestartSearch();

            CreateNewFilterSettings();
        }
예제 #2
0
        public MemberPickerVM(Language language, ITreeViewNodeFilter filter, IEnumerable<LoadedAssembly> assemblies)
        {
            this.Language = language;
            this.ShowInternalApi = true;
            this.filter = filter;
            this.origFilter = filter;

            assemblyList = new AssemblyList("Member Picker List", false);
            foreach (var asm in assemblies)
                assemblyList.ForceAddAssemblyToList(asm, true, false, -1, false);

            this.assemblyListTreeNode = new AssemblyListTreeNode(assemblyList);
            this.assemblyListTreeNode.DisableDrop = true;
            if (assemblyListTreeNode.Children.Count > 0)
                SelectedItem = assemblyListTreeNode.Children[0];

            // Make sure we don't hook this event before the assembly list node because we depend
            // on the new asm node being present when we restart the search.
            assemblyList.CollectionChanged += (s, e) => RestartSearch();

            CreateNewFilterSettings();
        }