Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-fonts
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
Aleksandr Isakov
wine-fonts
Commits
c14c3a6e
Commit
c14c3a6e
authored
Sep 29, 2009
by
Jacek Caban
Committed by
Alexandre Julliard
Sep 29, 2009
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
mshtml: Added ScriptHost IServiceProvider stub implementation.
parent
2ea23923
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
43 additions
and
1 deletion
+43
-1
script.c
dlls/mshtml/script.c
+42
-0
script.c
dlls/mshtml/tests/script.c
+1
-1
No files found.
dlls/mshtml/script.c
View file @
c14c3a6e
...
...
@@ -47,6 +47,7 @@ struct ScriptHost {
const
IActiveScriptSiteInterruptPollVtbl
*
lpIActiveScriptSiteInterruptPollVtbl
;
const
IActiveScriptSiteWindowVtbl
*
lpIActiveScriptSiteWindowVtbl
;
const
IActiveScriptSiteDebug32Vtbl
*
lpIActiveScriptSiteDebug32Vtbl
;
const
IServiceProviderVtbl
*
lpServiceProviderVtbl
;
LONG
ref
;
...
...
@@ -239,6 +240,9 @@ static HRESULT WINAPI ActiveScriptSite_QueryInterface(IActiveScriptSite *iface,
}
else
if
(
IsEqualGUID
(
&
IID_IActiveScriptSiteDebug32
,
riid
))
{
TRACE
(
"(%p)->(IID_IActiveScriptSiteDebug32 %p)
\n
"
,
This
,
ppv
);
*
ppv
=
ACTSCPDBG32
(
This
);
}
else
if
(
IsEqualGUID
(
&
IID_IServiceProvider
,
riid
))
{
TRACE
(
"(%p)->(IID_IServiceProvider %p)
\n
"
,
This
,
ppv
);
*
ppv
=
SERVPROV
(
This
);
}
else
if
(
IsEqualGUID
(
&
IID_ICanHandleException
,
riid
))
{
TRACE
(
"(%p)->(IID_ICanHandleException not supported %p)
\n
"
,
This
,
ppv
);
return
E_NOINTERFACE
;
...
...
@@ -529,6 +533,43 @@ static const IActiveScriptSiteDebug32Vtbl ActiveScriptSiteDebug32Vtbl = {
ActiveScriptSiteDebug32_OnScriptErrorDebug
};
#define SERVPROV_THIS(iface) DEFINE_THIS(ScriptHost, ServiceProvider, iface)
static
HRESULT
WINAPI
ASServiceProvider_QueryInterface
(
IServiceProvider
*
iface
,
REFIID
riid
,
void
**
ppv
)
{
ScriptHost
*
This
=
SERVPROV_THIS
(
iface
);
return
IActiveScriptSite_QueryInterface
(
ACTSCPSITE
(
This
),
riid
,
ppv
);
}
static
ULONG
WINAPI
ASServiceProvider_AddRef
(
IServiceProvider
*
iface
)
{
ScriptHost
*
This
=
SERVPROV_THIS
(
iface
);
return
IActiveScriptSite_AddRef
(
ACTSCPSITE
(
This
));
}
static
ULONG
WINAPI
ASServiceProvider_Release
(
IServiceProvider
*
iface
)
{
ScriptHost
*
This
=
SERVPROV_THIS
(
iface
);
return
IActiveScriptSite_Release
(
ACTSCPSITE
(
This
));
}
static
HRESULT
WINAPI
ASServiceProvider_QueryService
(
IServiceProvider
*
iface
,
REFGUID
guidService
,
REFIID
riid
,
void
**
ppv
)
{
ScriptHost
*
This
=
SERVPROV_THIS
(
iface
);
FIXME
(
"(%p)->(%s %s %p)
\n
"
,
This
,
debugstr_guid
(
guidService
),
debugstr_guid
(
riid
),
ppv
);
return
E_NOINTERFACE
;
}
#undef SERVPROV_THIS
static
const
IServiceProviderVtbl
ASServiceProviderVtbl
=
{
ASServiceProvider_QueryInterface
,
ASServiceProvider_AddRef
,
ASServiceProvider_Release
,
ASServiceProvider_QueryService
};
static
ScriptHost
*
create_script_host
(
HTMLWindow
*
window
,
const
GUID
*
guid
)
{
ScriptHost
*
ret
;
...
...
@@ -539,6 +580,7 @@ static ScriptHost *create_script_host(HTMLWindow *window, const GUID *guid)
ret
->
lpIActiveScriptSiteInterruptPollVtbl
=
&
ActiveScriptSiteInterruptPollVtbl
;
ret
->
lpIActiveScriptSiteWindowVtbl
=
&
ActiveScriptSiteWindowVtbl
;
ret
->
lpIActiveScriptSiteDebug32Vtbl
=
&
ActiveScriptSiteDebug32Vtbl
;
ret
->
lpServiceProviderVtbl
=
&
ASServiceProviderVtbl
;
ret
->
ref
=
1
;
ret
->
window
=
window
;
ret
->
script_state
=
SCRIPTSTATE_UNINITIALIZED
;
...
...
dlls/mshtml/tests/script.c
View file @
c14c3a6e
...
...
@@ -1053,7 +1053,7 @@ static HRESULT WINAPI ActiveScript_SetScriptSite(IActiveScript *iface, IActiveSc
ok
(
hres
==
E_NOINTERFACE
,
"Could not get IID_ICanHandleException interface: %08x
\n
"
,
hres
);
hres
=
IActiveScriptSite_QueryInterface
(
pass
,
&
IID_IServiceProvider
,
(
void
**
)
&
service
);
todo_wine
ok
(
hres
==
S_OK
,
"Could not get IServiceProvider interface: %08x
\n
"
,
hres
);
ok
(
hres
==
S_OK
,
"Could not get IServiceProvider interface: %08x
\n
"
,
hres
);
if
(
SUCCEEDED
(
hres
))
IServiceProvider_Release
(
service
);
...
...
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