diff --git a/Plugins/Flow.Launcher.Plugin.Explorer/Helper/ShellContextMenuDisplayHelper.cs b/Plugins/Flow.Launcher.Plugin.Explorer/Helper/ShellContextMenuDisplayHelper.cs index e7694cea5..304c47cb6 100644 --- a/Plugins/Flow.Launcher.Plugin.Explorer/Helper/ShellContextMenuDisplayHelper.cs +++ b/Plugins/Flow.Launcher.Plugin.Explorer/Helper/ShellContextMenuDisplayHelper.cs @@ -4,6 +4,7 @@ using System.IO; using System.Linq; using System.Runtime.InteropServices; using System.Text; +using System.Threading; using System.Windows; using System.Windows.Interop; using System.Windows.Media; @@ -275,6 +276,10 @@ public static class ShellContextMenuDisplayHelper contextMenu = (IContextMenu)Marshal.GetTypedObjectForIUnknown(pContextMenu, typeof(IContextMenu)); + // Without waiting, some items, such as "Send to > Documents", don't always appear, which shifts item ids + // even though it shouldn't. Please replace this if you find a better way to fix this bug. + Thread.Sleep(200); + hMenu = CreatePopupMenu(); contextMenu.QueryContextMenu(hMenu, 0, ContextMenuStartId, ContextMenuEndId, (uint)ContextMenuFlags.Explore);