diff --git a/Microsoft.Toolkit.Uwp.PlatformDifferencesGen/Program.cs b/Microsoft.Toolkit.Uwp.PlatformDifferencesGen/Program.cs index 2a9d17bee..429032bcb 100644 --- a/Microsoft.Toolkit.Uwp.PlatformDifferencesGen/Program.cs +++ b/Microsoft.Toolkit.Uwp.PlatformDifferencesGen/Program.cs @@ -24,6 +24,7 @@ namespace DifferencesGen public class Program { private static HashSet enumTypes = new HashSet(); + private static HashSet typeEvents = new HashSet(); public static void Main(string[] args) { @@ -120,10 +121,10 @@ namespace DifferencesGen { addedTypes.Add(type.Key, null); - if (enumTypes.Contains(type.Key)) - { - System.Diagnostics.Debug.WriteLine($"New enum {type.Key}"); - } + //if (enumTypes.Contains(type.Key)) + //{ + // System.Diagnostics.Debug.WriteLine($"New enum {type.Key}"); + //} continue; } @@ -138,9 +139,17 @@ namespace DifferencesGen continue; } - if (enumTypes.Contains(type.Key)) + //if (enumTypes.Contains(type.Key)) + //{ + // System.Diagnostics.Debug.WriteLine($"Enum {type.Key} has new members: {string.Join(",", newerVersionTypeMembers)}"); + //} + + foreach (var member in newerVersionTypeMembers) { - System.Diagnostics.Debug.WriteLine($"Enum {type.Key} has new members: {string.Join(",", newerVersionTypeMembers)}"); + if (typeEvents.Contains($"{type.Key}-{member}")) + { + System.Diagnostics.Debug.WriteLine($"Type {type.Key} has new event: {member}"); + } } addedTypes.Add(type.Key, newerVersionTypeMembers.ToList()); @@ -230,8 +239,7 @@ namespace DifferencesGen methodInfo.Name.StartsWith("set_") || methodInfo.Name.StartsWith("put_") || methodInfo.Name.StartsWith("add_") || - methodInfo.Name.StartsWith("remove_") - ) + methodInfo.Name.StartsWith("remove_")) { continue; } @@ -243,6 +251,12 @@ namespace DifferencesGen { members.Add(propertyInfo.Name); } + + foreach (var eventInfo in exportedType.GetEvents()) + { + typeEvents.Add($"{exportedType.FullName}-{eventInfo.Name}"); + members.Add(eventInfo.Name); + } } types.Add(exportedType.FullName, members); diff --git a/Microsoft.Toolkit.Uwp.PlatformSpecificAnalyzer/Differences-5.0.0.0.gz b/Microsoft.Toolkit.Uwp.PlatformSpecificAnalyzer/Differences-5.0.0.0.gz index 8bae34583..7d04654ec 100644 Binary files a/Microsoft.Toolkit.Uwp.PlatformSpecificAnalyzer/Differences-5.0.0.0.gz and b/Microsoft.Toolkit.Uwp.PlatformSpecificAnalyzer/Differences-5.0.0.0.gz differ diff --git a/Microsoft.Toolkit.Uwp.PlatformSpecificAnalyzer/Differences-6.0.0.0.gz b/Microsoft.Toolkit.Uwp.PlatformSpecificAnalyzer/Differences-6.0.0.0.gz index 882a28f2e..90a9ae8fe 100644 Binary files a/Microsoft.Toolkit.Uwp.PlatformSpecificAnalyzer/Differences-6.0.0.0.gz and b/Microsoft.Toolkit.Uwp.PlatformSpecificAnalyzer/Differences-6.0.0.0.gz differ