Author: gadamopoulos
Date: Tue Nov 29 15:38:55 2016
New Revision: 73405
URL:
http://svn.reactos.org/svn/reactos?rev=73405&view=rev
Log:
[SHELL32]
- CDefViewBckgrndMenu : Add class to handle the background menu of the CDefView and handle
stuff that previously were handled by CDefaultContextMenu. Let the shell folders fill
their own part of the background context menu.
- CDefView: Create a CDefViewBckgrndMenu instead of a CDefaultContextMenu which was
completely wrong.
- CDesktopFolder, CFSFolder: Implement returning the background context menu in
CreateViewObject. Note that I am not completely sure that the callback should be adding
the Properties item.
- CDefaultContextMenu: Remove code that was moved to CDefViewBckgrndMenu and try to
improve the overzealous debug prints regarding the shell extensions.
CORE-12410, CORE-12472
Added:
trunk/reactos/dll/win32/shell32/CDefViewBckgrndMenu.cpp (with props)
Modified:
trunk/reactos/dll/win32/shell32/CDefView.cpp
trunk/reactos/dll/win32/shell32/CDefaultContextMenu.cpp
trunk/reactos/dll/win32/shell32/CMakeLists.txt
trunk/reactos/dll/win32/shell32/folders/CDesktopFolder.cpp
trunk/reactos/dll/win32/shell32/folders/CDesktopFolder.h
trunk/reactos/dll/win32/shell32/folders/CFSFolder.cpp
trunk/reactos/dll/win32/shell32/lang/bg-BG.rc
trunk/reactos/dll/win32/shell32/lang/ca-ES.rc
trunk/reactos/dll/win32/shell32/lang/cs-CZ.rc
trunk/reactos/dll/win32/shell32/lang/da-DK.rc
trunk/reactos/dll/win32/shell32/lang/de-DE.rc
trunk/reactos/dll/win32/shell32/lang/el-GR.rc
trunk/reactos/dll/win32/shell32/lang/en-GB.rc
trunk/reactos/dll/win32/shell32/lang/en-US.rc
trunk/reactos/dll/win32/shell32/lang/es-ES.rc
trunk/reactos/dll/win32/shell32/lang/fi-FI.rc
trunk/reactos/dll/win32/shell32/lang/fr-FR.rc
trunk/reactos/dll/win32/shell32/lang/he-IL.rc
trunk/reactos/dll/win32/shell32/lang/hu-HU.rc
trunk/reactos/dll/win32/shell32/lang/it-IT.rc
trunk/reactos/dll/win32/shell32/lang/ja-JP.rc
trunk/reactos/dll/win32/shell32/lang/ko-KR.rc
trunk/reactos/dll/win32/shell32/lang/nl-NL.rc
trunk/reactos/dll/win32/shell32/lang/no-NO.rc
trunk/reactos/dll/win32/shell32/lang/pl-PL.rc
trunk/reactos/dll/win32/shell32/lang/pt-BR.rc
trunk/reactos/dll/win32/shell32/lang/pt-PT.rc
trunk/reactos/dll/win32/shell32/lang/ro-RO.rc
trunk/reactos/dll/win32/shell32/lang/ru-RU.rc
trunk/reactos/dll/win32/shell32/lang/sk-SK.rc
trunk/reactos/dll/win32/shell32/lang/sl-SI.rc
trunk/reactos/dll/win32/shell32/lang/sq-AL.rc
trunk/reactos/dll/win32/shell32/lang/sv-SE.rc
trunk/reactos/dll/win32/shell32/lang/tr-TR.rc
trunk/reactos/dll/win32/shell32/lang/uk-UA.rc
trunk/reactos/dll/win32/shell32/lang/zh-CN.rc
trunk/reactos/dll/win32/shell32/lang/zh-TW.rc
trunk/reactos/dll/win32/shell32/shfldr.h
Modified: trunk/reactos/dll/win32/shell32/CDefView.cpp
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/shell32/CDefView…
==============================================================================
--- trunk/reactos/dll/win32/shell32/CDefView.cpp [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/shell32/CDefView.cpp [iso-8859-1] Tue Nov 29 15:38:55 2016
@@ -2223,15 +2223,13 @@
case SVGIO_BACKGROUND:
if (IsEqualIID(riid, IID_IContextMenu))
{
- //*ppvOut = ISvBgCm_Constructor(m_pSFParent, FALSE);
if (!ppvOut)
hr = E_OUTOFMEMORY;
- IContextMenu* pcm;
- hr = CDefFolderMenu_Create2(NULL, NULL, 0, NULL, m_pSFParent, NULL, 0,
NULL, &pcm);
+ hr = CDefViewBckgrndMenu_CreateInstance(m_pSF2Parent, riid, ppvOut);
if (FAILED_UNEXPECTEDLY(hr))
return hr;
- *ppvOut = pcm;
+
}
else if (IsEqualIID(riid, IID_IDispatch))
{
Added: trunk/reactos/dll/win32/shell32/CDefViewBckgrndMenu.cpp
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/shell32/CDefView…
==============================================================================
--- trunk/reactos/dll/win32/shell32/CDefViewBckgrndMenu.cpp (added)
+++ trunk/reactos/dll/win32/shell32/CDefViewBckgrndMenu.cpp [iso-8859-1] Tue Nov 29
15:38:55 2016
@@ -0,0 +1,286 @@
+/*
+ * PROJECT: shell32
+ * LICENSE: GPL - See COPYING in the top level directory
+ * FILE: dll/win32/shell32/CDefViewBckgrndMenu.cpp
+ * PURPOSE: background context menu of the CDefView
+ * PROGRAMMERS: Giannis Adamopoulos
+ */
+
+#include <precomp.h>
+
+WINE_DEFAULT_DEBUG_CHANNEL(shell);
+
+class CDefViewBckgrndMenu :
+ public CComObjectRootEx<CComMultiThreadModelNoCS>,
+ public IContextMenu3,
+ public IObjectWithSite
+{
+ private:
+ CComPtr<IUnknown> m_site;
+ CComPtr<IShellFolder> m_psf;
+ CComPtr<IContextMenu> m_folderCM;
+
+ BOOL _bIsDesktopBrowserMenu();
+ BOOL _bCanPaste();
+ public:
+ CDefViewBckgrndMenu();
+ ~CDefViewBckgrndMenu();
+ HRESULT Initialize(IShellFolder* psf);
+
+ // IContextMenu
+ virtual HRESULT WINAPI QueryContextMenu(HMENU hMenu, UINT indexMenu, UINT
idCmdFirst, UINT idCmdLast, UINT uFlags);
+ virtual HRESULT WINAPI InvokeCommand(LPCMINVOKECOMMANDINFO lpcmi);
+ virtual HRESULT WINAPI GetCommandString(UINT_PTR idCommand, UINT uFlags, UINT
*lpReserved, LPSTR lpszName, UINT uMaxNameLen);
+
+ // IContextMenu2
+ virtual HRESULT WINAPI HandleMenuMsg(UINT uMsg, WPARAM wParam, LPARAM lParam);
+
+ // IContextMenu3
+ virtual HRESULT WINAPI HandleMenuMsg2(UINT uMsg, WPARAM wParam, LPARAM lParam,
LRESULT *plResult);
+
+ // IObjectWithSite
+ virtual HRESULT STDMETHODCALLTYPE SetSite(IUnknown *pUnkSite);
+ virtual HRESULT STDMETHODCALLTYPE GetSite(REFIID riid, void **ppvSite);
+
+ BEGIN_COM_MAP(CDefViewBckgrndMenu)
+ COM_INTERFACE_ENTRY_IID(IID_IContextMenu, IContextMenu)
+ COM_INTERFACE_ENTRY_IID(IID_IContextMenu2, IContextMenu2)
+ COM_INTERFACE_ENTRY_IID(IID_IContextMenu3, IContextMenu3)
+ COM_INTERFACE_ENTRY_IID(IID_IObjectWithSite, IObjectWithSite)
+ END_COM_MAP()
+};
+
+CDefViewBckgrndMenu::CDefViewBckgrndMenu()
+{
+}
+
+CDefViewBckgrndMenu::~CDefViewBckgrndMenu()
+{
+}
+
+BOOL CDefViewBckgrndMenu::_bIsDesktopBrowserMenu()
+{
+ if (!m_site)
+ return FALSE;
+
+ /* Get a pointer to the shell browser */
+ CComPtr<IShellView> psv;
+ HRESULT hr = IUnknown_QueryService(m_site, SID_IFolderView, IID_PPV_ARG(IShellView,
&psv));
+ if (FAILED_UNEXPECTEDLY(hr))
+ return FALSE;
+
+ FOLDERSETTINGS FolderSettings;
+ hr = psv->GetCurrentInfo(&FolderSettings);
+ if (FAILED_UNEXPECTEDLY(hr))
+ return FALSE;
+
+ return ((FolderSettings.fFlags & FWF_DESKTOP) == FWF_DESKTOP);
+}
+
+BOOL CDefViewBckgrndMenu::_bCanPaste()
+{
+ /* If the folder doesn't have a drop target we can't paste */
+ CComPtr<IDropTarget> pdt;
+ HRESULT hr = m_psf->CreateViewObject(NULL, IID_PPV_ARG(IDropTarget, &pdt));
+ if (FAILED(hr))
+ return FALSE;
+
+ /* We can only paste if CFSTR_SHELLIDLIST is present in the clipboard */
+ CComPtr<IDataObject> pDataObj;
+ hr = OleGetClipboard(&pDataObj);
+ if (FAILED(hr))
+ return FALSE;
+
+ STGMEDIUM medium;
+ FORMATETC formatetc;
+
+ /* Set the FORMATETC structure*/
+ InitFormatEtc(formatetc, RegisterClipboardFormatW(CFSTR_SHELLIDLIST),
TYMED_HGLOBAL);
+ hr = pDataObj->GetData(&formatetc, &medium);
+ if (FAILED(hr))
+ return FALSE;
+
+ ReleaseStgMedium(&medium);
+ return TRUE;
+}
+
+HRESULT
+CDefViewBckgrndMenu::Initialize(IShellFolder* psf)
+{
+ m_psf = psf;
+ return S_OK;
+}
+
+HRESULT
+WINAPI
+CDefViewBckgrndMenu::SetSite(IUnknown *pUnkSite)
+{
+ m_site = pUnkSite;
+ return S_OK;
+}
+
+HRESULT
+WINAPI
+CDefViewBckgrndMenu::GetSite(REFIID riid, void **ppvSite)
+{
+ if (!m_site)
+ return E_FAIL;
+
+ return m_site->QueryInterface(riid, ppvSite);
+}
+
+HRESULT
+WINAPI
+CDefViewBckgrndMenu::QueryContextMenu(HMENU hMenu, UINT indexMenu, UINT idCmdFirst, UINT
idCmdLast, UINT uFlags)
+{
+ HRESULT hr;
+ HMENU hMenuPart;
+
+ /* Load the default part of the background context menu */
+ hMenuPart = LoadMenuW(shell32_hInstance, L"MENU_002");
+ if (hMenuPart)
+ {
+ /* Don't show the view submenu for the desktop */
+ if (_bIsDesktopBrowserMenu())
+ {
+ DeleteMenu(hMenuPart, FCIDM_SHVIEW_VIEW, MF_BYCOMMAND);
+ }
+
+ /* Disable the paste options if it is not possible */
+ if (!_bCanPaste())
+ {
+ EnableMenuItem(hMenuPart, FCIDM_SHVIEW_INSERT, MF_BYCOMMAND | MF_GRAYED);
+ EnableMenuItem(hMenuPart, FCIDM_SHVIEW_INSERTLINK, MF_BYCOMMAND |
MF_GRAYED);
+ }
+
+ /* merge general background context menu in */
+ Shell_MergeMenus(hMenu, GetSubMenu(hMenuPart, 0), indexMenu, 0, 0xFFFF,
MM_DONTREMOVESEPS | MM_SUBMENUSHAVEIDS);
+ indexMenu += GetMenuItemCount(GetSubMenu(hMenuPart, 0));
+ DestroyMenu(hMenuPart);
+ }
+ else
+ {
+ ERR("Failed to load menu from resource!\n");
+ }
+
+ /* Query the shell folder to add any items it wants to add in the background context
menu */
+ hMenuPart = CreatePopupMenu();
+ if (hMenuPart)
+ {
+ hr = m_psf->CreateViewObject(NULL, IID_PPV_ARG(IContextMenu,
&m_folderCM));
+ if (SUCCEEDED(hr))
+ {
+ hr = m_folderCM->QueryContextMenu(hMenuPart, 0, idCmdFirst, idCmdLast,
uFlags);
+ if (SUCCEEDED(hr))
+ {
+ Shell_MergeMenus(hMenu, hMenuPart, indexMenu, 0, 0xFFFF,
MM_DONTREMOVESEPS | MM_SUBMENUSHAVEIDS);
+ DestroyMenu(hMenuPart);
+ }
+ else
+ {
+ WARN("QueryContextMenu failed!\n");
+ }
+ }
+ else
+ {
+ WARN("GetUIObjectOf didn't give any context menu!\n");
+ }
+ }
+ else
+ {
+ ERR("CreatePopupMenu failed!\n");
+ }
+
+ return S_OK;
+}
+
+HRESULT
+WINAPI
+CDefViewBckgrndMenu::InvokeCommand(LPCMINVOKECOMMANDINFO lpcmi)
+{
+ /* The commands that are handled by the def view are forwarded to it */
+ switch (LOWORD(lpcmi->lpVerb))
+ {
+ case FCIDM_SHVIEW_BIGICON:
+ case FCIDM_SHVIEW_SMALLICON:
+ case FCIDM_SHVIEW_LISTVIEW:
+ case FCIDM_SHVIEW_REPORTVIEW:
+ case 0x30: /* FIX IDS in resource files */
+ case 0x31:
+ case 0x32:
+ case 0x33:
+ case FCIDM_SHVIEW_AUTOARRANGE:
+ case FCIDM_SHVIEW_SNAPTOGRID:
+ case FCIDM_SHVIEW_REFRESH:
+ if (!m_site)
+ return E_FAIL;
+
+ /* Get a pointer to the shell browser */
+ CComPtr<IShellView> psv;
+ HRESULT hr = IUnknown_QueryService(m_site, SID_IFolderView,
IID_PPV_ARG(IShellView, &psv));
+ if (FAILED_UNEXPECTEDLY(hr))
+ return hr;
+
+ HWND hwndSV = NULL;
+ if (SUCCEEDED(psv->GetWindow(&hwndSV)))
+ SendMessageW(hwndSV, WM_COMMAND, MAKEWPARAM(LOWORD(lpcmi->lpVerb), 0),
0);
+ return S_OK;
+ }
+
+ /* Unknown commands are added by the folder context menu so forward the invocation
*/
+ return m_folderCM->InvokeCommand(lpcmi);
+
+}
+
+HRESULT
+WINAPI
+CDefViewBckgrndMenu::GetCommandString(UINT_PTR idCommand, UINT uFlags, UINT *lpReserved,
LPSTR lpszName, UINT uMaxNameLen)
+{
+ if (m_folderCM)
+ {
+ return m_folderCM->GetCommandString(idCommand, uFlags, lpReserved, lpszName,
uMaxNameLen);
+ }
+
+ return E_NOTIMPL;
+}
+
+HRESULT
+WINAPI
+CDefViewBckgrndMenu::HandleMenuMsg(UINT uMsg, WPARAM wParam, LPARAM lParam)
+{
+ if(m_folderCM)
+ {
+ CComPtr<IContextMenu2> pfolderCM2;
+ HRESULT hr = m_folderCM->QueryInterface(IID_PPV_ARG(IContextMenu2,
&pfolderCM2));
+ if (FAILED_UNEXPECTEDLY(hr))
+ return hr;
+
+ return pfolderCM2->HandleMenuMsg(uMsg, wParam, lParam);
+ }
+
+ return E_NOTIMPL;
+}
+
+HRESULT
+WINAPI
+CDefViewBckgrndMenu::HandleMenuMsg2(UINT uMsg, WPARAM wParam, LPARAM lParam, LRESULT
*plResult)
+{
+ if(m_folderCM)
+ {
+ CComPtr<IContextMenu3> pfolderCM3;
+ HRESULT hr = m_folderCM->QueryInterface(IID_PPV_ARG(IContextMenu3,
&pfolderCM3));
+ if (FAILED_UNEXPECTEDLY(hr))
+ return hr;
+
+ return pfolderCM3->HandleMenuMsg2(uMsg, wParam, lParam, plResult);
+ }
+
+ return E_NOTIMPL;
+}
+
+
+HRESULT
+CDefViewBckgrndMenu_CreateInstance(IShellFolder* psf, REFIID riid, void **ppv)
+{
+ return ShellObjectCreatorInit<CDefViewBckgrndMenu>(psf, riid, ppv);
+}
Propchange: trunk/reactos/dll/win32/shell32/CDefViewBckgrndMenu.cpp
------------------------------------------------------------------------------
svn:eol-style = native
Modified: trunk/reactos/dll/win32/shell32/CDefaultContextMenu.cpp
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/shell32/CDefault…
==============================================================================
--- trunk/reactos/dll/win32/shell32/CDefaultContextMenu.cpp [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/shell32/CDefaultContextMenu.cpp [iso-8859-1] Tue Nov 29
15:38:55 2016
@@ -84,14 +84,11 @@
HRESULT LoadDynamicContextMenuHandler(HKEY hKey, const CLSID *pclsid);
BOOL EnumerateDynamicContextHandlerForKey(HKEY hRootKey);
UINT InsertMenuItemsOfDynamicContextMenuExtension(HMENU hMenu, UINT IndexMenu,
UINT idCmdFirst, UINT idCmdLast);
- UINT BuildBackgroundContextMenu(HMENU hMenu, UINT iIdCmdFirst, UINT iIdCmdLast,
UINT uFlags);
UINT AddStaticContextMenusToMenu(HMENU hMenu, UINT IndexMenu);
UINT BuildShellItemContextMenu(HMENU hMenu, UINT iIdCmdFirst, UINT iIdCmdLast,
UINT uFlags);
- HRESULT NotifyShellViewWindow(LPCMINVOKECOMMANDINFO lpcmi, BOOL bRefresh);
HRESULT DoPaste(LPCMINVOKECOMMANDINFO lpcmi, BOOL bLink);
HRESULT DoOpenOrExplore(LPCMINVOKECOMMANDINFO lpcmi);
HRESULT DoCreateLink(LPCMINVOKECOMMANDINFO lpcmi);
- HRESULT DoRefresh(LPCMINVOKECOMMANDINFO lpcmi);
HRESULT DoDelete(LPCMINVOKECOMMANDINFO lpcmi);
HRESULT DoCopyOrCut(LPCMINVOKECOMMANDINFO lpcmi, BOOL bCopy);
HRESULT DoRename(LPCMINVOKECOMMANDINFO lpcmi);
@@ -188,6 +185,12 @@
{
TRACE("cidl %u\n", pdcm->cidl);
+ if (!pdcm->pcmcb && !lpfn)
+ {
+ ERR("CDefaultContextMenu needs a callback!\n");
+ return E_INVALIDARG;
+ }
+
m_cidl = pdcm->cidl;
m_apidl = const_cast<PCUITEMID_CHILD_ARRAY>(_ILCopyaPidl(pdcm->apidl,
m_cidl));
if (m_cidl && !m_apidl)
@@ -236,7 +239,7 @@
return m_pfnmcb(m_psf, NULL, m_pDataObj, uMsg, wParam, (LPARAM)lParam);
}
- return S_OK;
+ return E_FAIL;
}
void CDefaultContextMenu::AddStaticEntry(const HKEY hkeyClass, const WCHAR *szVerb)
@@ -325,20 +328,6 @@
return bRet;
}
-static
-VOID
-DisablePasteOptions(HMENU hMenu)
-{
- MENUITEMINFOW mii;
-
- mii.cbSize = sizeof(mii);
- mii.fMask = MIIM_STATE;
- mii.fState = MFS_DISABLED;
-
- SetMenuItemInfoW(hMenu, FCIDM_SHVIEW_INSERT, FALSE, &mii);
- SetMenuItemInfoW(hMenu, FCIDM_SHVIEW_INSERTLINK, FALSE, &mii);
-}
-
BOOL
CDefaultContextMenu::IsShellExtensionAlreadyLoaded(const CLSID *pclsid)
{
@@ -375,8 +364,11 @@
return hr;
hr = pExtInit->Initialize(m_pidlFolder, m_pDataObj, hKey);
- if (FAILED_UNEXPECTEDLY(hr))
+ if (FAILED(hr))
+ {
+ WARN("IShellExtInit::Initialize failed.clsid %s hr 0x%x\n",
wine_dbgstr_guid(pclsid), hr);
return hr;
+ }
PDynamicShellEntry pEntry = (DynamicShellEntry *)HeapAlloc(GetProcessHeap(), 0,
sizeof(DynamicShellEntry));
if (!pEntry)
@@ -406,7 +398,6 @@
BOOL
CDefaultContextMenu::EnumerateDynamicContextHandlerForKey(HKEY hRootKey)
{
-
WCHAR wszName[MAX_PATH], wszBuf[MAX_PATH], *pwszClsid;
DWORD cchName;
HRESULT hr;
@@ -437,24 +428,31 @@
hr = CLSIDFromString(wszBuf, &clsid);
pwszClsid = wszBuf;
}
- if (SUCCEEDED(hr))
- {
- if (m_bGroupPolicyActive)
+
+ if (FAILED(hr))
+ {
+ ERR("CLSIDFromString failed for clsid %S hr 0x%x\n", pwszClsid,
hr);
+ continue;
+ }
+
+ if (m_bGroupPolicyActive)
+ {
+ if (RegGetValueW(HKEY_LOCAL_MACHINE,
+ L"Software\\Microsoft\\Windows\\CurrentVersion\\Shell
Extensions\\Approved",
+ pwszClsid,
+ RRF_RT_REG_SZ,
+ NULL,
+ NULL,
+ NULL) != ERROR_SUCCESS)
{
- if (RegGetValueW(HKEY_LOCAL_MACHINE,
-
L"Software\\Microsoft\\Windows\\CurrentVersion\\Shell Extensions\\Approved",
- pwszClsid,
- RRF_RT_REG_SZ,
- NULL,
- NULL,
- NULL) == ERROR_SUCCESS)
- {
- LoadDynamicContextMenuHandler(hKey, &clsid);
- }
+ ERR("Shell extension %s not approved!\n", pwszClsid);
+ continue;
}
- else
- LoadDynamicContextMenuHandler(hKey, &clsid);
- }
+ }
+
+ hr = LoadDynamicContextMenuHandler(hKey, &clsid);
+ if (FAILED(hr))
+ WARN("Failed to get context menu entires from shell extension! clsid:
%S\n", pwszClsid);
}
RegCloseKey(hKey);
@@ -492,66 +490,6 @@
m_iIdSHELast = idCmdFirst;
TRACE("SH_LoadContextMenuHandlers first %x last %x\n", m_iIdSHEFirst,
m_iIdSHELast);
return IndexMenu;
-}
-
-UINT
-CDefaultContextMenu::BuildBackgroundContextMenu(
- HMENU hMenu,
- UINT iIdCmdFirst,
- UINT iIdCmdLast,
- UINT uFlags)
-{
- UINT IndexMenu = 0;
- HMENU hSubMenu;
-
- TRACE("BuildBackgroundContextMenu entered\n");
-
- SFGAOF rfg = SFGAO_FILESYSTEM | SFGAO_FOLDER;
- HRESULT hr = m_psf->GetAttributesOf(0, NULL, &rfg);
- if (FAILED(hr))
- {
- ERR("GetAttributesOf failed: %x\n", hr);
- rfg = 0;
- }
-
- hSubMenu = LoadMenuW(shell32_hInstance, L"MENU_002");
- if (hSubMenu)
- {
- /* view option is only available in browsing mode */
- if (_ILIsDesktop(m_pidlFolder))
- DeleteMenu(hSubMenu, FCIDM_SHVIEW_VIEW, MF_BYCOMMAND);
-
- /* merge general background context menu in */
- iIdCmdFirst = Shell_MergeMenus(hMenu, GetSubMenu(hSubMenu, 0), IndexMenu, 0,
0xFFFF, MM_DONTREMOVESEPS | MM_SUBMENUSHAVEIDS) + 1;
- DestroyMenu(hSubMenu);
- }
-
- if (!HasClipboardData())
- {
- TRACE("disabling paste options\n");
- DisablePasteOptions(hMenu);
- }
-
- /* Directory is progid of filesystem folders only */
- if ((rfg & (SFGAO_FILESYSTEM|SFGAO_FOLDER)) == (SFGAO_FILESYSTEM|SFGAO_FOLDER))
- {
- /* Load context menu handlers */
- TRACE("Add background handlers: %p\n", m_pidlFolder);
- HKEY hKey;
- if (RegOpenKeyExW(HKEY_CLASSES_ROOT, L"Directory\\Background", 0,
KEY_READ, &hKey) == ERROR_SUCCESS)
- {
- EnumerateDynamicContextHandlerForKey(hKey);
- RegCloseKey(hKey);
- }
-
- if (InsertMenuItemsOfDynamicContextMenuExtension(hMenu, GetMenuItemCount(hMenu) -
1, iIdCmdFirst, iIdCmdLast))
- {
- /* seperate dynamic context menu items */
- _InsertMenuItemW(hMenu, GetMenuItemCount(hMenu) - 1, TRUE, -1, MFT_SEPARATOR,
NULL, MFS_ENABLED);
- }
- }
-
- return iIdCmdLast;
}
UINT
@@ -697,51 +635,55 @@
InsertMenuItemW(hMenu, indexMenu, fByPosition, &mii);
}
-UINT
-CDefaultContextMenu::BuildShellItemContextMenu(
+HRESULT
+WINAPI
+CDefaultContextMenu::QueryContextMenu(
HMENU hMenu,
- UINT iIdCmdFirst,
- UINT iIdCmdLast,
+ UINT IndexMenu,
+ UINT idCmdFirst,
+ UINT idCmdLast,
UINT uFlags)
{
HRESULT hr;
TRACE("BuildShellItemContextMenu entered\n");
- ASSERT(m_cidl >= 1);
-
+
+ /* Load static verbs and shell extensions from registry */
for (UINT i = 0; i < m_cKeys; i++)
{
AddStaticEntriesForKey(m_aKeys[i]);
EnumerateDynamicContextHandlerForKey(m_aKeys[i]);
}
- /* add static actions */
- SFGAOF rfg = SFGAO_BROWSABLE | SFGAO_CANCOPY | SFGAO_CANLINK | SFGAO_CANMOVE |
SFGAO_CANDELETE | SFGAO_CANRENAME | SFGAO_HASPROPSHEET | SFGAO_FILESYSTEM | SFGAO_FOLDER;
- hr = m_psf->GetAttributesOf(m_cidl, m_apidl, &rfg);
- if (FAILED(hr))
- {
- ERR("GetAttributesOf failed: %x\n", hr);
- rfg = 0;
- }
-
- /* add static context menu handlers */
- UINT IndexMenu = AddStaticContextMenusToMenu(hMenu, 0);
-
- /* now process dynamic context menu handlers */
+ /* Add static context menu handlers */
+ IndexMenu = AddStaticContextMenusToMenu(hMenu, IndexMenu);
+
+ /* Add dynamic context menu handlers */
BOOL bAddSep = FALSE;
- IndexMenu = InsertMenuItemsOfDynamicContextMenuExtension(hMenu, IndexMenu,
iIdCmdFirst, iIdCmdLast);
+ IndexMenu = InsertMenuItemsOfDynamicContextMenuExtension(hMenu, IndexMenu,
idCmdFirst, idCmdLast);
TRACE("IndexMenu %d\n", IndexMenu);
/* Now let the callback add its own items */
QCMINFO qcminfo;
qcminfo.hmenu = hMenu;
qcminfo.indexMenu = IndexMenu;
- qcminfo.idCmdFirst = iIdCmdFirst;
- qcminfo.idCmdLast = iIdCmdLast;
+ qcminfo.idCmdFirst = idCmdFirst;
+ qcminfo.idCmdLast = idCmdLast;
qcminfo.pIdMap = NULL;
_DoCallback(DFM_MERGECONTEXTMENU, uFlags, &qcminfo);
IndexMenu = GetMenuItemCount(hMenu);
+ /* If this is a background context menu we are done */
+ if (!m_cidl)
+ return S_OK;
+
+ /* Get the attributes of the items */
+ SFGAOF rfg = SFGAO_BROWSABLE | SFGAO_CANCOPY | SFGAO_CANLINK | SFGAO_CANMOVE |
SFGAO_CANDELETE | SFGAO_CANRENAME | SFGAO_HASPROPSHEET | SFGAO_FILESYSTEM | SFGAO_FOLDER;
+ hr = m_psf->GetAttributesOf(m_cidl, m_apidl, &rfg);
+ if (FAILED_UNEXPECTEDLY(hr))
+ return S_OK;
+
+ /* Add the standard menu entries based on the attributes of the items */
BOOL bClipboardData = (HasClipboardData() && (rfg & SFGAO_FILESYSTEM));
if (rfg & (SFGAO_CANCOPY | SFGAO_CANMOVE) || bClipboardData)
{
@@ -788,60 +730,6 @@
_InsertMenuItemW(hMenu, IndexMenu++, TRUE, 0, MFT_SEPARATOR, NULL, 0);
_InsertMenuItemW(hMenu, IndexMenu++, TRUE, FCIDM_SHVIEW_PROPERTIES, MFT_STRING,
MAKEINTRESOURCEW(IDS_PROPERTIES), MFS_ENABLED);
}
-
- return iIdCmdLast;
-}
-
-HRESULT
-WINAPI
-CDefaultContextMenu::QueryContextMenu(
- HMENU hMenu,
- UINT IndexMenu,
- UINT idCmdFirst,
- UINT idCmdLast,
- UINT uFlags)
-{
- if (m_cidl)
- idCmdFirst = BuildShellItemContextMenu(hMenu, idCmdFirst, idCmdLast, uFlags);
- else
- idCmdFirst = BuildBackgroundContextMenu(hMenu, idCmdFirst, idCmdLast, uFlags);
-
- return S_OK;
-}
-
-HRESULT
-CDefaultContextMenu::NotifyShellViewWindow(LPCMINVOKECOMMANDINFO lpcmi, BOOL bRefresh)
-{
- if (!m_site)
- return E_FAIL;
-
- /* Get a pointer to the shell browser */
- CComPtr<IShellView> psv;
- HRESULT hr = IUnknown_QueryService(m_site, SID_IFolderView, IID_PPV_ARG(IShellView,
&psv));
- if (FAILED_UNEXPECTEDLY(hr))
- return hr;
-
- HWND hwndSV = NULL;
- if (SUCCEEDED(psv->GetWindow(&hwndSV)))
- SendMessageW(hwndSV, WM_COMMAND, MAKEWPARAM(LOWORD(lpcmi->lpVerb), 0), 0);
- return S_OK;
-}
-
-
-HRESULT CDefaultContextMenu::DoRefresh(LPCMINVOKECOMMANDINFO lpcmi)
-{
- if (!m_site)
- return E_FAIL;
-
- /* Get a pointer to the shell view */
- CComPtr<IShellView> psv;
- HRESULT hr = IUnknown_QueryService(m_site, SID_IFolderView, IID_PPV_ARG(IShellView,
&psv));
- if (FAILED_UNEXPECTEDLY(hr))
- return hr;
-
- hr = psv->Refresh();
- if (FAILED_UNEXPECTEDLY(hr))
- return hr;
return S_OK;
}
@@ -1285,21 +1173,6 @@
/* Check if this is a Id */
switch (LOWORD(LocalInvokeInfo.lpVerb))
{
- case FCIDM_SHVIEW_BIGICON:
- case FCIDM_SHVIEW_SMALLICON:
- case FCIDM_SHVIEW_LISTVIEW:
- case FCIDM_SHVIEW_REPORTVIEW:
- case 0x30: /* FIX IDS in resource files */
- case 0x31:
- case 0x32:
- case 0x33:
- case FCIDM_SHVIEW_AUTOARRANGE:
- case FCIDM_SHVIEW_SNAPTOGRID:
- Result = NotifyShellViewWindow(&LocalInvokeInfo, FALSE);
- break;
- case FCIDM_SHVIEW_REFRESH:
- Result = DoRefresh(&LocalInvokeInfo);
- break;
case FCIDM_SHVIEW_INSERT:
Result = DoPaste(&LocalInvokeInfo, FALSE);
break;
Modified: trunk/reactos/dll/win32/shell32/CMakeLists.txt
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/shell32/CMakeLis…
==============================================================================
--- trunk/reactos/dll/win32/shell32/CMakeLists.txt [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/shell32/CMakeLists.txt [iso-8859-1] Tue Nov 29 15:38:55 2016
@@ -63,6 +63,7 @@
CFileSysBindData.cpp
CDefView.cpp
CDefViewDual.cpp
+ CDefViewBckgrndMenu.cpp
stubs.cpp
systray.cpp
CDefaultContextMenu.cpp
Modified: trunk/reactos/dll/win32/shell32/folders/CDesktopFolder.cpp
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/shell32/folders/…
==============================================================================
--- trunk/reactos/dll/win32/shell32/folders/CDesktopFolder.cpp [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/shell32/folders/CDesktopFolder.cpp [iso-8859-1] Tue Nov 29
15:38:55 2016
@@ -529,8 +529,21 @@
}
else if (IsEqualIID (riid, IID_IContextMenu))
{
- WARN ("IContextMenu not implemented\n");
- hr = E_NOTIMPL;
+ HKEY hKeys[16];
+ UINT cKeys = 0;
+ AddClassKeyToArray(L"Directory\\Background", hKeys, &cKeys);
+
+ DEFCONTEXTMENU dcm;
+ dcm.hwnd = hwndOwner;
+ dcm.pcmcb = this;
+ dcm.pidlFolder = pidlRoot;
+ dcm.psf = this;
+ dcm.cidl = 0;
+ dcm.apidl = NULL;
+ dcm.cKeys = cKeys;
+ dcm.aKeys = hKeys;
+ dcm.punkAssociationInfo = NULL;
+ hr = SHCreateDefaultContextMenu (&dcm, riid, ppvOut);
}
else if (IsEqualIID (riid, IID_IShellView))
{
@@ -646,13 +659,23 @@
else
{
/* Do not use the context menu of the CFSFolder here. */
- /* We need to pass a pointer of the CDesktopFolder so as the data object
that the context menu gets is rooted to the desktop */
+ /* We need to pass a pointer of the CDesktopFolder so as the data object that
the context menu gets is rooted to the desktop */
/* Otherwise operations like that involve items from both user and shared
desktop will not work */
- IContextMenu * pCm = NULL;
HKEY hKeys[16];
UINT cKeys = 0;
AddFSClassKeysToArray(apidl[0], hKeys, &cKeys);
- hr = CDefFolderMenu_Create2(pidlRoot, hwndOwner, cidl, apidl,
static_cast<IShellFolder*>(this), NULL, cKeys, hKeys, &pCm);
+
+ DEFCONTEXTMENU dcm;
+ dcm.hwnd = hwndOwner;
+ dcm.pcmcb = this;
+ dcm.pidlFolder = pidlRoot;
+ dcm.psf = this;
+ dcm.cidl = cidl;
+ dcm.apidl = apidl;
+ dcm.cKeys = cKeys;
+ dcm.aKeys = hKeys;
+ dcm.punkAssociationInfo = NULL;
+ hr = SHCreateDefaultContextMenu (&dcm, riid, &pObj);
}
}
else if (IsEqualIID (riid, IID_IDataObject) && (cidl >= 1))
@@ -844,6 +867,59 @@
return S_OK;
}
+HRESULT WINAPI CDesktopFolder::CallBack(IShellFolder *psf, HWND hwndOwner, IDataObject
*pdtobj, UINT uMsg, WPARAM wParam, LPARAM lParam)
+{
+ if (uMsg != DFM_MERGECONTEXTMENU && uMsg != DFM_INVOKECOMMAND)
+ return S_OK;
+
+ /* no data object means no selection */
+ if (!pdtobj)
+ {
+ if (uMsg == DFM_INVOKECOMMAND && wParam == DFM_CMD_PROPERTIES)
+ {
+ if (32 >= (UINT)ShellExecuteW(hwndOwner, L"open",
L"rundll32.exe shell32.dll,Control_RunDLL desk.cpl", NULL, NULL,
SW_SHOWNORMAL))
+ return E_FAIL;
+ return S_OK;
+ }
+ else if (uMsg == DFM_MERGECONTEXTMENU)
+ {
+ QCMINFO *pqcminfo = (QCMINFO *)lParam;
+ _InsertMenuItemW(pqcminfo->hmenu, pqcminfo->indexMenu++, TRUE, 0,
MFT_SEPARATOR, NULL, 0);
+ _InsertMenuItemW(pqcminfo->hmenu, pqcminfo->indexMenu++, TRUE,
FCIDM_SHVIEW_PROPERTIES, MFT_STRING, MAKEINTRESOURCEW(IDS_PROPERTIES), MFS_ENABLED);
+ }
+
+ return S_OK;
+ }
+
+ PIDLIST_ABSOLUTE pidlFolder;
+ PUITEMID_CHILD *apidl;
+ UINT cidl;
+ HRESULT hr = SH_GetApidlFromDataObject(pdtobj, &pidlFolder, &apidl,
&cidl);
+ if (FAILED_UNEXPECTEDLY(hr))
+ return hr;
+
+ if (cidl > 1)
+ ERR("SHMultiFileProperties is not yet implemented\n");
+
+ STRRET strFile;
+ hr = GetDisplayNameOf(apidl[0], SHGDN_FORPARSING, &strFile);
+ if (SUCCEEDED(hr))
+ {
+ hr = SH_ShowPropertiesDialog(strFile.pOleStr, pidlFolder, apidl);
+ if (FAILED(hr))
+ ERR("SH_ShowPropertiesDialog failed\n");
+ }
+ else
+ {
+ ERR("Failed to get display name\n");
+ }
+
+ SHFree(pidlFolder);
+ _ILFreeaPidl(apidl, cidl);
+
+ return hr;
+}
+
/*************************************************************************
* SHGetDesktopFolder [SHELL32.@]
*/
Modified: trunk/reactos/dll/win32/shell32/folders/CDesktopFolder.h
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/shell32/folders/…
==============================================================================
--- trunk/reactos/dll/win32/shell32/folders/CDesktopFolder.h [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/shell32/folders/CDesktopFolder.h [iso-8859-1] Tue Nov 29
15:38:55 2016
@@ -27,7 +27,8 @@
public CComCoClass<CDesktopFolder, &CLSID_ShellDesktop>,
public CComObjectRootEx<CComMultiThreadModelNoCS>,
public IShellFolder2,
- public IPersistFolder2
+ public IPersistFolder2,
+ public IContextMenuCB
{
private:
/* both paths are parsible from the desktop */
@@ -75,6 +76,9 @@
// *** IPersistFolder2 methods ***
virtual HRESULT WINAPI GetCurFolder(LPITEMIDLIST * pidl);
+ // IContextMenuCB
+ virtual HRESULT WINAPI CallBack(IShellFolder *psf, HWND hwndOwner, IDataObject
*pdtobj, UINT uMsg, WPARAM wParam, LPARAM lParam);
+
DECLARE_REGISTRY_RESOURCEID(IDR_SHELLDESKTOP)
DECLARE_CENTRAL_INSTANCE_NOT_AGGREGATABLE(CDesktopFolder)
Modified: trunk/reactos/dll/win32/shell32/folders/CFSFolder.cpp
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/shell32/folders/…
==============================================================================
--- trunk/reactos/dll/win32/shell32/folders/CFSFolder.cpp [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/shell32/folders/CFSFolder.cpp [iso-8859-1] Tue Nov 29 15:38:55
2016
@@ -371,8 +371,21 @@
hr = CFSDropTarget_CreateInstance(sPathTarget, riid, ppvOut);
else if (IsEqualIID (riid, IID_IContextMenu))
{
- FIXME ("IContextMenu not implemented\n");
- hr = E_NOTIMPL;
+ HKEY hKeys[16];
+ UINT cKeys = 0;
+ AddClassKeyToArray(L"Directory\\Background", hKeys, &cKeys);
+
+ DEFCONTEXTMENU dcm;
+ dcm.hwnd = hwndOwner;
+ dcm.pcmcb = this;
+ dcm.pidlFolder = pidlRoot;
+ dcm.psf = this;
+ dcm.cidl = 0;
+ dcm.apidl = NULL;
+ dcm.cKeys = cKeys;
+ dcm.aKeys = hKeys;
+ dcm.punkAssociationInfo = NULL;
+ hr = SHCreateDefaultContextMenu (&dcm, riid, ppvOut);
}
else if (IsEqualIID (riid, IID_IShellView))
{
@@ -513,7 +526,7 @@
}
else
{
- hr = IDataObject_Constructor (hwndOwner, pidlRoot,
(LPCITEMIDLIST*)&pidlRoot, 1, (IDataObject **)&pObj);
+ hr = E_INVALIDARG;
}
}
else if ((IsEqualIID (riid, IID_IExtractIconA) || IsEqualIID (riid,
IID_IExtractIconW)) && (cidl == 1))
@@ -1101,6 +1114,33 @@
HRESULT WINAPI CFSFolder::CallBack(IShellFolder *psf, HWND hwndOwner, IDataObject
*pdtobj, UINT uMsg, WPARAM wParam, LPARAM lParam)
{
+ if (uMsg != DFM_MERGECONTEXTMENU && uMsg != DFM_INVOKECOMMAND)
+ return S_OK;
+
+ /* no data object means no selection */
+ if (!pdtobj)
+ {
+ if (uMsg == DFM_INVOKECOMMAND && wParam == DFM_CMD_PROPERTIES)
+ {
+ PUITEMID_CHILD pidlChild = ILClone(ILFindLastID(pidlRoot));
+ LPITEMIDLIST pidlParent = ILClone(pidlRoot);
+ ILRemoveLastID(pidlParent);
+ HRESULT hr = SH_ShowPropertiesDialog(sPathTarget, pidlParent,
&pidlChild);
+ if (FAILED(hr))
+ ERR("SH_ShowPropertiesDialog failed\n");
+ ILFree(pidlChild);
+ ILFree(pidlParent);
+ }
+ else if (uMsg == DFM_MERGECONTEXTMENU)
+ {
+ QCMINFO *pqcminfo = (QCMINFO *)lParam;
+ _InsertMenuItemW(pqcminfo->hmenu, pqcminfo->indexMenu++, TRUE, 0,
MFT_SEPARATOR, NULL, 0);
+ _InsertMenuItemW(pqcminfo->hmenu, pqcminfo->indexMenu++, TRUE,
FCIDM_SHVIEW_PROPERTIES, MFT_STRING, MAKEINTRESOURCEW(IDS_PROPERTIES), MFS_ENABLED);
+ }
+
+ return S_OK;
+ }
+
if (uMsg != DFM_INVOKECOMMAND || wParam != DFM_CMD_PROPERTIES)
return S_OK;
Modified: trunk/reactos/dll/win32/shell32/lang/bg-BG.rc
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/shell32/lang/bg-…
==============================================================================
--- trunk/reactos/dll/win32/shell32/lang/bg-BG.rc [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/shell32/lang/bg-BG.rc [iso-8859-1] Tue Nov 29 15:38:55 2016
@@ -38,8 +38,6 @@
MENUITEM "", -1, MFT_SEPARATOR
MENUITEM "ÐоÑÑавÑне", FCIDM_SHVIEW_INSERT
MENUITEM "ÐоÑÑавÑне каÑо вÑÑзка",
FCIDM_SHVIEW_INSERTLINK
- MENUITEM "", -1, MFT_SEPARATOR
- MENUITEM "СвойÑÑва", FCIDM_SHVIEW_PROPERTIES
END
END
Modified: trunk/reactos/dll/win32/shell32/lang/ca-ES.rc
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/shell32/lang/ca-…
==============================================================================
--- trunk/reactos/dll/win32/shell32/lang/ca-ES.rc [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/shell32/lang/ca-ES.rc [iso-8859-1] Tue Nov 29 15:38:55 2016
@@ -38,8 +38,6 @@
MENUITEM "", -1, MFT_SEPARATOR
MENUITEM "Paste", FCIDM_SHVIEW_INSERT
MENUITEM "Paste as Link", FCIDM_SHVIEW_INSERTLINK
- MENUITEM "", -1, MFT_SEPARATOR
- MENUITEM "Properties", FCIDM_SHVIEW_PROPERTIES
END
END
Modified: trunk/reactos/dll/win32/shell32/lang/cs-CZ.rc
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/shell32/lang/cs-…
==============================================================================
--- trunk/reactos/dll/win32/shell32/lang/cs-CZ.rc [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/shell32/lang/cs-CZ.rc [iso-8859-1] Tue Nov 29 15:38:55 2016
@@ -44,8 +44,6 @@
MENUITEM "", -1, MFT_SEPARATOR
MENUITEM "V&ložit", FCIDM_SHVIEW_INSERT
MENUITEM "Vložit zást&upce", FCIDM_SHVIEW_INSERTLINK
- MENUITEM "", -1, MFT_SEPARATOR
- MENUITEM "&Vlastnosti", FCIDM_SHVIEW_PROPERTIES
END
END
Modified: trunk/reactos/dll/win32/shell32/lang/da-DK.rc
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/shell32/lang/da-…
==============================================================================
--- trunk/reactos/dll/win32/shell32/lang/da-DK.rc [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/shell32/lang/da-DK.rc [iso-8859-1] Tue Nov 29 15:38:55 2016
@@ -44,8 +44,6 @@
MENUITEM "", -1, MFT_SEPARATOR
MENUITEM "Indsæt", FCIDM_SHVIEW_INSERT
MENUITEM "Indsæt som Link", FCIDM_SHVIEW_INSERTLINK
- MENUITEM "", -1, MFT_SEPARATOR
- MENUITEM "Egenskaber", FCIDM_SHVIEW_PROPERTIES
END
END
Modified: trunk/reactos/dll/win32/shell32/lang/de-DE.rc
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/shell32/lang/de-…
==============================================================================
--- trunk/reactos/dll/win32/shell32/lang/de-DE.rc [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/shell32/lang/de-DE.rc [iso-8859-1] Tue Nov 29 15:38:55 2016
@@ -38,8 +38,6 @@
MENUITEM "", -1, MFT_SEPARATOR
MENUITEM "Einfügen", FCIDM_SHVIEW_INSERT
MENUITEM "Einfügen als Verweis", FCIDM_SHVIEW_INSERTLINK
- MENUITEM "", -1, MFT_SEPARATOR
- MENUITEM "&Eigenschaften", FCIDM_SHVIEW_PROPERTIES
END
END
Modified: trunk/reactos/dll/win32/shell32/lang/el-GR.rc
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/shell32/lang/el-…
==============================================================================
--- trunk/reactos/dll/win32/shell32/lang/el-GR.rc [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/shell32/lang/el-GR.rc [iso-8859-1] Tue Nov 29 15:38:55 2016
@@ -38,8 +38,6 @@
MENUITEM "", -1, MFT_SEPARATOR
MENUITEM "ÎÏικÏληÏη", FCIDM_SHVIEW_INSERT
MENUITEM "ÎÏικÏληÏη ÏÏ
νÏÏμεÏ
ÏηÏ", FCIDM_SHVIEW_INSERTLINK
- MENUITEM "", -1, MFT_SEPARATOR
- MENUITEM "ÎδιÏÏηÏεÏ", FCIDM_SHVIEW_PROPERTIES
END
END
Modified: trunk/reactos/dll/win32/shell32/lang/en-GB.rc
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/shell32/lang/en-…
==============================================================================
--- trunk/reactos/dll/win32/shell32/lang/en-GB.rc [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/shell32/lang/en-GB.rc [iso-8859-1] Tue Nov 29 15:38:55 2016
@@ -38,8 +38,6 @@
MENUITEM "", -1, MFT_SEPARATOR
MENUITEM "Paste", FCIDM_SHVIEW_INSERT
MENUITEM "Paste as Link", FCIDM_SHVIEW_INSERTLINK
- MENUITEM "", -1, MFT_SEPARATOR
- MENUITEM "Properties", FCIDM_SHVIEW_PROPERTIES
END
END
Modified: trunk/reactos/dll/win32/shell32/lang/en-US.rc
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/shell32/lang/en-…
==============================================================================
--- trunk/reactos/dll/win32/shell32/lang/en-US.rc [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/shell32/lang/en-US.rc [iso-8859-1] Tue Nov 29 15:38:55 2016
@@ -38,8 +38,6 @@
MENUITEM "", -1, MFT_SEPARATOR
MENUITEM "Paste", FCIDM_SHVIEW_INSERT
MENUITEM "Paste as Link", FCIDM_SHVIEW_INSERTLINK
- MENUITEM "", -1, MFT_SEPARATOR
- MENUITEM "Properties", FCIDM_SHVIEW_PROPERTIES
END
END
Modified: trunk/reactos/dll/win32/shell32/lang/es-ES.rc
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/shell32/lang/es-…
==============================================================================
--- trunk/reactos/dll/win32/shell32/lang/es-ES.rc [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/shell32/lang/es-ES.rc [iso-8859-1] Tue Nov 29 15:38:55 2016
@@ -40,8 +40,6 @@
MENUITEM "", -1, MFT_SEPARATOR
MENUITEM "Pegar", FCIDM_SHVIEW_INSERT
MENUITEM "Pegar acceso directo", FCIDM_SHVIEW_INSERTLINK
- MENUITEM "", -1, MFT_SEPARATOR
- MENUITEM "Propiedades", FCIDM_SHVIEW_PROPERTIES
END
END
Modified: trunk/reactos/dll/win32/shell32/lang/fi-FI.rc
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/shell32/lang/fi-…
==============================================================================
--- trunk/reactos/dll/win32/shell32/lang/fi-FI.rc [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/shell32/lang/fi-FI.rc [iso-8859-1] Tue Nov 29 15:38:55 2016
@@ -38,8 +38,6 @@
MENUITEM "", -1, MFT_SEPARATOR
MENUITEM "Liitä", FCIDM_SHVIEW_INSERT
MENUITEM "Liitä Linkiksi", FCIDM_SHVIEW_INSERTLINK
- MENUITEM "", -1, MFT_SEPARATOR
- MENUITEM "Ominaisuudet", FCIDM_SHVIEW_PROPERTIES
END
END
Modified: trunk/reactos/dll/win32/shell32/lang/fr-FR.rc
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/shell32/lang/fr-…
==============================================================================
--- trunk/reactos/dll/win32/shell32/lang/fr-FR.rc [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/shell32/lang/fr-FR.rc [iso-8859-1] Tue Nov 29 15:38:55 2016
@@ -38,8 +38,6 @@
MENUITEM "", -1, MFT_SEPARATOR
MENUITEM "Coller", FCIDM_SHVIEW_INSERT
MENUITEM "Coller comme un lien", FCIDM_SHVIEW_INSERTLINK
- MENUITEM "", -1, MFT_SEPARATOR
- MENUITEM "Propriétés", FCIDM_SHVIEW_PROPERTIES
END
END
Modified: trunk/reactos/dll/win32/shell32/lang/he-IL.rc
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/shell32/lang/he-…
==============================================================================
--- trunk/reactos/dll/win32/shell32/lang/he-IL.rc [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/shell32/lang/he-IL.rc [iso-8859-1] Tue Nov 29 15:38:55 2016
@@ -38,8 +38,6 @@
MENUITEM "", -1, MFT_SEPARATOR
MENUITEM "×××ק", FCIDM_SHVIEW_INSERT
MENUITEM "×××ק ×ק×צ×ר ×ר×", FCIDM_SHVIEW_INSERTLINK
- MENUITEM "", -1, MFT_SEPARATOR
- MENUITEM "××פ××× ××", FCIDM_SHVIEW_PROPERTIES
END
END
Modified: trunk/reactos/dll/win32/shell32/lang/hu-HU.rc
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/shell32/lang/hu-…
==============================================================================
--- trunk/reactos/dll/win32/shell32/lang/hu-HU.rc [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/shell32/lang/hu-HU.rc [iso-8859-1] Tue Nov 29 15:38:55 2016
@@ -38,8 +38,6 @@
MENUITEM "", -1, MFT_SEPARATOR
MENUITEM "Beillesztés", FCIDM_SHVIEW_INSERT
MENUITEM "Parancsikon beillesztése", FCIDM_SHVIEW_INSERTLINK
- MENUITEM "", -1, MFT_SEPARATOR
- MENUITEM "BeállÃtások", FCIDM_SHVIEW_PROPERTIES
END
END
Modified: trunk/reactos/dll/win32/shell32/lang/it-IT.rc
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/shell32/lang/it-…
==============================================================================
--- trunk/reactos/dll/win32/shell32/lang/it-IT.rc [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/shell32/lang/it-IT.rc [iso-8859-1] Tue Nov 29 15:38:55 2016
@@ -38,8 +38,6 @@
MENUITEM "", -1, MFT_SEPARATOR
MENUITEM "Incolla", FCIDM_SHVIEW_INSERT
MENUITEM "Crea Collegamento", FCIDM_SHVIEW_INSERTLINK
- MENUITEM "", -1, MFT_SEPARATOR
- MENUITEM "Proprietà ", FCIDM_SHVIEW_PROPERTIES
END
END
Modified: trunk/reactos/dll/win32/shell32/lang/ja-JP.rc
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/shell32/lang/ja-…
==============================================================================
--- trunk/reactos/dll/win32/shell32/lang/ja-JP.rc [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/shell32/lang/ja-JP.rc [iso-8859-1] Tue Nov 29 15:38:55 2016
@@ -38,8 +38,6 @@
MENUITEM "", -1, MFT_SEPARATOR
MENUITEM "è²¼ãä»ã", FCIDM_SHVIEW_INSERT
MENUITEM "ã·ã§ã¼ãã«ããã®è²¼ãä»ã",
FCIDM_SHVIEW_INSERTLINK
- MENUITEM "", -1, MFT_SEPARATOR
- MENUITEM "ããããã£", FCIDM_SHVIEW_PROPERTIES
END
END
Modified: trunk/reactos/dll/win32/shell32/lang/ko-KR.rc
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/shell32/lang/ko-…
==============================================================================
--- trunk/reactos/dll/win32/shell32/lang/ko-KR.rc [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/shell32/lang/ko-KR.rc [iso-8859-1] Tue Nov 29 15:38:55 2016
@@ -38,8 +38,6 @@
MENUITEM "", -1, MFT_SEPARATOR
MENUITEM "Paste", FCIDM_SHVIEW_INSERT
MENUITEM "Paste as Link", FCIDM_SHVIEW_INSERTLINK
- MENUITEM "", -1, MFT_SEPARATOR
- MENUITEM "Properties", FCIDM_SHVIEW_PROPERTIES
END
END
Modified: trunk/reactos/dll/win32/shell32/lang/nl-NL.rc
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/shell32/lang/nl-…
==============================================================================
--- trunk/reactos/dll/win32/shell32/lang/nl-NL.rc [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/shell32/lang/nl-NL.rc [iso-8859-1] Tue Nov 29 15:38:55 2016
@@ -38,8 +38,6 @@
MENUITEM "", -1, MFT_SEPARATOR
MENUITEM "Paste", FCIDM_SHVIEW_INSERT
MENUITEM "Paste as Link", FCIDM_SHVIEW_INSERTLINK
- MENUITEM "", -1, MFT_SEPARATOR
- MENUITEM "Properties", FCIDM_SHVIEW_PROPERTIES
END
END
Modified: trunk/reactos/dll/win32/shell32/lang/no-NO.rc
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/shell32/lang/no-…
==============================================================================
--- trunk/reactos/dll/win32/shell32/lang/no-NO.rc [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/shell32/lang/no-NO.rc [iso-8859-1] Tue Nov 29 15:38:55 2016
@@ -38,8 +38,6 @@
MENUITEM "", -1, MFT_SEPARATOR
MENUITEM "Lim inn", FCIDM_SHVIEW_INSERT
MENUITEM "Lim inn som snarvei", FCIDM_SHVIEW_INSERTLINK
- MENUITEM "", -1, MFT_SEPARATOR
- MENUITEM "Egenskaper", FCIDM_SHVIEW_PROPERTIES
END
END
Modified: trunk/reactos/dll/win32/shell32/lang/pl-PL.rc
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/shell32/lang/pl-…
==============================================================================
--- trunk/reactos/dll/win32/shell32/lang/pl-PL.rc [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/shell32/lang/pl-PL.rc [iso-8859-1] Tue Nov 29 15:38:55 2016
@@ -42,8 +42,6 @@
MENUITEM "", -1, MFT_SEPARATOR
MENUITEM "W&klej", FCIDM_SHVIEW_INSERT
MENUITEM "Wklej s&krót", FCIDM_SHVIEW_INSERTLINK
- MENUITEM "", -1, MFT_SEPARATOR
- MENUITEM "WÅaÅciwoÅci", FCIDM_SHVIEW_PROPERTIES
END
END
Modified: trunk/reactos/dll/win32/shell32/lang/pt-BR.rc
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/shell32/lang/pt-…
==============================================================================
--- trunk/reactos/dll/win32/shell32/lang/pt-BR.rc [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/shell32/lang/pt-BR.rc [iso-8859-1] Tue Nov 29 15:38:55 2016
@@ -38,8 +38,6 @@
MENUITEM "", -1, MFT_SEPARATOR
MENUITEM "Co&lar", FCIDM_SHVIEW_INSERT
MENUITEM "Colar a&talho", FCIDM_SHVIEW_INSERTLINK
- MENUITEM "", -1, MFT_SEPARATOR
- MENUITEM "Propriedades", FCIDM_SHVIEW_PROPERTIES
END
END
Modified: trunk/reactos/dll/win32/shell32/lang/pt-PT.rc
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/shell32/lang/pt-…
==============================================================================
--- trunk/reactos/dll/win32/shell32/lang/pt-PT.rc [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/shell32/lang/pt-PT.rc [iso-8859-1] Tue Nov 29 15:38:55 2016
@@ -38,8 +38,6 @@
MENUITEM "", -1, MFT_SEPARATOR
MENUITEM "Co&lar", FCIDM_SHVIEW_INSERT
MENUITEM "Colar a&talho", FCIDM_SHVIEW_INSERTLINK
- MENUITEM "", -1, MFT_SEPARATOR
- MENUITEM "Propriedades", FCIDM_SHVIEW_PROPERTIES
END
END
Modified: trunk/reactos/dll/win32/shell32/lang/ro-RO.rc
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/shell32/lang/ro-…
==============================================================================
--- trunk/reactos/dll/win32/shell32/lang/ro-RO.rc [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/shell32/lang/ro-RO.rc [iso-8859-1] Tue Nov 29 15:38:55 2016
@@ -40,8 +40,6 @@
MENUITEM "", -1, MFT_SEPARATOR
MENUITEM "&LipeÈte", FCIDM_SHVIEW_INSERT
MENUITEM "LipeÈte ca sc&urtÄturÄ", FCIDM_SHVIEW_INSERTLINK
- MENUITEM "", -1, MFT_SEPARATOR
- MENUITEM "&ProprietÄÈi", FCIDM_SHVIEW_PROPERTIES
END
END
Modified: trunk/reactos/dll/win32/shell32/lang/ru-RU.rc
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/shell32/lang/ru-…
==============================================================================
--- trunk/reactos/dll/win32/shell32/lang/ru-RU.rc [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/shell32/lang/ru-RU.rc [iso-8859-1] Tue Nov 29 15:38:55 2016
@@ -40,8 +40,6 @@
MENUITEM "", -1, MFT_SEPARATOR
MENUITEM "&ÐÑÑавиÑÑ", FCIDM_SHVIEW_INSERT
MENUITEM "ÐÑÑавиÑÑ &ÑÑлÑк", FCIDM_SHVIEW_INSERTLINK
- MENUITEM "", -1, MFT_SEPARATOR
- MENUITEM "Сво&йÑÑва", FCIDM_SHVIEW_PROPERTIES
END
END
Modified: trunk/reactos/dll/win32/shell32/lang/sk-SK.rc
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/shell32/lang/sk-…
==============================================================================
--- trunk/reactos/dll/win32/shell32/lang/sk-SK.rc [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/shell32/lang/sk-SK.rc [iso-8859-1] Tue Nov 29 15:38:55 2016
@@ -38,8 +38,6 @@
MENUITEM "", -1, MFT_SEPARATOR
MENUITEM "&Prilepiť", FCIDM_SHVIEW_INSERT
MENUITEM "Prilepiť od&kaz", FCIDM_SHVIEW_INSERTLINK
- MENUITEM "", -1, MFT_SEPARATOR
- MENUITEM "Vl&astnosti", FCIDM_SHVIEW_PROPERTIES
END
END
Modified: trunk/reactos/dll/win32/shell32/lang/sl-SI.rc
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/shell32/lang/sl-…
==============================================================================
--- trunk/reactos/dll/win32/shell32/lang/sl-SI.rc [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/shell32/lang/sl-SI.rc [iso-8859-1] Tue Nov 29 15:38:55 2016
@@ -38,8 +38,6 @@
MENUITEM "", -1, MFT_SEPARATOR
MENUITEM "Paste", FCIDM_SHVIEW_INSERT
MENUITEM "Paste as Link", FCIDM_SHVIEW_INSERTLINK
- MENUITEM "", -1, MFT_SEPARATOR
- MENUITEM "Properties", FCIDM_SHVIEW_PROPERTIES
END
END
Modified: trunk/reactos/dll/win32/shell32/lang/sq-AL.rc
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/shell32/lang/sq-…
==============================================================================
--- trunk/reactos/dll/win32/shell32/lang/sq-AL.rc [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/shell32/lang/sq-AL.rc [iso-8859-1] Tue Nov 29 15:38:55 2016
@@ -42,8 +42,6 @@
MENUITEM "", -1, MFT_SEPARATOR
MENUITEM "Ngjit", FCIDM_SHVIEW_INSERT
MENUITEM "Ngjit si Lidhje", FCIDM_SHVIEW_INSERTLINK
- MENUITEM "", -1, MFT_SEPARATOR
- MENUITEM "Cilësime", FCIDM_SHVIEW_PROPERTIES
END
END
Modified: trunk/reactos/dll/win32/shell32/lang/sv-SE.rc
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/shell32/lang/sv-…
==============================================================================
--- trunk/reactos/dll/win32/shell32/lang/sv-SE.rc [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/shell32/lang/sv-SE.rc [iso-8859-1] Tue Nov 29 15:38:55 2016
@@ -38,8 +38,6 @@
MENUITEM "", -1, MFT_SEPARATOR
MENUITEM "Klistra in", FCIDM_SHVIEW_INSERT
MENUITEM "Klistra in som genväg", FCIDM_SHVIEW_INSERTLINK
- MENUITEM "", -1, MFT_SEPARATOR
- MENUITEM "Egenskaper", FCIDM_SHVIEW_PROPERTIES
END
END
Modified: trunk/reactos/dll/win32/shell32/lang/tr-TR.rc
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/shell32/lang/tr-…
==============================================================================
--- trunk/reactos/dll/win32/shell32/lang/tr-TR.rc [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/shell32/lang/tr-TR.rc [iso-8859-1] Tue Nov 29 15:38:55 2016
@@ -40,8 +40,6 @@
MENUITEM "", -1, MFT_SEPARATOR
MENUITEM "Y&apıÅtır", FCIDM_SHVIEW_INSERT
MENUITEM "K&ısayol YapıÅtır", FCIDM_SHVIEW_INSERTLINK
- MENUITEM "", -1, MFT_SEPARATOR
- MENUITEM "&Husûsîyetler", FCIDM_SHVIEW_PROPERTIES
END
END
Modified: trunk/reactos/dll/win32/shell32/lang/uk-UA.rc
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/shell32/lang/uk-…
==============================================================================
--- trunk/reactos/dll/win32/shell32/lang/uk-UA.rc [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/shell32/lang/uk-UA.rc [iso-8859-1] Tue Nov 29 15:38:55 2016
@@ -38,8 +38,6 @@
MENUITEM "", -1, MFT_SEPARATOR
MENUITEM "ÐÑÑавиÑи", FCIDM_SHVIEW_INSERT
MENUITEM "ÐÑÑавиÑи ÑÑлик", FCIDM_SHVIEW_INSERTLINK
- MENUITEM "", -1, MFT_SEPARATOR
- MENUITEM "ÐлаÑÑивоÑÑÑ", FCIDM_SHVIEW_PROPERTIES
END
END
Modified: trunk/reactos/dll/win32/shell32/lang/zh-CN.rc
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/shell32/lang/zh-…
==============================================================================
--- trunk/reactos/dll/win32/shell32/lang/zh-CN.rc [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/shell32/lang/zh-CN.rc [iso-8859-1] Tue Nov 29 15:38:55 2016
@@ -47,8 +47,6 @@
MENUITEM "", -1, MFT_SEPARATOR
MENUITEM "ç²è´´", FCIDM_SHVIEW_INSERT
MENUITEM "ç²è´´å¿«æ·æ¹å¼", FCIDM_SHVIEW_INSERTLINK
- MENUITEM "", -1, MFT_SEPARATOR
- MENUITEM "å±æ§", FCIDM_SHVIEW_PROPERTIES
END
END
Modified: trunk/reactos/dll/win32/shell32/lang/zh-TW.rc
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/shell32/lang/zh-…
==============================================================================
--- trunk/reactos/dll/win32/shell32/lang/zh-TW.rc [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/shell32/lang/zh-TW.rc [iso-8859-1] Tue Nov 29 15:38:55 2016
@@ -46,8 +46,6 @@
MENUITEM "", -1, MFT_SEPARATOR
MENUITEM "è²¼ä¸", FCIDM_SHVIEW_INSERT
MENUITEM "è²¼ä¸æ·å¾", FCIDM_SHVIEW_INSERTLINK
- MENUITEM "", -1, MFT_SEPARATOR
- MENUITEM "屬æ§", FCIDM_SHVIEW_PROPERTIES
END
END
Modified: trunk/reactos/dll/win32/shell32/shfldr.h
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/shell32/shfldr.h…
==============================================================================
--- trunk/reactos/dll/win32/shell32/shfldr.h [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/shell32/shfldr.h [iso-8859-1] Tue Nov 29 15:38:55 2016
@@ -63,6 +63,8 @@
void AddFSClassKeysToArray(PCUITEMID_CHILD pidl, HKEY* array, UINT* cKeys);
+HRESULT CDefViewBckgrndMenu_CreateInstance(IShellFolder* psf, REFIID riid, void **ppv);
+
HRESULT SH_GetApidlFromDataObject(IDataObject *pDataObject, PIDLIST_ABSOLUTE*
ppidlfolder, PUITEMID_CHILD **apidlItems, UINT *pcidl);
static __inline int SHELL32_GUIDToStringA (REFGUID guid, LPSTR str)