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
410501e6
Commit
410501e6
authored
Dec 06, 2010
by
Jacek Caban
Committed by
Alexandre Julliard
Dec 06, 2010
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
mshtml: Added QuickActivation support.
parent
c706bba6
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
63 additions
and
2 deletions
+63
-2
npplugin.c
dlls/mshtml/npplugin.c
+10
-2
pluginhost.c
dlls/mshtml/pluginhost.c
+51
-0
pluginhost.h
dlls/mshtml/pluginhost.h
+2
-0
No files found.
dlls/mshtml/npplugin.c
View file @
410501e6
...
...
@@ -303,8 +303,16 @@ static NPError CDECL NPP_Destroy(NPP instance, NPSavedData **save)
static
NPError
CDECL
NPP_SetWindow
(
NPP
instance
,
NPWindow
*
window
)
{
FIXME
(
"(%p %p)
\n
"
,
instance
,
window
);
return
NPERR_GENERIC_ERROR
;
PluginHost
*
host
=
instance
->
pdata
;
RECT
pos_rect
=
{
0
,
0
,
window
->
width
,
window
->
height
};
TRACE
(
"(%p %p)
\n
"
,
instance
,
window
);
if
(
!
host
)
return
NPERR_GENERIC_ERROR
;
update_plugin_window
(
host
,
window
->
window
,
&
pos_rect
);
return
NPERR_NO_ERROR
;
}
static
NPError
CDECL
NPP_NewStream
(
NPP
instance
,
NPMIMEType
type
,
NPStream
*
stream
,
NPBool
seekable
,
UINT16
*
stype
)
...
...
dlls/mshtml/pluginhost.c
View file @
410501e6
...
...
@@ -36,6 +36,57 @@
WINE_DEFAULT_DEBUG_CHANNEL
(
mshtml
);
static
void
activate_plugin
(
PluginHost
*
host
)
{
IClientSecurity
*
client_security
;
IQuickActivate
*
quick_activate
;
HRESULT
hres
;
if
(
!
host
->
plugin_unk
)
return
;
/* Note native calls QI on plugin for an undocumented IID and CLSID_HTMLDocument */
/* FIXME: call FreezeEvents(TRUE) */
hres
=
IUnknown_QueryInterface
(
host
->
plugin_unk
,
&
IID_IClientSecurity
,
(
void
**
)
&
client_security
);
if
(
SUCCEEDED
(
hres
))
{
FIXME
(
"Handle IClientSecurity
\n
"
);
IClientSecurity_Release
(
client_security
);
return
;
}
hres
=
IUnknown_QueryInterface
(
host
->
plugin_unk
,
&
IID_IQuickActivate
,
(
void
**
)
&
quick_activate
);
if
(
SUCCEEDED
(
hres
))
{
QACONTAINER
container
=
{
sizeof
(
container
)};
QACONTROL
control
=
{
sizeof
(
control
)};
container
.
pClientSite
=
&
host
->
IOleClientSite_iface
;
container
.
dwAmbientFlags
=
QACONTAINER_SUPPORTSMNEMONICS
|
QACONTAINER_MESSAGEREFLECT
|
QACONTAINER_USERMODE
;
container
.
pAdviseSink
=
NULL
;
/* FIXME */
container
.
pPropertyNotifySink
=
NULL
;
/* FIXME */
hres
=
IQuickActivate_QuickActivate
(
quick_activate
,
&
container
,
&
control
);
if
(
FAILED
(
hres
))
FIXME
(
"QuickActivate failed: %08x
\n
"
,
hres
);
}
else
{
FIXME
(
"No IQuickActivate
\n
"
);
}
}
void
update_plugin_window
(
PluginHost
*
host
,
HWND
hwnd
,
const
RECT
*
rect
)
{
if
(
!
hwnd
||
(
host
->
hwnd
&&
host
->
hwnd
!=
hwnd
))
{
FIXME
(
"unhandled hwnd
\n
"
);
return
;
}
if
(
!
host
->
hwnd
)
{
host
->
hwnd
=
hwnd
;
activate_plugin
(
host
);
}
}
static
inline
PluginHost
*
impl_from_IOleClientSite
(
IOleClientSite
*
iface
)
{
return
CONTAINING_RECORD
(
iface
,
PluginHost
,
IOleClientSite_iface
);
...
...
dlls/mshtml/pluginhost.h
View file @
410501e6
...
...
@@ -24,6 +24,8 @@ typedef struct {
LONG
ref
;
IUnknown
*
plugin_unk
;
HWND
hwnd
;
}
PluginHost
;
HRESULT
create_plugin_host
(
IUnknown
*
,
PluginHost
**
);
void
update_plugin_window
(
PluginHost
*
,
HWND
,
const
RECT
*
);
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