mirror of
https://github.com/reactos/reactos.git
synced 2024-08-03 01:50:57 +00:00
Fix menu leaks in explorer
svn path=/trunk/; revision=34284
This commit is contained in:
parent
9865603d81
commit
32111e8715
|
@ -656,6 +656,7 @@ HRESULT DesktopShellView::DoDesktopContextMenu(int x, int y)
|
|||
}
|
||||
} else
|
||||
_cm_ifs.reset();
|
||||
DestroyMenu(hmenu);
|
||||
}
|
||||
|
||||
pcm->Release();
|
||||
|
|
|
@ -855,6 +855,8 @@ PopupMenu::PopupMenu(UINT nid)
|
|||
{
|
||||
HMENU hMenu = LoadMenu(g_Globals._hInstance, MAKEINTRESOURCE(nid));
|
||||
_hmenu = GetSubMenu(hMenu, 0);
|
||||
RemoveMenu(hMenu, 0, MF_BYPOSITION);
|
||||
DestroyMenu(hMenu);
|
||||
}
|
||||
|
||||
|
||||
|
|
|
@ -566,6 +566,7 @@ HRESULT ShellFolderContextMenu(IShellFolder* shell_folder, HWND hwndParent, int
|
|||
}
|
||||
} else
|
||||
cm_ifs.reset();
|
||||
DestroyMenu(hmenu);
|
||||
}
|
||||
|
||||
pcm->Release();
|
||||
|
|
|
@ -663,6 +663,11 @@ struct PopupMenu
|
|||
{
|
||||
}
|
||||
|
||||
~PopupMenu()
|
||||
{
|
||||
DestroyMenu(_hmenu);
|
||||
}
|
||||
|
||||
PopupMenu(UINT nid);
|
||||
|
||||
operator HMENU() {return _hmenu;}
|
||||
|
|
Loading…
Reference in a new issue