From 55182a7ce7dccabcebe704d051b3ea738c7a8e7d Mon Sep 17 00:00:00 2001 From: Marco Gavelli Date: Sun, 27 Sep 2020 17:53:21 +0200 Subject: [PATCH 1/2] Set Prefer32Bit to false --- Files.Launcher/Files.Launcher.csproj | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Files.Launcher/Files.Launcher.csproj b/Files.Launcher/Files.Launcher.csproj index 2f953e6ba9bc..53129c6b2c01 100644 --- a/Files.Launcher/Files.Launcher.csproj +++ b/Files.Launcher/Files.Launcher.csproj @@ -27,6 +27,7 @@ 4 8.0 false + false AnyCPU @@ -37,6 +38,7 @@ prompt 4 8.0 + false From 62228e1b3affaa9f94e7ba2699ebf4913ac32a99 Mon Sep 17 00:00:00 2001 From: Marco Gavelli Date: Sun, 27 Sep 2020 18:05:09 +0200 Subject: [PATCH 2/2] Add workaround for NVidia context menu --- Files.Launcher/Win32API_ContextMenu.cs | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/Files.Launcher/Win32API_ContextMenu.cs b/Files.Launcher/Win32API_ContextMenu.cs index 46e0f4c20acc..66e9fc5b67d9 100644 --- a/Files.Launcher/Win32API_ContextMenu.cs +++ b/Files.Launcher/Win32API_ContextMenu.cs @@ -288,6 +288,12 @@ private static void EnumMenuItems( private static string GetCommandString(Shell32.IContextMenu cMenu, uint offset, Shell32.GCS flags = Shell32.GCS.GCS_VERBW) { + if (offset > 5000) + { + // Hackish workaround to avoid an AccessViolationException on some items, + // notably the "Run with graphic processor" menu item of NVidia cards + return null; + } SafeCoTaskMemString commandString = null; try {