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
8def42e7
Commit
8def42e7
authored
Oct 19, 2017
by
Jacek Caban
Committed by
Alexandre Julliard
Oct 19, 2017
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
mshtml: Store event target in DOMEvent.
Signed-off-by:
Jacek Caban
<
jacek@codeweavers.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
bbfe9e76
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
7 additions
and
9 deletions
+7
-9
htmlevent.c
dlls/mshtml/htmlevent.c
+6
-9
htmlevent.h
dlls/mshtml/htmlevent.h
+1
-0
No files found.
dlls/mshtml/htmlevent.c
View file @
8def42e7
...
...
@@ -229,7 +229,6 @@ struct HTMLEventObj {
LONG
ref
;
EventTarget
*
target
;
const
event_info_t
*
type
;
DOMEvent
*
event
;
VARIANT
return_value
;
...
...
@@ -282,8 +281,6 @@ static ULONG WINAPI HTMLEventObj_Release(IHTMLEventObj *iface)
TRACE
(
"(%p) ref=%d
\n
"
,
This
,
ref
);
if
(
!
ref
)
{
if
(
This
->
target
)
IDispatchEx_Release
(
&
This
->
target
->
dispex
.
IDispatchEx_iface
);
if
(
This
->
event
)
IDOMEvent_Release
(
&
This
->
event
->
IDOMEvent_iface
);
release_dispex
(
&
This
->
dispex
);
...
...
@@ -331,8 +328,8 @@ static HRESULT WINAPI HTMLEventObj_get_srcElement(IHTMLEventObj *iface, IHTMLEle
TRACE
(
"(%p)->(%p)
\n
"
,
This
,
p
);
*
p
=
NULL
;
if
(
This
->
target
)
IDispatchEx_QueryInterface
(
&
This
->
target
->
dispex
.
IDispatchEx_iface
,
&
IID_IHTMLElement
,
(
void
**
)
p
);
if
(
This
->
event
&&
This
->
event
->
target
)
IDispatchEx_QueryInterface
(
&
This
->
event
->
target
->
dispex
.
IDispatchEx_iface
,
&
IID_IHTMLElement
,
(
void
**
)
p
);
return
S_OK
;
}
...
...
@@ -871,6 +868,8 @@ static ULONG WINAPI DOMEvent_Release(IDOMEvent *iface)
TRACE
(
"(%p) ref=%u
\n
"
,
This
,
ref
);
if
(
!
ref
)
{
if
(
This
->
target
)
IDispatchEx_Release
(
&
This
->
target
->
dispex
.
IDispatchEx_iface
);
nsIDOMEvent_Release
(
This
->
nsevent
);
release_dispex
(
&
This
->
dispex
);
heap_free
(
This
);
...
...
@@ -1415,10 +1414,8 @@ static void fire_event_obj(EventTarget *event_target, DOMEvent *event, HTMLEvent
if
(
target_vtbl
&&
target_vtbl
->
set_current_event
)
prev_event
=
target_vtbl
->
set_current_event
(
&
event_target
->
dispex
,
event_obj
?
&
event_obj
->
IHTMLEventObj_iface
:
NULL
);
if
(
event_obj
)
{
event_obj
->
target
=
event_target
;
IDispatchEx_AddRef
(
&
event_target
->
dispex
.
IDispatchEx_iface
);
}
event
->
target
=
event_target
;
IDispatchEx_AddRef
(
&
event_target
->
dispex
.
IDispatchEx_iface
);
for
(
i
=
0
;
i
<
chain_cnt
;
i
++
)
{
call_event_handlers
(
event_obj
,
target_chain
[
i
],
event
->
event_id
);
...
...
dlls/mshtml/htmlevent.h
View file @
8def42e7
...
...
@@ -63,6 +63,7 @@ typedef struct {
nsIDOMEvent
*
nsevent
;
eventid_t
event_id
;
EventTarget
*
target
;
}
DOMEvent
;
eventid_t
str_to_eid
(
LPCWSTR
)
DECLSPEC_HIDDEN
;
...
...
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