Skip to content

Commit 76041fa

Browse files
committed
WInMergeContextMenu.dll: Disable advanced menu due to stability issues
1 parent 5aa19f9 commit 76041fa

File tree

2 files changed

+6
-8
lines changed

2 files changed

+6
-8
lines changed

ShellExtension/Common/WinMergeContextMenu.cpp

+1-7
Original file line numberDiff line numberDiff line change
@@ -238,17 +238,13 @@ HRESULT WinMergeContextMenu::InvokeCommand(DWORD verb)
238238

239239
if (verb == CMD_COMPARE)
240240
{
241+
bCompare = TRUE;
241242
switch (m_dwMenuState)
242243
{
243-
case MENU_SIMPLE:
244-
bCompare = TRUE;
245-
break;
246-
247244
case MENU_ONESEL_PREV:
248245
m_strPaths.resize(2);
249246
m_strPaths[1] = m_strPaths[0];
250247
m_strPaths[0] = m_strPreviousPaths[0];
251-
bCompare = TRUE;
252248

253249
// Forget previous selection
254250
if (reg.Open(HKEY_CURRENT_USER, f_RegDir) == ERROR_SUCCESS)
@@ -263,7 +259,6 @@ HRESULT WinMergeContextMenu::InvokeCommand(DWORD verb)
263259
m_strPaths[2] = m_strPaths[0];
264260
m_strPaths[0] = m_strPreviousPaths[0];
265261
m_strPaths[1] = m_strPreviousPaths[1];
266-
bCompare = TRUE;
267262

268263
// Forget previous selection
269264
if (reg.Open(HKEY_CURRENT_USER, f_RegDir) == ERROR_SUCCESS)
@@ -276,7 +271,6 @@ HRESULT WinMergeContextMenu::InvokeCommand(DWORD verb)
276271
case MENU_TWOSEL:
277272
case MENU_THREESEL:
278273
// "Compare" - compare m_strPaths
279-
bCompare = TRUE;
280274
m_strPreviousPaths[0].erase();
281275
m_strPreviousPaths[1].erase();
282276
break;

ShellExtension/WinMergeContextMenu/dllmain.cpp

+5-1
Original file line numberDiff line numberDiff line change
@@ -300,7 +300,7 @@ class __declspec(uuid("90340779-F37E-468E-9728-A2593498ED32")) WinMergeFileDirEx
300300
, WinMergeExplorerCommandBase(&m_contextMenu)
301301
{
302302
}
303-
const wchar_t* Title() override { return L"WinMerge"; }
303+
const wchar_t* Title() override { return L"&WinMerge"; }
304304
const int IconId(_In_opt_ IShellItemArray* selection) override
305305
{
306306
auto paths = GetPaths(selection);
@@ -311,10 +311,14 @@ class __declspec(uuid("90340779-F37E-468E-9728-A2593498ED32")) WinMergeFileDirEx
311311
const int Verb() override { return WinMergeContextMenu::CMD_COMPARE; }
312312
const EXPCMDFLAGS Flags() override
313313
{
314+
// Due to stability issues, the advanced menu is currently disabled.
315+
return ECF_DEFAULT;
316+
/*
314317
if ((m_contextMenu.GetContextMenuEnabled() & (WinMergeContextMenu::EXT_ENABLED | WinMergeContextMenu::EXT_ADVANCED)) == (WinMergeContextMenu::EXT_ENABLED | WinMergeContextMenu::EXT_ADVANCED))
315318
return ECF_HASSUBCOMMANDS;
316319
else
317320
return ECF_DEFAULT;
321+
*/
318322
}
319323
const EXPCMDSTATE State(_In_opt_ IShellItemArray* selection) override
320324
{

0 commit comments

Comments
 (0)