[2/2] mshtml: Add VT_INT support in IHTMLElementCollection_item
Konstantin Kondratyuk
kondratyuk at etersoft.ru
Fri Dec 19 06:34:16 CST 2008
VT_INT type isn't documented in MSDN, but it is supported in Windows
--
Best regards,
Konstantin Kondratyuk.
-------------- next part --------------
From fb6ea4822030b80ccfcbc0e39028a6b3225de558 Mon Sep 17 00:00:00 2001
From: Konstantin Kondratyuk <kondratyuk at etersoft.ru>
Date: Fri, 19 Dec 2008 15:21:27 +0300
Subject: [PATCH] mshtml: Add VT_INT support in IHTMLElementCollection_item
---
dlls/mshtml/htmlelemcol.c | 14 ++++++++++++++
1 files changed, 14 insertions(+), 0 deletions(-)
diff --git a/dlls/mshtml/htmlelemcol.c b/dlls/mshtml/htmlelemcol.c
index f0ca6d7..cc7c94b 100644
--- a/dlls/mshtml/htmlelemcol.c
+++ b/dlls/mshtml/htmlelemcol.c
@@ -256,6 +256,20 @@ static HRESULT WINAPI HTMLElementCollection_item(IHTMLElementCollection *iface,
return S_OK;
}
+ if(V_VT(&name) == VT_INT) {
+ TRACE("name is VT_INT: %d\n", V_INT(&name));
+
+ if(V_INT(&name) < 0)
+ return E_INVALIDARG;
+ if(V_INT(&name) >= This->len)
+ return S_OK;
+
+ *pdisp = (IDispatch*)This->elems[V_INT(&name)];
+ IDispatch_AddRef(*pdisp);
+ TRACE("Returning pdisp=%p\n", pdisp);
+ return S_OK;
+ }
+
if(V_VT(&name) == VT_BSTR) {
DWORD i;
--
1.6.0.2.GIT
More information about the wine-patches
mailing list