Code:
/ DotNET / DotNET / 8.0 / untmp / WIN_WINDOWS / lh_tools_devdiv_wpf / Windows / wcp / Core / System / Windows / ContentOperations.cs / 1 / ContentOperations.cs
namespace System.Windows { ////// This interface defines the common methods and services available from a ContentElement. /// public static class ContentOperations { ////// Get the Visual parent of this ContentElement. /// public static DependencyObject GetParent(ContentElement reference) { if(reference == null) { throw new ArgumentNullException("reference"); } return reference._parent; } ////// Set the Visual parent of this ContentElement. /// ////// This is different than Visuals. For Visuals, you have to /// Add/Remove the visual from a children collection to change /// the parent. I think it is a better model, but I don't /// know if we want to expose a full children collection for /// content elements. /// public static void SetParent(ContentElement reference, DependencyObject parent) { if(reference == null) { throw new ArgumentNullException("reference"); } DependencyObject oldParent = reference._parent; reference._parent = parent; // Raise content parent changed notification reference.OnContentParentChanged(oldParent); } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. // Copyright (c) Microsoft Corporation. All rights reserved.
Link Menu
This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- TableCell.cs
- SignedPkcs7.cs
- CheckBox.cs
- BatchStream.cs
- selecteditemcollection.cs
- CreateUserErrorEventArgs.cs
- NotConverter.cs
- BaseParser.cs
- ContentElementAutomationPeer.cs
- HashCoreRequest.cs
- OleDbConnectionInternal.cs
- DelegateArgumentValue.cs
- _ProxyRegBlob.cs
- ListViewItemMouseHoverEvent.cs
- _HeaderInfoTable.cs
- ReadOnlyDictionary.cs
- WinEventTracker.cs
- DesignerActionKeyboardBehavior.cs
- Literal.cs
- PriorityRange.cs
- IsolatedStorageFile.cs
- ObjectDataSourceDisposingEventArgs.cs
- SqlServer2KCompatibilityAnnotation.cs
- MSAAEventDispatcher.cs
- MatchingStyle.cs
- ProofTokenCryptoHandle.cs
- EventPropertyMap.cs
- PropertyMetadata.cs
- CustomValidator.cs
- DrawListViewColumnHeaderEventArgs.cs
- DeploymentExceptionMapper.cs
- TextCollapsingProperties.cs
- tooltip.cs
- ParsedAttributeCollection.cs
- GridEntryCollection.cs
- BamlRecordWriter.cs
- EntityContainerEmitter.cs
- ImageIndexConverter.cs
- WebBrowser.cs
- DrawTreeNodeEventArgs.cs
- IImplicitResourceProvider.cs
- LinearKeyFrames.cs
- Util.cs
- CharEnumerator.cs
- DataFieldCollectionEditor.cs
- TemplateControlParser.cs
- UpDownEvent.cs
- VectorAnimation.cs
- AppSecurityManager.cs
- InheritedPropertyChangedEventArgs.cs
- LayeredChannelListener.cs
- AcceleratedTokenAuthenticator.cs
- BindingExpression.cs
- FontSourceCollection.cs
- ToolStripItemImageRenderEventArgs.cs
- ElementMarkupObject.cs
- PropertyGridEditorPart.cs
- UIPermission.cs
- DateTimeFormatInfo.cs
- ContainerParaClient.cs
- DES.cs
- AbstractSvcMapFileLoader.cs
- WebControlsSection.cs
- TextProperties.cs
- SelectionProviderWrapper.cs
- AutomationElementCollection.cs
- _Win32.cs
- PolyQuadraticBezierSegment.cs
- SoapMessage.cs
- WebPartEventArgs.cs
- Compress.cs
- TextFormatter.cs
- CodeDOMUtility.cs
- StartUpEventArgs.cs
- DoubleAnimationUsingPath.cs
- Token.cs
- ColumnHeaderConverter.cs
- GridViewDeletedEventArgs.cs
- PrefixHandle.cs
- TextRangeEdit.cs
- CqlLexer.cs
- SignatureToken.cs
- XmlSortKey.cs
- ControlParameter.cs
- ToolboxSnapDragDropEventArgs.cs
- WebUtil.cs
- HttpHeaderCollection.cs
- MultipleFilterMatchesException.cs
- SimpleTypeResolver.cs
- BindingContext.cs
- TextBounds.cs
- DataSysAttribute.cs
- ToolStripPanelDesigner.cs
- ActivationServices.cs
- WebPartHeaderCloseVerb.cs
- AccessibleObject.cs
- TemplateParser.cs
- PenCursorManager.cs
- Stack.cs
- ButtonBaseAutomationPeer.cs