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
599769f8
Commit
599769f8
authored
May 14, 2018
by
Jacek Caban
Committed by
Alexandre Julliard
May 14, 2018
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
jscript: Use jsdisp_define_property to set prototype constructors.
Signed-off-by:
Jacek Caban
<
jacek@codeweavers.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
3767d63a
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
3 additions
and
7 deletions
+3
-7
dispex.c
dlls/jscript/dispex.c
+0
-5
function.c
dlls/jscript/function.c
+2
-1
jscript.h
dlls/jscript/jscript.h
+0
-1
es5.js
dlls/mshtml/tests/es5.js
+1
-0
No files found.
dlls/jscript/dispex.c
View file @
599769f8
...
...
@@ -1316,11 +1316,6 @@ HRESULT jsdisp_propput_name(jsdisp_t *obj, const WCHAR *name, jsval_t val)
return
jsdisp_propput
(
obj
,
name
,
PROPF_ENUMERABLE
|
PROPF_CONFIGURABLE
|
PROPF_WRITABLE
,
val
);
}
HRESULT
jsdisp_propput_dontenum
(
jsdisp_t
*
obj
,
const
WCHAR
*
name
,
jsval_t
val
)
{
return
jsdisp_propput
(
obj
,
name
,
PROPF_CONFIGURABLE
|
PROPF_WRITABLE
,
val
);
}
HRESULT
jsdisp_propput_idx
(
jsdisp_t
*
obj
,
DWORD
idx
,
jsval_t
val
)
{
WCHAR
buf
[
12
];
...
...
dlls/jscript/function.c
View file @
599769f8
...
...
@@ -672,7 +672,8 @@ static HRESULT set_constructor_prop(script_ctx_t *ctx, jsdisp_t *constr, jsdisp_
{
static
const
WCHAR
constructorW
[]
=
{
'c'
,
'o'
,
'n'
,
's'
,
't'
,
'r'
,
'u'
,
'c'
,
't'
,
'o'
,
'r'
,
0
};
return
jsdisp_propput_dontenum
(
prot
,
constructorW
,
jsval_obj
(
constr
));
return
jsdisp_define_data_property
(
prot
,
constructorW
,
PROPF_WRITABLE
|
PROPF_CONFIGURABLE
,
jsval_obj
(
constr
));
}
HRESULT
create_builtin_constructor
(
script_ctx_t
*
ctx
,
builtin_invoke_t
value_proc
,
const
WCHAR
*
name
,
...
...
dlls/jscript/jscript.h
View file @
599769f8
...
...
@@ -284,7 +284,6 @@ HRESULT disp_propput(script_ctx_t*,IDispatch*,DISPID,jsval_t) DECLSPEC_HIDDEN;
HRESULT
jsdisp_propget
(
jsdisp_t
*
,
DISPID
,
jsval_t
*
)
DECLSPEC_HIDDEN
;
HRESULT
jsdisp_propput
(
jsdisp_t
*
,
const
WCHAR
*
,
DWORD
,
jsval_t
)
DECLSPEC_HIDDEN
;
HRESULT
jsdisp_propput_name
(
jsdisp_t
*
,
const
WCHAR
*
,
jsval_t
)
DECLSPEC_HIDDEN
;
HRESULT
jsdisp_propput_dontenum
(
jsdisp_t
*
,
const
WCHAR
*
,
jsval_t
)
DECLSPEC_HIDDEN
;
HRESULT
jsdisp_propput_idx
(
jsdisp_t
*
,
DWORD
,
jsval_t
)
DECLSPEC_HIDDEN
;
HRESULT
jsdisp_propget_name
(
jsdisp_t
*
,
LPCWSTR
,
jsval_t
*
)
DECLSPEC_HIDDEN
;
HRESULT
jsdisp_get_idx
(
jsdisp_t
*
,
DWORD
,
jsval_t
*
)
DECLSPEC_HIDDEN
;
...
...
dlls/mshtml/tests/es5.js
View file @
599769f8
...
...
@@ -198,6 +198,7 @@ function test_getOwnPropertyDescriptor() {
test_own_data_prop_desc
(
String
,
"prototype"
,
false
,
false
,
false
);
test_own_data_prop_desc
(
function
(){},
"prototype"
,
true
,
false
,
false
);
test_own_data_prop_desc
(
Function
,
"prototype"
,
false
,
false
,
false
);
test_own_data_prop_desc
(
String
.
prototype
,
"constructor"
,
true
,
false
,
true
);
next_test
();
}
...
...
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