diff --git a/src/modules/launcher/Plugins/Microsoft.Plugin.WindowWalker/Components/OpenWindows.cs b/src/modules/launcher/Plugins/Microsoft.Plugin.WindowWalker/Components/OpenWindows.cs index fccf71c5d9..af135a238d 100644 --- a/src/modules/launcher/Plugins/Microsoft.Plugin.WindowWalker/Components/OpenWindows.cs +++ b/src/modules/launcher/Plugins/Microsoft.Plugin.WindowWalker/Components/OpenWindows.cs @@ -5,6 +5,8 @@ // Code forked from Betsegaw Tadele's https://github.com/betsegaw/windowwalker/ using System; using System.Collections.Generic; +using System.Diagnostics; +using System.IO; namespace Microsoft.Plugin.WindowWalker.Components { @@ -13,6 +15,11 @@ namespace Microsoft.Plugin.WindowWalker.Components /// internal class OpenWindows { + /// + /// PowerLauncher main executable + /// + private static readonly string _powerLauncherExe = Path.GetFileName(Process.GetCurrentProcess().MainModule.FileName); + /// /// Delegate handler for open windows updates /// @@ -86,7 +93,7 @@ namespace Microsoft.Plugin.WindowWalker.Components if (newWindow.IsWindow && newWindow.Visible && newWindow.IsOwner && (!newWindow.IsToolWindow || newWindow.IsAppWindow) && !newWindow.TaskListDeleted && - newWindow.ClassName != "Windows.UI.Core.CoreWindow") + newWindow.ClassName != "Windows.UI.Core.CoreWindow" && newWindow.ProcessName != _powerLauncherExe) { windows.Add(newWindow); }