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
6e74ec00
Commit
6e74ec00
authored
Oct 13, 1999
by
Francois Gouget
Committed by
Alexandre Julliard
Oct 13, 1999
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Use the COM macros rather than directly accessing the lpvtbl field.
parent
22d4b0af
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
43 additions
and
44 deletions
+43
-44
avifile.c
dlls/avifil32/avifile.c
+20
-20
dplay.c
dlls/dplayx/dplay.c
+6
-7
dplobby.c
dlls/dplayx/dplobby.c
+3
-3
typelib.c
dlls/oleaut32/typelib.c
+12
-12
brsfolder.c
dlls/shell32/brsfolder.c
+1
-1
shellord.c
dlls/shell32/shellord.c
+1
-1
No files found.
dlls/avifil32/avifile.c
View file @
6e74ec00
...
...
@@ -377,16 +377,16 @@ HRESULT WINAPI AVIFileCreateStreamA(PAVIFILE iface,PAVISTREAM *ppavi,AVISTREAMIN
/* Only the szName at the end is different */
memcpy
(
&
psiw
,
psi
,
sizeof
(
*
psi
)
-
sizeof
(
psi
->
szName
));
lstrcpynAtoW
(
psiw
.
szName
,
psi
->
szName
,
sizeof
(
psi
->
szName
));
return
iface
->
lpvtbl
->
fn
CreateStream
(
iface
,
ppavi
,
&
psiw
);
return
IAVIFile_
CreateStream
(
iface
,
ppavi
,
&
psiw
);
}
HRESULT
WINAPI
AVIFileCreateStreamW
(
IAVIFile
*
iface
,
PAVISTREAM
*
avis
,
AVISTREAMINFOW
*
asi
)
{
return
iface
->
lpvtbl
->
fn
CreateStream
(
iface
,
avis
,
asi
);
return
IAVIFile_
CreateStream
(
iface
,
avis
,
asi
);
}
HRESULT
WINAPI
AVIFileGetStream
(
IAVIFile
*
iface
,
PAVISTREAM
*
avis
,
DWORD
fccType
,
LONG
lParam
)
{
return
iface
->
lpvtbl
->
fn
GetStream
(
iface
,
avis
,
fccType
,
lParam
);
return
IAVIFile_
GetStream
(
iface
,
avis
,
fccType
,
lParam
);
}
HRESULT
WINAPI
AVIFileInfoA
(
PAVIFILE
iface
,
LPAVIFILEINFOA
afi
,
LONG
size
)
{
...
...
@@ -395,7 +395,7 @@ HRESULT WINAPI AVIFileInfoA(PAVIFILE iface,LPAVIFILEINFOA afi,LONG size) {
if
(
size
<
sizeof
(
AVIFILEINFOA
))
return
AVIERR_BADSIZE
;
hres
=
iface
->
lpvtbl
->
fn
Info
(
iface
,
&
afiw
,
sizeof
(
afiw
));
hres
=
IAVIFile_
Info
(
iface
,
&
afiw
,
sizeof
(
afiw
));
memcpy
(
afi
,
&
afiw
,
sizeof
(
*
afi
)
-
sizeof
(
afi
->
szFileType
));
lstrcpynWtoA
(
afi
->
szFileType
,
afiw
.
szFileType
,
sizeof
(
afi
->
szFileType
));
return
hres
;
...
...
@@ -403,7 +403,7 @@ HRESULT WINAPI AVIFileInfoA(PAVIFILE iface,LPAVIFILEINFOA afi,LONG size) {
HRESULT
WINAPI
AVIStreamInfoW
(
PAVISTREAM
iface
,
AVISTREAMINFOW
*
asi
,
LONG
size
)
{
return
iface
->
lpvtbl
->
fn
Info
(
iface
,
asi
,
size
);
return
IAVIFile_
Info
(
iface
,
asi
,
size
);
}
HRESULT
WINAPI
AVIStreamInfoA
(
PAVISTREAM
iface
,
AVISTREAMINFOA
*
asi
,
LONG
...
...
@@ -413,14 +413,14 @@ HRESULT WINAPI AVIStreamInfoA(PAVISTREAM iface,AVISTREAMINFOA *asi,LONG
if
(
size
<
sizeof
(
AVISTREAMINFOA
))
return
AVIERR_BADSIZE
;
hres
=
iface
->
lpvtbl
->
fn
Info
(
iface
,
&
asiw
,
sizeof
(
asiw
));
hres
=
IAVIFile_
Info
(
iface
,
&
asiw
,
sizeof
(
asiw
));
memcpy
(
asi
,
&
asiw
,
sizeof
(
asiw
)
-
sizeof
(
asiw
.
szName
));
lstrcpynWtoA
(
asi
->
szName
,
asiw
.
szName
,
sizeof
(
asi
->
szName
));
return
hres
;
}
HRESULT
WINAPI
AVIFileInfoW
(
PAVIFILE
iface
,
LPAVIFILEINFOW
afi
,
LONG
size
)
{
return
iface
->
lpvtbl
->
fn
Info
(
iface
,
afi
,
size
);
return
IAVIFile_
Info
(
iface
,
afi
,
size
);
}
HRESULT
WINAPI
AVIMakeCompressedStream
(
PAVISTREAM
*
ppsCompressed
,
PAVISTREAM
ppsSource
,
AVICOMPRESSOPTIONS
*
aco
,
CLSID
*
pclsidHandler
)
{
...
...
@@ -435,7 +435,7 @@ HRESULT WINAPI AVIMakeCompressedStream(PAVISTREAM *ppsCompressed,PAVISTREAM ppsS
FIXME_
(
avifile
)(
"
\t
dwFlags: 0x%08lx
\n
"
,
aco
->
dwFlags
);
/* we just create a duplicate for now */
((
IUnknown
*
)
ppsSource
)
->
lpvtbl
->
fnAddRef
((
IUnknown
*
)
ppsSource
);
IAVIStream_AddRef
(
ppsSource
);
*
ppsCompressed
=
ppsSource
;
as
=
(
IAVIStreamImpl
*
)
ppsSource
;
...
...
@@ -467,33 +467,33 @@ HRESULT WINAPI AVIMakeCompressedStream(PAVISTREAM *ppsCompressed,PAVISTREAM ppsS
}
HRESULT
WINAPI
AVIStreamSetFormat
(
PAVISTREAM
iface
,
LONG
pos
,
LPVOID
format
,
LONG
formatsize
)
{
return
iface
->
lpvtbl
->
fn
SetFormat
(
iface
,
pos
,
format
,
formatsize
);
return
IAVIStream_
SetFormat
(
iface
,
pos
,
format
,
formatsize
);
}
HRESULT
WINAPI
AVIStreamReadFormat
(
PAVISTREAM
iface
,
LONG
pos
,
LPVOID
format
,
LONG
*
formatsize
)
{
return
iface
->
lpvtbl
->
fn
ReadFormat
(
iface
,
pos
,
format
,
formatsize
);
return
IAVIStream_
ReadFormat
(
iface
,
pos
,
format
,
formatsize
);
}
HRESULT
WINAPI
AVIStreamWrite
(
PAVISTREAM
iface
,
LONG
start
,
LONG
samples
,
LPVOID
buffer
,
LONG
buffersize
,
DWORD
flags
,
LONG
*
sampwritten
,
LONG
*
byteswritten
)
{
return
iface
->
lpvtbl
->
fn
Write
(
iface
,
start
,
samples
,
buffer
,
buffersize
,
flags
,
sampwritten
,
byteswritten
);
return
IAVIStream_
Write
(
iface
,
start
,
samples
,
buffer
,
buffersize
,
flags
,
sampwritten
,
byteswritten
);
}
HRESULT
WINAPI
AVIStreamRead
(
PAVISTREAM
iface
,
LONG
start
,
LONG
samples
,
LPVOID
buffer
,
LONG
buffersize
,
LONG
*
bytesread
,
LONG
*
samplesread
)
{
return
iface
->
lpvtbl
->
fn
Read
(
iface
,
start
,
samples
,
buffer
,
buffersize
,
bytesread
,
samplesread
);
return
IAVIStream_
Read
(
iface
,
start
,
samples
,
buffer
,
buffersize
,
bytesread
,
samplesread
);
}
HRESULT
WINAPI
AVIStreamWriteData
(
PAVISTREAM
iface
,
DWORD
fcc
,
LPVOID
lp
,
LONG
size
)
{
return
iface
->
lpvtbl
->
fn
WriteData
(
iface
,
fcc
,
lp
,
size
);
return
IAVIStream_
WriteData
(
iface
,
fcc
,
lp
,
size
);
}
HRESULT
WINAPI
AVIStreamReadData
(
PAVISTREAM
iface
,
DWORD
fcc
,
LPVOID
lp
,
LONG
*
lpread
)
{
return
iface
->
lpvtbl
->
fn
ReadData
(
iface
,
fcc
,
lp
,
lpread
);
return
IAVIStream_
ReadData
(
iface
,
fcc
,
lp
,
lpread
);
}
LONG
WINAPI
AVIStreamStart
(
PAVISTREAM
iface
)
{
AVISTREAMINFOW
si
;
iface
->
lpvtbl
->
fn
Info
(
iface
,
&
si
,
sizeof
(
si
));
IAVIStream_
Info
(
iface
,
&
si
,
sizeof
(
si
));
return
si
.
dwStart
;
}
...
...
@@ -501,14 +501,14 @@ LONG WINAPI AVIStreamLength(PAVISTREAM iface) {
AVISTREAMINFOW
si
;
HRESULT
ret
;
ret
=
iface
->
lpvtbl
->
fn
Info
(
iface
,
&
si
,
sizeof
(
si
));
ret
=
IAVIStream_
Info
(
iface
,
&
si
,
sizeof
(
si
));
if
(
ret
)
/* error */
return
1
;
return
si
.
dwLength
;
}
ULONG
WINAPI
AVIStreamRelease
(
PAVISTREAM
iface
)
{
return
((
LPUNKNOWN
)
iface
)
->
lpvtbl
->
fnRelease
((
LPUNKNOWN
)
iface
);
return
IAVIStream_Release
(
iface
);
}
PGETFRAME
WINAPI
AVIStreamGetFrameOpen
(
PAVISTREAM
iface
,
LPBITMAPINFOHEADER
bmi
)
{
...
...
@@ -517,16 +517,16 @@ PGETFRAME WINAPI AVIStreamGetFrameOpen(PAVISTREAM iface,LPBITMAPINFOHEADER bmi)
}
LPVOID
WINAPI
AVIStreamGetFrame
(
PGETFRAME
pg
,
LONG
pos
)
{
return
pg
->
lpvtbl
->
fn
GetFrame
(
pg
,
pos
);
return
IGetFrame_
GetFrame
(
pg
,
pos
);
}
HRESULT
WINAPI
AVIStreamGetFrameClose
(
PGETFRAME
pg
)
{
if
(
pg
)
((
LPUNKNOWN
)
pg
)
->
lpvtbl
->
fnRelease
((
LPUNKNOWN
)
pg
);
if
(
pg
)
IGetFrame_Release
(
pg
);
return
0
;
}
ULONG
WINAPI
AVIFileRelease
(
PAVIFILE
iface
)
{
return
((
LPUNKNOWN
)
iface
)
->
lpvtbl
->
fnRelease
((
LPUNKNOWN
)
iface
);
return
IAVIFile_Release
(
iface
);
}
void
WINAPI
AVIFileExit
(
void
)
{
...
...
dlls/dplayx/dplay.c
View file @
6e74ec00
...
...
@@ -50,7 +50,6 @@ struct IDirectPlayImpl
};
/* Get a new interface. To be used by QueryInterface. */
extern
HRESULT
directPlay_QueryInterface
...
...
@@ -72,7 +71,7 @@ HRESULT directPlay_QueryInterface
lpDP
->
lpvtbl
=
&
directPlay2WVT
;
InitializeCriticalSection
(
&
lpDP
->
DP_lock
);
IDirectPlayX_AddRef
(
lpDP
);
IDirectPlayX_AddRef
(
(
IDirectPlay4
*
)
lpDP
);
*
ppvObj
=
lpDP
;
...
...
@@ -92,7 +91,7 @@ HRESULT directPlay_QueryInterface
lpDP
->
lpvtbl
=
&
directPlay2AVT
;
InitializeCriticalSection
(
&
lpDP
->
DP_lock
);
IDirectPlayX_AddRef
(
lpDP
);
IDirectPlayX_AddRef
(
(
IDirectPlay4
*
)
lpDP
);
*
ppvObj
=
lpDP
;
...
...
@@ -112,7 +111,7 @@ HRESULT directPlay_QueryInterface
lpDP
->
lpvtbl
=
&
directPlay3WVT
;
InitializeCriticalSection
(
&
lpDP
->
DP_lock
);
IDirectPlayX_AddRef
(
lpDP
);
IDirectPlayX_AddRef
(
(
IDirectPlay4
*
)
lpDP
);
*
ppvObj
=
lpDP
;
...
...
@@ -132,7 +131,7 @@ HRESULT directPlay_QueryInterface
lpDP
->
lpvtbl
=
&
directPlay3AVT
;
InitializeCriticalSection
(
&
lpDP
->
DP_lock
);
IDirectPlayX_AddRef
(
lpDP
);
IDirectPlayX_AddRef
(
(
IDirectPlay4
*
)
lpDP
);
*
ppvObj
=
lpDP
;
...
...
@@ -152,7 +151,7 @@ HRESULT directPlay_QueryInterface
lpDP
->
lpvtbl
=
&
directPlay4WVT
;
InitializeCriticalSection
(
&
lpDP
->
DP_lock
);
IDirectPlayX_AddRef
(
lpDP
);
IDirectPlayX_AddRef
(
(
IDirectPlay4
*
)
lpDP
);
*
ppvObj
=
lpDP
;
...
...
@@ -172,7 +171,7 @@ HRESULT directPlay_QueryInterface
lpDP
->
lpvtbl
=
&
directPlay4AVT
;
InitializeCriticalSection
(
&
lpDP
->
DP_lock
);
IDirectPlayX_AddRef
(
lpDP
);
IDirectPlayX_AddRef
(
(
IDirectPlay4
*
)
lpDP
);
*
ppvObj
=
lpDP
;
...
...
dlls/dplayx/dplobby.c
View file @
6e74ec00
...
...
@@ -131,7 +131,7 @@ BOOL DPL_CreateIUnknown( IDirectPlayLobbyImpl* lpDPL )
{
InitializeCriticalSection
(
&
lpDPL
->
unk
->
DPL_lock
);
IDirectPlayLobby_AddRef
(
lpDPL
);
IDirectPlayLobby_AddRef
(
(
IDirectPlayLobby
*
)
lpDPL
);
return
TRUE
;
}
...
...
@@ -475,7 +475,7 @@ static HRESULT WINAPI IDirectPlayLobby3AImpl_QueryInterface
IsEqualGUID
(
&
IID_IDirectPlayLobby3A
,
riid
)
)
{
IDirectPlayLobby_AddRef
(
This
);
IDirectPlayLobby_AddRef
(
(
IDirectPlayLobby
*
)
This
);
*
ppvObj
=
This
;
return
S_OK
;
}
...
...
@@ -498,7 +498,7 @@ static HRESULT WINAPI IDirectPlayLobby3WImpl_QueryInterface
IsEqualGUID
(
&
IID_IDirectPlayLobby3
,
riid
)
)
{
IDirectPlayLobby_AddRef
(
This
);
IDirectPlayLobby_AddRef
(
(
IDirectPlayLobby
*
)
This
);
*
ppvObj
=
This
;
return
S_OK
;
}
...
...
dlls/oleaut32/typelib.c
View file @
6e74ec00
...
...
@@ -1230,7 +1230,7 @@ static HRESULT WINAPI ITypeLib_fnQueryInterface( LPTYPELIB This, REFIID riid,
IsEqualIID
(
riid
,
&
IID_ITypeLib2
))
*
ppvObject
=
This
;
if
(
*
ppvObject
){
(
*
(
LPTYPELIB
*
)
ppvObject
)
->
lpvtbl
->
fn
AddRef
(
This
);
ITypeLib_
AddRef
(
This
);
TRACE_
(
typelib
)(
"-- Interface: (%p)->(%p)
\n
"
,
ppvObject
,
*
ppvObject
);
return
S_OK
;
}
...
...
@@ -1626,7 +1626,7 @@ static HRESULT WINAPI ITypeInfo_fnQueryInterface( LPTYPEINFO iface, REFIID riid,
IsEqualIID
(
riid
,
&
IID_ITypeInfo2
))
*
ppvObject
=
This
;
if
(
*
ppvObject
){
(
*
(
LPTYPEINFO
*
)
ppvObject
)
->
lpvtbl
->
fn
AddRef
(
iface
);
ITypeInfo_
AddRef
(
iface
);
TRACE_
(
typelib
)(
"-- Interface: (%p)->(%p)
\n
"
,
ppvObject
,
*
ppvObject
);
return
S_OK
;
}
...
...
@@ -1773,9 +1773,9 @@ static HRESULT WINAPI ITypeInfo_fnGetNames( LPTYPEINFO iface, MEMBERID memid,
result
=
This
->
lpvtbl
->
fnGetRefTypeInfo
(
iface
,
This
->
impltypelist
->
reference
,
&
pTInfo
);
if
(
SUCCEEDED
(
result
)){
result
=
pTInfo
->
lpvtbl
->
fn
GetNames
(
pTInfo
,
memid
,
rgBstrNames
,
result
=
ITypeInfo_
GetNames
(
pTInfo
,
memid
,
rgBstrNames
,
cMaxNames
,
pcNames
);
pTInfo
->
lpvtbl
->
fn
Release
(
pTInfo
);
ITypeInfo_
Release
(
pTInfo
);
return
result
;
}
WARN_
(
typelib
)(
"Could not search inherited interface!
\n
"
);
...
...
@@ -1882,11 +1882,11 @@ static HRESULT WINAPI ITypeInfo_fnGetIDsOfNames( LPTYPEINFO iface,
This
->
TypeAttr
.
cImplTypes
){
/* recursive search */
ITypeInfo
*
pTInfo
;
ret
=
This
->
lpvtbl
->
fn
GetRefTypeInfo
(
iface
,
ret
=
ITypeInfo_
GetRefTypeInfo
(
iface
,
This
->
impltypelist
->
reference
,
&
pTInfo
);
if
(
SUCCEEDED
(
ret
)){
ret
=
pTInfo
->
lpvtbl
->
fn
GetIDsOfNames
(
pTInfo
,
rgszNames
,
cNames
,
pMemId
);
pTInfo
->
lpvtbl
->
fn
Release
(
pTInfo
);
ret
=
ITypeInfo_
GetIDsOfNames
(
pTInfo
,
rgszNames
,
cNames
,
pMemId
);
ITypeInfo_
Release
(
pTInfo
);
return
ret
;
}
WARN_
(
typelib
)(
"Could not search inherited interface!
\n
"
);
...
...
@@ -1977,10 +1977,10 @@ static HRESULT WINAPI ITypeInfo_fnGetRefTypeInfo( LPTYPEINFO iface,
result
=
This
->
lpvtbl
->
fnGetContainingTypeLib
(
iface
,
&
pTLib
,
&
Index
);
if
(
SUCCEEDED
(
result
)){
result
=
pTLib
->
lpvtbl
->
fn
GetTypeInfo
(
pTLib
,
result
=
ITypeLib_
GetTypeInfo
(
pTLib
,
HREFTYPE_INDEX
(
hRefType
),
ppTInfo
);
pTLib
->
lpvtbl
->
fn
Release
(
pTLib
);
ITypeLib_
Release
(
pTLib
);
}
}
else
{
/* imported type lib */
...
...
@@ -1993,7 +1993,7 @@ static HRESULT WINAPI ITypeInfo_fnGetRefTypeInfo( LPTYPEINFO iface,
return
TYPE_E_ELEMENTNOTFOUND
;
/* FIXME : correct? */
pTypeLib
=
pRefType
->
pImpTLInfo
->
pImpTypeLib
;
if
(
pTypeLib
)
/* typelib already loaded */
result
=
pTypeLib
->
lpvtbl
->
fn
GetTypeInfoOfGuid
(
result
=
ITypeLib_
GetTypeInfoOfGuid
(
(
LPTYPELIB
)
pTypeLib
,
&
pRefType
->
guid
,
ppTInfo
);
else
{
result
=
LoadRegTypeLib
(
&
pRefType
->
pImpTLInfo
->
guid
,
...
...
@@ -2005,7 +2005,7 @@ static HRESULT WINAPI ITypeInfo_fnGetRefTypeInfo( LPTYPEINFO iface,
SysFreeString
(
libnam
);
}
if
(
SUCCEEDED
(
result
)){
result
=
pTypeLib
->
lpvtbl
->
fn
GetTypeInfoOfGuid
(
result
=
ITypeLib_
GetTypeInfoOfGuid
(
(
LPTYPELIB
)
pTypeLib
,
&
pRefType
->
guid
,
ppTInfo
);
pRefType
->
pImpTLInfo
->
pImpTypeLib
=
pTypeLib
;
}
...
...
@@ -2065,7 +2065,7 @@ static HRESULT WINAPI ITypeInfo_fnGetContainingTypeLib( LPTYPEINFO iface,
ICOM_THIS
(
TLBTypeInfo
,
iface
);
*
ppTLib
=
(
LPTYPELIB
)(
This
->
pTypeLib
);
*
pIndex
=
This
->
index
;
(
*
ppTLib
)
->
lpvtbl
->
fn
AddRef
(
*
ppTLib
);
ITypeLib_
AddRef
(
*
ppTLib
);
TRACE_
(
typelib
)(
"(%p) returns (%p) index %d!
\n
"
,
This
,
*
ppTLib
,
*
pIndex
);
return
S_OK
;
}
...
...
dlls/shell32/brsfolder.c
View file @
6e74ec00
...
...
@@ -168,7 +168,7 @@ Done:
SetCursor
(
LoadCursorA
(
0
,
IDC_ARROWA
));
if
(
lpe
)
lpe
->
lpvtbl
->
fn
Release
(
lpe
);
IEnumIDList_
Release
(
lpe
);
if
(
pidlTemp
)
SHFree
(
pidlTemp
);
}
...
...
dlls/shell32/shellord.c
View file @
6e74ec00
...
...
@@ -844,7 +844,7 @@ HRESULT WINAPI SHGetInstanceExplorer (LPUNKNOWN * lpUnknown)
if
(
!
SHELL32_IExplorerInterface
)
return
E_FAIL
;
SHELL32_IExplorerInterface
->
lpvtbl
->
fn
AddRef
(
SHELL32_IExplorerInterface
);
IUnknown_
AddRef
(
SHELL32_IExplorerInterface
);
return
NOERROR
;
}
/*************************************************************************
...
...
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