regedit: Disallow editing root key names.

This commit is contained in:
Daniel Jelinski 2012-10-16 20:14:52 +02:00 committed by Alexandre Julliard
parent c00702cd6e
commit 003622c015
1 changed files with 6 additions and 0 deletions

View File

@ -405,6 +405,12 @@ LRESULT CALLBACK ChildWndProc(HWND hWnd, UINT message, WPARAM wParam, LPARAM lPa
TPM_RIGHTBUTTON, pt.x, pt.y, 0, hFrameWnd, NULL);
break;
}
case TVN_BEGINLABELEDITW: {
HKEY hRootKey;
LPWSTR path = GetItemPath(g_pChildWnd->hTreeWnd, 0, &hRootKey);
if (!path || !*path) return 1;
return 0;
}
case TVN_ENDLABELEDITW: {
HKEY hRootKey;
LPNMTVDISPINFOW dispInfo = (LPNMTVDISPINFOW)lParam;