/// <summary>
        /// Create a new router with the specified configuration.
        /// </summary>
        public CefMessageRouterBrowserSide(CefMessageRouterConfig config)
        {
            if (!config.Validate()) throw new ArgumentException("Invalid configuration.");

            _config = config;
            _queryMessageName = config.JSQueryFunction + CefMessageRouter.MessageSuffix;
            _cancelMessageName = config.JSCancelFunction + CefMessageRouter.MessageSuffix;
        }
示例#2
0
        /// <summary>
        /// Create a new router with the specified configuration.
        /// </summary>
        public CefMessageRouterRendererSide(CefMessageRouterConfig config)
        {
            if (!config.Validate())
            {
                throw new ArgumentException("Invalid configuration.");
            }

            _config            = config;
            _queryMessageName  = config.JSQueryFunction + CefMessageRouter.MessageSuffix;
            _cancelMessageName = config.JSCancelFunction + CefMessageRouter.MessageSuffix;
        }
示例#3
0
 public V8HandlerImpl(CefMessageRouterRendererSide router, CefMessageRouterConfig config)
 {
     _router    = router;
     _config    = config;
     _contextId = CefMessageRouter.ReservedId;
 }
示例#4
0
 /// <summary>
 /// Create a new router with the specified configuration.
 /// </summary>
 public static CefMessageRouterRendererSide Create(CefMessageRouterConfig config)
 {
     return(new CefMessageRouterRendererSide(config));
 }
 // TODO: Dispose method ?
 /// <summary>
 /// Create a new router with the specified configuration.
 /// </summary>
 public static CefMessageRouterBrowserSide Create(CefMessageRouterConfig config)
 {
     return new CefMessageRouterBrowserSide(config);
 }
 public V8HandlerImpl(CefMessageRouterRendererSide router, CefMessageRouterConfig config)
 {
     _router = router;
     _config = config;
     _contextId = CefMessageRouter.ReservedId;
 }