Skip to content
Snippets Groups Projects
Commit eb9d0e92 authored by Dimitrie O. Paun's avatar Dimitrie O. Paun Committed by Alexandre Julliard
Browse files

Add all needed accelerators to regedit. Cleanups.

parent 65be0d1f
No related branches found
No related tags found
No related merge requests found
......@@ -151,29 +151,15 @@ int APIENTRY WinMain(HINSTANCE hInstance,
{
MSG msg;
HACCEL hAccel;
/*
int hCrt;
FILE *hf;
AllocConsole();
hCrt = _open_osfhandle((long)GetStdHandle(STD_OUTPUT_HANDLE), _O_TEXT);
hf = _fdopen(hCrt, "w");
*stdout = *hf;
setvbuf(stdout, NULL, _IONBF, 0);
wprintf(L"command line exit, hInstance = %d\n", hInstance);
getch();
FreeConsole();
return 0;
*/
if (ProcessCmdLine(lpCmdLine)) {
return 0;
}
/* Initialize global strings */
LoadString(hInstance, IDS_APP_TITLE, szTitle, MAX_LOADSTRING);
LoadString(hInstance, IDC_REGEDIT_FRAME, szFrameClass, MAX_LOADSTRING);
LoadString(hInstance, IDC_REGEDIT, szChildClass, MAX_LOADSTRING);
LoadString(hInstance, IDS_APP_TITLE, szTitle, COUNT_OF(szTitle));
LoadString(hInstance, IDC_REGEDIT_FRAME, szFrameClass, COUNT_OF(szFrameClass));
LoadString(hInstance, IDC_REGEDIT, szChildClass, COUNT_OF(szChildClass));
/* Store instance handle in our global variable */
hInst = hInstance;
......@@ -186,7 +172,7 @@ int APIENTRY WinMain(HINSTANCE hInstance,
/* Main message loop */
while (GetMessage(&msg, (HWND)NULL, 0, 0)) {
if (!TranslateAccelerator(msg.hwnd, hAccel, &msg) &&
if (!TranslateAccelerator(hFrameWnd, hAccel, &msg) &&
!IsDialogMessage(hFrameWnd, &msg)) {
TranslateMessage(&msg);
DispatchMessage(&msg);
......
......@@ -25,6 +25,16 @@
LANGUAGE LANG_NEUTRAL, SUBLANG_NEUTRAL
IDC_REGEDIT ACCELERATORS
{
"^F", ID_EDIT_FIND
"^P", ID_REGISTRY_PRINT
VK_DELETE, ID_EDIT_DELETE, VIRTKEY
VK_F1, ID_HELP_HELPTOPICS, VIRTKEY
VK_F3, ID_EDIT_FINDNEXT, VIRTKEY
VK_F5, ID_VIEW_REFRESH, VIRTKEY
}
#include "resource.rc"
/* include localised resources */
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment