Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
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-winehq
Commits
c36fec1c
Commit
c36fec1c
authored
Aug 31, 2008
by
Alexander Nicolaysen Sørnes
Committed by
Alexandre Julliard
Sep 02, 2008
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
regedit: Set the unicode flag for the treeview.
parent
0035421e
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
9 additions
and
10 deletions
+9
-10
childwnd.c
programs/regedit/childwnd.c
+8
-10
treeview.c
programs/regedit/treeview.c
+1
-0
No files found.
programs/regedit/childwnd.c
View file @
c36fec1c
...
...
@@ -350,11 +350,11 @@ LRESULT CALLBACK ChildWndProc(HWND hWnd, UINT message, WPARAM wParam, LPARAM lPa
case
WM_NOTIFY
:
if
(((
int
)
wParam
==
TREE_WINDOW
)
&&
(
g_pChildWnd
!=
NULL
))
{
switch
(((
LPNMHDR
)
lParam
)
->
code
)
{
case
TVN_ITEMEXPANDING
:
case
TVN_ITEMEXPANDING
W
:
return
!
OnTreeExpanding
(
g_pChildWnd
->
hTreeWnd
,
(
NMTREEVIEW
*
)
lParam
);
case
TVN_SELCHANGED
:
case
TVN_SELCHANGED
W
:
OnTreeSelectionChanged
(
g_pChildWnd
->
hTreeWnd
,
g_pChildWnd
->
hListWnd
,
((
NMTREEVIEW
*
)
lParam
)
->
itemNew
.
hItem
,
TRUE
);
((
NMTREEVIEW
W
*
)
lParam
)
->
itemNew
.
hItem
,
TRUE
);
break
;
case
NM_SETFOCUS
:
g_pChildWnd
->
nFocusPanel
=
0
;
...
...
@@ -366,25 +366,23 @@ LRESULT CALLBACK ChildWndProc(HWND hWnd, UINT message, WPARAM wParam, LPARAM lPa
TPM_RIGHTBUTTON
,
pt
.
x
,
pt
.
y
,
0
,
hFrameWnd
,
NULL
);
break
;
}
case
TVN_ENDLABELEDIT
:
{
case
TVN_ENDLABELEDIT
W
:
{
HKEY
hRootKey
;
LPNMTVDISPINFO
dispInfo
=
(
LPNMTVDISPINFO
)
lParam
;
WCHAR
*
itemText
=
GetWideString
(
dispInfo
->
item
.
pszText
);
LPNMTVDISPINFOW
dispInfo
=
(
LPNMTVDISPINFOW
)
lParam
;
LPWSTR
path
=
GetItemPath
(
g_pChildWnd
->
hTreeWnd
,
0
,
&
hRootKey
);
BOOL
res
=
RenameKey
(
hWnd
,
hRootKey
,
path
,
item
Text
);
BOOL
res
=
RenameKey
(
hWnd
,
hRootKey
,
path
,
dispInfo
->
item
.
psz
Text
);
if
(
res
)
{
TVITEMEXW
item
;
LPWSTR
fullPath
=
GetPathFullPath
(
g_pChildWnd
->
hTreeWnd
,
item
Text
);
dispInfo
->
item
.
psz
Text
);
item
.
mask
=
TVIF_HANDLE
|
TVIF_TEXT
;
item
.
hItem
=
TreeView_GetSelection
(
g_pChildWnd
->
hTreeWnd
);
item
.
pszText
=
item
Text
;
item
.
pszText
=
dispInfo
->
item
.
psz
Text
;
SendMessageW
(
g_pChildWnd
->
hTreeWnd
,
TVM_SETITEMW
,
0
,
(
LPARAM
)
&
item
);
SendMessageW
(
hStatusBar
,
SB_SETTEXTW
,
0
,
(
LPARAM
)
fullPath
);
HeapFree
(
GetProcessHeap
(),
0
,
fullPath
);
}
HeapFree
(
GetProcessHeap
(),
0
,
path
);
HeapFree
(
GetProcessHeap
(),
0
,
itemText
);
return
res
;
}
default:
...
...
programs/regedit/treeview.c
View file @
c36fec1c
...
...
@@ -670,6 +670,7 @@ HWND CreateTreeView(HWND hwndParent, LPWSTR pHostName, UINT id)
WS_VISIBLE
|
WS_CHILD
|
WS_TABSTOP
|
TVS_HASLINES
|
TVS_HASBUTTONS
|
TVS_LINESATROOT
,
0
,
0
,
rcClient
.
right
,
rcClient
.
bottom
,
hwndParent
,
(
HMENU
)
ULongToHandle
(
id
),
hInst
,
NULL
);
SendMessageW
(
hwndTV
,
TVM_SETUNICODEFORMAT
,
TRUE
,
0
);
/* Initialize the image list, and add items to the control. */
if
(
!
InitTreeViewImageLists
(
hwndTV
)
||
!
InitTreeViewItems
(
hwndTV
,
pHostName
))
{
DestroyWindow
(
hwndTV
);
...
...
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