From b258f2977285f8534577ae67ce435c9a18902c7d Mon Sep 17 00:00:00 2001 From: Giannis Adamopoulos Date: Sun, 29 Mar 2015 00:37:39 +0000 Subject: [PATCH] [SHELL32] - Load the shell extensions of the * class only for files. CORE-6806 svn path=/trunk/; revision=66944 --- .../dll/win32/shell32/CDefaultContextMenu.cpp | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) diff --git a/reactos/dll/win32/shell32/CDefaultContextMenu.cpp b/reactos/dll/win32/shell32/CDefaultContextMenu.cpp index 233dbd5849c..e870b3ddb35 100644 --- a/reactos/dll/win32/shell32/CDefaultContextMenu.cpp +++ b/reactos/dll/win32/shell32/CDefaultContextMenu.cpp @@ -760,13 +760,6 @@ CDefaultContextMenu::BuildShellItemContextMenu( } } } - - if (RegOpenKeyExW(HKEY_CLASSES_ROOT, L"*", 0, KEY_READ, &hKey) == ERROR_SUCCESS) - { - /* load default extensions */ - EnumerateDynamicContextHandlerForKey(hKey); - RegCloseKey(hKey); - } } } else @@ -845,6 +838,15 @@ CDefaultContextMenu::BuildShellItemContextMenu( EnumerateDynamicContextHandlerForKey(hKey); RegCloseKey(hKey); } + + if (!(rfg & SFGAO_FOLDER)) + { + if (RegOpenKeyExW(HKEY_CLASSES_ROOT, L"*", 0, KEY_READ, &hKey) == ERROR_SUCCESS) + { + EnumerateDynamicContextHandlerForKey(hKey); + RegCloseKey(hKey); + } + } } /* add static context menu handlers */