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
c62e96eb
Commit
c62e96eb
authored
Mar 29, 2019
by
Jacek Caban
Committed by
Alexandre Julliard
Mar 29, 2019
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
mshtml: Implement IHTMLElement6::msMatchesSelector.
Signed-off-by:
Jacek Caban
<
jacek@codeweavers.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
6e34275f
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
23 additions
and
2 deletions
+23
-2
htmlelem.c
dlls/mshtml/htmlelem.c
+21
-2
elements.js
dlls/mshtml/tests/elements.js
+2
-0
No files found.
dlls/mshtml/htmlelem.c
View file @
c62e96eb
...
...
@@ -4514,8 +4514,27 @@ static HRESULT WINAPI HTMLElement6_getElementsByClassName(IHTMLElement6 *iface,
static
HRESULT
WINAPI
HTMLElement6_msMatchesSelector
(
IHTMLElement6
*
iface
,
BSTR
v
,
VARIANT_BOOL
*
pfMatches
)
{
HTMLElement
*
This
=
impl_from_IHTMLElement6
(
iface
);
FIXME
(
"(%p)->(%s %p)
\n
"
,
This
,
debugstr_w
(
v
),
pfMatches
);
return
E_NOTIMPL
;
nsAString
nsstr
;
cpp_bool
b
;
nsresult
nsres
;
TRACE
(
"(%p)->(%s %p)
\n
"
,
This
,
debugstr_w
(
v
),
pfMatches
);
if
(
!
This
->
dom_element
)
{
FIXME
(
"No dom element
\n
"
);
return
E_UNEXPECTED
;
}
nsAString_InitDepend
(
&
nsstr
,
v
);
nsres
=
nsIDOMElement_MozMatchesSelector
(
This
->
dom_element
,
&
nsstr
,
&
b
);
nsAString_Finish
(
&
nsstr
);
if
(
NS_FAILED
(
nsres
))
{
WARN
(
"MozMatchesSelector failed: %08x
\n
"
,
nsres
);
return
map_nsresult
(
nsres
);
}
*
pfMatches
=
b
;
return
S_OK
;
}
static
HRESULT
WINAPI
HTMLElement6_put_onabort
(
IHTMLElement6
*
iface
,
VARIANT
v
)
...
...
dlls/mshtml/tests/elements.js
View file @
c62e96eb
...
...
@@ -207,6 +207,8 @@ function test_query_selector() {
ok
(
e
.
tagName
===
"DIV"
,
"e.tagName = "
+
e
.
tagName
);
e
=
document
.
body
.
querySelector
(
".class1"
);
ok
(
e
.
tagName
===
"DIV"
,
"e.tagName = "
+
e
.
tagName
);
ok
(
e
.
msMatchesSelector
(
".class1"
)
===
true
,
"msMatchesSelector returned "
+
e
.
msMatchesSelector
(
".class1"
));
ok
(
e
.
msMatchesSelector
(
".class2"
)
===
false
,
"msMatchesSelector returned "
+
e
.
msMatchesSelector
(
".class2"
));
e
=
document
.
querySelector
(
"a"
);
ok
(
e
.
tagName
===
"A"
,
"e.tagName = "
+
e
.
tagName
);
...
...
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