jscript: Return BOOL instead of VARIANT_BOOL from jsdisp_is_own_prop.
This commit is contained in:
parent
bc768b0906
commit
29f4194d74
|
@ -1415,7 +1415,7 @@ HRESULT jsdisp_delete_idx(jsdisp_t *obj, DWORD idx)
|
|||
return delete_prop(prop);
|
||||
}
|
||||
|
||||
HRESULT jsdisp_is_own_prop(jsdisp_t *obj, BSTR name, VARIANT_BOOL *ret)
|
||||
HRESULT jsdisp_is_own_prop(jsdisp_t *obj, BSTR name, BOOL *ret)
|
||||
{
|
||||
dispex_prop_t *prop;
|
||||
HRESULT hres;
|
||||
|
@ -1424,6 +1424,6 @@ HRESULT jsdisp_is_own_prop(jsdisp_t *obj, BSTR name, VARIANT_BOOL *ret)
|
|||
if(FAILED(hres))
|
||||
return hres;
|
||||
|
||||
*ret = prop && (prop->type == PROP_JSVAL || prop->type == PROP_BUILTIN) ? VARIANT_TRUE : VARIANT_FALSE;
|
||||
*ret = prop && (prop->type == PROP_JSVAL || prop->type == PROP_BUILTIN);
|
||||
return S_OK;
|
||||
}
|
||||
|
|
|
@ -220,7 +220,7 @@ HRESULT jsdisp_propget_name(jsdisp_t*,LPCWSTR,jsval_t*,jsexcept_t*) DECLSPEC_HID
|
|||
HRESULT jsdisp_get_idx(jsdisp_t*,DWORD,jsval_t*,jsexcept_t*) DECLSPEC_HIDDEN;
|
||||
HRESULT jsdisp_get_id(jsdisp_t*,const WCHAR*,DWORD,DISPID*) DECLSPEC_HIDDEN;
|
||||
HRESULT jsdisp_delete_idx(jsdisp_t*,DWORD) DECLSPEC_HIDDEN;
|
||||
HRESULT jsdisp_is_own_prop(jsdisp_t*,BSTR,VARIANT_BOOL*) DECLSPEC_HIDDEN;
|
||||
HRESULT jsdisp_is_own_prop(jsdisp_t*,BSTR,BOOL*) DECLSPEC_HIDDEN;
|
||||
|
||||
HRESULT create_builtin_function(script_ctx_t*,builtin_invoke_t,const WCHAR*,const builtin_info_t*,DWORD,
|
||||
jsdisp_t*,jsdisp_t**) DECLSPEC_HIDDEN;
|
||||
|
|
|
@ -452,7 +452,7 @@ HRESULT to_boolean(jsval_t val, BOOL *ret)
|
|||
switch(val.type) {
|
||||
case JSV_UNDEFINED:
|
||||
case JSV_NULL:
|
||||
*ret = VARIANT_FALSE;
|
||||
*ret = FALSE;
|
||||
return S_OK;
|
||||
case JSV_OBJECT:
|
||||
*ret = get_object(val) != NULL;
|
||||
|
|
|
@ -123,7 +123,7 @@ static HRESULT Object_hasOwnProperty(script_ctx_t *ctx, vdisp_t *jsthis, WORD fl
|
|||
return hres;
|
||||
|
||||
if(is_jsdisp(jsthis)) {
|
||||
VARIANT_BOOL result;
|
||||
BOOL result;
|
||||
|
||||
hres = jsdisp_is_own_prop(jsthis->u.jsdisp, name, &result);
|
||||
if(FAILED(hres))
|
||||
|
|
Loading…
Reference in New Issue