Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
wine
Manage
Activity
Members
Labels
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Package registry
Container Registry
Model registry
Operate
Terraform modules
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Zsolt Vadász
wine
Commits
01d99121
Commit
01d99121
authored
19 years ago
by
Michael McCormack
Committed by
Alexandre Julliard
19 years ago
Browse files
Options
Downloads
Patches
Plain Diff
regedit: Fix some gcc 4.1 warnings.
parent
ae5823db
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
programs/regedit/treeview.c
+11
-10
11 additions, 10 deletions
programs/regedit/treeview.c
with
11 additions
and
10 deletions
programs/regedit/treeview.c
+
11
−
10
View file @
01d99121
...
...
@@ -134,7 +134,7 @@ HTREEITEM FindPathInTree(HWND hwndTV, LPCTSTR lpKeyName) {
buf
[
260
]
=
'\0'
;
hItem
=
TreeView_GetRoot
(
hwndTV
);
TreeView_Expand
(
hwndTV
,
hItem
,
TVE_EXPAND
);
SendMessage
(
hwndTV
,
TVM_EXPAND
,
TVE_EXPAND
,
(
LPARAM
)
hItem
);
hItem
=
TreeView_GetChild
(
hwndTV
,
hItem
);
hOldItem
=
hItem
;
while
(
1
)
{
...
...
@@ -145,9 +145,9 @@ HTREEITEM FindPathInTree(HWND hwndTV, LPCTSTR lpKeyName) {
tvi
.
hItem
=
hItem
;
tvi
.
pszText
=
buf
;
tvi
.
cchTextMax
=
260
;
TreeView_GetItem
(
hwndTV
,
&
tvi
);
SendMessage
(
hwndTV
,
TVM_GETITEM
,
0
,
(
LPARAM
)
&
tvi
);
if
(
!
_tcsicmp
(
tvi
.
pszText
,
lpItemName
))
{
TreeView_Expand
(
hwndTV
,
hItem
,
TVE_EXPAND
);
SendMessage
(
hwndTV
,
TVM_EXPAND
,
TVE_EXPAND
,
(
LPARAM
)
hItem
);
if
(
!
lpKeyName
)
return
hItem
;
hOldItem
=
hItem
;
...
...
@@ -425,7 +425,7 @@ static BOOL RefreshTreeItem(HWND hwndTV, HTREEITEM hItem)
while
(
childItem
)
{
HTREEITEM
nextItem
=
TreeView_GetNextSibling
(
hwndTV
,
childItem
);
if
(
RefreshTreeItem
(
hwndTV
,
childItem
)
==
FALSE
)
{
TreeView_DeleteItem
(
hwndTV
,
childItem
);
SendMessage
(
hwndTV
,
TVM_DELETEITEM
,
0
,
(
LPARAM
)
childItem
);
}
childItem
=
nextItem
;
}
...
...
@@ -455,7 +455,7 @@ BOOL RefreshTreeView(HWND hwndTV)
SetCursor
(
hcursorOld
);
/* We reselect the currently selected node, this will prompt a refresh of the listview. */
TreeView_SelectItem
(
hwndTV
,
hSelectedItem
);
SendMessage
(
hwndTV
,
TVM_SELECTITEM
,
TVGN_CARET
,
(
LPARAM
)
hSelectedItem
);
return
TRUE
;
}
...
...
@@ -476,7 +476,7 @@ HTREEITEM InsertNode(HWND hwndTV, HTREEITEM hItem, LPTSTR name)
item
.
cChildren
=
1
;
if
(
!
TreeView_SetItem
(
hwndTV
,
&
item
))
return
FALSE
;
}
TreeView_Expand
(
hwndTV
,
hItem
,
TVE_EXPAND
);
SendMessage
(
hwndTV
,
TVM_EXPAND
,
TVE_EXPAND
,
(
LPARAM
)
hItem
);
if
(
!
hNewItem
)
{
for
(
hNewItem
=
TreeView_GetChild
(
hwndTV
,
hItem
);
hNewItem
;
hNewItem
=
TreeView_GetNextSibling
(
hwndTV
,
hNewItem
))
{
item
.
mask
=
TVIF_HANDLE
|
TVIF_TEXT
;
...
...
@@ -487,7 +487,8 @@ HTREEITEM InsertNode(HWND hwndTV, HTREEITEM hItem, LPTSTR name)
if
(
lstrcmp
(
name
,
item
.
pszText
)
==
0
)
break
;
}
}
if
(
hNewItem
)
TreeView_SelectItem
(
hwndTV
,
hNewItem
);
if
(
hNewItem
)
SendMessage
(
hwndTV
,
TVM_SELECTITEM
,
TVGN_CARET
,
(
LPARAM
)
hNewItem
);
return
hNewItem
;
}
...
...
@@ -528,8 +529,8 @@ static BOOL InitTreeViewItems(HWND hwndTV, LPTSTR pHostName)
if
(
!
AddEntryToTree
(
hwndTV
,
hRoot
,
_T
(
"HKEY_DYN_DATA"
),
HKEY_DYN_DATA
,
1
))
return
FALSE
;
/* expand and select host name */
TreeView_Expand
(
hwndTV
,
hRoot
,
TVE_EXPAND
);
TreeView_Select
(
hwndTV
,
hRoot
,
TVGN_CARET
);
SendMessage
(
hwndTV
,
TVM_EXPAND
,
TVE_EXPAND
,
(
LPARAM
)
hRoot
);
SendMessage
(
hwndTV
,
TVM_SELECTITEM
,
TVGN_CARET
,
(
LPARAM
)
hRoot
);
return
TRUE
;
}
...
...
@@ -567,7 +568,7 @@ static BOOL InitTreeViewImageLists(HWND hwndTV)
}
/* Associate the image list with the tree view control. */
TreeView_SetImageList
(
hwndTV
,
himl
,
TVSIL_NORMAL
);
SendMessage
(
hwndTV
,
TVM_SETIMAGELIST
,
TVSIL_NORMAL
,
(
LPARAM
)
himl
);
return
TRUE
;
}
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment