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
f8f8f0a4
Commit
f8f8f0a4
authored
May 10, 2009
by
Nikolay Sivov
Committed by
Alexandre Julliard
May 11, 2009
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
comctl32/listview: Make ListView_* macros match PSDK.
parent
7d4bbe9e
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
13 additions
and
14 deletions
+13
-14
appwiz.c
dlls/appwiz.cpl/appwiz.c
+2
-2
control.c
dlls/shell32/control.c
+2
-2
shlview.c
dlls/shell32/shlview.c
+9
-10
commctrl.h
include/commctrl.h
+0
-0
No files found.
dlls/appwiz.cpl/appwiz.c
View file @
f8f8f0a4
...
...
@@ -365,7 +365,7 @@ static inline void EmptyList(void)
*/
static
void
UpdateButtons
(
HWND
hWnd
)
{
BOOL
sel
=
ListView_GetSelectedCount
(
GetDlgItem
(
hWnd
,
IDL_PROGRAMS
)
)
!=
0
;
BOOL
sel
=
SendMessageW
(
GetDlgItem
(
hWnd
,
IDL_PROGRAMS
),
LVM_GETSELECTEDCOUNT
,
0
,
0
)
!=
0
;
EnableWindow
(
GetDlgItem
(
hWnd
,
IDC_ADDREMOVE
),
sel
);
EnableWindow
(
GetDlgItem
(
hWnd
,
IDC_SUPPORT_INFO
),
sel
);
...
...
@@ -636,7 +636,7 @@ static HIMAGELIST AddListViewImageList(HWND hWnd)
ImageList_AddIcon
(
hSmall
,
hDefaultIcon
);
DestroyIcon
(
hDefaultIcon
);
(
void
)
ListView_SetImageList
(
hWnd
,
hSmall
,
LVSIL_SMALL
);
SendMessageW
(
hWnd
,
LVM_SETIMAGELIST
,
LVSIL_SMALL
,
(
LPARAM
)
hSmall
);
return
hSmall
;
}
...
...
dlls/shell32/control.c
View file @
f8f8f0a4
...
...
@@ -214,8 +214,8 @@ static BOOL Control_CreateListView (CPanel *panel)
panel
->
hImageListLarge
=
ImageList_Create
(
GetSystemMetrics
(
SM_CXICON
),
GetSystemMetrics
(
SM_CYICON
),
ILC_MASK
,
1
,
1
);
(
void
)
ListView_SetImageList
(
panel
->
hWndListView
,
panel
->
hImageListSmall
,
LVSIL_SMALL
);
(
void
)
ListView_SetImageList
(
panel
->
hWndListView
,
panel
->
hImageListLarge
,
LVSIL_NORMAL
);
SendMessageW
(
panel
->
hWndListView
,
LVM_SETIMAGELIST
,
LVSIL_SMALL
,
(
LPARAM
)
panel
->
hImageListSmall
);
SendMessageW
(
panel
->
hWndListView
,
LVM_SETIMAGELIST
,
LVSIL_NORMAL
,
(
LPARAM
)
panel
->
hImageListLarge
);
/* Create columns for list view */
lvc
.
mask
=
LVCF_FMT
|
LVCF_TEXT
|
LVCF_SUBITEM
|
LVCF_WIDTH
;
...
...
dlls/shell32/shlview.c
View file @
f8f8f0a4
...
...
@@ -560,7 +560,7 @@ static BOOLEAN LV_AddItem(IShellViewImpl * This, LPCITEMIDLIST pidl)
TRACE
(
"(%p)(pidl=%p)
\n
"
,
This
,
pidl
);
lvItem
.
mask
=
LVIF_TEXT
|
LVIF_IMAGE
|
LVIF_PARAM
;
/*set the mask*/
lvItem
.
iItem
=
ListView_GetItemCount
(
This
->
hWndList
);
/*add the item to the end of the list*/
lvItem
.
iItem
=
SendMessageW
(
This
->
hWndList
,
LVM_GETITEMCOUNT
,
0
,
0
);
/*add the item to the end of the list*/
lvItem
.
iSubItem
=
0
;
lvItem
.
lParam
=
(
LPARAM
)
ILClone
(
ILFindLastID
(
pidl
));
/*set the item's data*/
lvItem
.
pszText
=
LPSTR_TEXTCALLBACKW
;
/*get text on a callback basis*/
...
...
@@ -578,7 +578,7 @@ static BOOLEAN LV_DeleteItem(IShellViewImpl * This, LPCITEMIDLIST pidl)
TRACE
(
"(%p)(pidl=%p)
\n
"
,
This
,
pidl
);
nIndex
=
LV_FindItemByPidl
(
This
,
ILFindLastID
(
pidl
));
return
(
-
1
==
ListView_DeleteItem
(
This
->
hWndList
,
nIndex
))
?
FALSE
:
TRUE
;
return
(
-
1
==
SendMessageW
(
This
->
hWndList
,
LVM_DELETEITEM
,
nIndex
,
0
))
?
FALSE
:
TRUE
;
}
/**********************************************************
...
...
@@ -836,7 +836,7 @@ static UINT ShellView_GetSelections(IShellViewImpl * This)
SHFree
(
This
->
apidl
);
This
->
cidl
=
ListView_GetSelectedCount
(
This
->
hWndList
);
This
->
cidl
=
SendMessageW
(
This
->
hWndList
,
LVM_GETSELECTEDCOUNT
,
0
,
0
);
This
->
apidl
=
SHAlloc
(
This
->
cidl
*
sizeof
(
LPITEMIDLIST
));
TRACE
(
"selected=%i
\n
"
,
This
->
cidl
);
...
...
@@ -1494,14 +1494,13 @@ static LRESULT ShellView_OnNotify(IShellViewImpl * This, UINT CtlID, LPNMHDR lpn
if
(
plvKeyDown
->
wVKey
==
VK_F2
)
{
/* see how many files are selected */
int
i
=
ListView_GetSelectedCount
(
This
->
hWndList
);
int
i
=
SendMessageW
(
This
->
hWndList
,
LVM_GETSELECTEDCOUNT
,
0
,
0
);
/* get selected item */
if
(
i
==
1
)
{
/* get selected item */
i
=
ListView_GetNextItem
(
This
->
hWndList
,
-
1
,
LVNI_SELECTED
);
i
=
SendMessageW
(
This
->
hWndList
,
LVM_GETNEXTITEM
,
-
1
,
MAKELPARAM
(
LVNI_SELECTED
,
0
));
SendMessageW
(
This
->
hWndList
,
LVM_ENSUREVISIBLE
,
i
,
0
);
SendMessageW
(
This
->
hWndList
,
LVM_EDITLABELW
,
i
,
0
);
...
...
@@ -1524,7 +1523,7 @@ static LRESULT ShellView_OnNotify(IShellViewImpl * This, UINT CtlID, LPNMHDR lpn
if
(
psfhlp
==
NULL
)
break
;
if
(
!
(
i
=
ListView_GetSelectedCount
(
This
->
hWndList
)))
if
(
!
(
i
=
SendMessageW
(
This
->
hWndList
,
LVM_GETSELECTEDCOUNT
,
0
,
0
)))
break
;
/* allocate memory for the pidl array */
...
...
@@ -1534,11 +1533,11 @@ static LRESULT ShellView_OnNotify(IShellViewImpl * This, UINT CtlID, LPNMHDR lpn
/* retrieve all selected items */
i
=
0
;
item_index
=
-
1
;
while
(
ListView_GetSelectedCount
(
This
->
hWndList
)
>
i
)
while
(
SendMessageW
(
This
->
hWndList
,
LVM_GETSELECTEDCOUNT
,
0
,
0
)
>
i
)
{
/* get selected item */
item_index
=
ListView_GetNextItem
(
This
->
hWndList
,
item_index
,
LVNI_SELECTED
);
item_index
=
SendMessageW
(
This
->
hWndList
,
LVM_GETNEXTITEM
,
item_index
,
MAKELPARAM
(
LVNI_SELECTED
,
0
)
);
item
.
iItem
=
item_index
;
item
.
mask
=
LVIF_PARAM
;
SendMessageA
(
This
->
hWndList
,
LVM_GETITEMA
,
0
,
(
LPARAM
)
&
item
);
...
...
include/commctrl.h
View file @
f8f8f0a4
This diff is collapsed.
Click to expand it.
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