Regedit: Enhancements to the contextual menu in the treeview

1.  Implemented Export
2.  Added a placeholder for Permissions


svn path=/trunk/; revision=19449
This commit is contained in:
Nathan Woods 2005-11-22 04:54:18 +00:00
parent c6a600f0d3
commit 779147bf80
5 changed files with 11 additions and 1 deletions

View file

@ -135,9 +135,13 @@ BEGIN
MENUITEM "&DWORD Value", ID_EDIT_NEW_DWORDVALUE
END
MENUITEM "&Find", ID_EDIT_FIND, GRAYED
MENUITEM SEPARATOR
MENUITEM "&Delete", ID_TREE_DELETE
MENUITEM "&Rename", ID_TREE_RENAME
MENUITEM SEPARATOR
MENUITEM "&Export", ID_TREE_EXPORT
MENUITEM "&Permissions...", ID_TREE_PERMISSIONS, GRAYED
MENUITEM SEPARATOR
MENUITEM "&Copy Key Name", ID_EDIT_COPYKEYNAME
END
END

View file

@ -145,6 +145,9 @@ static BOOL _CmdWndProc(HWND hWnd, UINT message, WPARAM wParam, LPARAM lParam)
RefreshTreeItem(pChildWnd->hTreeWnd, hSelection); /* If delete failed; refresh to see partial results */
}
break;
case ID_TREE_EXPORT:
ExportRegistryFile(pChildWnd->hTreeWnd);
break;
case ID_EDIT_COPYKEYNAME:
hSelection = TreeView_GetSelection(pChildWnd->hTreeWnd);
keyPath = GetItemPath(pChildWnd->hTreeWnd, hSelection, &hRootKey);

View file

@ -344,7 +344,7 @@ static UINT_PTR CALLBACK ExportRegistryFile_OFNHookProc(HWND hdlg, UINT uiMsg, W
return iResult;
}
static BOOL ExportRegistryFile(HWND hWnd)
BOOL ExportRegistryFile(HWND hWnd)
{
OPENFILENAME ofn;
TCHAR ExportKeyPath[_MAX_PATH];

View file

@ -90,6 +90,7 @@ extern LRESULT CALLBACK FrameWndProc(HWND, UINT, WPARAM, LPARAM);
extern void SetupStatusBar(HWND hWnd, BOOL bResize);
extern void UpdateStatusBar(void);
extern BOOL CopyKeyName(HWND hWnd, HKEY hRootKey, LPCTSTR keyName);
extern BOOL ExportRegistryFile(HWND hWnd);
/* listview.c */
extern HWND CreateListView(HWND hwndParent, int id);

View file

@ -135,6 +135,8 @@
#define IDS_QUERY_DELETE_KEY_CONFIRM 32877
#define ID_TREE_SUGGESTION_MIN 32878
#define ID_TREE_SUGGESTION_MAX 32887
#define ID_TREE_EXPORT 32888
#define ID_TREE_PERMISSIONS 32889
#define IDS_FLT_REGFILES 31001
#define IDS_FLT_REGFILES_FLT 31002