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
0b556458
Commit
0b556458
authored
Jan 27, 2012
by
Jacek Caban
Committed by
Alexandre Julliard
Jan 27, 2012
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
mshtml: Follow anchors only on left button click.
parent
83693d96
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
25 additions
and
5 deletions
+25
-5
htmlanchor.c
dlls/mshtml/htmlanchor.c
+23
-3
htmlevent.c
dlls/mshtml/htmlevent.c
+1
-1
mshtml_private.h
dlls/mshtml/mshtml_private.h
+1
-1
No files found.
dlls/mshtml/htmlanchor.c
View file @
0b556458
...
@@ -18,6 +18,7 @@
...
@@ -18,6 +18,7 @@
#include <stdarg.h>
#include <stdarg.h>
#include <stdio.h>
#include <stdio.h>
#include <assert.h>
#define COBJMACROS
#define COBJMACROS
...
@@ -583,14 +584,33 @@ static void HTMLAnchorElement_destructor(HTMLDOMNode *iface)
...
@@ -583,14 +584,33 @@ static void HTMLAnchorElement_destructor(HTMLDOMNode *iface)
HTMLElement_destructor
(
&
This
->
element
.
node
);
HTMLElement_destructor
(
&
This
->
element
.
node
);
}
}
static
HRESULT
HTMLAnchorElement_handle_event
(
HTMLDOMNode
*
iface
,
eventid_t
eid
,
BOOL
*
prevent_default
)
static
HRESULT
HTMLAnchorElement_handle_event
(
HTMLDOMNode
*
iface
,
eventid_t
eid
,
nsIDOMEvent
*
event
,
BOOL
*
prevent_default
)
{
{
HTMLAnchorElement
*
This
=
impl_from_HTMLDOMNode
(
iface
);
HTMLAnchorElement
*
This
=
impl_from_HTMLDOMNode
(
iface
);
if
(
eid
==
EVENTID_CLICK
)
{
if
(
eid
==
EVENTID_CLICK
)
{
nsIDOMMouseEvent
*
mouse_event
;
PRUint16
button
;
nsresult
nsres
;
TRACE
(
"CLICK
\n
"
);
TRACE
(
"CLICK
\n
"
);
*
prevent_default
=
TRUE
;
return
navigate_anchor
(
This
);
nsres
=
nsIDOMEvent_QueryInterface
(
event
,
&
IID_nsIDOMMouseEvent
,
(
void
**
)
&
mouse_event
);
assert
(
nsres
==
NS_OK
);
nsres
=
nsIDOMMouseEvent_GetButton
(
mouse_event
,
&
button
);
assert
(
nsres
==
NS_OK
);
nsIDOMMouseEvent_Release
(
mouse_event
);
switch
(
button
)
{
case
0
:
*
prevent_default
=
TRUE
;
return
navigate_anchor
(
This
);
default:
*
prevent_default
=
FALSE
;
return
S_OK
;
}
}
}
return
S_OK
;
return
S_OK
;
...
...
dlls/mshtml/htmlevent.c
View file @
0b556458
...
@@ -1065,7 +1065,7 @@ void fire_event(HTMLDocumentNode *doc, eventid_t eid, BOOL set_event, nsIDOMNode
...
@@ -1065,7 +1065,7 @@ void fire_event(HTMLDocumentNode *doc, eventid_t eid, BOOL set_event, nsIDOMNode
break
;
break
;
if
(
node
&&
node
->
vtbl
->
handle_event
)
{
if
(
node
&&
node
->
vtbl
->
handle_event
)
{
hres
=
node
->
vtbl
->
handle_event
(
node
,
eid
,
&
prevent_default
);
hres
=
node
->
vtbl
->
handle_event
(
node
,
eid
,
nsevent
,
&
prevent_default
);
if
(
FAILED
(
hres
)
||
prevent_default
)
if
(
FAILED
(
hres
)
||
prevent_default
)
break
;
break
;
}
}
...
...
dlls/mshtml/mshtml_private.h
View file @
0b556458
...
@@ -518,7 +518,7 @@ typedef struct {
...
@@ -518,7 +518,7 @@ typedef struct {
HRESULT
(
*
get_attr_col
)(
HTMLDOMNode
*
,
HTMLAttributeCollection
**
);
HRESULT
(
*
get_attr_col
)(
HTMLDOMNode
*
,
HTMLAttributeCollection
**
);
event_target_t
**
(
*
get_event_target
)(
HTMLDOMNode
*
);
event_target_t
**
(
*
get_event_target
)(
HTMLDOMNode
*
);
HRESULT
(
*
fire_event
)(
HTMLDOMNode
*
,
DWORD
,
BOOL
*
);
HRESULT
(
*
fire_event
)(
HTMLDOMNode
*
,
DWORD
,
BOOL
*
);
HRESULT
(
*
handle_event
)(
HTMLDOMNode
*
,
DWORD
,
BOOL
*
);
HRESULT
(
*
handle_event
)(
HTMLDOMNode
*
,
DWORD
,
nsIDOMEvent
*
,
BOOL
*
);
HRESULT
(
*
put_disabled
)(
HTMLDOMNode
*
,
VARIANT_BOOL
);
HRESULT
(
*
put_disabled
)(
HTMLDOMNode
*
,
VARIANT_BOOL
);
HRESULT
(
*
get_disabled
)(
HTMLDOMNode
*
,
VARIANT_BOOL
*
);
HRESULT
(
*
get_disabled
)(
HTMLDOMNode
*
,
VARIANT_BOOL
*
);
HRESULT
(
*
get_document
)(
HTMLDOMNode
*
,
IDispatch
**
);
HRESULT
(
*
get_document
)(
HTMLDOMNode
*
,
IDispatch
**
);
...
...
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