Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-cw
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-cw
Commits
2bef3ad2
Commit
2bef3ad2
authored
Dec 06, 2010
by
Michael Stefaniuc
Committed by
Alexandre Julliard
Dec 07, 2010
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
mshtml: Use an iface instead of a vtbl pointer in UndoManager.
parent
2c04cfdb
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
24 additions
and
25 deletions
+24
-25
service.c
dlls/mshtml/service.c
+24
-25
No files found.
dlls/mshtml/service.c
View file @
2bef3ad2
...
...
@@ -35,27 +35,28 @@
WINE_DEFAULT_DEBUG_CHANNEL
(
mshtml
);
typedef
struct
{
const
IOleUndoManagerVtbl
*
lpOleUndoManagerVtbl
;
IOleUndoManager
IOleUndoManager_iface
;
LONG
ref
;
}
UndoManager
;
#define UNDOMGR(x) ((IOleUndoManager*) &(x)->lpOleUndoManagerVtbl)
#define UNDOMGR_THIS(iface) DEFINE_THIS(UndoManager, OleUndoManager, iface)
static
inline
UndoManager
*
impl_from_IOleUndoManager
(
IOleUndoManager
*
iface
)
{
return
CONTAINING_RECORD
(
iface
,
UndoManager
,
IOleUndoManager_iface
);
}
static
HRESULT
WINAPI
OleUndoManager_QueryInterface
(
IOleUndoManager
*
iface
,
REFIID
riid
,
void
**
ppv
)
{
UndoManager
*
This
=
UNDOMGR_THIS
(
iface
);
UndoManager
*
This
=
impl_from_IOleUndoManager
(
iface
);
*
ppv
=
NULL
;
if
(
IsEqualGUID
(
riid
,
&
IID_IUnknown
))
{
TRACE
(
"(%p)->(IID_IUnknown %p)
\n
"
,
This
,
ppv
);
*
ppv
=
UNDOMGR
(
This
)
;
*
ppv
=
&
This
->
IOleUndoManager_iface
;
}
else
if
(
IsEqualGUID
(
riid
,
&
IID_IOleUndoManager
))
{
TRACE
(
"(%p)->(IID_IOleUndoManager %p)
\n
"
,
This
,
ppv
);
*
ppv
=
UNDOMGR
(
This
)
;
*
ppv
=
&
This
->
IOleUndoManager_iface
;
}
...
...
@@ -65,7 +66,7 @@ static HRESULT WINAPI OleUndoManager_QueryInterface(IOleUndoManager *iface, REFI
static
ULONG
WINAPI
OleUndoManager_AddRef
(
IOleUndoManager
*
iface
)
{
UndoManager
*
This
=
UNDOMGR_THIS
(
iface
);
UndoManager
*
This
=
impl_from_IOleUndoManager
(
iface
);
LONG
ref
=
InterlockedIncrement
(
&
This
->
ref
);
TRACE
(
"(%p) ref=%d
\n
"
,
This
,
ref
);
...
...
@@ -75,7 +76,7 @@ static ULONG WINAPI OleUndoManager_AddRef(IOleUndoManager *iface)
static
ULONG
WINAPI
OleUndoManager_Release
(
IOleUndoManager
*
iface
)
{
UndoManager
*
This
=
UNDOMGR_THIS
(
iface
);
UndoManager
*
This
=
impl_from_IOleUndoManager
(
iface
);
LONG
ref
=
InterlockedDecrement
(
&
This
->
ref
);
TRACE
(
"(%p) ref=%d
\n
"
,
This
,
ref
);
...
...
@@ -88,7 +89,7 @@ static ULONG WINAPI OleUndoManager_Release(IOleUndoManager *iface)
static
HRESULT
WINAPI
OleUndoManager_Open
(
IOleUndoManager
*
iface
,
IOleParentUndoUnit
*
pPUU
)
{
UndoManager
*
This
=
UNDOMGR_THIS
(
iface
);
UndoManager
*
This
=
impl_from_IOleUndoManager
(
iface
);
FIXME
(
"(%p)->(%p)
\n
"
,
This
,
pPUU
);
return
E_NOTIMPL
;
}
...
...
@@ -96,42 +97,42 @@ static HRESULT WINAPI OleUndoManager_Open(IOleUndoManager *iface, IOleParentUndo
static
HRESULT
WINAPI
OleUndoManager_Close
(
IOleUndoManager
*
iface
,
IOleParentUndoUnit
*
pPUU
,
BOOL
fCommit
)
{
UndoManager
*
This
=
UNDOMGR_THIS
(
iface
);
UndoManager
*
This
=
impl_from_IOleUndoManager
(
iface
);
FIXME
(
"(%p)->(%p %x)
\n
"
,
This
,
pPUU
,
fCommit
);
return
E_NOTIMPL
;
}
static
HRESULT
WINAPI
OleUndoManager_Add
(
IOleUndoManager
*
iface
,
IOleUndoUnit
*
pUU
)
{
UndoManager
*
This
=
UNDOMGR_THIS
(
iface
);
UndoManager
*
This
=
impl_from_IOleUndoManager
(
iface
);
FIXME
(
"(%p)->(%p)
\n
"
,
This
,
pUU
);
return
E_NOTIMPL
;
}
static
HRESULT
WINAPI
OleUndoManager_GetOpenParentState
(
IOleUndoManager
*
iface
,
DWORD
*
pdwState
)
{
UndoManager
*
This
=
UNDOMGR_THIS
(
iface
);
UndoManager
*
This
=
impl_from_IOleUndoManager
(
iface
);
FIXME
(
"(%p)->(%p)
\n
"
,
This
,
pdwState
);
return
E_NOTIMPL
;
}
static
HRESULT
WINAPI
OleUndoManager_DiscardFrom
(
IOleUndoManager
*
iface
,
IOleUndoUnit
*
pUU
)
{
UndoManager
*
This
=
UNDOMGR_THIS
(
iface
);
UndoManager
*
This
=
impl_from_IOleUndoManager
(
iface
);
FIXME
(
"(%p)->(%p)
\n
"
,
This
,
pUU
);
return
S_OK
;
}
static
HRESULT
WINAPI
OleUndoManager_UndoTo
(
IOleUndoManager
*
iface
,
IOleUndoUnit
*
pUU
)
{
UndoManager
*
This
=
UNDOMGR_THIS
(
iface
);
UndoManager
*
This
=
impl_from_IOleUndoManager
(
iface
);
FIXME
(
"(%p)->(%p)
\n
"
,
This
,
pUU
);
return
E_NOTIMPL
;
}
static
HRESULT
WINAPI
OleUndoManager_RedoTo
(
IOleUndoManager
*
iface
,
IOleUndoUnit
*
pUU
)
{
UndoManager
*
This
=
UNDOMGR_THIS
(
iface
);
UndoManager
*
This
=
impl_from_IOleUndoManager
(
iface
);
FIXME
(
"(%p)->(%p)
\n
"
,
This
,
pUU
);
return
E_NOTIMPL
;
}
...
...
@@ -139,7 +140,7 @@ static HRESULT WINAPI OleUndoManager_RedoTo(IOleUndoManager *iface, IOleUndoUnit
static
HRESULT
WINAPI
OleUndoManager_EnumUndoable
(
IOleUndoManager
*
iface
,
IEnumOleUndoUnits
**
ppEnum
)
{
UndoManager
*
This
=
UNDOMGR_THIS
(
iface
);
UndoManager
*
This
=
impl_from_IOleUndoManager
(
iface
);
FIXME
(
"(%p)->(%p)
\n
"
,
This
,
ppEnum
);
return
E_NOTIMPL
;
}
...
...
@@ -147,34 +148,32 @@ static HRESULT WINAPI OleUndoManager_EnumUndoable(IOleUndoManager *iface,
static
HRESULT
WINAPI
OleUndoManager_EnumRedoable
(
IOleUndoManager
*
iface
,
IEnumOleUndoUnits
**
ppEnum
)
{
UndoManager
*
This
=
UNDOMGR_THIS
(
iface
);
UndoManager
*
This
=
impl_from_IOleUndoManager
(
iface
);
FIXME
(
"(%p)->(%p)
\n
"
,
This
,
ppEnum
);
return
E_NOTIMPL
;
}
static
HRESULT
WINAPI
OleUndoManager_GetLastUndoDescription
(
IOleUndoManager
*
iface
,
BSTR
*
pBstr
)
{
UndoManager
*
This
=
UNDOMGR_THIS
(
iface
);
UndoManager
*
This
=
impl_from_IOleUndoManager
(
iface
);
FIXME
(
"(%p)->(%p)
\n
"
,
This
,
pBstr
);
return
E_NOTIMPL
;
}
static
HRESULT
WINAPI
OleUndoManager_GetLastRedoDescription
(
IOleUndoManager
*
iface
,
BSTR
*
pBstr
)
{
UndoManager
*
This
=
UNDOMGR_THIS
(
iface
);
UndoManager
*
This
=
impl_from_IOleUndoManager
(
iface
);
FIXME
(
"(%p)->(%p)
\n
"
,
This
,
pBstr
);
return
E_NOTIMPL
;
}
static
HRESULT
WINAPI
OleUndoManager_Enable
(
IOleUndoManager
*
iface
,
BOOL
fEnable
)
{
UndoManager
*
This
=
UNDOMGR_THIS
(
iface
);
UndoManager
*
This
=
impl_from_IOleUndoManager
(
iface
);
FIXME
(
"(%p)->(%x)
\n
"
,
This
,
fEnable
);
return
E_NOTIMPL
;
}
#undef UNDOMGR_THIS
static
const
IOleUndoManagerVtbl
OleUndoManagerVtbl
=
{
OleUndoManager_QueryInterface
,
OleUndoManager_AddRef
,
...
...
@@ -197,10 +196,10 @@ static IOleUndoManager *create_undomgr(void)
{
UndoManager
*
ret
=
heap_alloc
(
sizeof
(
UndoManager
));
ret
->
lpOleUndoManager
Vtbl
=
&
OleUndoManagerVtbl
;
ret
->
IOleUndoManager_iface
.
lp
Vtbl
=
&
OleUndoManagerVtbl
;
ret
->
ref
=
1
;
return
UNDOMGR
(
ret
)
;
return
&
ret
->
IOleUndoManager_iface
;
}
/**********************************************************
...
...
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