static object OnCoerceValueContentProperty(DependencyObject d, object baseValue) { DockableFloatingWindow fl = ((DockableFloatingWindow)d); if (fl.Content != null) { throw new InvalidOperationException("Content on floating windows can't be set more than one time."); } if (!(baseValue is DockableContent) && !(baseValue is DockablePane)) { throw new InvalidOperationException("Content must be of type DockableContent or DockablePane"); } FloatingDockablePane paneToReturn = null; if (baseValue is DockableContent) { paneToReturn = new FloatingDockablePane(fl, baseValue as DockableContent); } else if (baseValue is DockablePane) { paneToReturn = new FloatingDockablePane(fl, baseValue as DockablePane); } return(paneToReturn); }
internal FloatingDockablePane(DockableFloatingWindow floatingWindow, DockableContent contentToTransfer) { _floatingWindow = floatingWindow; _contentToTransfer = contentToTransfer; }
internal FloatingDockablePane(DockableFloatingWindow floatingWindow, DockablePane paneToTransfer) { _floatingWindow = floatingWindow; _paneToTransfer = paneToTransfer; }