Пример #1
0
 /// <summary>
 /// Set the return value for the <see cref="CfrApp.GetResourceBundleHandler"/> render process callback.
 /// Calling SetReturnValue() more then once per callback or from different event handlers will cause an exception to be thrown.
 /// </summary>
 public void SetReturnValue(CfrResourceBundleHandler returnValue)
 {
     if (returnValueSet)
     {
         throw new CfxException("The return value has already been set");
     }
     m_returnValue  = returnValue;
     returnValueSet = true;
 }
Пример #2
0
            /// <summary>
            /// Set the return value for the <see cref="CfrApp.GetResourceBundleHandler"/> render process callback.
            /// Calling SetReturnValue() more then once per callback or from different event handlers will cause an exception to be thrown.
            /// </summary>
            public void SetReturnValue(CfrResourceBundleHandler returnValue)
            {
                if (returnValueSet)
                {
                    throw new CfxException("The return value has already been set");
                }
                var call = new CfxGetResourceBundleHandlerSetReturnValueRenderProcessCall();

                call.eventArgsId = eventArgsId;
                call.value       = CfrObject.Unwrap(returnValue);
                call.RequestExecution(CfxRemoteCallContext.CurrentContext.connection);
                returnValueSet = true;
            }