Ejemplo n.º 1
0
 protected override ComUnwrappedMetaObject UnwrapSelf()
 {
     return(new ComUnwrappedMetaObject(
                ComObject.RcwFromComObject(Expression),
                IDispatchRestriction(),
                _self.RuntimeCallableWrapper
                ));
 }
Ejemplo n.º 2
0
 protected virtual ComUnwrappedMetaObject UnwrapSelf()
 {
     return(new ComUnwrappedMetaObject(
                ComObject.RcwFromComObject(Expression),
                Restrictions.Merge(Restrictions.GetTypeRestriction(Expression, LimitType)),
                ((ComObject)Value).RuntimeCallableWrapper
                ));
 }
Ejemplo n.º 3
0
        private MetaObject BindEvent(ComEventDesc @event)
        {
            // BoundDispEvent CreateComEvent(object rcw, Guid sourceIid, int dispid)
            Expression result =
                Expression.Call(
                    typeof(ComRuntimeHelpers).GetMethod("CreateComEvent"),
                    ComObject.RcwFromComObject(Expression),
                    Expression.Constant(@event.sourceIID),
                    Expression.Constant(@event.dispid)
                    );

            return(new MetaObject(
                       result,
                       IDispatchRestriction()
                       ));
        }