~ubuntu-branches/ubuntu/wily/monodevelop/wily

« back to all changes in this revision

Viewing changes to src/core/MonoDevelop.Ide/MonoDevelop.Ide.Gui.Pads.ClassPad/ClassBrowserPadWidget.cs

  • Committer: Package Import Robot
  • Author(s): Jo Shields
  • Date: 2012-05-27 18:08:20 UTC
  • mfrom: (19.1.8 experimental)
  • Revision ID: package-import@ubuntu.com-20120527180820-fydl21qnbnfr8w2t
Tags: 3.0.2+dfsg-3
* [fcecfe7] Fix monodevelop-core-addins.pc.in to point to actual 
  installed location of assemblies.
* [26e1a07] DebSrc 3.0 does not support Quilt's -p parameter, so 
  manually adjust the path in the patch file.

Show diffs side-by-side

added added

removed removed

Lines of Context:
33
33
using Gdk;
34
34
using Gtk;
35
35
 
36
 
using MonoDevelop.Projects.Dom;
37
 
using MonoDevelop.Projects.Dom.Parser;
38
36
using MonoDevelop.Projects;
39
37
using MonoDevelop.Core;
40
38
using MonoDevelop.Ide.Gui;
41
39
using MonoDevelop.Ide.Gui.Components;
42
40
using MonoDevelop.Components.Docking;
 
41
using ICSharpCode.NRefactory.TypeSystem;
 
42
using MonoDevelop.Ide.TypeSystem;
43
43
 
44
44
namespace MonoDevelop.Ide.Gui.Pads.ClassBrowser
45
45
{
111
111
                                CancelSearchClicked (this, System.EventArgs.Empty);
112
112
                }
113
113
                
114
 
                List<IType> searchResults = new List<IType> ();
 
114
                List<ITypeDefinition> searchResults = new List<ITypeDefinition> ();
115
115
                Thread searchThread;
116
116
                object matchLock   = new object ();
117
117
                string matchString = string.Empty;
187
187
                        if (!IdeApp.Workspace.IsOpen)
188
188
                                return;
189
189
                        foreach (Project project in IdeApp.Workspace.GetAllProjects ()) {
190
 
                                ProjectDom dom = ProjectDomService.GetProjectDom (project);
 
190
                                var dom = TypeSystemService.GetCompilation (project);
191
191
                                if (dom == null)
192
192
                                        continue;
193
 
                                foreach (IType type in dom.Types) {
 
193
                                foreach (var type in dom.MainAssembly.TopLevelTypeDefinitions) {
194
194
                                        if (ShouldAdd (type)) {
195
195
                                                lock (searchResults) {
196
196
                                                        searchResults.Add (type);
208
208
                        lock (searchResults) {
209
209
                                int max = Math.Min (50, searchResults.Count);
210
210
                                for (int i = 0; i < max; i++) {
211
 
                                        list.AppendValues (ImageService.GetPixbuf (searchResults[i].StockIcon, Gtk.IconSize.Menu), searchResults[i].Name, searchResults[i]);
 
211
                                        list.AppendValues (ImageService.GetPixbuf (searchResults[i].GetStockIcon (), Gtk.IconSize.Menu), searchResults[i].Name, searchResults[i]);
212
212
                                }
213
213
                                searchResults.RemoveRange (0, max);
214
214
                                return searchResults.Count > 0;