public WindowsEvents(Interop.IHTMLWindow2 window, IHtmlEditor editor, IHtmlWindow htmlWindow) { this.window = window; this.editor = editor; this.htmlWindow = (GuruComponents.Netrix.WebEditing.Documents.HtmlWindow)htmlWindow; this.ConnectWindow(); this.ConnectDocument(); }
private Interop.IHTMLEventObj GetEventObject() { if (_element == null) { return(null); } _document = (Interop.IHTMLDocument2) this._element.GetDocument(); Interop.IHTMLWindow2 window1 = _document.GetParentWindow(); return(window1.@event); }
protected HtmlEvents(IElement _element) { this._element = _element; Interop.IHTMLDocument2 _document = _element.HtmlEditor.GetActiveDocument(false); if (_document == null) { return; } window = _document.GetParentWindow(); }
internal HtmlWindow(Interop.IHTMLWindow2 window, IHtmlEditor editor) { this.editor = editor; try { this.window = window.parent; doc = window.document; } catch { } }
private Interop.IHTMLEventObj GetEventObject() { _document = (Interop.IHTMLDocument2) this._element.GetDocument(); try { Interop.IHTMLWindow2 window1 = _document.GetParentWindow(); return(window1.@event); } catch { return(null); } }
internal FrameWindow(Interop.IHTMLWindow2 window, MSHTMLSite relatedSite, HtmlEditor htmlEditor) { this._relatedSite = relatedSite; this.window = window; this.doc = (Interop.IHTMLDocument2)window.document; this.url = ((Interop.IHTMLLocation)((Interop.IHTMLWindow2)doc.GetParentWindow()).location).href; this.body = (Interop.IHTMLElement3)doc.GetBody(); this.framebase = ((Interop.IHTMLWindow4)window).frameElement; this.htmlFormatter = new HtmlFormatter(); this.CommandTarget = (Interop.IOleCommandTarget)doc; this.winEvents = new FrameEvents(window, htmlEditor); this.winEvents.Activate += new EventHandler(winEvents_Activate); this.winEvents.DeActivate += new EventHandler(winEvents_DeActivate); this.nativeElement = (FrameElement)htmlEditor.GenericElementFactory.CreateElement(framebase as Interop.IHTMLElement); }
public FrameEvents(Interop.IHTMLWindow2 window, IHtmlEditor editor) : base(window, editor, new HtmlWindow(window, editor)) { }