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
da4a45cd
Commit
da4a45cd
authored
Oct 17, 2022
by
Gabriel Ivăncescu
Committed by
Alexandre Julliard
Oct 19, 2022
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
mshtml: Move the OleObj interfaces out of basedoc.
Signed-off-by:
Gabriel Ivăncescu
<
gabrielopcode@gmail.com
>
parent
6c706e02
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
72 additions
and
45 deletions
+72
-45
editor.c
dlls/mshtml/editor.c
+2
-2
htmldoc.c
dlls/mshtml/htmldoc.c
+44
-24
mshtml_private.h
dlls/mshtml/mshtml_private.h
+18
-10
oleobj.c
dlls/mshtml/oleobj.c
+0
-0
persist.c
dlls/mshtml/persist.c
+3
-3
pluginhost.c
dlls/mshtml/pluginhost.c
+1
-1
view.c
dlls/mshtml/view.c
+4
-5
No files found.
dlls/mshtml/editor.c
View file @
da4a45cd
...
...
@@ -1266,11 +1266,11 @@ HRESULT setup_edit_mode(HTMLDocumentObj *doc)
if
(
doc
->
hostui
)
IDocHostUIHandler_ShowUI
(
doc
->
hostui
,
DOCHOSTUITYPE_AUTHOR
,
&
doc
->
basedoc
.
IOleInPlaceActiveObject_iface
,
&
doc
->
IOleCommandTarget_iface
,
&
doc
->
IOleInPlaceActiveObject_iface
,
&
doc
->
IOleCommandTarget_iface
,
doc
->
frame
,
doc
->
ip_window
);
if
(
doc
->
ip_window
)
call_set_active_object
(
doc
->
ip_window
,
&
doc
->
basedoc
.
IOleInPlaceActiveObject_iface
);
call_set_active_object
(
doc
->
ip_window
,
&
doc
->
IOleInPlaceActiveObject_iface
);
SetRectEmpty
(
&
rcBorderWidths
);
if
(
doc
->
frame
)
...
...
dlls/mshtml/htmldoc.c
View file @
da4a45cd
...
...
@@ -5613,30 +5613,10 @@ static BOOL htmldoc_qi(HTMLDocument *This, REFIID riid, void **ppv)
*
ppv
=
&
This
->
IDocumentSelector_iface
;
else
if
(
IsEqualGUID
(
&
IID_IDocumentEvent
,
riid
))
*
ppv
=
&
This
->
IDocumentEvent_iface
;
else
if
(
IsEqualGUID
(
&
IID_IOleObject
,
riid
))
*
ppv
=
&
This
->
IOleObject_iface
;
else
if
(
IsEqualGUID
(
&
IID_IOleDocument
,
riid
))
*
ppv
=
&
This
->
IOleDocument_iface
;
else
if
(
IsEqualGUID
(
&
IID_IOleInPlaceActiveObject
,
riid
))
*
ppv
=
&
This
->
IOleInPlaceActiveObject_iface
;
else
if
(
IsEqualGUID
(
&
IID_IOleWindow
,
riid
))
*
ppv
=
&
This
->
IOleInPlaceActiveObject_iface
;
else
if
(
IsEqualGUID
(
&
IID_IOleInPlaceObject
,
riid
))
*
ppv
=
&
This
->
IOleInPlaceObjectWindowless_iface
;
else
if
(
IsEqualGUID
(
&
IID_IOleInPlaceObjectWindowless
,
riid
))
*
ppv
=
&
This
->
IOleInPlaceObjectWindowless_iface
;
else
if
(
IsEqualGUID
(
&
IID_IOleControl
,
riid
))
*
ppv
=
&
This
->
IOleControl_iface
;
else
if
(
IsEqualGUID
(
&
DIID_DispHTMLDocument
,
riid
))
*
ppv
=
&
This
->
IHTMLDocument2_iface
;
else
if
(
IsEqualGUID
(
&
IID_ISupportErrorInfo
,
riid
))
*
ppv
=
&
This
->
ISupportErrorInfo_iface
;
else
if
(
IsEqualGUID
(
&
IID_IObjectWithSite
,
riid
))
*
ppv
=
&
This
->
IObjectWithSite_iface
;
else
if
(
IsEqualGUID
(
&
IID_IOleContainer
,
riid
))
*
ppv
=
&
This
->
IOleContainer_iface
;
else
if
(
IsEqualGUID
(
&
IID_IObjectSafety
,
riid
))
*
ppv
=
&
This
->
IObjectSafety_iface
;
else
if
(
IsEqualGUID
(
&
IID_IProvideClassInfo
,
riid
))
*
ppv
=
&
This
->
IProvideMultipleClassInfo_iface
;
else
if
(
IsEqualGUID
(
&
IID_IProvideClassInfo2
,
riid
))
...
...
@@ -5706,8 +5686,6 @@ static void init_doc(HTMLDocument *doc, IUnknown *outer, IDispatchEx *dispex)
doc
->
outer_unk
=
outer
;
doc
->
dispex
=
dispex
;
HTMLDocument_OleObj_Init
(
doc
);
}
static
inline
HTMLDocumentNode
*
impl_from_HTMLDOMNode
(
HTMLDOMNode
*
iface
)
...
...
@@ -5742,6 +5720,26 @@ static HRESULT HTMLDocumentNode_QI(HTMLDOMNode *iface, REFIID riid, void **ppv)
*
ppv
=
&
This
->
IHlinkTarget_iface
;
else
if
(
IsEqualGUID
(
&
IID_IOleCommandTarget
,
riid
))
*
ppv
=
&
This
->
IOleCommandTarget_iface
;
else
if
(
IsEqualGUID
(
&
IID_IOleObject
,
riid
))
*
ppv
=
&
This
->
IOleObject_iface
;
else
if
(
IsEqualGUID
(
&
IID_IOleDocument
,
riid
))
*
ppv
=
&
This
->
IOleDocument_iface
;
else
if
(
IsEqualGUID
(
&
IID_IOleInPlaceActiveObject
,
riid
))
*
ppv
=
&
This
->
IOleInPlaceActiveObject_iface
;
else
if
(
IsEqualGUID
(
&
IID_IOleWindow
,
riid
))
*
ppv
=
&
This
->
IOleInPlaceActiveObject_iface
;
else
if
(
IsEqualGUID
(
&
IID_IOleInPlaceObject
,
riid
))
*
ppv
=
&
This
->
IOleInPlaceObjectWindowless_iface
;
else
if
(
IsEqualGUID
(
&
IID_IOleInPlaceObjectWindowless
,
riid
))
*
ppv
=
&
This
->
IOleInPlaceObjectWindowless_iface
;
else
if
(
IsEqualGUID
(
&
IID_IOleControl
,
riid
))
*
ppv
=
&
This
->
IOleControl_iface
;
else
if
(
IsEqualGUID
(
&
IID_IObjectWithSite
,
riid
))
*
ppv
=
&
This
->
IObjectWithSite_iface
;
else
if
(
IsEqualGUID
(
&
IID_IOleContainer
,
riid
))
*
ppv
=
&
This
->
IOleContainer_iface
;
else
if
(
IsEqualGUID
(
&
IID_IObjectSafety
,
riid
))
*
ppv
=
&
This
->
IObjectSafety_iface
;
else
if
(
IsEqualGUID
(
&
IID_IServiceProvider
,
riid
))
*
ppv
=
&
This
->
IServiceProvider_iface
;
else
if
(
IsEqualGUID
(
&
IID_IConnectionPointContainer
,
riid
))
...
...
@@ -6136,6 +6134,7 @@ static HTMLDocumentNode *alloc_doc_node(HTMLDocumentObj *doc_obj, HTMLInnerWindo
HTMLDocumentNode_Persist_Init
(
doc
);
HTMLDocumentNode_Service_Init
(
doc
);
HTMLDocumentNode_OleCmd_Init
(
doc
);
HTMLDocumentNode_OleObj_Init
(
doc
);
HTMLDocumentNode_SecMgr_Init
(
doc
);
list_init
(
&
doc
->
selection_list
);
...
...
@@ -6270,6 +6269,26 @@ static HRESULT WINAPI HTMLDocumentObj_QueryInterface(IUnknown *iface, REFIID rii
*
ppv
=
&
This
->
IHlinkTarget_iface
;
}
else
if
(
IsEqualGUID
(
&
IID_IOleCommandTarget
,
riid
))
{
*
ppv
=
&
This
->
IOleCommandTarget_iface
;
}
else
if
(
IsEqualGUID
(
&
IID_IOleObject
,
riid
))
{
*
ppv
=
&
This
->
IOleObject_iface
;
}
else
if
(
IsEqualGUID
(
&
IID_IOleDocument
,
riid
))
{
*
ppv
=
&
This
->
IOleDocument_iface
;
}
else
if
(
IsEqualGUID
(
&
IID_IOleInPlaceActiveObject
,
riid
))
{
*
ppv
=
&
This
->
IOleInPlaceActiveObject_iface
;
}
else
if
(
IsEqualGUID
(
&
IID_IOleWindow
,
riid
))
{
*
ppv
=
&
This
->
IOleInPlaceActiveObject_iface
;
}
else
if
(
IsEqualGUID
(
&
IID_IOleInPlaceObject
,
riid
))
{
*
ppv
=
&
This
->
IOleInPlaceObjectWindowless_iface
;
}
else
if
(
IsEqualGUID
(
&
IID_IOleInPlaceObjectWindowless
,
riid
))
{
*
ppv
=
&
This
->
IOleInPlaceObjectWindowless_iface
;
}
else
if
(
IsEqualGUID
(
&
IID_IOleControl
,
riid
))
{
*
ppv
=
&
This
->
IOleControl_iface
;
}
else
if
(
IsEqualGUID
(
&
IID_IObjectWithSite
,
riid
))
{
*
ppv
=
&
This
->
IObjectWithSite_iface
;
}
else
if
(
IsEqualGUID
(
&
IID_IOleContainer
,
riid
))
{
*
ppv
=
&
This
->
IOleContainer_iface
;
}
else
if
(
IsEqualGUID
(
&
IID_IObjectSafety
,
riid
))
{
*
ppv
=
&
This
->
IObjectSafety_iface
;
}
else
if
(
IsEqualGUID
(
&
IID_IServiceProvider
,
riid
))
{
*
ppv
=
&
This
->
IServiceProvider_iface
;
}
else
if
(
IsEqualGUID
(
&
IID_ITargetContainer
,
riid
))
{
...
...
@@ -6318,11 +6337,11 @@ static ULONG WINAPI HTMLDocumentObj_Release(IUnknown *iface)
if
(
This
->
view_sink
)
IAdviseSink_Release
(
This
->
view_sink
);
if
(
This
->
client
)
IOleObject_SetClientSite
(
&
This
->
basedoc
.
IOleObject_iface
,
NULL
);
IOleObject_SetClientSite
(
&
This
->
IOleObject_iface
,
NULL
);
if
(
This
->
hostui
)
ICustomDoc_SetUIHandler
(
&
This
->
ICustomDoc_iface
,
NULL
);
if
(
This
->
in_place_active
)
IOleInPlaceObjectWindowless_InPlaceDeactivate
(
&
This
->
basedoc
.
IOleInPlaceObjectWindowless_iface
);
IOleInPlaceObjectWindowless_InPlaceDeactivate
(
&
This
->
IOleInPlaceObjectWindowless_iface
);
if
(
This
->
ipsite
)
IOleDocumentView_SetInPlaceSite
(
&
This
->
IOleDocumentView_iface
,
NULL
);
if
(
This
->
undomgr
)
...
...
@@ -6501,6 +6520,7 @@ static HRESULT create_document_object(BOOL is_mhtml, IUnknown *outer, REFIID rii
HTMLDocumentObj_Persist_Init
(
doc
);
HTMLDocumentObj_Service_Init
(
doc
);
HTMLDocumentObj_OleCmd_Init
(
doc
);
HTMLDocumentObj_OleObj_Init
(
doc
);
TargetContainer_Init
(
doc
);
doc
->
is_mhtml
=
is_mhtml
;
...
...
dlls/mshtml/mshtml_private.h
View file @
da4a45cd
...
...
@@ -648,16 +648,8 @@ struct HTMLDocument {
IHTMLDocument7
IHTMLDocument7_iface
;
IDocumentSelector
IDocumentSelector_iface
;
IDocumentEvent
IDocumentEvent_iface
;
IOleObject
IOleObject_iface
;
IOleDocument
IOleDocument_iface
;
IOleInPlaceActiveObject
IOleInPlaceActiveObject_iface
;
IOleInPlaceObjectWindowless
IOleInPlaceObjectWindowless_iface
;
IOleControl
IOleControl_iface
;
IDispatchEx
IDispatchEx_iface
;
ISupportErrorInfo
ISupportErrorInfo_iface
;
IObjectWithSite
IObjectWithSite_iface
;
IOleContainer
IOleContainer_iface
;
IObjectSafety
IObjectSafety_iface
;
IProvideMultipleClassInfo
IProvideMultipleClassInfo_iface
;
IMarkupServices
IMarkupServices_iface
;
IMarkupContainer
IMarkupContainer_iface
;
...
...
@@ -702,6 +694,14 @@ struct HTMLDocumentObj {
IPersistHistory
IPersistHistory_iface
;
IHlinkTarget
IHlinkTarget_iface
;
IOleCommandTarget
IOleCommandTarget_iface
;
IOleObject
IOleObject_iface
;
IOleDocument
IOleDocument_iface
;
IOleControl
IOleControl_iface
;
IOleInPlaceActiveObject
IOleInPlaceActiveObject_iface
;
IOleInPlaceObjectWindowless
IOleInPlaceObjectWindowless_iface
;
IObjectWithSite
IObjectWithSite_iface
;
IOleContainer
IOleContainer_iface
;
IObjectSafety
IObjectSafety_iface
;
IServiceProvider
IServiceProvider_iface
;
ITargetContainer
ITargetContainer_iface
;
...
...
@@ -903,6 +903,14 @@ struct HTMLDocumentNode {
IPersistHistory
IPersistHistory_iface
;
IHlinkTarget
IHlinkTarget_iface
;
IOleCommandTarget
IOleCommandTarget_iface
;
IOleObject
IOleObject_iface
;
IOleDocument
IOleDocument_iface
;
IOleControl
IOleControl_iface
;
IOleInPlaceActiveObject
IOleInPlaceActiveObject_iface
;
IOleInPlaceObjectWindowless
IOleInPlaceObjectWindowless_iface
;
IObjectWithSite
IObjectWithSite_iface
;
IOleContainer
IOleContainer_iface
;
IObjectSafety
IObjectSafety_iface
;
IServiceProvider
IServiceProvider_iface
;
IInternetHostSecurityManager
IInternetHostSecurityManager_iface
;
...
...
@@ -970,17 +978,17 @@ void detach_dom_implementation(IHTMLDOMImplementation*) DECLSPEC_HIDDEN;
HRESULT
create_html_storage
(
HTMLInnerWindow
*
,
BOOL
,
IHTMLStorage
**
)
DECLSPEC_HIDDEN
;
void
detach_html_storage
(
IHTMLStorage
*
)
DECLSPEC_HIDDEN
;
void
HTMLDocument_OleObj_Init
(
HTMLDocument
*
)
DECLSPEC_HIDDEN
;
void
HTMLDocument_View_Init
(
HTMLDocumentObj
*
)
DECLSPEC_HIDDEN
;
void
HTMLDocumentObj_Persist_Init
(
HTMLDocumentObj
*
)
DECLSPEC_HIDDEN
;
void
HTMLDocumentObj_Service_Init
(
HTMLDocumentObj
*
)
DECLSPEC_HIDDEN
;
void
HTMLDocumentObj_OleCmd_Init
(
HTMLDocumentObj
*
)
DECLSPEC_HIDDEN
;
void
HTMLDocumentObj_OleObj_Init
(
HTMLDocumentObj
*
)
DECLSPEC_HIDDEN
;
void
TargetContainer_Init
(
HTMLDocumentObj
*
)
DECLSPEC_HIDDEN
;
void
HTMLDocumentNode_Persist_Init
(
HTMLDocumentNode
*
)
DECLSPEC_HIDDEN
;
void
HTMLDocumentNode_Service_Init
(
HTMLDocumentNode
*
)
DECLSPEC_HIDDEN
;
void
HTMLDocumentNode_OleCmd_Init
(
HTMLDocumentNode
*
)
DECLSPEC_HIDDEN
;
void
HTMLDocumentNode_OleObj_Init
(
HTMLDocumentNode
*
)
DECLSPEC_HIDDEN
;
void
HTMLDocumentNode_SecMgr_Init
(
HTMLDocumentNode
*
)
DECLSPEC_HIDDEN
;
HRESULT
HTMLCurrentStyle_Create
(
HTMLElement
*
,
IHTMLCurrentStyle
**
)
DECLSPEC_HIDDEN
;
...
...
dlls/mshtml/oleobj.c
View file @
da4a45cd
This diff is collapsed.
Click to expand it.
dlls/mshtml/persist.c
View file @
da4a45cd
...
...
@@ -685,7 +685,7 @@ static HRESULT WINAPI DocObjPersistMoniker_Load(IPersistMoniker *iface, BOOL fFu
hres
=
IUnknown_QueryInterface
(
unk
,
&
IID_IOleClientSite
,
(
void
**
)
&
client
);
if
(
SUCCEEDED
(
hres
))
{
TRACE
(
"Got client site %p
\n
"
,
client
);
IOleObject_SetClientSite
(
&
This
->
basedoc
.
IOleObject_iface
,
client
);
IOleObject_SetClientSite
(
&
This
->
IOleObject_iface
,
client
);
IOleClientSite_Release
(
client
);
}
...
...
@@ -1508,7 +1508,7 @@ static HRESULT WINAPI DocNodeHlinkTarget_Navigate(IHlinkTarget *iface, DWORD grf
FIXME
(
"JumpLocation not supported
\n
"
);
if
(
This
->
basedoc
.
doc_obj
->
client
)
return
IOleObject_DoVerb
(
&
This
->
basedoc
.
IOleObject_iface
,
OLEIVERB_SHOW
,
NULL
,
NULL
,
-
1
,
NULL
,
NULL
);
return
IOleObject_DoVerb
(
&
This
->
IOleObject_iface
,
OLEIVERB_SHOW
,
NULL
,
NULL
,
-
1
,
NULL
,
NULL
);
return
IHlinkTarget_Navigate
(
&
This
->
basedoc
.
doc_obj
->
IHlinkTarget_iface
,
grfHLNF
,
pwzJumpLocation
);
}
...
...
@@ -1602,7 +1602,7 @@ static HRESULT WINAPI DocObjHlinkTarget_Navigate(IHlinkTarget *iface, DWORD grfH
return
S_OK
;
}
return
IOleObject_DoVerb
(
&
This
->
basedoc
.
IOleObject_iface
,
OLEIVERB_SHOW
,
NULL
,
NULL
,
-
1
,
NULL
,
NULL
);
return
IOleObject_DoVerb
(
&
This
->
IOleObject_iface
,
OLEIVERB_SHOW
,
NULL
,
NULL
,
-
1
,
NULL
,
NULL
);
}
static
HRESULT
WINAPI
DocObjHlinkTarget_GetMoniker
(
IHlinkTarget
*
iface
,
LPCWSTR
pwzLocation
,
DWORD
dwAssign
,
...
...
dlls/mshtml/pluginhost.c
View file @
da4a45cd
...
...
@@ -1602,7 +1602,7 @@ static HRESULT WINAPI PHClientSite_GetContainer(IOleClientSite *iface, IOleConta
return
E_UNEXPECTED
;
}
*
ppContainer
=
&
This
->
doc
->
basedoc
.
IOleContainer_iface
;
*
ppContainer
=
&
This
->
doc
->
IOleContainer_iface
;
IOleContainer_AddRef
(
*
ppContainer
);
return
S_OK
;
}
...
...
dlls/mshtml/view.c
View file @
da4a45cd
...
...
@@ -541,7 +541,7 @@ static HRESULT WINAPI OleDocumentView_Show(IOleDocumentView *iface, BOOL fShow)
ShowWindow
(
This
->
hwnd
,
SW_HIDE
);
if
(
This
->
in_place_active
)
IOleInPlaceObjectWindowless_InPlaceDeactivate
(
&
This
->
basedoc
.
IOleInPlaceObjectWindowless_iface
);
IOleInPlaceObjectWindowless_InPlaceDeactivate
(
&
This
->
IOleInPlaceObjectWindowless_iface
);
if
(
This
->
ip_window
)
{
IOleInPlaceUIWindow_Release
(
This
->
ip_window
);
...
...
@@ -612,8 +612,7 @@ static HRESULT WINAPI OleDocumentView_UIActivate(IOleDocumentView *iface, BOOL f
hres
=
IOleInPlaceSite_OnUIActivate
(
This
->
ipsite
);
if
(
SUCCEEDED
(
hres
))
{
call_set_active_object
((
IOleInPlaceUIWindow
*
)
This
->
frame
,
&
This
->
basedoc
.
IOleInPlaceActiveObject_iface
);
call_set_active_object
((
IOleInPlaceUIWindow
*
)
This
->
frame
,
&
This
->
IOleInPlaceActiveObject_iface
);
}
else
{
FIXME
(
"OnUIActivate failed: %08lx
\n
"
,
hres
);
IOleInPlaceFrame_Release
(
This
->
frame
);
...
...
@@ -625,14 +624,14 @@ static HRESULT WINAPI OleDocumentView_UIActivate(IOleDocumentView *iface, BOOL f
if
(
This
->
hostui
)
{
hres
=
IDocHostUIHandler_ShowUI
(
This
->
hostui
,
This
->
nscontainer
->
usermode
==
EDITMODE
?
DOCHOSTUITYPE_AUTHOR
:
DOCHOSTUITYPE_BROWSE
,
&
This
->
basedoc
.
IOleInPlaceActiveObject_iface
,
&
This
->
IOleCommandTarget_iface
,
&
This
->
IOleInPlaceActiveObject_iface
,
&
This
->
IOleCommandTarget_iface
,
This
->
frame
,
This
->
ip_window
);
if
(
FAILED
(
hres
))
IDocHostUIHandler_HideUI
(
This
->
hostui
);
}
if
(
This
->
ip_window
)
call_set_active_object
(
This
->
ip_window
,
&
This
->
basedoc
.
IOleInPlaceActiveObject_iface
);
call_set_active_object
(
This
->
ip_window
,
&
This
->
IOleInPlaceActiveObject_iface
);
SetRectEmpty
(
&
rcBorderWidths
);
IOleInPlaceFrame_SetBorderSpace
(
This
->
frame
,
&
rcBorderWidths
);
...
...
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