[SHLWAPI]

* SHInvokeDefaultCommand is supposed to invoke the DEFAULT command, so why was bInvokeDefault given FALSE?!

[RSHELL]
* A couple of trivial fixes.

[NTUSER/USER32]
* I missed two bits. See CORE-7966 for more info on the menu issue.

CORE-7586

svn path=/branches/shell-experiments/; revision=62420
This commit is contained in:
David Quintana 2014-03-05 09:12:40 +00:00
parent d1e5c6a2b9
commit 11e4273379
5 changed files with 6 additions and 6 deletions

View file

@ -517,7 +517,7 @@ BOOL CMenuDeskBar::_IsSubMenuParent(HWND hwnd)
popup = NULL; popup = NULL;
hr = IUnknown_GetSite(window, IID_PPV_ARG(IMenuPopup, &popup)); hr = IUnknown_GetSite(window, IID_PPV_ARG(IMenuPopup, &popup));
if (FAILED_UNEXPECTEDLY(hr)) if (FAILED(hr))
return FALSE; return FALSE;
} }

View file

@ -816,7 +816,7 @@ HRESULT CMenuStaticToolbar::FillToolbar()
{ {
AddSeparator(last); AddSeparator(last);
} }
else // if (info.fType == MFT_STRING) else if (!(info.fType & MFT_BITMAP))
{ {
info.cch++; info.cch++;

View file

@ -1,4 +1,4 @@
/* /*
* SHLWAPI ordinal functions * SHLWAPI ordinal functions
* *
* Copyright 1997 Marcus Meissner * Copyright 1997 Marcus Meissner
@ -2911,7 +2911,7 @@ HWND WINAPI SHCreateWorkerWindowW(LONG wndProc, HWND hWndParent, DWORD dwExStyle
HRESULT WINAPI SHInvokeDefaultCommand(HWND hWnd, IShellFolder* lpFolder, LPCITEMIDLIST lpApidl) HRESULT WINAPI SHInvokeDefaultCommand(HWND hWnd, IShellFolder* lpFolder, LPCITEMIDLIST lpApidl)
{ {
TRACE("%p %p %p\n", hWnd, lpFolder, lpApidl); TRACE("%p %p %p\n", hWnd, lpFolder, lpApidl);
return SHInvokeCommand(hWnd, lpFolder, lpApidl, FALSE); return SHInvokeCommand(hWnd, lpFolder, lpApidl, TRUE);
} }
/************************************************************************* /*************************************************************************

View file

@ -976,7 +976,7 @@ IntGetSystemMenu(PWND Window, BOOL bRevert, BOOL RetMenu)
ItemInfo.cbSize = sizeof(MENUITEMINFOW); ItemInfo.cbSize = sizeof(MENUITEMINFOW);
ItemInfo.fMask = MIIM_FTYPE | MIIM_STRING | MIIM_STATE | MIIM_SUBMENU; ItemInfo.fMask = MIIM_FTYPE | MIIM_STRING | MIIM_STATE | MIIM_SUBMENU;
ItemInfo.fType = MF_POPUP; ItemInfo.fType = 0;
ItemInfo.fState = MFS_ENABLED; ItemInfo.fState = MFS_ENABLED;
ItemInfo.dwTypeData = NULL; ItemInfo.dwTypeData = NULL;
ItemInfo.cch = 0; ItemInfo.cch = 0;

View file

@ -1696,7 +1696,7 @@ static void FASTCALL MenuSelectItem(HWND hwndOwner, PROSMENUINFO hmenu, UINT wIn
SendMessageW(hwndOwner, WM_MENUSELECT, SendMessageW(hwndOwner, WM_MENUSELECT,
MAKELONG(ItemInfo.hSubMenu ? wIndex : ItemInfo.wID, MAKELONG(ItemInfo.hSubMenu ? wIndex : ItemInfo.wID,
ItemInfo.fType | ItemInfo.fState | MF_MOUSESELECT | ItemInfo.fType | ItemInfo.fState | MF_MOUSESELECT |
(hmenu->Flags & MF_SYSMENU)), (LPARAM) hmenu->Self); (hmenu->Flags & (MF_SYSMENU|MF_POPUP))), (LPARAM) hmenu->Self);
} }
} }
} }