/// <summary> /// Attaches sciter to the host control. Control handle should be created at this point /// </summary> public void AttachToControl() { View = SciterView.Attach(Control.Handle, this); if (_loadHtmlRequest != null) { _loadHtmlRequest(View); } }
/// <summary> /// Attaches SciterView to the existing window /// </summary> public static SciterView Attach(IntPtr handle, ISciterHost host) { #region Parameters checking if (handle == IntPtr.Zero) { throw new ArgumentException("handle"); } if (host == null) { throw new ArgumentNullException("host"); } #endregion SciterView view = new SciterView(); view.Host = host; view.HandleInternal = handle; view.Hook = WindowHook.Install(handle, view.ProcessMessage); view.InitializeSciter(); return(view); }