mirror of
https://github.com/reactos/reactos.git
synced 2025-08-06 23:32:58 +00:00
[EXPLORER][BROWSEUI][SHLWAPI][BOOTDATA][WIN32K] Support AppKeys and more WM_APPCOMMANDs (#7879)
Implements a couple of extra commands in IShellBrowser and adds support for the AppKeys fallback registry key (used when the foreground application does not handle the command).
This commit is contained in:
parent
2e85425c53
commit
5a10ec60be
13 changed files with 219 additions and 61 deletions
|
@ -426,6 +426,19 @@ STDAPI DllGetClassObject(REFCLSID rclsid, REFIID riid, LPVOID *ppv)
|
|||
return hResult;
|
||||
}
|
||||
|
||||
static HRESULT UpdateRegistryFromResource(BOOL Register)
|
||||
{
|
||||
static const BYTE resid[] =
|
||||
{
|
||||
IDR_FOLDEROPTIONS,
|
||||
IDR_EXPLORER,
|
||||
};
|
||||
HRESULT hr = S_OK;
|
||||
for (SIZE_T i = 0; i < _countof(resid) && SUCCEEDED(hr); ++i)
|
||||
hr = gModule.UpdateRegistryFromResource(resid[i], Register, NULL);
|
||||
return hr;
|
||||
}
|
||||
|
||||
/***********************************************************************
|
||||
* DllRegisterServer (SHELL32.@)
|
||||
*/
|
||||
|
@ -437,8 +450,7 @@ STDAPI DllRegisterServer()
|
|||
if (FAILED(hr))
|
||||
return hr;
|
||||
|
||||
hr = gModule.UpdateRegistryFromResource(IDR_FOLDEROPTIONS, TRUE, NULL);
|
||||
if (FAILED(hr))
|
||||
if (FAILED(hr = UpdateRegistryFromResource(TRUE)))
|
||||
return hr;
|
||||
|
||||
hr = SHELL_RegisterShellFolders();
|
||||
|
@ -459,8 +471,7 @@ STDAPI DllUnregisterServer()
|
|||
if (FAILED(hr))
|
||||
return hr;
|
||||
|
||||
hr = gModule.UpdateRegistryFromResource(IDR_FOLDEROPTIONS, FALSE, NULL);
|
||||
if (FAILED(hr))
|
||||
if (FAILED(hr = UpdateRegistryFromResource(FALSE)))
|
||||
return hr;
|
||||
|
||||
return S_OK;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue