Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-cw
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-cw
Commits
649643aa
Commit
649643aa
authored
Jan 16, 2004
by
Thomas Weidenmueller
Committed by
Alexandre Julliard
Jan 16, 2004
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Added context menu support.
parent
f3957f52
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
38 additions
and
0 deletions
+38
-0
En.rc
programs/regedit/En.rc
+23
-0
listview.c
programs/regedit/listview.c
+7
-0
main.c
programs/regedit/main.c
+2
-0
main.h
programs/regedit/main.h
+4
-0
resource.h
programs/regedit/resource.h
+2
-0
No files found.
programs/regedit/En.rc
View file @
649643aa
...
@@ -102,6 +102,29 @@ BEGIN
...
@@ -102,6 +102,29 @@ BEGIN
END
END
END
END
IDR_POPUP_MENUS MENU DISCARDABLE
BEGIN
POPUP ""
BEGIN
MENUITEM "&Modify", ID_EDIT_MODIFY
MENUITEM "Modify Binary Data", ID_EDIT_MODIFY_BIN
MENUITEM SEPARATOR
MENUITEM "&Delete\tDel", ID_EDIT_DELETE
MENUITEM "&Rename", ID_EDIT_RENAME
END
POPUP ""
BEGIN
POPUP "&New"
BEGIN
MENUITEM "&Key", ID_EDIT_NEW_KEY
MENUITEM SEPARATOR
MENUITEM "&String Value", ID_EDIT_NEW_STRINGVALUE
MENUITEM "&Binary Value", ID_EDIT_NEW_BINARYVALUE
MENUITEM "&DWORD Value", ID_EDIT_NEW_DWORDVALUE
END
END
END
/*
/*
* Dialog
* Dialog
...
...
programs/regedit/listview.c
View file @
649643aa
...
@@ -346,6 +346,13 @@ static LRESULT CALLBACK ListWndProc(HWND hWnd, UINT message, WPARAM wParam, LPAR
...
@@ -346,6 +346,13 @@ static LRESULT CALLBACK ListWndProc(HWND hWnd, UINT message, WPARAM wParam, LPAR
return
CallWindowProc
(
g_orgListWndProc
,
hWnd
,
message
,
wParam
,
lParam
);
return
CallWindowProc
(
g_orgListWndProc
,
hWnd
,
message
,
wParam
,
lParam
);
}
}
break
;
break
;
case
WM_CONTEXTMENU
:
{
POINTS
pt
=
MAKEPOINTS
(
lParam
);
int
cnt
=
ListView_GetNextItem
(
hWnd
,
-
1
,
LVNI_FOCUSED
|
LVNI_SELECTED
);
TrackPopupMenu
(
GetSubMenu
(
hPopupMenus
,
cnt
==
-
1
?
PM_NEW
:
PM_MODIFYVALUE
),
TPM_RIGHTBUTTON
,
pt
.
x
,
pt
.
y
,
0
,
hFrameWnd
,
NULL
);
break
;
}
case
WM_KEYDOWN
:
case
WM_KEYDOWN
:
if
(
wParam
==
VK_TAB
)
{
if
(
wParam
==
VK_TAB
)
{
/*TODO: SetFocus(Globals.hDriveBar) */
/*TODO: SetFocus(Globals.hDriveBar) */
...
...
programs/regedit/main.c
View file @
649643aa
...
@@ -42,6 +42,7 @@ HINSTANCE hInst;
...
@@ -42,6 +42,7 @@ HINSTANCE hInst;
HWND
hFrameWnd
;
HWND
hFrameWnd
;
HWND
hStatusBar
;
HWND
hStatusBar
;
HMENU
hMenuFrame
;
HMENU
hMenuFrame
;
HMENU
hPopupMenus
=
0
;
UINT
nClipboardFormat
;
UINT
nClipboardFormat
;
LPCTSTR
strClipboardFormat
=
_T
(
"TODO: SET CORRECT FORMAT"
);
LPCTSTR
strClipboardFormat
=
_T
(
"TODO: SET CORRECT FORMAT"
);
...
@@ -104,6 +105,7 @@ BOOL InitInstance(HINSTANCE hInstance, int nCmdShow)
...
@@ -104,6 +105,7 @@ BOOL InitInstance(HINSTANCE hInstance, int nCmdShow)
hChildWndClass
=
hChildWndClass
;
/* warning eater */
hChildWndClass
=
hChildWndClass
;
/* warning eater */
hMenuFrame
=
LoadMenu
(
hInstance
,
MAKEINTRESOURCE
(
IDR_REGEDIT_MENU
));
hMenuFrame
=
LoadMenu
(
hInstance
,
MAKEINTRESOURCE
(
IDR_REGEDIT_MENU
));
hPopupMenus
=
LoadMenu
(
hInstance
,
MAKEINTRESOURCE
(
IDR_POPUP_MENUS
));
/* Initialize the Windows Common Controls DLL */
/* Initialize the Windows Common Controls DLL */
InitCommonControls
();
InitCommonControls
();
...
...
programs/regedit/main.h
View file @
649643aa
...
@@ -32,6 +32,9 @@
...
@@ -32,6 +32,9 @@
#define COUNT_OF(a) (sizeof(a)/sizeof(a[0]))
#define COUNT_OF(a) (sizeof(a)/sizeof(a[0]))
#define PM_MODIFYVALUE 0
#define PM_NEW 1
extern
HINSTANCE
hInst
;
extern
HINSTANCE
hInst
;
/******************************************************************************/
/******************************************************************************/
...
@@ -64,6 +67,7 @@ extern HINSTANCE hInst;
...
@@ -64,6 +67,7 @@ extern HINSTANCE hInst;
extern
HWND
hFrameWnd
;
extern
HWND
hFrameWnd
;
extern
HMENU
hMenuFrame
;
extern
HMENU
hMenuFrame
;
extern
HWND
hStatusBar
;
extern
HWND
hStatusBar
;
extern
HMENU
hPopupMenus
;
extern
HFONT
hFont
;
extern
HFONT
hFont
;
extern
enum
OPTION_FLAGS
Options
;
extern
enum
OPTION_FLAGS
Options
;
...
...
programs/regedit/resource.h
View file @
649643aa
...
@@ -41,6 +41,7 @@
...
@@ -41,6 +41,7 @@
#define IDD_DIALOG2 132
#define IDD_DIALOG2 132
#define IDB_CLOSED_FILE 133
#define IDB_CLOSED_FILE 133
#define IDB_ROOT 134
#define IDB_ROOT 134
#define IDR_POPUP_MENUS 137
#define IDC_LICENSE_EDIT 1029
#define IDC_LICENSE_EDIT 1029
#define ID_REGISTRY_EXIT 32770
#define ID_REGISTRY_EXIT 32770
#define ID_FAVOURITES_ADDTOFAVOURITES 32772
#define ID_FAVOURITES_ADDTOFAVOURITES 32772
...
@@ -114,6 +115,7 @@
...
@@ -114,6 +115,7 @@
#define IDC_DWORD_DEC 32854
#define IDC_DWORD_DEC 32854
#define IDS_NEWKEY 32860
#define IDS_NEWKEY 32860
#define IDS_NEWVALUE 32861
#define IDS_NEWVALUE 32861
#define ID_EDIT_MODIFY_BIN 32870
#define IDD_EDIT_STRING 2000
#define IDD_EDIT_STRING 2000
#define IDC_VALUE_NAME 2001
#define IDC_VALUE_NAME 2001
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment