In my application I need to get a list of all windows.
var windows = Application.Current.Windows;
If I run my application in debug mode I see not only my forms in the list, but also instances of Microsoft.XamlDiagnostics.WpfTap.WpfVisualTreeService.Adorners.AdornerLayerWindow created by Visual Studio debugging tool for XAML.
What is the right way to filter list of windows to ignore windows created by debugging tool? I don't want to reference additional assembly and check if
window is AdornerLayerWindow
and I don't want to filter like
window.GetType().Name != "AdornerLayerWindow"
Any other ideas?