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
bd407b70
Commit
bd407b70
authored
Oct 10, 2011
by
Michael Stefaniuc
Committed by
Alexandre Julliard
Oct 10, 2011
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
shell32: Return the IEnumIDList object on its creation.
parent
27b284d4
Show whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
48 additions
and
39 deletions
+48
-39
cpanelfolder.c
dlls/shell32/cpanelfolder.c
+5
-3
enumidlist.c
dlls/shell32/enumidlist.c
+2
-20
recyclebin.c
dlls/shell32/recyclebin.c
+4
-4
shell32_main.h
dlls/shell32/shell32_main.h
+17
-1
shfldr_desktop.c
dlls/shell32/shfldr_desktop.c
+5
-3
shfldr_fs.c
dlls/shell32/shfldr_fs.c
+5
-3
shfldr_mycomp.c
dlls/shell32/shfldr_mycomp.c
+5
-3
shfldr_netplaces.c
dlls/shell32/shfldr_netplaces.c
+5
-2
No files found.
dlls/shell32/cpanelfolder.c
View file @
bd407b70
...
...
@@ -445,16 +445,18 @@ static HRESULT WINAPI ISF_ControlPanel_fnEnumObjects(IShellFolder2 *iface, HWND
DWORD
dwFlags
,
LPENUMIDLIST
*
ppEnumIDList
)
{
ICPanelImpl
*
This
=
impl_from_IShellFolder2
(
iface
);
IEnumIDListImpl
*
list
;
TRACE
(
"(%p)->(HWND=%p flags=0x%08x pplist=%p)
\n
"
,
This
,
hwndOwner
,
dwFlags
,
ppEnumIDList
);
*
ppEnumIDList
=
IEnumIDList_Constructor
();
if
(
*
ppEnumIDList
)
if
(
!
(
list
=
IEnumIDList_Constructor
()))
return
E_OUTOFMEMORY
;
*
ppEnumIDList
=
&
list
->
IEnumIDList_iface
;
CreateCPanelEnumList
(
*
ppEnumIDList
,
dwFlags
);
TRACE
(
"--(%p)->(new ID List: %p)
\n
"
,
This
,
*
ppEnumIDList
);
return
(
*
ppEnumIDList
)
?
S_OK
:
E_OUTOFMEMORY
;
return
S_OK
;
}
/**************************************************************************
...
...
dlls/shell32/enumidlist.c
View file @
bd407b70
...
...
@@ -36,22 +36,6 @@
WINE_DEFAULT_DEBUG_CHANNEL
(
shell
);
struct
enumlist
{
struct
enumlist
*
pNext
;
LPITEMIDLIST
pidl
;
};
typedef
struct
{
IEnumIDList
IEnumIDList_iface
;
LONG
ref
;
struct
enumlist
*
mpFirst
;
struct
enumlist
*
mpLast
;
struct
enumlist
*
mpCurrent
;
}
IEnumIDListImpl
;
/**************************************************************************
* AddToEnumList()
*/
...
...
@@ -340,7 +324,7 @@ static const IEnumIDListVtbl eidlvt =
IEnumIDList_fnClone
,
};
IEnumIDList
*
IEnumIDList_Constructor
(
void
)
IEnumIDList
Impl
*
IEnumIDList_Constructor
(
void
)
{
IEnumIDListImpl
*
lpeidl
=
HeapAlloc
(
GetProcessHeap
(),
HEAP_ZERO_MEMORY
,
sizeof
(
*
lpeidl
));
...
...
@@ -349,10 +333,8 @@ IEnumIDList *IEnumIDList_Constructor(void)
lpeidl
->
ref
=
1
;
lpeidl
->
IEnumIDList_iface
.
lpVtbl
=
&
eidlvt
;
}
else
return
NULL
;
TRACE
(
"-- (%p)->()
\n
"
,
lpeidl
);
return
&
lpeidl
->
IEnumIDList_iface
;
return
lpeidl
;
}
dlls/shell32/recyclebin.c
View file @
bd407b70
...
...
@@ -408,7 +408,7 @@ static HRESULT WINAPI RecycleBin_ParseDisplayName(IShellFolder2 *This, HWND hwnd
static
HRESULT
WINAPI
RecycleBin_EnumObjects
(
IShellFolder2
*
iface
,
HWND
hwnd
,
SHCONTF
grfFlags
,
IEnumIDList
**
ppenumIDList
)
{
RecycleBin
*
This
=
impl_from_IShellFolder2
(
iface
);
IEnumIDList
*
list
;
IEnumIDList
Impl
*
list
;
LPITEMIDLIST
*
pidls
;
HRESULT
ret
=
E_OUTOFMEMORY
;
int
pidls_count
;
...
...
@@ -426,16 +426,16 @@ static HRESULT WINAPI RecycleBin_EnumObjects(IShellFolder2 *iface, HWND hwnd, SH
if
(
FAILED
(
ret
=
TRASH_EnumItems
(
&
pidls
,
&
pidls_count
)))
goto
failed
;
for
(
i
=
0
;
i
<
pidls_count
;
i
++
)
if
(
!
AddToEnumList
(
list
,
pidls
[
i
]))
if
(
!
AddToEnumList
(
&
list
->
IEnumIDList_iface
,
pidls
[
i
]))
goto
failed
;
}
*
ppenumIDList
=
list
;
*
ppenumIDList
=
&
list
->
IEnumIDList_iface
;
return
S_OK
;
failed:
if
(
list
)
IEnumIDList_Release
(
list
);
IEnumIDList_Release
(
&
list
->
IEnumIDList_iface
);
for
(;
i
<
pidls_count
;
i
++
)
ILFree
(
pidls
[
i
]);
SHFree
(
pidls
);
...
...
dlls/shell32/shell32_main.h
View file @
bd407b70
...
...
@@ -205,8 +205,24 @@ HRESULT SHELL_RegisterShellFolders(void) DECLSPEC_HIDDEN;
BOOL
SHELL_IsShortcut
(
LPCITEMIDLIST
)
DECLSPEC_HIDDEN
;
/* IEnumIDList stuff */
struct
enumlist
{
struct
enumlist
*
pNext
;
LPITEMIDLIST
pidl
;
};
typedef
struct
{
IEnumIDList
IEnumIDList_iface
;
LONG
ref
;
struct
enumlist
*
mpFirst
;
struct
enumlist
*
mpLast
;
struct
enumlist
*
mpCurrent
;
}
IEnumIDListImpl
;
/* Creates an IEnumIDList; add LPITEMIDLISTs to it with AddToEnumList. */
LPENUMIDLIST
IEnumIDList_Constructor
(
void
)
DECLSPEC_HIDDEN
;
IEnumIDListImpl
*
IEnumIDList_Constructor
(
void
)
DECLSPEC_HIDDEN
;
BOOL
AddToEnumList
(
IEnumIDList
*
list
,
LPITEMIDLIST
pidl
)
DECLSPEC_HIDDEN
;
/* Enumerates the folders and/or files (depending on dwFlags) in lpszPath and
...
...
dlls/shell32/shfldr_desktop.c
View file @
bd407b70
...
...
@@ -345,17 +345,19 @@ static HRESULT WINAPI ISF_Desktop_fnEnumObjects (IShellFolder2 * iface,
HWND
hwndOwner
,
DWORD
dwFlags
,
LPENUMIDLIST
*
ppEnumIDList
)
{
IDesktopFolderImpl
*
This
=
impl_from_IShellFolder2
(
iface
);
IEnumIDListImpl
*
list
;
TRACE
(
"(%p)->(HWND=%p flags=0x%08x pplist=%p)
\n
"
,
This
,
hwndOwner
,
dwFlags
,
ppEnumIDList
);
*
ppEnumIDList
=
IEnumIDList_Constructor
();
if
(
*
ppEnumIDList
)
if
(
!
(
list
=
IEnumIDList_Constructor
()))
return
E_OUTOFMEMORY
;
*
ppEnumIDList
=
&
list
->
IEnumIDList_iface
;
CreateDesktopEnumList
(
*
ppEnumIDList
,
dwFlags
);
TRACE
(
"-- (%p)->(new ID List: %p)
\n
"
,
This
,
*
ppEnumIDList
);
return
*
ppEnumIDList
?
S_OK
:
E_OUTOFMEMORY
;
return
S_OK
;
}
/**************************************************************************
...
...
dlls/shell32/shfldr_fs.c
View file @
bd407b70
...
...
@@ -448,17 +448,19 @@ IShellFolder_fnEnumObjects (IShellFolder2 * iface, HWND hwndOwner,
DWORD
dwFlags
,
LPENUMIDLIST
*
ppEnumIDList
)
{
IGenericSFImpl
*
This
=
impl_from_IShellFolder2
(
iface
);
IEnumIDListImpl
*
list
;
TRACE
(
"(%p)->(HWND=%p flags=0x%08x pplist=%p)
\n
"
,
This
,
hwndOwner
,
dwFlags
,
ppEnumIDList
);
*
ppEnumIDList
=
IEnumIDList_Constructor
();
if
(
*
ppEnumIDList
)
if
(
!
(
list
=
IEnumIDList_Constructor
()))
return
E_OUTOFMEMORY
;
*
ppEnumIDList
=
&
list
->
IEnumIDList_iface
;
CreateFolderEnumList
(
*
ppEnumIDList
,
This
->
sPathTarget
,
dwFlags
);
TRACE
(
"-- (%p)->(new ID List: %p)
\n
"
,
This
,
*
ppEnumIDList
);
return
*
ppEnumIDList
?
S_OK
:
E_OUTOFMEMORY
;
return
S_OK
;
}
/**************************************************************************
...
...
dlls/shell32/shfldr_mycomp.c
View file @
bd407b70
...
...
@@ -355,17 +355,19 @@ static HRESULT WINAPI ISF_MyComputer_fnEnumObjects (IShellFolder2 *iface,
HWND
hwndOwner
,
DWORD
dwFlags
,
LPENUMIDLIST
*
ppEnumIDList
)
{
IMyComputerFolderImpl
*
This
=
impl_from_IShellFolder2
(
iface
);
IEnumIDListImpl
*
list
;
TRACE
(
"(%p)->(HWND=%p flags=0x%08x pplist=%p)
\n
"
,
This
,
hwndOwner
,
dwFlags
,
ppEnumIDList
);
*
ppEnumIDList
=
IEnumIDList_Constructor
();
if
(
*
ppEnumIDList
)
if
(
!
(
list
=
IEnumIDList_Constructor
()))
return
E_OUTOFMEMORY
;
*
ppEnumIDList
=
&
list
->
IEnumIDList_iface
;
CreateMyCompEnumList
(
*
ppEnumIDList
,
dwFlags
);
TRACE
(
"-- (%p)->(new ID List: %p)
\n
"
,
This
,
*
ppEnumIDList
);
return
(
*
ppEnumIDList
)
?
S_OK
:
E_OUTOFMEMORY
;
return
S_OK
;
}
/**************************************************************************
...
...
dlls/shell32/shfldr_netplaces.c
View file @
bd407b70
...
...
@@ -244,15 +244,18 @@ static HRESULT WINAPI ISF_NetworkPlaces_fnEnumObjects (IShellFolder2 * iface,
HWND
hwndOwner
,
DWORD
dwFlags
,
LPENUMIDLIST
*
ppEnumIDList
)
{
IGenericSFImpl
*
This
=
impl_from_IShellFolder2
(
iface
);
IEnumIDListImpl
*
list
;
TRACE
(
"(%p)->(HWND=%p flags=0x%08x pplist=%p)
\n
"
,
This
,
hwndOwner
,
dwFlags
,
ppEnumIDList
);
*
ppEnumIDList
=
IEnumIDList_Constructor
();
if
(
!
(
list
=
IEnumIDList_Constructor
()))
return
E_OUTOFMEMORY
;
*
ppEnumIDList
=
&
list
->
IEnumIDList_iface
;
TRACE
(
"-- (%p)->(new ID List: %p)
\n
"
,
This
,
*
ppEnumIDList
);
return
(
*
ppEnumIDList
)
?
S_OK
:
E_OUTOFMEMORY
;
return
S_OK
;
}
/**************************************************************************
...
...
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