File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -32,6 +32,19 @@ public bool Equals(ProjectItemWrapper other)
3232 }
3333 }
3434
35+ public class ProjectItemComparer : IEqualityComparer < ProjectItemWrapper >
36+ {
37+ public bool Equals ( ProjectItemWrapper x , ProjectItemWrapper y )
38+ {
39+ return x . Equals ( y ) ;
40+ }
41+
42+ public int GetHashCode ( ProjectItemWrapper obj )
43+ {
44+ return obj . Filename . GetHashCode ( ) ;
45+ }
46+ }
47+
3548 /// <summary>
3649 /// This is the class that implements the package exposed by this assembly.
3750 ///
@@ -199,13 +212,19 @@ private IEnumerable<ProjectItemWrapper> EnumerateProjectItems(ProjectItems items
199212
200213 private void MenuItemCallback ( object sender , EventArgs e )
201214 {
202- var projItems = new List < ProjectItemWrapper > ( ) ;
215+ var projItems = new Dictionary < string , ProjectItemWrapper > ( StringComparer . Ordinal ) ;
203216 foreach ( var proj in GetProjects ( ) )
204217 {
205- projItems . AddRange ( EnumerateProjectItems ( proj . ProjectItems ) ) ;
218+ foreach ( var item in EnumerateProjectItems ( proj . ProjectItems ) )
219+ {
220+ if ( ! projItems . ContainsKey ( item . Filename ) )
221+ {
222+ projItems . Add ( item . Filename , item ) ;
223+ }
224+ }
206225 }
207226
208- var wnd = new ListFiles ( projItems ) ;
227+ var wnd = new ListFiles ( projItems . Values ) ;
209228 wnd . Owner = HwndSource . FromHwnd ( new IntPtr ( GetActiveIDE ( ) . MainWindow . HWnd ) ) . RootVisual as System . Windows . Window ;
210229 wnd . Width = wnd . Owner . Width / 2 ;
211230 wnd . Height = wnd . Owner . Height / 3 ;
Original file line number Diff line number Diff line change 2929// You can specify all the values or you can default the Revision and Build Numbers
3030// by using the '*' as shown below:
3131
32- [ assembly: AssemblyVersion ( "1.11.3 .0" ) ]
33- [ assembly: AssemblyFileVersion ( "1.11.3 .0" ) ]
32+ [ assembly: AssemblyVersion ( "1.11.4 .0" ) ]
33+ [ assembly: AssemblyFileVersion ( "1.11.4 .0" ) ]
3434
3535
3636
Original file line number Diff line number Diff line change 11<?xml version =" 1.0" encoding =" utf-8" ?>
22<PackageManifest Version =" 2.0.0" xmlns =" http://schemas.microsoft.com/developer/vsx-schema/2011" xmlns : d =" http://schemas.microsoft.com/developer/vsx-schema-design/2011" >
33 <Metadata >
4- <Identity Id =" 6bb18fff-9e74-4deb-97df-6a94ddafb74e" Version =" 1.11.3 " Language =" en-US" Publisher =" Pernicious Games" />
4+ <Identity Id =" 6bb18fff-9e74-4deb-97df-6a94ddafb74e" Version =" 1.11.4 " Language =" en-US" Publisher =" Pernicious Games" />
55 <DisplayName >OpenFileInSolution</DisplayName >
66 <Description >Shows a list of all files in the current solution and allows quickly filtering and opening them.</Description >
77 <License >LICENSE</License >
You can’t perform that action at this time.
0 commit comments