Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
wine
Manage
Activity
Members
Labels
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Package registry
Container Registry
Model registry
Operate
Terraform modules
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Alexey Alyaev
wine
Commits
8d97a7b3
Commit
8d97a7b3
authored
2 years ago
by
Gabriel Ivăncescu
Committed by
Alexandre Julliard
2 years ago
Browse files
Options
Downloads
Patches
Plain Diff
mshtml: Implement ProgressEvent's lengthComputable prop.
Signed-off-by:
Gabriel Ivăncescu
<
gabrielopcode@gmail.com
>
parent
f0806c52
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
dlls/mshtml/htmlevent.c
+11
-2
11 additions, 2 deletions
dlls/mshtml/htmlevent.c
dlls/mshtml/tests/xhr.js
+5
-0
5 additions, 0 deletions
dlls/mshtml/tests/xhr.js
with
16 additions
and
2 deletions
dlls/mshtml/htmlevent.c
+
11
−
2
View file @
8d97a7b3
...
...
@@ -2498,8 +2498,17 @@ static HRESULT WINAPI DOMProgressEvent_Invoke(IDOMProgressEvent *iface, DISPID d
static
HRESULT
WINAPI
DOMProgressEvent_get_lengthComputable
(
IDOMProgressEvent
*
iface
,
VARIANT_BOOL
*
p
)
{
DOMProgressEvent
*
This
=
impl_from_IDOMProgressEvent
(
iface
);
FIXME
(
"(%p)->(%p)
\n
"
,
This
,
p
);
return
E_NOTIMPL
;
nsresult
nsres
;
cpp_bool
b
;
TRACE
(
"(%p)->(%p)
\n
"
,
This
,
p
);
nsres
=
nsIDOMProgressEvent_GetLengthComputable
(
This
->
nsevent
,
&
b
);
if
(
NS_FAILED
(
nsres
))
return
map_nsresult
(
nsres
);
*
p
=
b
?
VARIANT_TRUE
:
VARIANT_FALSE
;
return
S_OK
;
}
static
HRESULT
WINAPI
DOMProgressEvent_get_loaded
(
IDOMProgressEvent
*
iface
,
ULONGLONG
*
p
)
...
...
This diff is collapsed.
Click to expand it.
dlls/mshtml/tests/xhr.js
+
5
−
0
View file @
8d97a7b3
...
...
@@ -47,6 +47,7 @@ function test_xhr() {
var
props
=
[
"
initProgressEvent
"
,
"
lengthComputable
"
,
"
loaded
"
,
"
total
"
];
for
(
var
i
=
0
;
i
<
props
.
length
;
i
++
)
ok
(
props
[
i
]
in
e
,
props
[
i
]
+
"
not available in loadstart
"
);
ok
(
e
.
lengthComputable
===
false
,
"
lengthComputable in loadstart =
"
+
e
.
lengthComputable
);
loadstart
=
true
;
};
xhr
.
onloadend
=
function
(
e
)
{
...
...
@@ -55,6 +56,7 @@ function test_xhr() {
var
props
=
[
"
initProgressEvent
"
,
"
lengthComputable
"
,
"
loaded
"
,
"
total
"
];
for
(
var
i
=
0
;
i
<
props
.
length
;
i
++
)
ok
(
props
[
i
]
in
e
,
props
[
i
]
+
"
not available in loadend
"
);
ok
(
e
.
lengthComputable
===
true
,
"
lengthComputable in loadend =
"
+
e
.
lengthComputable
);
next_test
();
};
}
...
...
@@ -171,6 +173,9 @@ function test_timeout() {
else
ok
(
props
[
r
]
in
e
,
props
[
r
]
+
"
not available
"
);
}
if
(
v
>=
10
)
{
ok
(
e
.
lengthComputable
===
false
,
"
lengthComputable =
"
+
e
.
lengthComputable
);
}
next_test
();
}
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment