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
c833238a
Commit
c833238a
authored
Mar 11, 2021
by
Jacek Caban
Committed by
Alexandre Julliard
Mar 11, 2021
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
mshtml: Initialize DOMEvent object with compat mode.
Signed-off-by:
Jacek Caban
<
jacek@codeweavers.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
78be5629
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
11 additions
and
11 deletions
+11
-11
htmlevent.c
dlls/mshtml/htmlevent.c
+6
-6
htmlevent.h
dlls/mshtml/htmlevent.h
+1
-1
nsembed.c
dlls/mshtml/nsembed.c
+1
-1
nsevents.c
dlls/mshtml/nsevents.c
+2
-2
xmlhttprequest.c
dlls/mshtml/xmlhttprequest.c
+1
-1
No files found.
dlls/mshtml/htmlevent.c
View file @
c833238a
...
...
@@ -2201,7 +2201,7 @@ static BOOL check_event_iface(nsIDOMEvent *event, REFIID riid)
return
TRUE
;
}
static
DOMEvent
*
alloc_event
(
nsIDOMEvent
*
nsevent
,
eventid_t
event_id
)
static
DOMEvent
*
alloc_event
(
nsIDOMEvent
*
nsevent
,
compat_mode_t
compat_mode
,
eventid_t
event_id
)
{
dispex_static_data_t
*
dispex_data
=
&
DOMEvent_dispex
;
DOMEvent
*
event
=
NULL
;
...
...
@@ -2266,11 +2266,11 @@ static DOMEvent *alloc_event(nsIDOMEvent *nsevent, eventid_t event_id)
else
event
->
keyboard_event
=
NULL
;
init_dispex
(
&
event
->
dispex
,
(
IUnknown
*
)
&
event
->
IDOMEvent_iface
,
dispex_data
);
init_dispex
_with_compat_mode
(
&
event
->
dispex
,
(
IUnknown
*
)
&
event
->
IDOMEvent_iface
,
dispex_data
,
compat_mode
);
return
event
;
}
HRESULT
create_event_from_nsevent
(
nsIDOMEvent
*
nsevent
,
DOMEvent
**
ret_event
)
HRESULT
create_event_from_nsevent
(
nsIDOMEvent
*
nsevent
,
compat_mode_t
compat_mode
,
DOMEvent
**
ret_event
)
{
eventid_t
event_id
=
EVENTID_LAST
;
DOMEvent
*
event
;
...
...
@@ -2290,7 +2290,7 @@ HRESULT create_event_from_nsevent(nsIDOMEvent *nsevent, DOMEvent **ret_event)
}
nsAString_Finish
(
&
nsstr
);
event
=
alloc_event
(
nsevent
,
event_id
);
event
=
alloc_event
(
nsevent
,
compat_mode
,
event_id
);
if
(
!
event
)
return
E_OUTOFMEMORY
;
...
...
@@ -2313,7 +2313,7 @@ HRESULT create_document_event_str(HTMLDocumentNode *doc, const WCHAR *type, IDOM
return
E_FAIL
;
}
event
=
alloc_event
(
nsevent
,
EVENTID_LAST
);
event
=
alloc_event
(
nsevent
,
dispex_compat_mode
(
&
doc
->
node
.
event_target
.
dispex
),
EVENTID_LAST
);
nsIDOMEvent_Release
(
nsevent
);
if
(
!
event
)
return
E_OUTOFMEMORY
;
...
...
@@ -2337,7 +2337,7 @@ HRESULT create_document_event(HTMLDocumentNode *doc, eventid_t event_id, DOMEven
return
E_FAIL
;
}
event
=
alloc_event
(
nsevent
,
event_id
);
event
=
alloc_event
(
nsevent
,
dispex_compat_mode
(
&
doc
->
node
.
event_target
.
dispex
),
event_id
);
if
(
!
event
)
return
E_OUTOFMEMORY
;
...
...
dlls/mshtml/htmlevent.h
View file @
c833238a
...
...
@@ -110,7 +110,7 @@ void dispatch_event(EventTarget*,DOMEvent*) DECLSPEC_HIDDEN;
HRESULT
create_document_event
(
HTMLDocumentNode
*
,
eventid_t
,
DOMEvent
**
)
DECLSPEC_HIDDEN
;
HRESULT
create_document_event_str
(
HTMLDocumentNode
*
,
const
WCHAR
*
,
IDOMEvent
**
)
DECLSPEC_HIDDEN
;
HRESULT
create_event_from_nsevent
(
nsIDOMEvent
*
,
DOMEvent
**
)
DECLSPEC_HIDDEN
;
HRESULT
create_event_from_nsevent
(
nsIDOMEvent
*
,
compat_mode_t
,
DOMEvent
**
)
DECLSPEC_HIDDEN
;
void
init_nsevents
(
HTMLDocumentNode
*
)
DECLSPEC_HIDDEN
;
void
release_nsevents
(
HTMLDocumentNode
*
)
DECLSPEC_HIDDEN
;
...
...
dlls/mshtml/nsembed.c
View file @
c833238a
...
...
@@ -1659,7 +1659,7 @@ static nsresult NSAPI nsContextMenuListener_OnShowContextMenu(nsIContextMenuList
if
(
FAILED
(
hres
))
return
NS_ERROR_FAILURE
;
hres
=
create_event_from_nsevent
(
aEvent
,
&
event
);
hres
=
create_event_from_nsevent
(
aEvent
,
dispex_compat_mode
(
&
node
->
event_target
.
dispex
),
&
event
);
if
(
SUCCEEDED
(
hres
))
{
dispatch_event
(
&
node
->
event_target
,
event
);
IDOMEvent_Release
(
&
event
->
IDOMEvent_iface
);
...
...
dlls/mshtml/nsevents.c
View file @
c833238a
...
...
@@ -270,7 +270,7 @@ static nsresult NSAPI handle_load(nsIDOMEventListener *iface, nsIDOMEvent *event
}
if
(
doc
->
window
)
{
hres
=
create_event_from_nsevent
(
event
,
&
load_event
);
hres
=
create_event_from_nsevent
(
event
,
dispex_compat_mode
(
&
doc
->
node
.
event_target
.
dispex
),
&
load_event
);
if
(
SUCCEEDED
(
hres
))
{
dispatch_event
(
&
doc
->
window
->
event_target
,
load_event
);
IDOMEvent_Release
(
&
load_event
->
IDOMEvent_iface
);
...
...
@@ -319,7 +319,7 @@ static nsresult NSAPI handle_htmlevent(nsIDOMEventListener *iface, nsIDOMEvent *
if
(
FAILED
(
hres
))
return
NS_OK
;
hres
=
create_event_from_nsevent
(
nsevent
,
&
event
);
hres
=
create_event_from_nsevent
(
nsevent
,
dispex_compat_mode
(
&
doc
->
node
.
event_target
.
dispex
),
&
event
);
if
(
FAILED
(
hres
))
{
node_release
(
node
);
return
NS_OK
;
...
...
dlls/mshtml/xmlhttprequest.c
View file @
c833238a
...
...
@@ -205,7 +205,7 @@ static nsresult NSAPI XMLHttpReqEventListener_HandleEvent(nsIDOMEventListener *i
if
(
!
This
->
xhr
)
return
NS_OK
;
hres
=
create_event_from_nsevent
(
nsevent
,
&
event
);
hres
=
create_event_from_nsevent
(
nsevent
,
dispex_compat_mode
(
&
This
->
xhr
->
event_target
.
dispex
),
&
event
);
if
(
SUCCEEDED
(
hres
)
){
dispatch_event
(
&
This
->
xhr
->
event_target
,
event
);
IDOMEvent_Release
(
&
event
->
IDOMEvent_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