/// <summary> /// </summary> private void OnParentResize(object src, EventArgs e) { if (tridentView != null) { Interop.COMRECT r = new Interop.COMRECT(); Interop.GetClientRect(hostControl.Handle, r); tridentView.SetRect(r); } }
/// <summary> /// </summary> public void ActivateMSHTML() { Debug.Assert(tridentOleObject != null, "How'd we get here when trident is null!"); try { Interop.COMRECT r = new Interop.COMRECT(); Interop.GetClientRect(hostControl.Handle, r); tridentOleObject.DoVerb(Interop.OLEIVERB_UIACTIVATE, Interop.NullIntPtr, (Interop.IOleClientSite) this, 0, hostControl.Handle, r); } catch (Exception e) { Debug.Fail(e.ToString()); } }
/////////////////////////////////////////////////////////////////////////// // Interop.IOleDocumentSite Implementation public int ActivateMe(Interop.IOleDocumentView pViewToActivate) { Debug.Assert(pViewToActivate != null, "Expected the view to be non-null"); if (pViewToActivate == null) { return(Interop.E_INVALIDARG); } Interop.COMRECT r = new Interop.COMRECT(); Interop.GetClientRect(hostControl.Handle, r); tridentView = pViewToActivate; tridentView.SetInPlaceSite((Interop.IOleInPlaceSite) this); tridentView.UIActivate(1); tridentView.SetRect(r); tridentView.Show(1); return(Interop.S_OK); }
public int OnPosRectChange(Interop.COMRECT lprcPosRect) { // TODO: Add DocHostUIHandler.OnPosRectChange implementation return(0); }
public void GetWindowContext(out Interop.IOleInPlaceFrame ppFrame, out Interop.IOleInPlaceUIWindow ppDoc, Interop.COMRECT lprcPosRect, Interop.COMRECT lprcClipRect, Interop.tagOIFI lpFrameInfo) { // TODO: Add DocHostUIHandler.GetWindowContext implementation ppFrame = null; ppDoc = null; }
public int ResizeBorder(Interop.COMRECT rect, Interop.IOleInPlaceUIWindow doc, bool fFrameWindow) { return(Interop.E_NOTIMPL); }
public void SetBorderSpace(Interop.COMRECT pborderwidths) { throw new COMException(String.Empty, Interop.E_NOTIMPL); }
/////////////////////////////////////////////////////////////////////////// // Interop.IOleInPlaceFrame Implementation public void GetBorder(Interop.COMRECT lprectBorder) { throw new COMException(String.Empty, Interop.E_NOTIMPL); }
public int OnPosRectChange(Interop.COMRECT lprcPosRect) { return(Interop.S_OK); }
public void GetWindowContext(out Interop.IOleInPlaceFrame ppFrame, out Interop.IOleInPlaceUIWindow ppDoc, Interop.COMRECT lprcPosRect, Interop.COMRECT lprcClipRect, Interop.tagOIFI lpFrameInfo) { ppFrame = (Interop.IOleInPlaceFrame) this; ppDoc = null; Interop.GetClientRect(hostControl.Handle, lprcPosRect); Interop.GetClientRect(hostControl.Handle, lprcClipRect); lpFrameInfo.cb = Marshal.SizeOf(typeof(Interop.tagOIFI)); lpFrameInfo.fMDIApp = 0; lpFrameInfo.hwndFrame = hostControl.Handle; lpFrameInfo.hAccel = Interop.NullIntPtr; lpFrameInfo.cAccelEntries = 0; }