Commit 2f460788 authored by Piotr Caban's avatar Piotr Caban Committed by Alexandre Julliard

jscript: Added VBArray.dimensions() implementation.

parent 2aa7e3c6
......@@ -2253,6 +2253,7 @@ ok(String.length == 1, "String.length = " + String.length);
var tmp = new VBArray(createArray());
tmp = new VBArray(VBArray(createArray()));
ok(tmp.dimensions() == 2, "tmp.dimensions() = " + tmp.dimensions());
ok(tmp.lbound() == 0, "tmp.lbound() = " + tmp.lbound());
ok(tmp.lbound(1) == 0, "tmp.lbound(1) = " + tmp.lbound(1));
ok(tmp.lbound(2, 1) == 2, "tmp.lbound(2, 1) = " + tmp.lbound(2, 1));
......
......@@ -47,8 +47,17 @@ static inline VBArrayInstance *vbarray_this(vdisp_t *jsthis)
static HRESULT VBArray_dimensions(script_ctx_t *ctx, vdisp_t *vthis, WORD flags, DISPPARAMS *dp,
VARIANT *retv, jsexcept_t *ei, IServiceProvider *caller)
{
FIXME("\n");
return E_NOTIMPL;
VBArrayInstance *vbarray;
TRACE("\n");
vbarray = vbarray_this(vthis);
if(!vbarray)
return throw_type_error(ctx, ei, IDS_NOT_VBARRAY, NULL);
if(retv)
num_set_val(retv, SafeArrayGetDim(vbarray->safearray));
return S_OK;
}
static HRESULT VBArray_getItem(script_ctx_t *ctx, vdisp_t *vthis, WORD flags, DISPPARAMS *dp,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment