diff options
author | suke <suke@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2002-10-17 12:35:48 +0000 |
---|---|---|
committer | suke <suke@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2002-10-17 12:35:48 +0000 |
commit | 9dce0d8f0b1cd52fee0a9ddad61fa63d8c83c829 (patch) | |
tree | ff4cb5b5f4cb9242c86d3fcca0e1570bfa673644 | |
parent | 020caa3fc8b2ce78591eaa04e674907b48e5b7b0 (diff) | |
download | ruby-9dce0d8f0b1cd52fee0a9ddad61fa63d8c83c829.tar.gz |
* win32ole.c(EVENTSINK_Invoke): set pvarResult.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2968 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
-rw-r--r-- | ext/win32ole/win32ole.c | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/ext/win32ole/win32ole.c b/ext/win32ole/win32ole.c index d34cf854ec..29be931534 100644 --- a/ext/win32ole/win32ole.c +++ b/ext/win32ole/win32ole.c @@ -4754,7 +4754,7 @@ STDMETHODIMP EVENTSINK_Invoke( unsigned int i; ITypeInfo *pTypeInfo; VARIANT *pvar; - VALUE ary, obj, event, handler, args, argv, ev; + VALUE ary, obj, event, handler, args, argv, ev, result; BOOL is_default_handler = FALSE; PIEVENTSINKOBJ pEV = (PIEVENTSINKOBJ)pEventSink; @@ -4794,12 +4794,17 @@ STDMETHODIMP EVENTSINK_Invoke( if (rb_ary_entry(event, 3) == Qtrue) { argv = rb_ary_new(); rb_ary_push(args, argv); - rb_apply(handler, rb_intern("call"), args); + result = rb_apply(handler, rb_intern("call"), args); ary2ptr_dispparams(argv, pdispparams); } else { - rb_apply(handler, rb_intern("call"), args); + result = rb_apply(handler, rb_intern("call"), args); } + + if (pvarResult) { + ole_val2variant(result, pvarResult); + } + return NOERROR; } |