Alex Villacís Lasso : oleaut32: Add wrapper for dereferencing a VARIANT of type VT_DISPATCH and returning the VARIANT value .
Alexandre Julliard
julliard at wine.codeweavers.com
Wed Jan 3 05:37:34 CST 2007
Module: wine
Branch: master
Commit: 4245cbb31ce87c5c9368377109849066fcdaa296
URL: http://source.winehq.org/git/wine.git/?a=commit;h=4245cbb31ce87c5c9368377109849066fcdaa296
Author: Alex Villacís Lasso <a_villacis at palosanto.com>
Date: Tue Jan 2 18:48:10 2007 -0500
oleaut32: Add wrapper for dereferencing a VARIANT of type VT_DISPATCH and returning the VARIANT value.
---
dlls/oleaut32/variant.c | 16 ++++++++++++++++
1 files changed, 16 insertions(+), 0 deletions(-)
diff --git a/dlls/oleaut32/variant.c b/dlls/oleaut32/variant.c
index f586d8a..52193e9 100644
--- a/dlls/oleaut32/variant.c
+++ b/dlls/oleaut32/variant.c
@@ -2856,6 +2856,22 @@ HRESULT WINAPI VarCmp(LPVARIANT left, LP
#undef _VARCMP
}
+static HRESULT VARIANT_FetchDispatchValue(LPVARIANT pvDispatch, LPVARIANT pValue)
+{
+ HRESULT hres;
+ static DISPPARAMS emptyParams = { NULL, NULL, 0, 0 };
+
+ if ((V_VT(pvDispatch) & VT_TYPEMASK) == VT_DISPATCH) {
+ if (NULL == V_DISPATCH(pvDispatch)) return DISP_E_TYPEMISMATCH;
+ hres = IDispatch_Invoke(V_DISPATCH(pvDispatch), DISPID_VALUE, &IID_NULL,
+ LOCALE_USER_DEFAULT, DISPATCH_PROPERTYGET, &emptyParams, pValue,
+ NULL, NULL);
+ } else {
+ hres = DISP_E_TYPEMISMATCH;
+ }
+ return hres;
+}
+
/**********************************************************************
* VarAnd [OLEAUT32.142]
*
More information about the wine-cvs
mailing list